Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
16 changes: 8 additions & 8 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ jobs:
git -c user.email=ci@aspect.build -c user.name=CI commit -q -m "rendered ${{ matrix.preset }}"
# Normalize (buildifier + gazelle + format), mirroring the publish job.
bazel run --run_in_cwd @buildifier_prebuilt//buildifier -- -r . || true
aspect gazelle --task-key gazelle-${{ matrix.preset }} --check-only=false || true
aspect gazelle --task:name gazelle-${{ matrix.preset }} --check-only=false || true
case "${{ matrix.preset }}" in
minimal|scala|ruby) ;;
*) aspect format --task-key format-${{ matrix.preset }} --scope=all || true ;;
*) aspect format --task:name format-${{ matrix.preset }} --scope=all || true ;;
esac
git add -A
git -c user.email=ci@aspect.build -c user.name=CI commit -q --amend --no-edit || true
Expand All @@ -86,7 +86,7 @@ jobs:
# No separate build step: `aspect test` builds everything it needs.
- name: Test
working-directory: ${{ env.WS }}
run: aspect test --task-key test-${{ matrix.preset }} -- //...
run: aspect test --task:name test-${{ matrix.preset }} -- //...

# The steps below run the SAME tasks the generated project's CI
# (template/.github/workflows/ci.yaml) runs, with the same per-preset
Expand All @@ -97,34 +97,34 @@ jobs:
# buildifier always runs (Starlark; only needs buildifier_prebuilt).
- name: Buildifier
working-directory: ${{ env.WS }}
run: aspect buildifier --task-key buildifier-${{ matrix.preset }} --scope=all
run: aspect buildifier --task:name buildifier-${{ matrix.preset }} --scope=all

# gazelle runs for every preset (the stamped CI always has a gazelle job).
- name: Gazelle (no changes expected)
working-directory: ${{ env.WS }}
run: aspect gazelle --task-key gazelle-check-${{ matrix.preset }}
run: aspect gazelle --task:name gazelle-check-${{ matrix.preset }}

# Lint runs only for presets with a wired rules_lint aspect (matches the
# stamped CI's lint-job gating and .aspect/config.axl's aspects list).
# go/scala have no linter; rust lints via clippy (aspect_rules_lint_rust).
- name: Lint
if: ${{ !contains(fromJSON('["minimal","go","scala"]'), matrix.preset) }}
working-directory: ${{ env.WS }}
run: aspect lint --task-key lint-${{ matrix.preset }} -- //...
run: aspect lint --task:name lint-${{ matrix.preset }} -- //...

# format runs for every preset with a wired source formatter. scala/ruby
# have none; minimal has no languages (buildifier covers its Starlark).
- name: Format (no changes expected)
if: ${{ !contains(fromJSON('["minimal","scala","ruby"]'), matrix.preset) }}
working-directory: ${{ env.WS }}
run: aspect format --task-key format-${{ matrix.preset }} --scope=all
run: aspect format --task:name format-${{ matrix.preset }} --scope=all

# delivery runs for presets whose stamped CI has a delivery job (oci/stamp).
# --track-state=false --mode=always mirrors the stamped delivery job.
- name: Delivery
if: ${{ contains(fromJSON('["go","kitchen-sink"]'), matrix.preset) }}
working-directory: ${{ env.WS }}
run: aspect delivery --task-key delivery-${{ matrix.preset }} --track-state=false --mode=always
run: aspect delivery --task:name delivery-${{ matrix.preset }} --track-state=false --mode=always

# Execute the preset's user story — an executable-Markdown tutorial that
# builds/tests/extends the generated project. Run with `sh` (the ~~~ alias
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish-starters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,10 @@ jobs:
# format for sources (skip presets with no source formatter). --scope=all
# since there's no base ref to diff against. Then amend the commit.
bazel run --run_in_cwd @buildifier_prebuilt//buildifier -- -r . || true
aspect gazelle --task-key publish-gazelle --check-only=false || true
aspect gazelle --task:name publish-gazelle --check-only=false || true
case "${{ matrix.preset }}" in
minimal|scala|ruby) ;;
*) aspect format --task-key publish-format --scope=all || true ;;
*) aspect format --task:name publish-format --scope=all || true ;;
esac
git add -A
git commit -q --amend --no-edit
Expand Down
2 changes: 1 addition & 1 deletion dev.axl
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def _impl(ctx):
# NB: --preset has no static `values=` list because the valid presets are read
# at runtime from template-config.json (preset_flags fails on an unknown name).
render_preset = task(
name = "render-preset",
kind = "render-preset",
summary = "Render one template preset into an output directory",
implementation = _impl,
args = {
Expand Down
2 changes: 1 addition & 1 deletion template/.aspect/version.axl
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
# CI runner uses the same CLI. Bump it to upgrade.
#
# See https://aspect.build/docs/cli/install#pinning-a-version
version("2026.25.10")
version("2026.26.15")
12 changes: 6 additions & 6 deletions template/.github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- uses: aspect-build/setup-aspect@36c688a9bbb0c84d55d7eca31bf3215e9d265bff # v2026.24.1
with:
aspect-api-token: ${{ '{{' }} secrets.ASPECT_API_TOKEN {{ '}}' }}
- run: aspect test --task-key test -- //...
- run: aspect test --task:name test -- //...

gazelle:
runs-on: ubuntu-latest
Expand All @@ -35,7 +35,7 @@ jobs:
- uses: aspect-build/setup-aspect@36c688a9bbb0c84d55d7eca31bf3215e9d265bff # v2026.24.1
with:
aspect-api-token: ${{ '{{' }} secrets.ASPECT_API_TOKEN {{ '}}' }}
- run: aspect gazelle --task-key gazelle
- run: aspect gazelle --task:name gazelle

buildifier:
runs-on: ubuntu-latest
Expand All @@ -44,7 +44,7 @@ jobs:
- uses: aspect-build/setup-aspect@36c688a9bbb0c84d55d7eca31bf3215e9d265bff # v2026.24.1
with:
aspect-api-token: ${{ '{{' }} secrets.ASPECT_API_TOKEN {{ '}}' }}
- run: aspect buildifier --task-key buildifier
- run: aspect buildifier --task:name buildifier
{% if go or python or javascript or cpp or kotlin or rust or shell or java %}

format:
Expand All @@ -54,7 +54,7 @@ jobs:
- uses: aspect-build/setup-aspect@36c688a9bbb0c84d55d7eca31bf3215e9d265bff # v2026.24.1
with:
aspect-api-token: ${{ '{{' }} secrets.ASPECT_API_TOKEN {{ '}}' }}
- run: aspect format --task-key format
- run: aspect format --task:name format
{% endif %}
{# Only presets with a wired rules_lint aspect get a lint job (matches the
aspects list in .aspect/config.axl). go/scala have no linter. #}
Expand All @@ -67,7 +67,7 @@ jobs:
- uses: aspect-build/setup-aspect@36c688a9bbb0c84d55d7eca31bf3215e9d265bff # v2026.24.1
with:
aspect-api-token: ${{ '{{' }} secrets.ASPECT_API_TOKEN {{ '}}' }}
- run: aspect lint --task-key lint -- //...
- run: aspect lint --task:name lint -- //...
{% endif %}
{% if oci or stamp %}

Expand All @@ -83,5 +83,5 @@ jobs:
aspect-api-token: ${{ '{{' }} secrets.ASPECT_API_TOKEN {{ '}}' }}
# Selective delivery (change detection) requires the Aspect Workflows
# backend; on plain ephemeral runners deliver unconditionally.
- run: aspect delivery --task-key delivery --track-state=false --mode=always
- run: aspect delivery --task:name delivery --track-state=false --mode=always
{% endif %}
2 changes: 1 addition & 1 deletion user_stories/STRUCTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ The two non-language presets differ:
```
- **`aspect` vs `bazel`** — use `aspect build`/`aspect test` for the task-driven
commands; `bazel run` is fine for running a binary and capturing its output.
- **`--task-key` on `aspect test`** — pass `--task-key test-<preset>-story` so the
- **`--task:name` on `aspect test`** — pass `--task:name test-<preset>-story` so the
story's test run gets a distinct task identity from the CI `test` task it shares
a workspace with (otherwise their state tracking collides). One key per story.
- **BUILD generation** — run `aspect gazelle` for languages that support it; for
Expand Down
6 changes: 3 additions & 3 deletions user_stories/cpp.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/cpp` package. Build it, test it, and run it:

~~~sh
aspect build --task-key build-cpp-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/cpp:main
aspect test --task-key test-cpp-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/cpp:hello_test
aspect build --task:name build-cpp-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/cpp:main
aspect test --task:name test-cpp-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/cpp:hello_test
output=$(bazel run //hello/cpp:main)
echo "${output}" | grep -q "Hello, world!" || {
echo >&2 "Wanted output containing 'Hello, world!' but got '${output}'"
Expand Down Expand Up @@ -72,7 +72,7 @@ EOF
Build and run the new command:

~~~sh
aspect build --task-key build-cpp-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //src/greet:greet
aspect build --task:name build-cpp-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //src/greet:greet
output=$(bazel run //src/greet:greet)
echo "${output}" | grep -q "Greetings from Bazel" || {
echo >&2 "Wanted output containing 'Greetings from Bazel' but got '${output}'"
Expand Down
6 changes: 3 additions & 3 deletions user_stories/go.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/go` package. Build it, test it, and run it:

~~~sh
aspect build --task-key build-go-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/go:hello
aspect test --task-key test-go-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/go:hello_test
aspect build --task:name build-go-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/go:hello
aspect test --task:name test-go-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/go:hello_test
output=$(bazel run //hello/go:hello)
echo "${output}" | grep -q "Hello, world!" || {
echo >&2 "Wanted output containing 'Hello, world!' but got '${output}'"
Expand Down Expand Up @@ -71,7 +71,7 @@ bazel run //tools/gazelle:gazelle -- cmd/greet
Build and run the new command:

~~~sh
aspect build --task-key build-go-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:greet
aspect build --task:name build-go-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:greet
output=$(bazel run //cmd/greet:greet)
echo "${output}" | grep -q "Greetings from Bazel" || {
echo >&2 "Wanted output containing 'Greetings from Bazel' but got '${output}'"
Expand Down
6 changes: 3 additions & 3 deletions user_stories/java.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/java` package. Build it, test it, and run it:

~~~sh
aspect build --task-key build-java-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/java:hello
aspect test --task-key test-java-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/java:hello_test
aspect build --task:name build-java-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/java:hello
aspect test --task:name test-java-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/java:hello_test
output=$(bazel run //hello/java:hello)
echo "${output}" | grep -q "Hello, world!" || {
echo >&2 "Wanted output containing 'Hello, world!' but got '${output}'"
Expand Down Expand Up @@ -80,7 +80,7 @@ EOF
Build and run the new command:

~~~sh
aspect build --task-key build-java-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:greet
aspect build --task:name build-java-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:greet
output=$(bazel run //cmd/greet:greet)
echo "${output}" | grep -q "Greetings from Bazel" || {
echo >&2 "Wanted output containing 'Greetings from Bazel' but got '${output}'"
Expand Down
6 changes: 3 additions & 3 deletions user_stories/js.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/js` package. Build it, test it, and run it:

~~~sh
aspect build --task-key build-js-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/js:hello
aspect test --task-key test-js-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/js:hello_test
aspect build --task:name build-js-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/js:hello
aspect test --task:name test-js-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/js:hello_test
output=$(bazel run //hello/js:hello)
echo "${output}" | grep -q "Hello, world!" || {
echo >&2 "Wanted output containing 'Hello, world!' but got '${output}'"
Expand Down Expand Up @@ -100,7 +100,7 @@ EOF
Build and run the new command:

~~~sh
aspect build --task-key build-js-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:main
aspect build --task:name build-js-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:main
output=$(bazel run //cmd/greet:main)
echo "${output}" | grep -q "Greetings from Bazel" || {
echo >&2 "Wanted output containing 'Greetings from Bazel' but got '${output}'"
Expand Down
4 changes: 2 additions & 2 deletions user_stories/kitchen-sink.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ The `kitchen-sink` preset enables every supported language, and ships a tiny
tests green:

~~~sh
aspect build --task-key build-kitchen-sink-story --github-status-comments:enabled=false --github-status-checks:enabled=false //...
aspect test --task-key test-kitchen-sink-story --github-status-comments:enabled=false --github-status-checks:enabled=false //...
aspect build --task:name build-kitchen-sink-story --github-status-comments:enabled=false --github-status-checks:enabled=false //...
aspect test --task:name test-kitchen-sink-story --github-status-comments:enabled=false --github-status-checks:enabled=false //...
~~~

## Run a couple of the samples
Expand Down
6 changes: 3 additions & 3 deletions user_stories/kotlin.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/kotlin` package. Build it, test it, and run it:

~~~sh
aspect build --task-key build-kotlin-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/kotlin:hello
aspect test --task-key test-kotlin-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/kotlin:hello_test
aspect build --task:name build-kotlin-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/kotlin:hello
aspect test --task:name test-kotlin-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/kotlin:hello_test
output=$(bazel run //hello/kotlin:hello)
echo "${output}" | grep -q "Hello, world!" || {
echo >&2 "Wanted output containing 'Hello, world!' but got '${output}'"
Expand Down Expand Up @@ -73,7 +73,7 @@ EOF
Build and run the new command:

~~~sh
aspect build --task-key build-kotlin-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //src/greet:greet
aspect build --task:name build-kotlin-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //src/greet:greet
output=$(bazel run //src/greet:greet)
echo "${output}" | grep -q "Greetings from Bazel" || {
echo >&2 "Wanted output containing 'Greetings from Bazel' but got '${output}'"
Expand Down
6 changes: 3 additions & 3 deletions user_stories/py.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/py` package. Build and test it:

~~~sh
aspect build --task-key build-py-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/py:hello
aspect test --task-key test-py-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/py:hello_test
aspect build --task:name build-py-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/py:hello
aspect test --task:name test-py-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/py:hello_test
~~~

## Add your own code
Expand Down Expand Up @@ -71,5 +71,5 @@ EOF
Build the new command:

~~~sh
aspect build --task-key build-py-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:main
aspect build --task:name build-py-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //cmd/greet:main
~~~
6 changes: 3 additions & 3 deletions user_stories/ruby.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/ruby` package. Build it, test it, and run it:

~~~sh
aspect build --task-key build-ruby-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/ruby:hello
aspect test --task-key test-ruby-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/ruby:hello_test
aspect build --task:name build-ruby-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/ruby:hello
aspect test --task:name test-ruby-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/ruby:hello_test
output=$(bazel run //hello/ruby:hello)
echo "${output}" | grep -q "Hello, world!" || {
echo >&2 "Wanted output containing 'Hello, world!' but got '${output}'"
Expand Down Expand Up @@ -74,7 +74,7 @@ EOF
Build and run it to see the result:

~~~sh
aspect build --task-key build-ruby-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //app:greet
aspect build --task:name build-ruby-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //app:greet
output=$(bazel run //app:greet)
echo "${output}" | grep -q "Greetings from Bazel + Ruby!" || {
echo >&2 "Wanted output containing 'Greetings from Bazel + Ruby!' but got '${output}'"
Expand Down
6 changes: 3 additions & 3 deletions user_stories/rust.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ so skipping `direnv` means you're responsible for installing them yourself.
The starter ships a tiny `hello/rust` package. Build it, test it, and run it:

~~~sh
aspect build --task-key build-rust-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/rust:hello
aspect test --task-key test-rust-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/rust:hello_test
aspect build --task:name build-rust-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/rust:hello
aspect test --task:name test-rust-story --github-status-comments:enabled=false --github-status-checks:enabled=false //hello/rust:hello_test
output=$(bazel run //hello/rust:hello)
echo "${output}" | grep -q "Hello, world!" || {
echo >&2 "Wanted output containing 'Hello, world!' but got '${output}'"
Expand Down Expand Up @@ -71,7 +71,7 @@ EOF
Build and run the new command:

~~~sh
aspect build --task-key build-rust-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //src/greet:greet
aspect build --task:name build-rust-greet --github-status-comments:enabled=false --github-status-checks:enabled=false //src/greet:greet
output=$(bazel run //src/greet:greet)
echo "${output}" | grep -q "Greetings from Bazel" || {
echo >&2 "Wanted output containing 'Greetings from Bazel' but got '${output}'"
Expand Down
Loading