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
11 changes: 11 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ jobs:
path: .stack-specification
- name: Check whitespace
run: git diff --check "$(git hash-object -t tree /dev/null)" HEAD
- name: Validate provider catalogs
run: node scripts/validate-provider-catalogs.mjs
- name: Install latest stable Rust toolchain
run: rustup toolchain install stable --profile minimal --component clippy,rustfmt,llvm-tools-preview
- name: Check formatting
Expand Down Expand Up @@ -67,6 +69,8 @@ jobs:
./target/release/stack fmt --help
./target/release/stack render --help
./target/release/stack icons --help
./target/release/stack icons list
./target/release/stack icons list aws s3
./target/release/stack icons import --help
- name: Verify repository files
run: |
Expand All @@ -83,6 +87,13 @@ jobs:
test -s Cargo.lock
test -s src/main.rs
test -s src/provider.rs
test -s src/provider_catalog.rs
test -s catalogs/aws.json
test -s catalogs/gcp.json
test -s catalogs/azure.json
test -s catalogs/simple-icons.json
test -s scripts/generate-provider-catalogs.mjs
test -s scripts/validate-provider-catalogs.mjs
test -s tests/specification-revision
test -s tests/fixtures/render.stack

Expand Down
13 changes: 7 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "stack-cli"
version = "0.1.0"
version = "0.2.0"
edition = "2024"
rust-version = "1.85"
publish = false
Expand All @@ -15,10 +15,11 @@ path = "src/main.rs"

[dependencies]
roxmltree = "=0.21.1"
serde = { version = "=1.0.229", features = ["derive"] }
serde_json = "=1.0.151"
sha2 = "=0.11.0"
stack-engine = { git = "https://github.com/stack-sh/engine.git", rev = "c82595e33c6f26b67fec7b5c2171921765e30000" }
stack-theme = { git = "https://github.com/stack-sh/theme.git", rev = "2347315e6e86ab9d2708e05fd3f9b5f3d87e1241" }
stack-engine = { git = "https://github.com/stack-sh/engine.git", rev = "2c9adabd2ffee627ac5fe3ee26331b0ad75bceac" }
stack-theme = { git = "https://github.com/stack-sh/theme.git", rev = "7e208d6a3c90d255799f390a4e8b86248c73caee" }
zip = { version = "=6.0.0", default-features = false, features = ["deflate-flate2-zlib-rs"] }

[features]
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ stack fmt --check arch.stack
stack fmt -
stack render arch.stack
stack render arch.stack -o arch.svg
stack icons list
stack icons list aws s3
stack icons import aws ~/Downloads/aws-icons.zip --accept-terms -o .stack-icons/aws
stack render arch.stack --provider-pack .stack-icons/aws -o arch.svg --notice arch.NOTICE.md
```
Expand All @@ -23,7 +25,9 @@ stack render arch.stack --provider-pack .stack-icons/aws -o arch.svg --notice ar

`stack render` uses the same engine pipeline to produce deterministic standalone SVG. Without `-o`, standard output contains only SVG. With `-o`, the output is written atomically in the destination directory. Repeat `--provider-pack <DIRECTORY>` to load local imported packs, and use `--notice <NOTICE>` to save the exact provider pack revisions, terms, source archives, and icon IDs embedded in that artifact. Pack files are bounded and validated before rendering; the command performs no download or upload. Diagnostics remain on standard error, warnings preserve SVG, and Stack errors never create or replace output.

`stack icons import` creates a local provider pack from an official ZIP archive that the user selected. It performs no network request or upload, requires explicit terms acceptance, verifies the complete archive against an audited SHA-256, reads only allowlisted SVG entries with fixed size limits, removes active or external content, preserves the official colors and geometry, and writes the manifest, notice, and processed SVGs atomically to a new directory. The initial audited profiles import 7 AWS, 6 Google Cloud, or 5 Azure icons. See [the provider icon import guide](./docs/provider-icon-import.md) for exact sources, hashes, IDs, and terms.
`stack icons list [PROVIDER] [QUERY]` searches the asset-free catalog by ID, product name, or category. The catalog currently contains 1,051 IDs: 305 AWS, 45 Google Cloud, 639 Azure, and 62 curated developer and collaboration tool icons. This command reads only metadata embedded in the CLI.

`stack icons import` creates a local provider pack from official ZIP archives that the user selected. It performs no network request or upload, requires explicit terms acceptance, verifies every complete archive against an audited SHA-256, reads only allowlisted SVG entries with fixed size limits, removes active or external content, preserves official colors and geometry, and writes the manifest, notice, and processed SVGs atomically to a new directory. Google Cloud combines its core and category archives with `--source categories=<ARCHIVE>`. Simple Icons entries also retain the recorded rights-owner source and brand-guideline links because that project's CC0 distribution does not grant rights to every underlying brand. See [the provider icon import guide](./docs/provider-icon-import.md) for sources, hashes, usage, and rights boundaries.

| Result | Exit status |
| --- | ---: |
Expand Down
Loading