Skip to content

Instantly share code, notes, and snippets.

@hi-ogawa
Last active December 19, 2025 10:25
Show Gist options
  • Select an option

  • Save hi-ogawa/df7f630fb7361dec4b6c019c8d007873 to your computer and use it in GitHub Desktop.

Select an option

Save hi-ogawa/df7f630fb7361dec4b6c019c8d007873 to your computer and use it in GitHub Desktop.
Test renovate config locally

Local Testing Renovate Configuration

When you modify your Renovate config, you typically need to merge to main and wait for Renovate to run to see if your changes work. This makes debugging slow and painful.

Instead, you can run Renovate locally with --platform=local to verify your config changes without pushing to remote. This lets you see exactly which files are detected, which dependencies would be updated, and whether your packageRules are matching correctly.

Quick Summary

For a quick sanity check, run Renovate with --dry-run=lookup. This shows a summary of detected managers and dependency counts without the verbose debug output.

RENOVATE_CONFIG_FILE=.github/renovate.json \
  pnpm dlx renovate --platform=local --dry-run=lookup
INFO: Dependency extraction complete (repository=local)
      "stats": {
        "managers": {
          "github-actions": {"fileCount": 4, "depCount": 8},
          "npm": {"fileCount": 9, "depCount": 81}
        },
        "total": {"fileCount": 13, "depCount": 89}
      }
INFO: Repository finished (repository=local)

Detailed Debug

Add LOG_LEVEL=debug to see the full picture of how Renovate processes your config.

RENOVATE_CONFIG_FILE=.github/renovate.json LOG_LEVEL=debug \
  pnpm dlx renovate --platform=local --dry-run=lookup

1. Your config file is loaded

Renovate reads your config file and shows the raw configuration before any processing.

DEBUG: File config
       "config": {
         "extends": ["config:recommended", "schedule:weekly", "group:allNonMajor"],
         "packageRules": [{"matchDepTypes": ["peerDependencies"], "enabled": false}]
         ...
       }

2. Presets are expanded into full config

The extends presets like config:recommended are resolved into their actual values. This is useful to verify what schedule or rules are actually applied.

INFO: Full resolved config and hostRules including presets (repository=local)
      "config": {
        "schedule": ["* 0-3 * * 1"],
        "packageRules": [ ... expanded rules ... ]
        ...
      }

3. All package files and dependencies are detected

This is the main section to verify your config works as expected. It shows every detected file, each dependency with its current version, and what updates are available.

DEBUG: packageFiles with updates (repository=local)
       "config": {
         "npm": [
           {
             "packageFile": "examples/basic/package.json",
             "deps": [
               {
                 "depName": "@cloudflare/vite-plugin",
                 "currentValue": "^1.13.9",
                 "lockedVersion": "1.18.0",
                 "updates": [{ "newVersion": "1.19.0", "updateType": "minor" }]
               },
               ...
             ]
           },
           ...
         ]
       }

4. Disabled dependencies are logged

When a dependency is excluded by your packageRules, Renovate logs it explicitly. This confirms your rules are working as intended.

DEBUG: Dependency: vite, is disabled (repository=local)

5. Summary

The final summary shows how many files and dependencies were processed.

INFO: Dependency extraction complete (repository=local)
      "stats": { "total": {"fileCount": 13, "depCount": 89} }

INFO: Repository finished (repository=local)

GitHub Actions and GITHUB_TOKEN

When running locally without authentication, GitHub Actions dependencies will be skipped with github-token-required:

WARN: GitHub token is required for some dependencies (repository=local)
      "githubDeps": ["actions/setup-node", "node", "actions/checkout"]

To check updates for GitHub Actions, provide a token:

GITHUB_TOKEN=ghp_xxx RENOVATE_CONFIG_FILE=.github/renovate.json \
  pnpm dlx renovate --platform=local --dry-run=lookup

References

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment