Skip to content

Instantly share code, notes, and snippets.

@hjhart
Last active June 18, 2019 21:57
Show Gist options
  • Save hjhart/d6162db7802021e4d04b10c9b3adf0e4 to your computer and use it in GitHub Desktop.
Save hjhart/d6162db7802021e4d04b10c9b3adf0e4 to your computer and use it in GitHub Desktop.

Revisions

  1. hjhart revised this gist Jun 18, 2019. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion better_circleci.bundle_install.yml
    Original file line number Diff line number Diff line change
    @@ -2,7 +2,7 @@ bundle_install:
    description: Bundle Install
    steps:
    - run:
    name: Export a cache key to BASH_ENV
    name: Expire cache key every month
    command: date '+%Y %m' > ~/voom/dependency_checksum

    - restore_cache:
  2. hjhart renamed this gist Jun 18, 2019. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  3. hjhart created this gist Jun 18, 2019.
    25 changes: 25 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,25 @@
    bundle_install:
    description: Bundle Install
    steps:
    - run:
    name: Export a cache key to BASH_ENV
    command: date '+%Y %m' > ~/voom/dependency_checksum

    - restore_cache:
    keys:
    - v1-bundle-{{ arch }}-{{ checksum "~/voom/dependency_checksum" }}-{{ checksum "~/voom/Gemfile.lock" }}
    - v1-bundle-{{ arch }}-{{ checksum "~/voom/dependency_checksum" }}
    - v1-bundle-{{ arch }}-

    - run:
    name: Install Bundler
    command: gem install bundler -v 1.17.3

    - run:
    name: Bundle Install
    command: cd ~/voom/; bundle check || bundle install --frozen --without production --without staging

    - save_cache:
    key: v1-bundle-{{ arch }}-{{ checksum "~/voom/dependency_checksum" }}-{{ checksum "~/voom/Gemfile.lock" }}
    paths:
    - ~/voom/vendor/bundle