Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ tasks:
status:
# Don't do any of this if you aren't in a git repository; quote to avoid yaml intrepretering the ! as a node tag
# https://yaml.org/spec/1.2.2/#691-node-tags
- '! test -d .git'
- '! git rev-parse --git-dir'
cmds:
- uv tool install pre-commit
# Don't run this in pipelines
Expand Down Expand Up @@ -128,9 +128,9 @@ tasks:
env:
GH_TOKEN:
sh: |
if [[ -n "${GH_TOKEN:-}" ]]; then
if [ -n "${GH_TOKEN:-}" ]; then
echo "${GH_TOKEN}"
elif command -v gh &> /dev/null && gh auth token &> /dev/null; then
elif gh auth token > /dev/null 2>&1; then
gh auth token
fi
cmds:
Expand Down
8 changes: 4 additions & 4 deletions {{cookiecutter.project_name}}/Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ tasks:
- pyproject.toml
- uv.lock
preconditions:
- which uv
- uv --version
cmds:
# Sync dependencies with uv
- uv sync --frozen --all-extras
Expand All @@ -47,7 +47,7 @@ tasks:
status:
# Don't do any of this if you aren't in a git repository; quote to avoid yaml intrepretering the ! as a node tag
# https://yaml.org/spec/1.2.2/#691-node-tags
- '! test -d .git'
- '! git rev-parse --git-dir'
cmds:
- uv tool install pre-commit
# Don't run this in pipelines
Expand Down Expand Up @@ -205,9 +205,9 @@ tasks:
env:
GH_TOKEN:
sh: |
if [[ -n "${GH_TOKEN:-}" ]]; then
if [ -n "${GH_TOKEN:-}" ]; then
echo "${GH_TOKEN}"
elif command -v gh &> /dev/null && gh auth token &> /dev/null; then
elif gh auth token > /dev/null 2>&1; then
gh auth token
fi
cmds:
Expand Down
Loading