ci: add file hygiene workflow and canonical config templates#1758
ci: add file hygiene workflow and canonical config templates#1758yshyn-iohk wants to merge 5 commits into
Conversation
Scalafmt vs EditorConfig Conflict AnalysisNo conflict. Here's why:
Scalafmt and editorconfig-checker operate at different levels: scalafmt reformats Scala AST (imports, alignment, wrapping), while editorconfig-checker validates raw file bytes (BOM, line endings, trailing whitespace). They don't step on each other. |
Lint Triage Summary
Markdown — Top errors (auto-fixable marked with 🔧)
~800 of 1209 errors are auto-fixable with YAML — Top errors
Most YAML warnings are config-fixable. Syntax errors come from Helm templates (Go templating in YAML) and large OpenAPI specs which need to be excluded from yamllint. ShellCheck — 18 warnings across 8 files
Strategy: Config fixes + |
FabioPinheiro
left a comment
There was a problem hiding this comment.
Please split it in three commits:
1- Code/Files
2- Auto generated changes
3- Add the second commit to the .git-blame-ignore-revs
Don't squash the commits when merging
Add reusable file-hygiene workflow caller and canonical lint configs: - .github/workflows/file-hygiene.yml: caller for lint-files.yml - .editorconfig: UTF-8 (no BOM), LF line endings, indent rules - .gitattributes: LF normalization for text files, binary rules - .markdownlint.yml: markdownlint rules with relaxations for this repo - .markdownlint-cli2.yaml: ignore patterns for generated/vendored files - .markdownlintignore: local ignore patterns - .yamllint.yml: yamllint rules with relaxations for Docker Compose, Helm templates, and OpenAPI specs - .shellcheckrc: suppress intentional case pattern overlap and generated gradlew warnings Refs: hyperledger-identus/hyperledger-identus#172 Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io>
Remove CHANGELOG.md from castor/, cloud-agent/service/, connect/, mercury/, pollux/, and prism-node/client/scala-client/. The root CHANGELOG.md is the single source of truth for release notes. Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io>
Markdownlint auto-fix (--fix) resolved ~1000 issues: - MD009: trailing spaces - MD012: multiple consecutive blank lines - MD022: missing blank lines around headings - MD031: missing blank lines around fenced code blocks - MD032: missing blank lines around lists - MD047: missing final newline Manual fixes: - MD060: reformat misaligned tables in MAINTAINERS.md, infrastructure READMEs, vdr/manage.md, research doc - MD051: fix broken anchor link in signing-commits.md - MD028: merge consecutive blockquotes in linting.md - MD029: fix numbered list continuity in credentialdefinition/create.md, credentials/connectionless/issue.md, schemas/create.md, authserver-oid4vci-contract.md YAML fixes: - Add final newline to dependabot.yml and apisix config.yaml - Trim trailing spaces in .allstar/binary_artifacts.yaml ShellCheck fixes: - SC2155: separate declare and assign in keycloak/init-script.sh and get-versions.sh - SC2164: add || exit after cd in get-versions.sh - SC2034: export PORT in multi/stop.sh Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io>
Add the mass lint auto-fix commit (03b3786) to the blame ignore list so git blame skips past formatting-only changes. Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io>
Active maintainers: - Add Fabio Pinheiro (FabioPinheiro) and Allain Magyar (amagyar-iohk) - Update Pat Losoponkul GitHub ID from patlo-iog to patextreme - Update GitHub team from open-enterprise-agent-maintainers to identus-maintainers - Update company affiliation from IOHK to IOG - Fix sublist formatting in "Becoming a Maintainer" section Emeritus maintainers: - Move Björn Sandmann (bsandmann), David Poltorak (davidpoltorak-io), and Shailesh Patil (mineme0110) to emeritus Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Yurii Shynbuiev <yurii.shynbuiev@iohk.io>
a76157f to
fd6a3c3
Compare
|
|
Thanks, @FabioPinheiro, for the nice recommendation about adding autoformatted changes to |
|
but now you can't squash merge. And if you rebase you need to update the commit id on .git-blame-ignore-revs |
|
All commits from this PR were rebased on the main branch with the correction of the .git-blame-ignore-revs file. |



Summary
Implements file hygiene linting for cloud-agent as part of the org-wide rollout (hyperledger-identus/hyperledger-identus#172).
1. CI workflow and lint configuration
file-hygiene.ymlcaller workflow invoking the reusablelint-files.ymlfromhyperledger-identus/.github.gitattributes,.editorconfig,.markdownlint.yml,.yamllint.yml,.shellcheckrc.markdownlint-cli2.yamlwith ignore patterns for generated/vendored files (API clients, node_modules, Helm charts, OpenAPI spec)2. Changelog cleanups
CHANGELOG.mdfrom 6 subdirectories (castor, cloud-agent/service, connect, mercury, pollux, prism-node/client/scala-client)CHANGELOG.mdis the single source of truth3. Lint fixes across the repo (65 files)
4.
.git-blame-ignore-revsgit blameskips past formatting-only changes5. Maintainers update
patlo-iog→patextreme)open-enterprise-agent-maintainers→identus-maintainers)Scalafmt compatibility
No conflict — scalafmt (2-space indent,
maxColumn = 120) and editorconfig-checker operate at different levels. See analysis comment.Test plan
🤖 Generated with Claude Code