Skip to content

Commit 612f8d9

Browse files
committed
chore(git): merge from master
2 parents 9b24262 + 40a6709 commit 612f8d9

17 files changed

Lines changed: 1088 additions & 49 deletions

.devcontainer/devcontainer.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"name": "parallel-disk-usage (Rust only)",
3+
"image": "mcr.microsoft.com/devcontainers/rust:1",
4+
"customizations": {
5+
"vscode": {
6+
"extensions": [
7+
"rust-lang.rust-analyzer",
8+
"timonwong.shellcheck",
9+
"mkhl.shfmt"
10+
]
11+
}
12+
},
13+
"postCreateCommand": "bash .devcontainer/post-create.sh"
14+
}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"name": "parallel-disk-usage (full)",
3+
"image": "mcr.microsoft.com/devcontainers/rust:1",
4+
"features": {
5+
"ghcr.io/devcontainers/features/node:1": {
6+
"version": "lts",
7+
"nodeGypDependencies": true
8+
},
9+
"ghcr.io/devcontainers/features/python:1": {
10+
"version": "3.12",
11+
"installTools": true
12+
},
13+
"ghcr.io/devcontainers-contrib/features/shellcheck:1": {},
14+
"ghcr.io/devcontainers-contrib/features/shfmt:1": {}
15+
},
16+
"customizations": {
17+
"vscode": {
18+
"extensions": [
19+
"rust-lang.rust-analyzer",
20+
"timonwong.shellcheck",
21+
"mkhl.shfmt"
22+
]
23+
}
24+
},
25+
"postCreateCommand": "bash .devcontainer/full/post-create.sh"
26+
}

.devcontainer/full/post-create.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
4+
echo "Installing Python dependencies..." >&2
5+
python3 -m pip install --user toml
6+
7+
echo "Installing pnpm and project Node dependencies..." >&2
8+
npm install -g pnpm@7.9.0
9+
(cd ci/github-actions && pnpm install --frozen-lockfile)
10+
11+
bash "$(dirname "$0")/../install-rust-toolchain.sh"
12+
bash "$(dirname "$0")/../install-hyperfine.sh"

.devcontainer/install-hyperfine.sh

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#!/usr/bin/env bash
2+
# Shared helper: install hyperfine binary from GitHub releases into ~/.local/bin
3+
set -euo pipefail
4+
5+
arch="$(uname -m)"
6+
case "$arch" in
7+
x86_64) hyperfine_target="x86_64-unknown-linux-musl" ;;
8+
aarch64) hyperfine_target="aarch64-unknown-linux-musl" ;;
9+
*)
10+
echo "ERROR: Unsupported architecture for hyperfine prebuilt binary: $arch" >&2
11+
exit 1
12+
;;
13+
esac
14+
15+
mkdir -p "$HOME/.local/bin"
16+
17+
echo "Installing hyperfine from GitHub release..." >&2
18+
hyperfine_version="1.20.0"
19+
hyperfine_archive="hyperfine-v${hyperfine_version}-${hyperfine_target}"
20+
hyperfine_url="https://github.com/sharkdp/hyperfine/releases/download/v${hyperfine_version}/${hyperfine_archive}.tar.gz"
21+
curl -fsSL "$hyperfine_url" | tar -xz --strip-components=1 -C "$HOME/.local/bin" "${hyperfine_archive}/hyperfine"
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
4+
REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
5+
6+
echo "Installing Rust toolchain from rust-toolchain..." >&2
7+
rustup toolchain install "$(<"$REPO_ROOT/rust-toolchain")"
8+
rustup component add clippy rustfmt rust-analyzer

.devcontainer/post-create.sh

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
4+
mkdir -p "$HOME/.local/bin"
5+
6+
bash "$(dirname "$0")/install-rust-toolchain.sh"
7+
bash "$(dirname "$0")/install-hyperfine.sh"
8+
9+
arch="$(uname -m)"
10+
11+
echo "Installing shellcheck from GitHub release..." >&2
12+
shellcheck_version="0.11.0"
13+
case "$arch" in
14+
x86_64) shellcheck_arch="linux.x86_64" ;;
15+
aarch64) shellcheck_arch="linux.aarch64" ;;
16+
*)
17+
echo "ERROR: Unsupported architecture for shellcheck prebuilt binary: $arch" >&2
18+
exit 1
19+
;;
20+
esac
21+
shellcheck_archive="shellcheck-v${shellcheck_version}.${shellcheck_arch}"
22+
shellcheck_url="https://github.com/koalaman/shellcheck/releases/download/v${shellcheck_version}/${shellcheck_archive}.tar.gz"
23+
curl -fsSL "$shellcheck_url" | tar -xz --strip-components=1 -C "$HOME/.local/bin" "shellcheck-v${shellcheck_version}/shellcheck"
24+
25+
echo "Installing shfmt from GitHub release..." >&2
26+
shfmt_version="3.13.0"
27+
case "$arch" in
28+
x86_64) shfmt_arch="linux_amd64" ;;
29+
aarch64) shfmt_arch="linux_arm64" ;;
30+
*)
31+
echo "ERROR: Unsupported architecture for shfmt prebuilt binary: $arch" >&2
32+
exit 1
33+
;;
34+
esac
35+
shfmt_url="https://github.com/mvdan/sh/releases/download/v${shfmt_version}/shfmt_v${shfmt_version}_${shfmt_arch}"
36+
curl -fsSL "$shfmt_url" -o "$HOME/.local/bin/shfmt"
37+
chmod +x "$HOME/.local/bin/shfmt"

.github/copilot-instructions.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# AI Instructions
2+
3+
Read and follow the CONTRIBUTING.md file in this repository for all code style conventions, commit message format, and development guidelines.
4+
5+
## Quick Reference
6+
7+
- Commit format: Conventional Commits — `type(scope): lowercase description`
8+
- Version releases are the only exception: just the version number (e.g. `0.21.1`)
9+
- Prefer merged imports
10+
- Use descriptive generic names (`Size`, `Report`), not single letters
11+
- Use descriptive variable and closure parameter names by default — single letters are only allowed in: conventional names (`n` for count, `f` for formatter), comparison closures (`|a, b|`), trivial single-expression closures, fold accumulators, index variables (`i`/`j`/`k` in short closures or index-based loops only), and test fixtures (identical roles only). Never use single letters in multi-line functions or closures
12+
- Prefer `where` clauses for multiple trait bounds
13+
- Derive order: std traits → comparison traits → `Hash` → derive_more → feature-gated
14+
- Custom errors: `#[derive(Debug, Display, Error)]` + `#[non_exhaustive]`
15+
- Minimize `unwrap()` in non-test code — use proper error handling
16+
- `#![deny(warnings)]` is active — code must be warning-free
17+
- Install toolchain before running tests: `rustup toolchain install "$(< rust-toolchain)" && rustup component add --toolchain "$(< rust-toolchain)" rustfmt clippy`
18+
- If the AI agent is Claude Code, `gh` (GitHub CLI) is not installed — do not attempt to use it
19+
- Run `FMT=true LINT=true BUILD=true TEST=true DOC=true ./test.sh` to validate changes

AGENTS.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# AI Instructions
2+
3+
Read and follow the CONTRIBUTING.md file in this repository for all code style conventions, commit message format, and development guidelines.
4+
5+
## Quick Reference
6+
7+
- Commit format: Conventional Commits — `type(scope): lowercase description`
8+
- Version releases are the only exception: just the version number (e.g. `0.21.1`)
9+
- Prefer merged imports
10+
- Use descriptive generic names (`Size`, `Report`), not single letters
11+
- Use descriptive variable and closure parameter names by default — single letters are only allowed in: conventional names (`n` for count, `f` for formatter), comparison closures (`|a, b|`), trivial single-expression closures, fold accumulators, index variables (`i`/`j`/`k` in short closures or index-based loops only), and test fixtures (identical roles only). Never use single letters in multi-line functions or closures
12+
- Prefer `where` clauses for multiple trait bounds
13+
- Derive order: std traits → comparison traits → `Hash` → derive_more → feature-gated
14+
- Custom errors: `#[derive(Debug, Display, Error)]` + `#[non_exhaustive]`
15+
- Minimize `unwrap()` in non-test code — use proper error handling
16+
- `#![deny(warnings)]` is active — code must be warning-free
17+
- Install toolchain before running tests: `rustup toolchain install "$(< rust-toolchain)" && rustup component add --toolchain "$(< rust-toolchain)" rustfmt clippy`
18+
- If the AI agent is Claude Code, `gh` (GitHub CLI) is not installed — do not attempt to use it
19+
- Run `FMT=true LINT=true BUILD=true TEST=true DOC=true ./test.sh` to validate changes

CLAUDE.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# AI Instructions
2+
3+
Read and follow the CONTRIBUTING.md file in this repository for all code style conventions, commit message format, and development guidelines.
4+
5+
## Quick Reference
6+
7+
- Commit format: Conventional Commits — `type(scope): lowercase description`
8+
- Version releases are the only exception: just the version number (e.g. `0.21.1`)
9+
- Prefer merged imports
10+
- Use descriptive generic names (`Size`, `Report`), not single letters
11+
- Use descriptive variable and closure parameter names by default — single letters are only allowed in: conventional names (`n` for count, `f` for formatter), comparison closures (`|a, b|`), trivial single-expression closures, fold accumulators, index variables (`i`/`j`/`k` in short closures or index-based loops only), and test fixtures (identical roles only). Never use single letters in multi-line functions or closures
12+
- Prefer `where` clauses for multiple trait bounds
13+
- Derive order: std traits → comparison traits → `Hash` → derive_more → feature-gated
14+
- Custom errors: `#[derive(Debug, Display, Error)]` + `#[non_exhaustive]`
15+
- Minimize `unwrap()` in non-test code — use proper error handling
16+
- `#![deny(warnings)]` is active — code must be warning-free
17+
- Install toolchain before running tests: `rustup toolchain install "$(< rust-toolchain)" && rustup component add --toolchain "$(< rust-toolchain)" rustfmt clippy`
18+
- If the AI agent is Claude Code, `gh` (GitHub CLI) is not installed — do not attempt to use it
19+
- Run `FMT=true LINT=true BUILD=true TEST=true DOC=true ./test.sh` to validate changes

0 commit comments

Comments
 (0)