[SOLVED] “fatal: Could not read bundle ‘/path/to/your/file.ext’.” during git clone

17
Jan
0

$ git clone /path/to/repo/*
Initialized empty Git repository in /path/to/file.ext/.git/
error: ‘/path/to/repo/file.ext’ does not look like a v2 bundle file
fatal: Could not read bundle ‘/path/to/repo/file.ext’.

Fortunately, it happened after I’d just done a serious site-wide rename of a bunch of files, and I decided to try cleaning the repository.

This solved everything:
$ git gc /path/to/repo

Bookmark and Share
Tagged as:

[SOLVED] Ubuntu Startup-manager killed my windows partition entry in GRUB2

8
Jan
0

The issue

I had a scary thing happen the other day: the windows xp entry on GRUB2’s boot screen went missing!  This happened shortly after the windows partition had been encrypted with a McAfee product.  Ubuntu didn’t remove the entry itself; it was actually only after I tried to make a change to the startup configuration using a program called Startup-manager (you may have it in System > Administration) that the windows entry was removed. It was bad enough that Ubuntu could no longer see any files on the windows partition (mounted as /windows), but now I had no way to boot into windows to retrieve files.

The fix

And of course, I had no freaking clue how to manually modify GRUB2’s startup screen.  But after some digging, I figured out how to do it.  This worked for me in Ubuntu 9.10 Karmic Koala.  Hopefully it will save someone else’s day:

  1. Figure out where windows is.  Is it /dev/sda1 (very likely)? /dev/sda2?  To do this:
    1. System > Administration > Disk Utility
    2. Click each partition and find the one which matches the size of your bootable windows parition and which, when selected, shows a partition type of HPFS/NTFS. Example:
    3. Note the location of the partition; it is the last line of the descriptors of the partition. In the screenshot above, mine is /dev/sda1.
  2. Press ALT+F2
  3. enter the command gksudo gedit /etc/grub.d/40_custom
  4. below the comments in this file, and below any other entries which may have been added by one thing or another, add the following:
    [/sourcecode]

    echo “Adding Windows XP on {LOCATION OF YOUR WINDOWS PARTITION}” >&2
    cat << EOF
    menuentry “Windows XP Professional (on {LOCATION OF YOUR WINDOWS PARTITION})” {
    insmod ntfs
    set root=(hd0,{JUST THE LAST NUMBER OF THE LOCATION OF YOUR WINDOWS PARTITION})
    drivemap -s (hd0) ${root}
    chainloader +1
    }
    EOF[/shortcode]

  5. Replace {LOCATION OF YOUR WINDOWS PARTITION} in the code above with the location of your windows partition.
  6. Replace {JUST THE LAST NUMBER OF THE LOCATION OF YOUR WINDOWS PARTITION} with the last number of the location of your windows partition. E.g. /dev/sda1 would be 1.Your file will now look something like this:
  7. Save the file and close the editor.
  8. Press ALT + F2.
  9. enter the command gksudo grub-mkconfig

That should be it.  When you reboot, you should see your windows as a bootable option again.

Morals

The moral of this tale is to avoid startup-manager for grub configuration changes unless you’ve not got funky partitions. Keep in mind that future versions of start-up manager may fix this issue; the version i’m using is 1.9.12-ubuntu1.

Credits

I would not have been able to troubleshoot this issue if it weren’t for the following gracious contributions to the global knowledgebase.

Bookmark and Share

[SOLVED] Screen Resolution resets to something undesired in Ubuntu 9.10 Karmic

30
Nov
2

Assuming you have a monitor that supports some high resolution, say 1680 x 1050, and you’re using an nvidia card:

  1. System > Administration > Hardware Drivers
  2. Make sure the latest recommended nvidia proprietary driver is activated (if not, do it and reboot)
  3. System > Preferences > Display (it should ask if you want to use the proprietary config screen – select ‘Yes’)
  4. Select X Server Configuration
  5. Set the resolution to what you want and ‘Apply’, then quit the nvidia-settings screen.
  6. System > Preferences > Display (when it asks this time, select ‘No’)
  7. Click ‘Apply’
  8. Click ‘Keep configuration’ (assuming everything looks OK)
  9. Click Close

When you reboot, everything should be preserved.  I still notice a flicker on the boot-up screen when I think it tries to reset it to something else, but it should stay at the resolution you specified.

Bookmark and Share

Experiment 20090618

19
Jun
3

Experiment 20090618

Just like Experiment 20090616 except now pulling in from the 100 Days blogs (the wordier ones – sorry, graphical people!) as Steve had suggested. I had to figure out where to split phrases, so I’m doing so on the following characters:

  • .
  • ,
  • !
  • ?
  • - (these are tricky because there are many ways to code a hyphen – I don’t account for any variations, just he stock keyboard hyphen)
  • \n (which is a ‘new line’ character, meaning the ‘end of a line’)
Bookmark and Share

Experiement 20090617 Placeholder

19
Jun
0

This is just a placeholder.  Don’t bother clicking to this for now.

Bookmark and Share

Experiment 20090616

16
Jun
9

Experiment 20090616

A fun, pointless script which plays a lot with randomness: random start/end color, start/end position, start/end size, number of objects, time before beginning animation, length of animation, selection of verbiage.

Bookmark and Share

Experiment 20090615

16
Jun
1

Experiment 20090615

A simple podcast player. Makes use of jw player from longtail video.  Also experiments with linking to jquery ui resources hosted at googleapis.  Using CDNs for commonly used javascript and css resources is cool because a) you don’t have to host it yourself, b) people’s browsers cache it, so it loads much more quickly, and c) google knows what the hell they’re doing, so they serve it in the best way possible.  The only down side is that if their site ever gets bogged down or they go offline, you’re kinda screwed.  Still, Google is pretty safe to bet on, so we web developers do.

Bookmark and Share

Experiment 20090614 Placeholder

14
Jun
0

This is a placeholder for my 2009-06-14 project.

Bookmark and Share

Experiment 20090613 Placeholder

14
Jun
0

This is a placeholder for my project for 2009-06-13.

Bookmark and Share

“Simple Spy” Wrapper

13
Jun
1

“Simple Spy” Wrapper

No time to explain right now.  Gotta run!

[UPDATE 2009-06-14] I just looked at this again and it had some bugs in it, which I fixed, plus it turns out I forgot to tag it 100 Days, so no one has seen it yet, most likely.  I’m also going to take this opportunity to explain the script a little bit.  I guess there was this site called ‘Simple Spy’ which used some sort of rotating script to achieve this effect in their side bar.  jqueryfordesigners.com, which looks to be an excellent resource for attractive jquery demos and tutorials, did a little demo and tutorial on how to ajaxify it to pull content in from whatever source one desired.  But I didn’t follow the tutorial to create mine.  I rolled my own wrapper.  ‘Wrappers’ are pieces of code which abstract the functionality of some other code.  Simply put, a wrapper usually makes life easier for the next programmer, because it handles the inner working for you and gives you just an easy-to-use subset of tools or configuration options.

In this case, my wrapper gives the user one configuration option, FEED_URL.  Since I plugged in Maggie’s feed URL, the demo features her content.  If we provide my feed URL, we’d get content loading from my web site.  Of course, a lot more documentation and use cases would need to be written to make this useful to anyone, but it’s a dandy start.

Based on demo here: http://jqueryfordesigners.com/ajax-spy/

Bookmark and Share