From 57f650073afc9f8fb2c1bb9e970661c038cad316 Mon Sep 17 00:00:00 2001 From: Edward Date: Wed, 26 Nov 2025 15:11:28 -0600 Subject: [PATCH] Add invoke function for recording wins --- files/ts/bashrc | 9 +++++++-- files/ts/tasks.py | 42 +++++++++++++++++++++++++++++++++++++----- 2 files changed, 44 insertions(+), 7 deletions(-) diff --git a/files/ts/bashrc b/files/ts/bashrc index 56d0ff2..9c21777 100644 --- a/files/ts/bashrc +++ b/files/ts/bashrc @@ -117,13 +117,18 @@ if ! shopt -oq posix; then fi +# PyEnv export PYENV_ROOT="$HOME/.pyenv" [[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH" eval "$(pyenv init - bash)" eval "$(pyenv virtualenv-init -)" -eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" -source $HOME/envs/invoke/bin/activate +# Brew +eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" +# Invoke # from invoke --print-completion-script bash > ~/.invoke-complete.sh source $HOME/.invoke-complete.sh +source $HOME/.env + +source $HOME/envs/invoke/bin/activate diff --git a/files/ts/tasks.py b/files/ts/tasks.py index 2805fca..7818213 100644 --- a/files/ts/tasks.py +++ b/files/ts/tasks.py @@ -9,6 +9,19 @@ import os HOME = os.path.expanduser('~') TODAY = dt.now().strftime('%Y.%m.%d') +MONTH = dt.now().strftime('%m') +YEAR = dt.now().strftime('%Y') +JOURNAL = f"{HOME}/Journal/{YEAR}" + +SECDEV_LIMITED=os.environ.get('SECDEV_LIMITED') + + +# Helper functions for a consistent experience + +@task +def journal(c): + code(c, f'{HOME}/Journal') + def browse(c, url): c.run(f"firefox {url}") @@ -42,11 +55,17 @@ def timesheets(c): browse(c, "https://outlook.office.com/calendar/view/month") code(c, f"{HOME}/src/Learn_RobotFramework_IllinoisPTR") +@task(journal) +def daily(c): + '''Open daily reminders file for this month''' + code(c, f'{JOURNAL}/{MONTH}-daily.md') -@task + +@task(daily) def status(c): '''Check on status of priorities''' - browse('https://github.com/orgs/techservicesillinois/projects/10') + + browse(c, 'https://github.com/orgs/techservicesillinois/projects/10/views/11') @task @@ -54,15 +73,28 @@ def backlog(c): '''Prep for backlog grooming''' browse(c, 'https://github.com/orgs/techservicesillinois/projects/10/views/7') -JOURNAL = f"{HOME}/Journal" -@task +@task(journal) def retro(c): + '''Prep for team retrospective meeting''' + # Create and open retro notes file retro_file = f'{JOURNAL}/{TODAY}.Retro.md' if(not os.path.exists(retro_file)): c.run(f'{HOME}/envs/jinja/bin/jinja2 -D DATE={TODAY} {JOURNAL}/Retro.Template.md > {retro_file}') - code(c, retro_file) + # Close issues this sprint + browse(c, 'https://github.com/orgs/techservicesillinois/projects/10/views/5') + + # Shared folder for archiving Retro notes + browse(c, f'{SECDEV_LIMITED}') + + + +@task(journal) +def wins(c): + '''For recording team wins''' + code(c, f'{JOURNAL}/{YEAR}-Wins.md') + -- 2.47.3