Sha256: 7470c6a096041afcf5ce51fb621f0bf69a240441aae373cdf068b252e484ec13

Contents?: true

Size: 1.82 KB

Versions: 4

Compression:

Stored size: 1.82 KB

Contents

# this file is managed by dry-rb/devtools project

name: sync_configs

on:
  repository_dispatch:

jobs:
  sync-configs:
    runs-on: ubuntu-latest
    if: github.event.action == 'sync_configs'
    steps:
      - uses: actions/checkout@v1
      - name: Set up Ruby
        uses: eregon/use-ruby-action@master
        with:
          ruby-version: 2.6
      - name: Install latest bundler
        run: |
          gem install bundler
          bundle config set without 'tools benchmarks docs'
      - name: Install dependencies
        run: bundle install --jobs 4 --retry 3 --without tools test benchmarks docs
      - name: Symlink ossy
        run: ln -sf "$(bundle info ossy --path)/bin/ossy" bin/ossy
      - name: Clone devtools
        run: git clone https://github.com/dry-rb/devtools.git tmp/devtools
      - name: Compile file templates
        env:
          GITHUB_LOGIN: dry-bot
          GITHUB_TOKEN: ${{ secrets.GH_PAT }}
        run: |
          if [ -f "project.yml" ]; then
            for t in `ls tmp/devtools/templates`
            do
              bin/ossy t c tmp/devtools/templates/$t $(basename $t .erb) project.yml
            done
          fi
      - name: Update configuration files from devtools
        run: |
          if [ -f ".github/workflows/custom_ci.yml" ]; then
            rsync -arv --exclude '.github/workflows/ci.yml' tmp/devtools/shared/ . ;
          else
            rsync -arv tmp/devtools/shared/ . ;
          fi
      - name: Commit changes
        run: |
          rm bin/ossy
          git config --local user.email "dry-bot@dry-rb.org"
          git config --local user.name "dry-bot"
          git add -A
          git commit -m "[devtools] sync configs" || echo "nothing changed"
      - name: Push changes
        uses: ad-m/github-push-action@master
        with:
          github_token: ${{ secrets.GH_PAT }}

Version data entries

4 entries across 4 versions & 4 rubygems

Version Path
dry-initializer-3.0.3 .github/workflows/sync_configs.yml
dry-effects-0.1.4 .github/workflows/sync_configs.yml
dry-matcher-0.8.3 .github/workflows/sync_configs.yml
dry-monads-1.3.5 .github/workflows/sync_configs.yml