Today I Learned

Simplifying Circle CI setup for Crystal

Rather than setting up test environment for Crystal by yourself you can use official docker image:

version: 2
jobs:
  build:
    docker:
      - image: crystallang/crystal:0.25.0
    steps:
      - checkout

      - restore_cache:
          keys:
            - shards-{{ checksum "shard.lock" }}
      - run:
          name: Install shards
          command: |
            shards check || shards
      - save_cache:
          key: shards-{{ checksum "shard.lock" }}
          paths:
            - lib/
            - .shards/

      - run:
          name: Run specs
          command: crystal spec