articles := "./content/articles" docker_image := "homelab/docs" docker_tag := "latest" shortdate := `date +%F` [private] default: @just --list # Run the development server. [group('dev')] run: @swift run watch content Sources deploy # Create a new article with given name and tags. new-article name *tags: @echo "---" > {{articles}}/{{shortdate}}-{{name}}.md @echo "date: {{shortdate}}" >> {{articles}}/{{shortdate}}-{{name}}.md @echo "tags: `./scripts/join-tags.sh {{tags}}`" >> {{articles}}/{{shortdate}}-{{name}}.md @echo "---" >> {{articles}}/{{shortdate}}-{{name}}.md @echo {{articles}}/{{shortdate}}-{{name}}.md alias n := new-article latest-article: @echo "$(find {{articles}} -maxdepth 1 -mindepth 1 -type f | sort -nr | head -1)" alias l := latest-article [group('dev')] build: @docker build --tag {{docker_image}}:{{docker_tag}} .