38 lines
688 B
YAML
38 lines
688 B
YAML
# https://taskfile.dev
|
|
|
|
version: "3"
|
|
|
|
vars:
|
|
YEAR: 2022
|
|
DAY:
|
|
sh: date '+%d' | perl -pe's/^0//'
|
|
DAY_FORMATTED:
|
|
sh: date '+%d'
|
|
GREETING: Hello, World!
|
|
|
|
tasks:
|
|
"precommit:init": pre-commit install -t pre-merge-commit -t pre-push
|
|
|
|
integrate:
|
|
cmds:
|
|
- git is-clean
|
|
- git co main
|
|
- git weld -
|
|
|
|
lint:fix:
|
|
cmds:
|
|
- npx prettier --write {{.CLI_ARGS | default "." }}
|
|
|
|
page:
|
|
cmds:
|
|
- firefox https://adventofcode.com/{{.YEAR}}/day/{{.DAY}}
|
|
|
|
download:
|
|
cmds:
|
|
- aoc download -d {{.DAY}} -o -p 2022/{{.DAY_FORMATTED}}/puzzle.md -i 2022/{{.DAY_FORMATTED}}/input
|
|
|
|
default:
|
|
cmds:
|
|
- echo "{{.GREETING}}"
|
|
silent: true
|