Skip to content

Commit eac9b8f

Browse files
committed
chore: Merge branch 'main' into feature/kube-proxy
2 parents 7565d91 + 0f62acd commit eac9b8f

File tree

24 files changed

+2579
-142
lines changed

24 files changed

+2579
-142
lines changed

.github/workflows/pr_pre-commit.yml

Lines changed: 9 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -16,29 +16,15 @@ jobs:
1616
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
1717
with:
1818
fetch-depth: 0
19-
- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
19+
- uses: cachix/install-nix-action@08dcb3a5e62fa31e2da3d490afc4176ef55ecd72 #v30
2020
with:
21-
python-version: '3.12'
22-
- uses: dtolnay/rust-toolchain@master
21+
github_access_token: ${{ secrets.GITHUB_TOKEN }}
22+
- uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
2323
with:
24-
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
25-
components: rustfmt,clippy
26-
- name: Setup Hadolint
27-
shell: bash
28-
run: |
29-
set -euo pipefail
30-
31-
LOCATION_DIR="$HOME/.local/bin"
32-
LOCATION_BIN="$LOCATION_DIR/hadolint"
33-
34-
SYSTEM=$(uname -s)
35-
ARCH=$(uname -m)
36-
37-
mkdir -p "$LOCATION_DIR"
38-
curl -sL -o "${LOCATION_BIN}" "https://github.com/hadolint/hadolint/releases/download/${{ env.HADOLINT_VERSION }}/hadolint-$SYSTEM-$ARCH"
39-
chmod 700 "${LOCATION_BIN}"
40-
41-
echo "$LOCATION_DIR" >> "$GITHUB_PATH"
42-
- uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd # v3.0.1
24+
node-version: 18
25+
cache: yarn
26+
- run: yarn install --frozen-lockfile
27+
- uses: stackabletech/actions/run-pre-commit@9bd13255f286e4b7a654617268abe1b2f37c3e0a # v0.3.0
4328
with:
44-
extra_args: "--from-ref ${{ github.event.pull_request.base.sha }} --to-ref ${{ github.event.pull_request.head.sha }}"
29+
rust: ${{ env.RUST_TOOLCHAIN_VERSION }}
30+
hadolint: ${{ env.HADOLINT_VERSION }}

.pre-commit-config.yaml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ repos:
2323
- id: fmt
2424
args: ["--all", "--", "--check"]
2525
- id: clippy
26-
args: ["--all-targets", "--", "-D", "warnings"]
26+
args: ["--all-targets", "--all-features", "--", "-D", "warnings"]
2727

2828
- repo: https://github.com/adrienverge/yamllint
2929
rev: 81e9f98ffd059efe8aa9c1b1a42e5cce61b640c6 # 1.35.1
@@ -40,6 +40,7 @@ repos:
4040
hooks:
4141
- id: shellcheck
4242
args: ["--severity=info"]
43+
exclude: '^extra/completions/'
4344

4445
- repo: https://github.com/rhysd/actionlint
4546
rev: 62dc61a45fc95efe8c800af7a557ab0b9165d63b # 1.7.1
@@ -58,45 +59,45 @@ repos:
5859
files: ^rust/stackablectl/
5960
language: system
6061
entry: cargo xtask gen-man
61-
stages: [commit, merge-commit, manual]
62+
stages: [pre-commit, pre-merge-commit, manual]
6263
pass_filenames: false
6364

6465
- id: gen-comp
6566
name: gen-comp
6667
files: ^rust/stackablectl/
6768
language: system
6869
entry: cargo xtask gen-comp
69-
stages: [commit, merge-commit, manual]
70+
stages: [pre-commit, pre-merge-commit, manual]
7071
pass_filenames: false
7172

7273
- id: gen-openapi
7374
name: gen-openapi
7475
files: ^web/
7576
language: system
7677
entry: cargo xtask gen-openapi
77-
stages: [commit, merge-commit, manual]
78+
stages: [pre-commit, pre-merge-commit, manual]
7879
pass_filenames: false
7980

8081
- id: gen-ctl-readme
8182
name: gen-ctl-readme
8283
files: ^rust/stackablectl/
8384
language: system
8485
entry: cargo xtask gen-ctl-readme
85-
stages: [commit, merge-commit, manual]
86+
stages: [pre-commit, pre-merge-commit, manual]
8687
pass_filenames: false
8788

8889
- id: gen-docs
8990
name: gen-docs
9091
files: ^rust/stackablectl/
9192
language: system
9293
entry: cargo xtask gen-docs
93-
stages: [commit, merge-commit, manual]
94+
stages: [pre-commit, pre-merge-commit, manual]
9495
pass_filenames: false
9596

9697
- id: gen-cargo-nix
9798
name: gen-cargo-nix
9899
files: ^Cargo\.lock|go\.mod$
99100
language: system
100101
entry: make regenerate-nix
101-
stages: [commit, merge-commit, manual]
102+
stages: [pre-commit, pre-merge-commit, manual]
102103
pass_filenames: false

Cargo.lock

Lines changed: 13 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.nix

Lines changed: 74 additions & 47 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ bindgen = "0.70.1"
2323
cc = "1.0.83"
2424
clap = { version = "4.5", features = ["derive", "env"] }
2525
clap_complete = "4.5"
26+
clap_complete_nushell = "4.5"
2627
comfy-table = { version = "7.1", features = ["custom_styling"] }
2728
directories = "5.0"
2829
dotenvy = "0.15"

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ hooks are:
6565
- [`yamllint`](https://github.com/adrienverge/yamllint): Runs linting on all YAML files
6666
- [`markdownlint`](https://github.com/igorshubovych/markdownlint-cli): Runs linting on all Markdown files
6767
- [`prettier`](https://github.com/pre-commit/mirrors-prettier): Runs prettier on files located in `web`
68-
- `cargo clippy -- -D warnings`: Runs Clippy on all files and errors on warnings
68+
- `cargo clippy --all-targets --all-features -- -D warnings`: Runs Clippy on all files and errors on warnings
6969
- `cargo fmt -- --check`: Checks if Rust code needs formatting
7070
- `cargo xtask gen-comp`: Runs shell completions generation for `stackablectl`
7171
- `cargo xtask gen-man`: Runs man page generation for `stackablectl`
@@ -77,4 +77,3 @@ hooks are:
7777
[pre-commit]: https://pre-commit.com/
7878
[web-readme]: ./web/README.md
7979
[lib-readme]: ./rust/stackable-cockpit/README.md
80-
[xtasks]: ./xtask/src/main.rs

crate-hashes.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/modules/stackablectl/partials/commands/completions.adoc

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,12 @@ Generate shell completions for this tool
66
Usage: stackablectl completions [OPTIONS] <COMMAND>
77
88
Commands:
9-
bash Generate shell completions for Bash
10-
fish Generate shell completions for Fish
11-
zsh Generate shell completions for ZSH
12-
help Print this message or the help of the given subcommand(s)
9+
bash Generate shell completions for Bash
10+
elvish Generate shell completions for Elvish
11+
fish Generate shell completions for Fish
12+
nushell Generate shell completions for Nushell
13+
zsh Generate shell completions for ZSH
14+
help Print this message or the help of the given subcommand(s)
1315
1416
Options:
1517
-l, --log-level <LOG_LEVEL>

0 commit comments

Comments
 (0)