Scott Lahteine
6 years ago
3 changed files with 15 additions and 45 deletions
@ -1,24 +1,14 @@ |
|||||
#!/usr/bin/env bash |
#!/usr/bin/env bash |
||||
|
|
||||
if [ ! -z "$1" ]; then |
[ -z "$1" ] || cd $1 |
||||
cd $1 |
|
||||
fi |
|
||||
|
|
||||
if [ -d ".test" ]; then |
if [ -d ".test" ]; then |
||||
printf "\033[0;31mEnvironment backup already exists!\033[0m\n" |
printf "\033[0;31mEnvironment backup already exists!\033[0m\n" |
||||
else |
else |
||||
mkdir .test |
mkdir .test |
||||
cp Marlin/Configuration.h .test/Configuration.h |
cp Marlin/Configuration*.h .test/ |
||||
cp Marlin/Configuration_adv.h .test/Configuration_adv.h |
[ -f Marlin/_Bootscreen.h ] && cp Marlin/_Bootscreen.h .test/ |
||||
|
[ -f Marlin/_Statusscreen.h ] && cp Marlin/_Statusscreen.h .test/ |
||||
if [ -f Marlin/_Bootscreen.h ]; then |
|
||||
cp Marlin/_Bootscreen.h .test/_Bootscreen.h |
|
||||
fi |
|
||||
|
|
||||
if [ -f Marlin/_Statusscreen.h ]; then |
|
||||
cp Marlin/_Statusscreen.h .test/_Statusscreen.h |
|
||||
fi |
|
||||
|
|
||||
cp -r Marlin/src/pins .test/pins |
cp -r Marlin/src/pins .test/pins |
||||
printf "\033[0;32mEnvironment Backup created\033[0m\n" |
printf "\033[0;32mEnvironment Backup created\033[0m\n" |
||||
fi |
fi |
||||
|
@ -1,29 +1,13 @@ |
|||||
#!/usr/bin/env bash |
#!/usr/bin/env bash |
||||
|
|
||||
if [ -d ".pioenvs" ]; then |
[ -d ".pioenvs" ] && rm -r .pioenvs |
||||
rm -r .pioenvs |
[ -d ".piolibdeps" ] && rm -r .piolibdeps |
||||
fi |
[ -d ".piolib" ] && rm -r .piolib |
||||
|
|
||||
if [ -d ".piolibdeps" ]; then |
|
||||
rm -r .piolibdeps |
|
||||
fi |
|
||||
|
|
||||
if [ -d ".piolib" ]; then |
|
||||
rm -r .piolib |
|
||||
fi |
|
||||
|
|
||||
if [ ! -z "$1" ]; then |
if [ ! -z "$1" ]; then |
||||
if [ $1 = "--deep" ]; then |
if [ $1 = "--deep" ]; then |
||||
if [ -d "~/.platformio/packages" ]; then |
[ -d "~/.platformio/packages" ] && rm -r ~/.platformio/packages/* |
||||
rm -r ~/.platformio/packages/* |
[ -d "~/.platformio/platforms" ] && rm -r ~/.platformio/platforms/* |
||||
fi |
[ -d "~/.platformio/.cache" ] && rm -r ~/.platformio/.cache/* |
||||
|
|
||||
if [ -d "~/.platformio/platforms" ]; then |
|
||||
rm -r ~/.platformio/platforms/* |
|
||||
fi |
|
||||
|
|
||||
if [ -d "~/.platformio/.cache" ]; then |
|
||||
rm -r ~/.platformio/.cache/* |
|
||||
fi |
|
||||
fi |
fi |
||||
fi |
fi |
||||
|
Loading…
Reference in new issue