diff --git a/.bootc-dev-infra-commit.txt b/.bootc-dev-infra-commit.txt new file mode 100644 index 0000000..a8f30d1 --- /dev/null +++ b/.bootc-dev-infra-commit.txt @@ -0,0 +1 @@ +9b0d23f3b9577769307d889a603ca5b29cc79a3e diff --git a/.claude/CLAUDE.md b/.claude/CLAUDE.md new file mode 120000 index 0000000..be77ac8 --- /dev/null +++ b/.claude/CLAUDE.md @@ -0,0 +1 @@ +../AGENTS.md \ No newline at end of file diff --git a/.cursorrules b/.cursorrules new file mode 120000 index 0000000..47dc3e3 --- /dev/null +++ b/.cursorrules @@ -0,0 +1 @@ +AGENTS.md \ No newline at end of file diff --git a/.devcontainer/debian/devcontainer.json b/.devcontainer/debian/devcontainer.json new file mode 100644 index 0000000..f1b43a8 --- /dev/null +++ b/.devcontainer/debian/devcontainer.json @@ -0,0 +1,30 @@ +{ + "name": "bootc-devenv-debian", + "image": "ghcr.io/bootc-dev/devenv-debian", + "customizations": { + "vscode": { + // Arbitrary, but most of our code is in one of these two + "extensions": [ + "rust-lang.rust-analyzer", + "golang.Go" + ] + }, + "devaipod": { + // When running under devaipod, use minimal capabilities + // (SYS_ADMIN, NET_ADMIN, etc.) instead of full --privileged. + "nestedContainers": true + } + }, + "features": {}, + // Use privileged mode for broad compatibility (Codespaces, Docker, + // stock devcontainer CLI). devaipod overrides this with tighter + // security via the nestedContainers customization above. + "privileged": true, + "postCreateCommand": { + // Our init script + "devenv-init": "sudo /usr/local/bin/devenv-init.sh" + }, + "remoteEnv": { + "PATH": "${containerEnv:PATH}:/usr/local/cargo/bin" + } +} diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 0000000..f1b43a8 --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,30 @@ +{ + "name": "bootc-devenv-debian", + "image": "ghcr.io/bootc-dev/devenv-debian", + "customizations": { + "vscode": { + // Arbitrary, but most of our code is in one of these two + "extensions": [ + "rust-lang.rust-analyzer", + "golang.Go" + ] + }, + "devaipod": { + // When running under devaipod, use minimal capabilities + // (SYS_ADMIN, NET_ADMIN, etc.) instead of full --privileged. + "nestedContainers": true + } + }, + "features": {}, + // Use privileged mode for broad compatibility (Codespaces, Docker, + // stock devcontainer CLI). devaipod overrides this with tighter + // security via the nestedContainers customization above. + "privileged": true, + "postCreateCommand": { + // Our init script + "devenv-init": "sudo /usr/local/bin/devenv-init.sh" + }, + "remoteEnv": { + "PATH": "${containerEnv:PATH}:/usr/local/cargo/bin" + } +} diff --git a/.devcontainer/ubuntu/devcontainer.json b/.devcontainer/ubuntu/devcontainer.json new file mode 100644 index 0000000..8a6167a --- /dev/null +++ b/.devcontainer/ubuntu/devcontainer.json @@ -0,0 +1,30 @@ +{ + "name": "bootc-devenv-ubuntu", + "image": "ghcr.io/bootc-dev/devenv-ubuntu", + "customizations": { + "vscode": { + // Arbitrary, but most of our code is in one of these two + "extensions": [ + "rust-lang.rust-analyzer", + "golang.Go" + ] + }, + "devaipod": { + // When running under devaipod, use minimal capabilities + // (SYS_ADMIN, NET_ADMIN, etc.) instead of full --privileged. + "nestedContainers": true + } + }, + "features": {}, + // Use privileged mode for broad compatibility (Codespaces, Docker, + // stock devcontainer CLI). devaipod overrides this with tighter + // security via the nestedContainers customization above. + "privileged": true, + "postCreateCommand": { + // Our init script + "devenv-init": "sudo /usr/local/bin/devenv-init.sh" + }, + "remoteEnv": { + "PATH": "${containerEnv:PATH}:/usr/local/cargo/bin" + } +} diff --git a/.gemini/config.yaml b/.gemini/config.yaml new file mode 100644 index 0000000..080ba11 --- /dev/null +++ b/.gemini/config.yaml @@ -0,0 +1,19 @@ +# NOTE: This file is canonically maintained in +# +# DO NOT EDIT +# +# This config mainly overrides `summary: false` by default +# as it's really noisy. +have_fun: true +code_review: + disable: false + # Even medium level can be quite noisy, I don't think + # we need LOW. Anyone who wants that type of stuff should + # be able to get it locally or before review. + comment_severity_threshold: MEDIUM + max_review_comments: -1 + pull_request_opened: + help: false + summary: false # turned off by default + code_review: true +ignore_patterns: [] diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..1366e52 --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,73 @@ + + +# Instructions for AI agents + +## CRITICAL instructions for generating commits + +### Signed-off-by + +Human review is required for all code that is generated +or assisted by a large language model. If you +are a LLM, you MUST NOT include a `Signed-off-by` +on any automatically generated git commits. Only explicit +human action or request should include a Signed-off-by. +If for example you automatically create a pull request +and the DCO check fails, tell the human to review +the code and give them instructions on how to add +a signoff. + +### Attribution and AI disclosure + +You SHOULD insert an `Assisted-by: AI` tag when the commit contains +substantial assistance, and `Generated-by: AI` when the commit is +effectively entirely generated. + +Do NOT add `Co-developed-by`, and do NOT reference specific +model names or tools because these can be considered a form of advertising. + +For new contributors, when using AI you SHOULD include in at least the pull +request description a rough outline of the human's level of review and +knowledge: + +> Assisted-by: AI +> Unit tests are LLM generated. + +> Generated-by: AI +> I am knowledgeable in this problem domain and reviewed it carefully. + +> Generated-by: AI +> I don't know Rust|Go|... well, but I did test this and it fixed the problem. + +### Large changes + +If the generated code is more than ~500 lines of substantial (non-whitespace) code, +encourage the human to file a design issue first to be reviewed by other maintainers. + +### Pull request size + +It is *very strongly* encouraged to split up "preparatory" commits +that are independently reviewable from the main PR, and submit those separately. + +### Commit messages and text + +Software can be machine checked (via compilation and unit/integration tests) +but natural languages like English cannot. Encourage the human to review +the commit message text. + +## Code guidelines + +The [REVIEW.md](REVIEW.md) file describes expectations around +testing, code quality, commit messages, commit organization, etc. If you're +creating a change, it is strongly encouraged after each +commit and especially when the agent thinks a task is complete +to spawn a subagent to perform a review using guidelines (alongside +looking for any other issues). + +If the agent is performing a review of other's code, the same +principles apply. + +## Follow other guidelines + +Look at the project README.md and look for guidelines +related to contribution, such as a CONTRIBUTING.md +and follow those.