2018-07-14 04:42:15 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2018-08-21 01:52:25 +00:00
|
|
|
[ -z "$1" ] || cd $1
|
2018-07-14 04:42:15 +00:00
|
|
|
|
2018-09-02 08:27:39 +00:00
|
|
|
if [ -d ".test" ]; then
|
2018-07-14 04:42:15 +00:00
|
|
|
printf "\033[0;31mEnvironment backup already exists!\033[0m\n"
|
|
|
|
else
|
|
|
|
mkdir .test
|
2018-08-21 01:52:25 +00:00
|
|
|
cp Marlin/Configuration*.h .test/
|
|
|
|
[ -f Marlin/_Bootscreen.h ] && cp Marlin/_Bootscreen.h .test/
|
|
|
|
[ -f Marlin/_Statusscreen.h ] && cp Marlin/_Statusscreen.h .test/
|
2018-09-02 08:27:39 +00:00
|
|
|
cp -r Marlin/src/pins .test/pins
|
2018-07-14 04:42:15 +00:00
|
|
|
printf "\033[0;32mEnvironment Backup created\033[0m\n"
|
|
|
|
fi
|