Skip to main content

Trunk

Trunk currently consists of Trunk Check: a blazingly fast meta code checker and formatter with extraordinary features like caching, preexisting issue detection, a daemon, and a language server. Use it via our command line tool, VS Code extension, GitHub Action, or web app. In the future, Trunk will be much more.

Trunk is young, but we'll become the one stop shop for the full development experience of highly productive scalable repos: linting, formatting, code coverage, merge automation, test analytics, running/selecting tests, and more. Our goal is to enable you to land code faster: we believe that engineers should spend their time writing their code, not babysitting pull requests or struggling with their tools.

Right now our Trunk products include:

  • Check: A universal meta-linter to manange discovery, installation, execution and reporting of the formatters, static-analyzers and security tools your repo needs.
  • Coming Soon - Merge: An automatic PR merger

Development Status#

Trunk is currently in beta. We're typically releasing new versions every other week. Expect some bumps along the way, but give us lots of feedback, and we'll address your bugs and feature requests swiftly.

For support and feedback, reach out on your company's Trunk slack connect channel, or our Trunk Community slack. Thanks!

What's next for Trunk?#

  • Launch of Merge: a better way to merge
  • Stay tuned, the roadmap is long. We're additionally tackling these spaces:
    • Code coverage
    • Flaky test analysis
    • Running and selecting tests
    • Gaining insights into your engineering organization
  • Wish something existed in the dev productivity space? Let us know on slack

What's next for trunk check?#

What would you like to see next? Let us know on the Trunk Community slack!

General:

  • More linter and language support
  • Caching support for more languages
  • Support for vim, jetbrains, and other editors

Trunk Check CLI:

  • Ability to suggest new linters/formatters as you add files to your repo
  • Support for using system runtimes (python, node, etc) instead of always downloading a hermetic version

Trunk Check VSCode Extension:

  • Support for linting buffers during editing (before saving the file)

Why you need a super linter#

An ounce of prevention is worth a pound of cure. Running more well configured linters will reduce your bugs, increase consistency, reduce security vulnerabilities, and increase your overall speed. Spend a little time now, reap the rewards forever.

We believe every file in your repo should be linted, often by multiple linters. If you're currently linting only your primary language, you're doing it wrong. Lint everything: infra as code, config files, yaml, json, build files, dockerfiles, shell scripts, et. al.

Why Trunk is the best super linter#

  1. Hermetic: Both the trunk cli and all the linters you use are versioned inside your repo (.trunk/trunk.yaml) which ensures that everyone contributing to your repo is always using the same version of trunk. Whether using our VSCode extension, running trunk check, or running on CI, every developer always sees consistent results.
  2. Fast: We run a daemon in the background that starts checking your files the moment they're modified, so you can find out about all your blocking issues before you git push, not 10 minutes later when your CI run has finally finished.
  3. Cached: We can cache the results of an expanding set of formatters and linters, so you don't have to wait for them to run every time you modify a file.
  4. Git-aware: trunk is aware of your repo, which means that instead of nagging you about every issue already in your repository, we hold the line and only warn you about new issues.
  5. CI support: get trunk issues inline in your pull requests by running the Trunk GitHub Action
  6. IDE support: Use our VSCode Extension (more editor/ide support coming soon)
  7. Simple: Instead of seeing lint and format issues in a dozen different output formats from different tools, trunk provides a unified experience.

Trunk is hermetic (and why you should care)#

trunk has been engineered to be fully hermetic: we version and package everything we depend on, which means that you don't have to worry about what version of node or python is installed on your machine.

The result is a product/service that always behaves the same, be it on your laptop, Jocelyn's dev VM, Cristo's Macbook, or the cloud machines that power your CI (Continuous Integration). trunk is trunk is trunk.

Our goal in building trunk is to develop a tool that is actually plug-n-play, not just plug-n-pray. If you're sick of having to diagnose differing machine configurations and tracking down rogue apt packages, we think you'll enjoy using trunk.

Security & Telemetry#

Trunk does not do any processing remotely. When using the Trunk CLI, VSCode Extension, or GitHub Action, all processing happens on your local machine or on your CI system, so your code stays safe and sound. We do collect limited usage and errors reports, but we do not collect or send your code anywhere. When using the Trunk web app, you'll need to grant auth for a repo upon installing the Trunk Github App, you can see what permissions it requires upon installation, but note that we do not clone your repo on our servers