mirror of
https://github.com/dw-0/kiauh.git
synced 2025-12-18 21:24:28 +05:00
fix: typo
This commit is contained in:
@@ -126,19 +126,21 @@ install_kiauh_macros(){
|
||||
path=$(echo $config | rev | cut -d"/" -f2- | rev)
|
||||
if [ ! -f $path/kiauh_macros.cfg ]; then
|
||||
### copy kiauh_macros.cfg to config location
|
||||
status_msg "Creating macro config file ..."
|
||||
cp ${SRCDIR}/kiauh/resources/kiauh_macros.cfg $path
|
||||
ok_msg "$path/kiauh_macros.cfg created!"
|
||||
### write the include to the very first line of the printer.cfg
|
||||
sed -i "1 i [include kiauh_macros.cfg]" $path/printer.cfg
|
||||
ok_msg "$path/kiauh_macros.cfg created!"
|
||||
fi
|
||||
done
|
||||
### handle single printer.cfg
|
||||
elif [ -f $klipper_cfg_loc/printer.cfg ] && [ ! -f $klipper_cfg_loc/kiauh_macros.cfg ]; then
|
||||
### copy kiauh_macros.cfg to config location
|
||||
status_msg "Creating macro config file ..."
|
||||
cp ${SRCDIR}/kiauh/resources/kiauh_macros.cfg $klipper_cfg_loc
|
||||
ok_msg "$klipper_cfg_loc/kiauh_macros.cfg created!"
|
||||
### write the include to the very first line of the printer.cfg
|
||||
sed -i "1 i [include kiauh_macros.cfg]" $klipper_cfg_loc/printer.cfg
|
||||
ok_msg "$klipper_cfg_loc/kiauh_macros.cfg created!"
|
||||
fi
|
||||
### restart klipper service to parse the modified printer.cfg
|
||||
klipper_service "restart"
|
||||
|
||||
Reference in New Issue
Block a user