aliases: &build
  environment:
    BASH_ENV: "~/.nix-profile/etc/profile.d/nix.sh"

  machine: true

  steps:
    - checkout

    - run: git config --global user.email "travis-ci@example.com"
    - run: git config --global user.name "Travis-CI"

    - run: if [ $CIRCLE_JOB = "latest" ]; then curl https://nixos.org/nix/install | sh; fi;

    - run:
        command: echo "Yes" | ./try-reflex --command "exit 0"
        no_output_timeout: 3600

    - run: ./scripts/benchmark

    # Runs out of disk space
    - run: ./scripts/test -j 2

version: 2

workflows:
  version: 2
  both_nix:
    jobs:
      - pinned
      - latest

jobs:
  pinned: *build
  latest: *build

aliases: &build
  environment:
    BASH_ENV: "~/.nix-profile/etc/profile.d/nix.sh"

  machine: true

  parallelism: 2

  steps:
    - checkout

    - run: git config --global user.email "travis-ci@example.com"
    - run: git config --global user.name "Travis-CI"

    - run: if [ $CIRCLE_NODE_INDEX = 0 ]; then curl https://nixos.org/nix/install | sh; fi;

    - run:
        command: echo "Yes" | ./try-reflex --command "exit 0"
        no_output_timeout: 3600

    - run: ./scripts/benchmark

    # Runs out of disk space
    - run: ./scripts/test -j 2

version: 2

# Revert to workflows once they're supported by circleci's API
jobs:
  build: *build

Use job parallelism instead of workflows in circleci
Use job parallelism instead of workflows in circleci
