diff --git a/run_tip_generator.sh b/run_tip_generator.sh new file mode 100755 index 0000000..d075e9c --- /dev/null +++ b/run_tip_generator.sh @@ -0,0 +1,4 @@ +#!/bin/bash +cd "/Users/sebastianfrohlich/Projekte/Lotto" +source venv/bin/activate +python scripts/automation/weekly_tip_generator.py diff --git a/scripts/automation/com.lotto.weekly.plist b/scripts/automation/com.lotto.weekly.plist index a0de550..13a3d8f 100644 --- a/scripts/automation/com.lotto.weekly.plist +++ b/scripts/automation/com.lotto.weekly.plist @@ -2,22 +2,16 @@ - Label com.lotto.weekly - ProgramArguments - /bin/bash - -c - cd "/Users/sebastianfrohlich/Library/Mobile Documents/com~apple~CloudDocs/Jupyter Notebooks/Lotto" && source venv/bin/activate && python scripts/automation/weekly_tip_generator.py 2>&1 | tee -a logs/launchagent.log + /Users/sebastianfrohlich/Projekte/Lotto/run_tip_generator.sh - StartCalendarInterval - Weekday 2 @@ -26,7 +20,6 @@ Minute 0 - Weekday 5 @@ -37,34 +30,28 @@ - WorkingDirectory - /Users/sebastianfrohlich/Library/Mobile Documents/com~apple~CloudDocs/Jupyter Notebooks/Lotto + /Users/sebastianfrohlich/Projekte/Lotto - StandardOutPath - /Users/sebastianfrohlich/Library/Mobile Documents/com~apple~CloudDocs/Jupyter Notebooks/Lotto/logs/stdout.log + /Users/sebastianfrohlich/Projekte/Lotto/logs/stdout.log StandardErrorPath - /Users/sebastianfrohlich/Library/Mobile Documents/com~apple~CloudDocs/Jupyter Notebooks/Lotto/logs/stderr.log + /Users/sebastianfrohlich/Projekte/Lotto/logs/stderr.log - RunAtLoad - EnvironmentVariables PATH - /usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin + /opt/homebrew/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin LANG de_DE.UTF-8 - LaunchOnlyOnce - Nice 10 diff --git a/scripts/automation/weekly_tip_generator.py b/scripts/automation/weekly_tip_generator.py index e5ac531..e6e1ebc 100644 --- a/scripts/automation/weekly_tip_generator.py +++ b/scripts/automation/weekly_tip_generator.py @@ -271,7 +271,7 @@ def main(): parser.add_argument( '--data-dir', type=str, - default="/Users/sebastianfrohlich/Library/Mobile Documents/com~apple~CloudDocs/Jupyter Notebooks/Lotto/data", + default="/Users/sebastianfrohlich/Projekte/Lotto/data", help='Daten-Verzeichnis' )