Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/config/super-linter.env
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ VALIDATE_PYTHON_BLACK=false
FIX_BIOME_FORMAT=true
FIX_ENV=true
FIX_JSONC=true
FIX_JSONC_PRETTIER=true
FIX_MARKDOWN=true
FIX_MARKDOWN_PRETTIER=true
FIX_NATURAL_LANGUAGE=true
Expand Down
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [0.1.0] - 2026-02-14

### Added

- Initial release of flint lint task scripts
Expand All @@ -15,4 +17,5 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Renovate tracked-deps verification and generation
- Unified AUTOFIX environment variable pattern across all linters

[Unreleased]: https://github.com/grafana/flint/commits/main
[Unreleased]: https://github.com/grafana/flint/compare/v0.1.0...HEAD
[0.1.0]: https://github.com/grafana/flint/releases/tag/v0.1.0
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,30 @@ The `lint:renovate-deps` task runs Renovate locally in `--platform=local` mode,

- **Routine regeneration** → After any change to `renovate.json5`, Dockerfiles, `go.mod`, `package.json`, or other files Renovate scans, the linter will detect the change and require regeneration.

## Automatic version updates with Renovate

To let Renovate automatically update the pinned flint version in your
`mise.toml`, add this custom manager to your `renovate.json5`:

```json5
{
customManagers: [
{
customType: "regex",
description: "Update raw.githubusercontent.com version tags in mise.toml",
managerFilePatterns: ["/^mise\\.toml$/"],
matchStrings: [
"https://raw\\.githubusercontent\\.com/(?<depName>[^/]+/[^/]+)/(?<currentValue>v[^/]+)/",
],
datasourceTemplate: "github-tags",
},
],
}
```

This matches all `raw.githubusercontent.com` URLs in `mise.toml` and updates
the version tag (e.g., `v0.1.0`) when a new release is published.

## Per-repo configuration (not included)

Each consuming repository must provide its own:
Expand Down
18 changes: 17 additions & 1 deletion tasks/lint/renovate-deps.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,23 @@ def main():
log_path = run_renovate(tmpdir)
generated_data = extract_deps(log_path)

committed_data = json.loads(COMMITTED.read_text())
if not COMMITTED.exists():
if autofix:
print("AUTOFIX=true: Creating renovate-tracked-deps.json...")
with open(COMMITTED, "w", encoding="utf-8") as f:
json.dump(generated_data, f, indent=2)
f.write("\n")
print("renovate-tracked-deps.json has been created.")
committed_data = generated_data
else:
print(f"ERROR: {COMMITTED} does not exist.", file=sys.stderr)
print(
"Run 'mise run lint:renovate-deps' with AUTOFIX=true to create it.",
file=sys.stderr,
)
sys.exit(1)
else:
committed_data = json.loads(COMMITTED.read_text())

if committed_data == generated_data:
print("renovate-tracked-deps.json is up to date.")
Expand Down