-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into DEVOPS-1333-Add-code-signing-to-the-bws-CLI-…
…windows
- Loading branch information
Showing
2 changed files
with
25 additions
and
11 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 |
---|---|---|
|
@@ -8,8 +8,6 @@ on: | |
- main | ||
- rc | ||
- hotfix-rc | ||
paths: | ||
- "crates/**" | ||
|
||
jobs: | ||
build_rust: | ||
|
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 |
---|---|---|
|
@@ -12,9 +12,10 @@ on: | |
options: | ||
- Release | ||
- Dry Run | ||
permissions: | ||
id-token: write | ||
contents: write | ||
|
||
permissions: | ||
contents: read | ||
id-token: write | ||
|
||
jobs: | ||
setup: | ||
|
@@ -105,12 +106,27 @@ jobs: | |
for ((i=0; i<${#platforms[@]}; i++)); do | ||
cp "temp/${platforms[$i]}/${files[$i]}" "languages/ruby/bitwarden_sdk_secrets/lib/${platforms[$i]}/${files[$i]}" | ||
done | ||
shell: bash | ||
- name: Build gem | ||
run: gem build bitwarden-sdk-secrets.gemspec | ||
- name: bundle install | ||
run: bundle install | ||
working-directory: languages/ruby/bitwarden_sdk_secrets | ||
|
||
- name: Push gem to Rubygems | ||
if: ${{ github.event.inputs.release_type != 'Dry Run' }} | ||
uses: rubygems/release-gem@035c7c1c1c14d277318867ced5037926d2395300 # v1.0.1 | ||
- name: Set remote URL | ||
run: | | ||
# Attribute commits to the last committer on HEAD | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "bitwarden-devops-bot" | ||
git remote set-url origin "https://x-access-token:${{ github.token }}@github.com/$GITHUB_REPOSITORY" | ||
- name: Configure trusted publishing credentials | ||
uses: rubygems/configure-rubygems-credentials@bc6dd217f8a4f919d6835fcfefd470ef821f5c44 # v1.0.0 | ||
|
||
- name: Run release rake task | ||
if: ${{ inputs.release_type == 'Release' }} | ||
run: bundle exec rake release | ||
working-directory: languages/ruby/bitwarden_sdk_secrets | ||
|
||
- name: Wait for release to propagate | ||
if: ${{ inputs.release_type == 'Release' }} | ||
run: gem exec rubygems-await pkg/*.gem | ||
working-directory: languages/ruby/bitwarden_sdk_secrets |