Browse Source

Merge pull request #55 from iamarcel/fix-command-location

Dyamically get the `freedombone` command
Bob Mottram 10 years ago
parent
commit
ec83f3c171
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      src/freedombone-prep

+ 1
- 1
src/freedombone-prep View File

243
 $SUDO sed -i "/nameserver $NAMESERVER1/a\nameserver $NAMESERVER2" $MICROSD_MOUNT_POINT/$ROOTFS/etc/resolv.conf
243
 $SUDO sed -i "/nameserver $NAMESERVER1/a\nameserver $NAMESERVER2" $MICROSD_MOUNT_POINT/$ROOTFS/etc/resolv.conf
244
 
244
 
245
 # copy the commands to the card
245
 # copy the commands to the card
246
-$SUDO cp -f /usr/local/bin/freedombone* $MICROSD_MOUNT_POINT/$ROOTFS/usr/local/bin/
246
+$SUDO cp -f $(which freedombone)* $MICROSD_MOUNT_POINT/$ROOTFS/usr/local/bin/
247
 if [ ! -f $MICROSD_MOUNT_POINT/$ROOTFS/usr/local/bin/freedombone ]; then
247
 if [ ! -f $MICROSD_MOUNT_POINT/$ROOTFS/usr/local/bin/freedombone ]; then
248
     echo 'There was a problem with writing freedombone commands to the SD card'
248
     echo 'There was a problem with writing freedombone commands to the SD card'
249
     exit 8736
249
     exit 8736