From: Richard Jones Date: Thu, 30 Jul 2009 14:26:13 +0000 (+0100) Subject: Don't use relative paths, make people set $PATH. X-Git-Tag: 2.4~1 X-Git-Url: http://git.annexia.org/?a=commitdiff_plain;h=d42e3067d9fe488acd20a8db8c936fe3f53223e3;p=febootstrap.git Don't use relative paths, make people set $PATH. --- diff --git a/README b/README index ffc6608..8551df9 100644 --- a/README +++ b/README @@ -47,6 +47,12 @@ Building and installing make sudo make install +Note, if you want to run the scripts locally without installing, +you have to set the $PATH to the current directory, ie: + + PATH=$(pwd):$PATH + febootstrap [...] + Feedback and bugs ----------------- diff --git a/examples/README b/examples/README index 9660c0c..c52e7b0 100644 --- a/examples/README +++ b/examples/README @@ -2,3 +2,9 @@ You should read and edit these scripts before running them! You don't need to be root, in fact, you *shouldn't* be root when running these scripts! + +If you want to run the scripts without installing febootstrap, +then you need to make your $PATH point to the top build +directory, eg: + + PATH=$(pwd)/..:$PATH diff --git a/examples/guestfs-test.sh b/examples/guestfs-test.sh index 8092ff2..f253969 100755 --- a/examples/guestfs-test.sh +++ b/examples/guestfs-test.sh @@ -25,7 +25,7 @@ if [ ! -e vmlinuz -o ! -e guest-image ]; then exit 1 fi -../febootstrap \ +febootstrap \ -i bash \ -i coreutils \ -i lvm2 \ @@ -36,7 +36,7 @@ fi fedora-10 ./guestfs $1 echo -n "Before minimization: "; du -sh guestfs -../febootstrap-minimize --all ./guestfs +febootstrap-minimize --all ./guestfs echo -n "After minimization: "; du -sh guestfs # Create the /init which will scan for and enable all LVM volume groups. @@ -59,11 +59,11 @@ __EOF__ chmod +x init } export -f create_init -../febootstrap-run ./guestfs -- bash -c create_init +febootstrap-run ./guestfs -- bash -c create_init # Convert the filesystem to an initrd image. -../febootstrap-to-initramfs ./guestfs > guestfs-initrd.img +febootstrap-to-initramfs ./guestfs > guestfs-initrd.img # Now run qemu to boot this guestfs system. diff --git a/examples/minimal-filesystem.sh b/examples/minimal-filesystem.sh index 497d209..e1766a9 100755 --- a/examples/minimal-filesystem.sh +++ b/examples/minimal-filesystem.sh @@ -24,12 +24,12 @@ if [ ! -e vmlinuz ]; then exit 1 fi -../febootstrap -i bash -i coreutils fedora-10 ./minimal $1 +febootstrap -i bash -i coreutils fedora-10 ./minimal $1 # ... but let's minimize it aggressively. echo -n "Before minimization: "; du -sh minimal -../febootstrap-minimize --all --pack-executables ./minimal +febootstrap-minimize --all --pack-executables ./minimal echo -n "After minimization: "; du -sh minimal # Create the /init which is just a simple script to give users an @@ -47,11 +47,11 @@ __EOF__ chmod +x /init } export -f create_init -../febootstrap-run ./minimal -- bash -c create_init +febootstrap-run ./minimal -- bash -c create_init # Convert the filesystem to an initrd image. -../febootstrap-to-initramfs ./minimal > minimal-initrd.img +febootstrap-to-initramfs ./minimal > minimal-initrd.img # This is needed because of crappiness with qemu.