Repository navigation
docs(#79): add CLAUDE.md for agent repo context #80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
fullsend-ai-coder
wants to merge
1
commit into
main
Choose a base branch
from
agent/79-add-claude-md
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,92 @@ | ||
| # CLAUDE.md — Agent Context for redhat-developer/helm | ||
|
|
||
| ## Project overview | ||
|
|
||
| Red Hat's downstream build of [Helm](https://github.com/helm/helm). This is | ||
| not a fork — it is a rebuild with Red Hat's base image and FIPS compliance. | ||
| The upstream Helm source is vendored and patched per release branch. The main | ||
| branch tracks upstream Helm v4 development. | ||
|
|
||
| ## Build commands | ||
|
|
||
| ```bash | ||
| make build # Build the helm binary to bin/helm | ||
| make test # Run linter (golangci-lint) + unit tests | ||
| make test-unit # Unit tests only | ||
| make test-style # golangci-lint run ./... + license header check | ||
| make build-cross # Cross-compile for all supported platforms | ||
| make format # Run goimports | ||
| ``` | ||
|
|
||
| CI runs `make test-coverage` and `make build` via `.github/workflows/build-test.yml`. | ||
| Linting uses golangci-lint v2 (config in `.golangci.yml`). | ||
|
|
||
| ### FIPS builds (release branches only) | ||
|
|
||
| Release branches (e.g. `release-3.21`) add FIPS 140 compliance: | ||
| - `go.mod` includes `godebug fips140=auto` | ||
| - Makefile sets `GOFIPS140 ?= certified` and prepends it to build targets | ||
|
|
||
| The `main` branch (Helm v4) does not currently use FIPS flags. | ||
|
|
||
| ## Test commands | ||
|
|
||
| ```bash | ||
| go test ./... # All unit tests | ||
| go test ./pkg/action/... # Single package | ||
| go test -run TestSpecificFunc ./pkg/cmd/ # Single test | ||
| make test-coverage # Unit tests with coverage report | ||
| make gen-test-golden # Regenerate golden files for cmd/action tests | ||
| ``` | ||
|
|
||
| Tests use the `testify` assertion library (`github.com/stretchr/testify`). | ||
|
|
||
| ## Dependency management | ||
|
|
||
| Dependencies are managed with Go modules. The `main` branch does **not** | ||
| vendor dependencies (no `vendor/` directory). Release branches may vendor | ||
| via `go mod vendor`. | ||
|
|
||
| ```bash | ||
| go mod tidy # Clean up go.mod/go.sum | ||
| go mod vendor # Vendor dependencies (release branches only) | ||
| ``` | ||
|
|
||
| When bumping dependencies, ensure `go.sum` checksums are consistent and | ||
| `go.mod` changes are minimal (only the intended dependency). | ||
|
|
||
| ## Branch strategy | ||
|
|
||
| | Branch | Purpose | | ||
| |--------|---------| | ||
| | `main` | Default branch. Helm v4 development (unstable) | | ||
| | `release-X.Y` | Track upstream Helm releases for Red Hat rebuilds | | ||
|
|
||
| PRs often target `release-X.Y` branches rather than `main`. When creating | ||
| a PR, check the issue for the target branch — it may specify a release | ||
| branch (e.g. "apply to release-3.21"). | ||
|
|
||
| Helm v3 stable development continues on `dev-v3`. Bug fixes go to v4 | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [low] scope-creep Lines 69-70 introduce the dev-v3 branch, which was not listed in Issue #79's branch strategy requirements. The addition is factually accurate and useful for agents, but extends slightly beyond the explicit scope of the issue. |
||
| (`main`) first, then get backported to v3. | ||
|
|
||
| ## Downstream integration | ||
|
|
||
| - **Jira tickets**: Referenced as `HELM-xxx` or `OCPTOOLS-xxx` in issues | ||
| and PR descriptions | ||
| - **OCP target versions**: PRs note the target OpenShift version | ||
| (e.g. `ocp-tools-4.22`) | ||
| - **Post-merge workflow**: After a PR merges, update `upstream_sources.yml` | ||
| in the midstream repo, then run check-patch and Brew builds | ||
| - **Scratch/Brew builds**: `check-patch` validates the build before the | ||
| full `build-pipeline` Brew build | ||
|
|
||
| ## Review guidance for dependency bumps | ||
|
|
||
| When reviewing vendored dependency bumps: | ||
|
|
||
| 1. Verify `go.sum` checksums are consistent with the declared version | ||
| 2. Confirm vendored code matches the declared module version | ||
| 3. Check that no unrelated source changes are included | ||
| 4. Validate the CVE or security advisory justifying the bump | ||
| 5. Ensure the Go directive and K8s API versions are unchanged unless | ||
| intentionally updated | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[low] internal consistency
The branch strategy table lists only main and release-X.Y, but dev-v3 is described in prose at line 69. CI configurations confirm dev-v3 is a first-class branch (build-test.yml, codeql-analysis.yml, dependabot.yml). An agent scanning the table as a quick reference would miss this branch.