-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix!: Move release and upload into the please-release step
- Allows us to also upload the gem artifact to the releases page Signed-off-by: Dan Webb <[email protected]>
- Loading branch information
Showing
3 changed files
with
40 additions
and
40 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 |
---|---|---|
|
@@ -7,3 +7,17 @@ name: "Lint Unit" | |
jobs: | ||
lint-unit: | ||
uses: test-kitchen/.github/.github/workflows/lint-unit.yml@main | ||
|
||
pre-release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: google-github-actions/release-please-action@v3 | ||
id: release | ||
with: | ||
release-type: ruby | ||
package-name: kitchen-hyperv | ||
version-file: lib/kitchen/driver/hyperv_version.rb | ||
token: ${{ secrets.PUBLISH_WORKFLOW_TOKEN }} | ||
signoff: "Dan Webb <[email protected]>" | ||
changelog-notes-type: github | ||
prerelease: true |
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 |
---|---|---|
|
@@ -2,33 +2,47 @@ | |
"on": | ||
push: | ||
branches: [main] | ||
pull_request: | ||
|
||
name: release-please | ||
jobs: | ||
release-please: | ||
runs-on: ubuntu-latest | ||
if: github.ref != 'refs/heads/main' | ||
steps: | ||
- uses: google-github-actions/release-please-action@v3 | ||
id: release | ||
with: | ||
release-type: ruby | ||
package-name: kitchen-hyperv | ||
version-file: lib/kitchen/driver/hyperv_version.rb | ||
token: ${{ secrets.PUBLISH_WORKFLOW_TOKEN }} | ||
signoff: "Dan Webb <[email protected]>" | ||
prerelease: true | ||
changelog-notes-type: github | ||
|
||
release-please-main: | ||
- name: Upload Release Artifact | ||
if: ${{ steps.release.outputs.release_created }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
find . -name '*.gemspec' -maxdepth 1 -exec gem build {} \; | ||
gh release upload ${{ steps.release.outputs.tag_name }} *.gem | ||
publish-to-github: | ||
runs-on: ubuntu-latest | ||
if: github.ref == 'refs/heads/main' | ||
steps: | ||
- uses: google-github-actions/release-please-action@v3 | ||
- uses: actions/checkout@v3 | ||
- name: Build and publish to GitHub Package | ||
if: ${{ steps.release.outputs.release_created }} | ||
uses: actionshub/[email protected] | ||
with: | ||
release-type: ruby | ||
package-name: kitchen-hyperv | ||
version-file: lib/kitchen/driver/hyperv_version.rb | ||
token: ${{ secrets.PUBLISH_WORKFLOW_TOKEN }} | ||
signoff: "Dan Webb <[email protected]>" | ||
changelog-notes-type: github | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
owner: ${{ secrets.OWNER }} | ||
|
||
publish-to-rubygems: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Build and publish to RubyGems | ||
if: ${{ steps.release.outputs.release_created }} | ||
uses: actionshub/[email protected] | ||
with: | ||
api_key: ${{ secrets.RUBY_GEMS_API_KEY }} |
This file was deleted.
Oops, something went wrong.