LogoLogo
SlackLogin
  • Overview
    • Welcome
  • Setup & Configuration
    • Connecting to Trunk
    • Managing Your Organization
      • GitHub App Permissions
  • Integration with Slack
  • Flaky Tests (Beta)
    • Overview
    • Get Started
      • Test Frameworks
        • Android
        • Bazel
        • Behave
        • cargo-nextest
        • Cypress
        • Dart Test
        • Go
        • GoogleTest
        • Gradle
        • Jasmine
        • Jest
        • Karma
        • Maven
        • minitest
        • Mocha
        • Nightwatch
        • NUnit
        • Pest
        • PHPUnit
        • Playwright
        • Pytest
        • Robot Framework
        • RSpec
        • Swift Testing
        • Vitest
        • XCTest
        • Other Test Frameworks
      • CI Providers
        • Azure DevOps Pipelines
        • BitBucket Pipelines
        • Buildkite
        • CircleCI
        • Drone CI
        • GitHub Actions
        • GitLab
        • Jenkins
        • Semaphore CI
        • TeamCity
        • Travis CI
        • Other CI Providers
    • Dashboard
    • Flaky Test Detection
    • Quarantining
    • PR Comments
    • Ticketing Integrations
      • Jira Integration
      • Linear Integration
      • Other Ticketing Platforms
    • Webhooks
      • Slack Integration
      • Microsoft Teams Integration
      • GitHub Issues Integration
      • Linear Integration
    • Uploader CLI Reference
  • Code Quality
    • Overview
    • Why Metalinters?
      • How does it work?
      • Why Code Quality?
    • Setup & Installation
      • Initialize Trunk
      • Local Linting
      • Linting in CI
      • Nightly Report (Deprecated)
    • IDE Integration
      • VSCode
      • Neovim
      • GitHub Codespaces
    • Linters
      • Supported Linters
        • Actionlint
        • Ansible-lint
        • Autopep8
        • Bandit
        • Biome
        • Black
        • Brakeman
        • buf
        • Buildifier
        • cfnlint
        • Checkov
        • circleci
        • ClangFormat
        • clang-tidy
        • Clippy
        • cmake-format
        • codespell
        • cspell
        • cue-fmt
        • dart
        • deno
        • Detekt
        • djlint
        • dotenv-linter
        • dotnet-format
        • dustilock
        • ESLint
        • Flake8
        • git-diff-check
        • Gitleaks
        • Gofmt
        • gofumpt
        • goimports
        • gokart
        • golangci-lint
        • golines
        • google-java-format
        • graphql-schema-linter
        • hadolint
        • haml-lint
        • isort
        • iwyu
        • ktlint
        • kube-linter
        • markdown-link-check
        • markdown-table-prettify
        • Markdownlint
        • markdownlint-cli2
        • mypy
        • nancy
        • nixpkgs-fmt
        • opa
        • OSV-Scanner
        • Oxipng
        • perlcritic
        • perltidy
        • php-cs-fixer
        • phpstan
        • pmd
        • pragma-once
        • pre-commit-hooks
        • Prettier
        • prisma
        • psscriptanalyzer
        • Pylint
        • pyright
        • regal
        • remark-lint
        • renovate
        • rome
        • rubocop
        • Ruff
        • rufo
        • rustfmt
        • scalafmt
        • semgrep
        • ShellCheck
        • shfmt
        • sort-package-json
        • sourcery
        • sql-formatter
        • SQLFluff
        • sqlfmt
        • squawk
        • standardrb
        • stringslint
        • stylelint
        • stylua
        • SVGO
        • swiftformat
        • swiftlint
        • taplo
        • Terraform
        • terragrunt
        • terrascan
        • TFLint
        • tfsec
        • tofu
        • Trivy
        • Trufflehog
        • txtpbfmt
        • vale
        • Yamllint
        • yapf
      • Run Linters
      • Manage Linters
      • Configure Linters
      • Ignoring Issues and Files
      • Custom Linters
      • Shared Configs
      • Upgrades
    • CI Setup
      • GitHub Integration
      • Manual Setup
    • Debugging
    • Licensing
  • Merge Queue
    • Overview
    • How does it work?
    • Setup
      • Quick Start
      • Settings
      • Integration for Slack
    • Concepts and Optimizations
      • Predictive Testing
      • Optimistic Merging
      • Pending Failure Depth
      • Anti-Flake Protection
      • Batching
      • Parallel Queues
        • Bazel
        • Nx
        • API
      • FAQ
    • Priority
    • Managing Merge Queue
      • Using the Merge UI
      • Metrics
      • Command Line
    • Webhooks
    • Reference
  • CLI & API References
    • CLI Reference
      • Install
      • Getting Started
        • Code Quality
        • Merge Queue
        • Flaky Tests
        • Tools
        • Actions
          • Git Hooks
        • Announce
      • Compatibility
      • Caching
      • Commands Reference
        • Code Quality
        • Actions
        • Merge
      • Configuration
        • Plugins
          • Share Config Between Codebases
          • Exporting Linter Configs
        • Runtimes
        • Tools
        • Lint
          • Definitions
          • Commands
          • Output
          • Output Parsing
          • Files and Caching
          • Dependencies
          • Auto-Enable
        • Actions
          • Notifications
          • Logging and Troubleshooting
        • Merge
        • Telemetry
        • Per User Overrides
    • API Reference
      • Flaky Tests
      • Merge Queue
      • Webhooks Reference
  • Pricing & Security
    • Security
  • Billing
  • Community & Support
  • Links
    • Open App
    • Slack Community
    • Changelog
    • Feature Requests
On this page
  • What's deprecated
  • Why we’re deprecating these features
  • Migrating nightly and PR jobs
  • Caching
  • Limitations
Edit on GitHub
  1. Code Quality
  2. Setup & Installation
  3. Linting in CI

Migration Guide

Last updated 27 days ago

What's deprecated

The Code Quality dashboard on the Trunk Web App will be deprecated. Along with it, CI workflows configured and managed by the Trunk Web App will also be deprecated.

This means the Code Quality tab in the Trunk Web App will be deprecated.

This also means checking for issues nightly, and pull requests will be deprecated. You can check if you’re using these features in the Code Quality section of your repo settings. You can still run Code Quality in CI. Instructions for a replacement workflow will be provided later in this guide.

Lastly, Trunk will no longer collect your linting issues. This means the `--upload` flag will no longer work. You will also stop receiving Slack notifications about new issues discovered by linters.

This means if you're using these flags on your trunk check command, they will no longer work.

trunk check --upload --series=main

Why we’re deprecating these features

From both usage data and community feedback, we know the core value of Code Quality is in the CLI, IDE, and native CI integrations. We’ve deprecated some features to better support these key integrations with limited resources.

Migrating nightly and PR jobs

Nightly and PR jobs configured through the Trunk Web App will no longer be supported. You can migrate these workflows to run as a step in your existing CI pipelines.

Run on PRs using GitHub Actions

name: Trunk Code Quality
on:
  push:
    branches: main
  pull_request:
    branches: main
	
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      # ... other setup steps
      - name: Trunk Code Quality
        uses: trunk-io/trunk-action@v1
      # ... other CI steps

You will still receive inline comments about your errors if you run the action with the post-annotations argument.

You can also set up checks on PR without using the provided GitHub Action. Download the CLI in line and run the Code Quality CLI in CI mode to check a PR. Note that you will not receive inline arguments with this approach.

curl -fsSLO --retry 3 https://trunk.io/releases/trunk 
chmod +x trunk 
./trunk check --ci

Here’s an example of the commands in a GitHub Actions workflow, but you can do the same in virtually any CI pipeline.

name: Trunk Code Quality
on:
  push:
    branches: main
  pull_request:
    branches: main

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      # ... other setup steps
      - run: |
              curl -fsSLO --retry 3 https://trunk.io/releases/trunk 
              chmod +x trunk 
              ./trunk check --ci --ci-progress
      # ... other CI steps

Run nightly using GitHub Action

name: Trunk Code Quality
on:
  schedule:
    # Run at 4 PM UTC daily (cron uses UTC time)
    - cron: '0 16 * * *'
	
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      # ... other setup steps
      - name: Trunk Code Quality
        uses: trunk-io/trunk-action@v1
        with:
    		check-mode: all
      # ... other CI steps

Run nightly using other CI providers

Specify the --all flag on your trunk check command to run on your entire codebase. Trunk is Git aware and checks only files changed in a PR by default. Specifying --all will instead check the whole code base.

curl -fsSLO --retry 3 https://trunk.io/releases/trunk 
chmod +x trunk 
./trunk check --all --ci --ci-progress

Here’s an example of the command in a GitHub Actions workflow. This command will also work in any other CI provider.

name: Trunk Code Quality
on:
  schedule:
    # Run at 4 PM UTC daily (cron uses UTC time)
    - cron: '0 16 * * *'
	
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      # ... other setup steps
      - run: |
              curl -fsSLO --retry 3 https://trunk.io/releases/trunk 
              chmod +x trunk 
              ./trunk check --all --ci --ci-progress
      # ... other CI steps

Caching

You can cache Trunk’s binary and install tools to speed up your CI runs. Trunk caches the version of trunk itself, linters, formatters, and lint results in the ~/.cache/trunk folder. Consult the documentation for your CI provider to learn about caching this folder.

Limitations

Uploads and web reports based on Code Quality issues are no longer supported after this deprecation. These less-used features are deprecated so we can better maintain the core metalinter features of Code Quality. While an online report is no longer available, Trunk still produces standardized output by reformatting each linter’s output.

You will also stop receiving Slack notifications about new issues in your repo. Since Trunk is no longer able to receive uploads about your linter runs, it can’t send Slack notifications about them.

Trunk provides a to help you lint your code in CI. You add it as a step to your workflows. To run on pull requests or on a schedule, you can configure the appropriate triggers for your workflow.

To run Trunk’s to lint your entire code base nightly or on a schedule, you can specify the `check-mode: all` argument when running the action.

If you have additional questions or concerns, please reach out to us on .

GitHub Action
GitHub Action
Slack
The Code Quality tab in the Trunk Web App.
You can check in the Code Quality settings of your repo to see if you're currently using deprecated features.
Inline linter errors and warnings as you review PRs.