forked from rodjek/puppet-lint
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(MAINT) Add CI and release workflows
- Loading branch information
Showing
3 changed files
with
44 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,66 +1,20 @@ | ||
name: CI | ||
name: "ci" | ||
|
||
on: | ||
push: | ||
branches: [master] | ||
branches: | ||
- master | ||
pull_request: | ||
branches: [master] | ||
branches: | ||
- master | ||
schedule: | ||
- cron: "3 0 * * *" | ||
- cron: "0 0 * * *" | ||
workflow_dispatch: | ||
|
||
jobs: | ||
lint: | ||
name: RuboCop | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: 2.7 | ||
bundler-cache: true | ||
- run: bundle exec rake rubocop | ||
release: | ||
uses: "puppetlabs/cat-github-actions/.github/workflows/gem_ci.yml@main" | ||
with: | ||
with_acceptance: "false" | ||
secrets: "inherit" | ||
|
||
spec: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: ["ubuntu-latest", "windows-latest"] | ||
ruby: | ||
- "2.4" | ||
- "2.5" | ||
- "2.7" | ||
needs: lint | ||
name: RSpec - ${{ matrix.os }} - Ruby ${{ matrix.ruby }} | ||
runs-on: ${{ matrix.os }} | ||
env: | ||
COVERAGE: yes | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
- run: bundle exec rake | ||
|
||
release_tests: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: ["ubuntu-latest", "windows-latest"] | ||
ruby: | ||
- "2.4" | ||
- "2.5" | ||
- "2.7" | ||
needs: lint | ||
name: Release Tests - ${{ matrix.os }} - Ruby ${{ matrix.ruby }} | ||
runs-on: ${{ matrix.os }} | ||
env: | ||
BUNDLE_WITHOUT: development system_tests | ||
CHECK: ci | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
- run: bundle exec rake ci |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: "Release" | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
target: | ||
description: "The target for the release. This can be a commit sha or a branch." | ||
required: false | ||
default: "main" | ||
|
||
jobs: | ||
release: | ||
uses: "puppetlabs/cat-github-actions/.github/workflows/gem_release.yml@main" | ||
with: | ||
target: "${{ github.event.inputs.target }}" | ||
secrets: "inherit" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: "Release Prep" | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
target: | ||
description: "The target for the release. This can be a commit sha or a branch." | ||
required: false | ||
default: "main" | ||
|
||
jobs: | ||
release_prep: | ||
uses: "puppetlabs/cat-github-actions/.github/workflows/gem_release_prep.yml@main" | ||
with: | ||
target: "${{ github.event.inputs.target }}" | ||
secrets: "inherit" |