From 34ae230569d04ccf03b8bd71a9941c395c901350 Mon Sep 17 00:00:00 2001 From: Anthony Cieri Date: Wed, 10 Jul 2024 20:09:58 -0700 Subject: [PATCH] feat: Git pull in setup.sh --- src/pi_startup/auto_update_service/setup.sh | 12 +++++++++--- src/pi_startup/startup_stuff/localtesting.sh | 2 ++ src/pi_startup/startup_stuff/test.py | 0 src/pi_startup/startup_stuff/test.sh | 2 +- 4 files changed, 12 insertions(+), 4 deletions(-) mode change 100755 => 100644 src/pi_startup/auto_update_service/setup.sh mode change 100755 => 100644 src/pi_startup/startup_stuff/test.py mode change 100755 => 100644 src/pi_startup/startup_stuff/test.sh diff --git a/src/pi_startup/auto_update_service/setup.sh b/src/pi_startup/auto_update_service/setup.sh old mode 100755 new mode 100644 index 15e86a0..939d8d9 --- a/src/pi_startup/auto_update_service/setup.sh +++ b/src/pi_startup/auto_update_service/setup.sh @@ -1,11 +1,17 @@ -# No shebang, not executable run this with bash directly +# No shebang, not executable. Run this with bash directly # Test script # Runs some other scripts +git_dir='/home/pi/Documents/ug-pi/' + +cd git_dir + +git pull >> ~/Documents/setup.log + echo $(pwd) > testing.txt -/home/pi/Documents/ug-pi/src/pi_startup/startup_stuff/test.sh +bash ./src/pi_startup/startup_stuff/test.sh -python3 /home/pi/Documents/ug-pi/src/pi_startup/startup_stuff/test.py > ~/Documents/test_py_output.txt +python3 ./src/pi_startup/startup_stuff/test.py > ~/Documents/test_py_output.txt diff --git a/src/pi_startup/startup_stuff/localtesting.sh b/src/pi_startup/startup_stuff/localtesting.sh index ddfdee0..aa3ce88 100644 --- a/src/pi_startup/startup_stuff/localtesting.sh +++ b/src/pi_startup/startup_stuff/localtesting.sh @@ -1,2 +1,4 @@ +# No shebang, not executable. Run this with bash directly + python3 $1 > test_py_output.txt diff --git a/src/pi_startup/startup_stuff/test.py b/src/pi_startup/startup_stuff/test.py old mode 100755 new mode 100644 diff --git a/src/pi_startup/startup_stuff/test.sh b/src/pi_startup/startup_stuff/test.sh old mode 100755 new mode 100644 index 7a2e085..c3f5410 --- a/src/pi_startup/startup_stuff/test.sh +++ b/src/pi_startup/startup_stuff/test.sh @@ -1,5 +1,5 @@ -#! /bin/bash +# No shebang, not executable. Run this with bash directly # Makes a file somewhere