turborepo

Build system optimized for JavaScript and TypeScript, written in Rust

MIT License

Downloads
49.2M
Stars
26.1K
Committers
440

Bot releases are hidden (Show)

turborepo - v1.1.0-canary.1

Published by jaredpalmer over 2 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.26...v1.1.0-canary.1

turborepo - v1.0.28

Published by jaredpalmer almost 3 years ago

What's changed?

  • Updated next-env.d.ts in create-turbo so that there isn't a cache miss on the first run due to altered source

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.27...v1.0.28

turborepo - v1.0.27

Published by jaredpalmer almost 3 years ago

What's changed?

  • Patched bug causing turbo to hang on errors #557

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.26...v1.0.27

turborepo - v1.0.26

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.25...v1.0.26

turborepo - v1.0.25

Published by jaredpalmer almost 3 years ago

What's new?

Environment variable dependencies and hashing

When you use turbo with tools which inline environment variables at build time (e.g. Next.js or Create React App), it is important you tell turbo about it. Otherwise, you could ship a cached artifact with the wrong environment variables!

With this release, you can now change a task hash by doing any of the following:

  • (new) Including environment variables in a dependsOn in your pipeline definition prefixed by a $ will impact the cache fingerprint on a per-task or per-package-task basis.
  • (new) Including environment variables in globalDependencies list prefixed by a $ will impact the cache fingerprint of all tasks.
  • Including files or globs of files in globalDependencies will impact the cache fingerprint of all tasks.
  • (new) The value of any environment variable that includes THASH in its name will impact the cache fingerprint of all tasks.

Example Configuration

{
  "turbo": {
    "pipeline": {
      "build": {
        "dependsOn": {
          "^build"
          // env vars will impact hashes of all "build" tasks
          "$SOME_ENV_VAR"
        },
        "outputs": ["dist/**"]
      },
      "web#build": { // override settings for the "build" task for the "web" app
        "dependsOn": [
          "^build",
           // env vars that will impact the hash of "build" task for only "web" app
           "$STRIPE_SECRET_KEY",
           "$NEXT_PUBLIC_STRIPE_PUBLIC_KEY",
           "$NEXT_PUBLIC_ANALYTICS_ID",
        ],
        "outputs": [".next/**"],
      },
      "docs#build": { // override settings for the "build" task for the "docs" app
        "dependsOn": [
          "^build",
           // env vars that will impact the hash of "build" task for only "web" app
           "$STRIPE_SECRET_KEY",
           "$NEXT_PUBLIC_STRIPE_PUBLIC_KEY",
           "$NEXT_PUBLIC_ANALYTICS_ID",
        ],
        "outputs": [".next/**"],
      }
    },
    "baseBranch": "origin/main",
    "globalDependencies": [
      "$GITHUB_TOKEN"// env var that will impact the hashes of all tasks,
      "tsconfig.json" // file contents will impact the hashes of all tasks,
      ".env.*" // glob file contents will impact the hashes of all tasks,
    ],
  }
}

Bugfixes

  • Correctly show pnpx command in create-turbo
  • Treat symlink directory as directory in globalDependencies
  • Fix cpu overloading during long running tasks
  • Better error message when workspaces are not defined

Commits

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.24...v1.0.25

turborepo - v1.0.25-canary.1

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.24...v1.0.25-canary.1

turborepo - v1.0.25-canary.0

Published by jaredpalmer almost 3 years ago

What's New?

Hashing Environment Variables

When you use turbo with tools which inline environment variables at build time (e.g. Next.js or Create React App), it is important you tell turbo about it. Otherwise, you could ship a cached artifact with the wrong environment variables!

With this PR, you can now change a task hash by doing any of the following:

  • Including environment variables in a dependsOn in your pipeline definition prefixed by a $ will impact the cache fingerprint on a per-task or per-package-task basis.
  • Including environment variables in globalDependencies list prefixed by a $ will impact the cache fingerprint of all tasks.
  • Including files or globs of files in globalDependencies will impact the cache fingerprint of all tasks.
  • The value of any environment variable that includes THASH in its name will impact the cache fingerprint of all tasks.

Example Configuration

{
  "turbo": {
    "pipeline": {
      "build": {
        "dependsOn": {
          "^build"
          // env vars will impact hashes of all "build" tasks
          "$SOME_ENV_VAR"
        },
        "outputs": ["dist/**"]
      },
      "web#build": { // override settings for the "build" task for the "web" app
        "dependsOn": [
          "^build",
           // env vars that will impact the hash of "build" task for only "web" app
           "$STRIPE_SECRET_KEY",
           "$NEXT_PUBLIC_STRIPE_PUBLIC_KEY",
           "$NEXT_PUBLIC_ANALYTICS_ID",
        ],
        "outputs": [".next/**"],
      },
      "docs#build": { // override settings for the "build" task for the "docs" app
        "dependsOn": [
          "^build",
           // env vars that will impact the hash of "build" task for only "web" app
           "$STRIPE_SECRET_KEY",
           "$NEXT_PUBLIC_STRIPE_PUBLIC_KEY",
           "$NEXT_PUBLIC_ANALYTICS_ID",
        ],
        "outputs": [".next/**"],
      }
    },
    "baseBranch": "origin/main",
    "globalDependencies": [
      "$GITHUB_TOKEN"// env var that will impact the hashes of all tasks,
      "tsconfig.json" // file contents will impact the hashes of all tasks,
      ".env.*" // glob file contents will impact the hashes of all tasks,
    ],
  }
}

Commits

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.24...v1.0.25-canary.0

turborepo - v1.0.24

Published by jaredpalmer almost 3 years ago

What's Changed?

  • Added pnpm starter to create-turbo
  • Fixed yarn lockfile parsing on Windows machines. In the past, windows machines would not resolve yarn deps like linux and mac, but just hash the contents of the file. This has been fixed and removed.
  • Fixed log output streaming so that both stderr and stdout now correctly print output regardless of which one goes first. This was causing rollup and storybook watch commands to hang

Commits

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.23...v1.0.24

turborepo - v1.0.24-canary.2

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.23...v1.0.24-canary.2

turborepo - v1.0.24-canary.1

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.23...v1.0.24-canary.1

turborepo - v1.0.24-canary.0

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.23...v1.0.24-canary.0

turborepo - v1.0.23

Published by jaredpalmer almost 3 years ago

What's Changed

  • Refactor internal implementation of --scope and adde more more e2e tests by @jaredpalmer in #421

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.22...v1.0.23

turborepo - v1.0.22

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.21...v1.0.22

turborepo - v1.0.21

Published by jaredpalmer almost 3 years ago

What's changed?

  • Fix postinstall script to work with NPM. Sorry about that! postinstall scripts are very hard to test. Going to deprecate 1.0.20 on npm since it is botched.

Commits

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.20...v1.0.21

turborepo - v1.0.20

Published by jaredpalmer almost 3 years ago

What's new?

Docs

Commits

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.19...v1.0.20

turborepo - v1.0.20-canary.2

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.19...v1.0.20-canary.2

turborepo - v1.0.20-canary.1

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.19...v1.0.20-canary.1

turborepo - v1.0.20-canary.0

Published by jaredpalmer almost 3 years ago

What's Changed

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.19...v1.0.20-canary.0

turborepo - v1.0.19

Published by jaredpalmer almost 3 years ago

What's Changed

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.18...v1.0.19

turborepo - v1.0.18

Published by jaredpalmer almost 3 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/vercel/turborepo/compare/v1.0.17...v1.0.18