-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Copy actions from daos-stack/daos. These need to be published and commonly available. Skip-PR-comments: true Run-GHA: true Required-githooks: true Signed-off-by: Brian J. Murrell <[email protected]>
- Loading branch information
1 parent
206df77
commit e65371a
Showing
3 changed files
with
45 additions
and
3 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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
name: 'Import Commit Pragmas' | ||
description: 'Import Commit Pragmas' | ||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.pull_request.head.sha }} | ||
- run: . ci/gha_functions.sh; | ||
git show -s --format=%B | sed -e "s/'/'\"'\"'/g" | | ||
get_commit_pragmas | | ||
sed -e 's/^/CP_/' >> $GITHUB_ENV | ||
shell: bash |
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,28 @@ | ||
name: 'Set Variable from Commit Pragma' | ||
description: 'Set Variable from Commit Pragma' | ||
inputs: | ||
commit_message: | ||
description: Dequoted commit message | ||
required: true | ||
pragma: | ||
description: Pragma to make a variable from | ||
required: true | ||
default: | ||
description: Default value if pragma is not found | ||
required: false | ||
outputs: | ||
value: | ||
description: The value of the pragma | ||
value: ${{ steps.value.outputs.value }} | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Create Variable | ||
id: value | ||
shell: bash | ||
run: | | ||
. ci/gha_functions.sh | ||
set -eu | ||
eval $(echo '${{ inputs.commit_message }}' | get_commit_pragmas) | ||
echo "value=${${{ inputs.pragma }}:-${{ inputs.default }}}" >> $GITHUB_OUTPUT |
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