Fixed home reference for sed
This commit is contained in:
parent
b551aee9ee
commit
afbb0315c6
4
setup.sh
4
setup.sh
@ -97,9 +97,11 @@ echo.Cyan "Setup Moonraker"
|
|||||||
cd $ROOT_DIR/$PRINTER_NAME/printer_data/config
|
cd $ROOT_DIR/$PRINTER_NAME/printer_data/config
|
||||||
sed -i -e "s/PRINTERNAME/$PRINTER_NAME/g" "moonraker.conf"
|
sed -i -e "s/PRINTERNAME/$PRINTER_NAME/g" "moonraker.conf"
|
||||||
sed -i -e "s/pi/$USER/g" "moonraker.conf"
|
sed -i -e "s/pi/$USER/g" "moonraker.conf"
|
||||||
|
|
||||||
echo.Cyan "Setup Mainsail Config"
|
echo.Cyan "Setup Mainsail Config"
|
||||||
cd $ROOT_DIR/$PRINTER_NAME/mainsail-config
|
cd $ROOT_DIR/$PRINTER_NAME/mainsail-config
|
||||||
sed -i -e "s/~\/printer_data/$HOME\/$PRINTER_NAME\/printer_data/g" "client.cfg"
|
USABLE_HOME=`echo "$HOME" | sed -e 's/\//\\\//'`
|
||||||
|
sed -i -e "s/~\/printer_data/$USABLE_HOME\/$PRINTER_NAME\/printer_data/g" "client.cfg"
|
||||||
sed -i -e "s/pi/$USER/g" "client.cfg"
|
sed -i -e "s/pi/$USER/g" "client.cfg"
|
||||||
|
|
||||||
# Download Mainsail
|
# Download Mainsail
|
||||||
|
Loading…
Reference in New Issue
Block a user