Skip to content

Commit

Permalink
Add some human-friendly comments that display in the Action output.
Browse files Browse the repository at this point in the history
  • Loading branch information
aholmes committed Feb 3, 2023
1 parent 640be62 commit 085aa8d
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,17 @@ runs:
- name: Get commit range
id: commit-range
shell: bash
run: echo "COMMITISH=$(${{ github.action_path }}/scripts/get-commitish.sh '${{ github.event.before }}' '${{ github.sha }}')" >> $GITHUB_OUTPUT
run: |
echo Finding relevant commit range for changed PUML files ...
echo "COMMITISH=$(${{ github.action_path }}/scripts/get-commitish.sh '${{ github.event.before }}' '${{ github.sha }}')" >> $GITHUB_OUTPUT
- name: Get parsable changed file names
id: parsable-files
shell: bash
env:
COMMITISH: ${{ steps.commit-range.outputs.COMMITISH }}
run: |
echo Parsing changed PUML file names ...
CHANGED_FILES=$( \
${{ github.action_path }}/scripts/get-changed-files.sh \
| ${{ github.action_path }}/scripts/get-shell-parsable-files.awk)
Expand All @@ -33,13 +36,16 @@ runs:
shell: bash
env:
CHANGED_FILES: ${{ steps.parsable-files.outputs.CHANGED_FILES }}
run: echo $(${{ github.action_path }}/scripts/get-shell-safe-files.sh) >> $GITHUB_OUTPUT
run: |
echo Sanitizing changed PUML file names for shell safety ...
echo $(${{ github.action_path }}/scripts/get-shell-safe-files.sh) >> $GITHUB_OUTPUT
- name: Removed PUML files detected
id: detected-removed-files
shell: bash
if: success()
run: |
echo Checking for removed PUML files ...
set -o pipefail
orphaned_files='${{ steps.changed-plantuml-files.outputs.orphaned_files}}'
if [[ $orphaned_files == "" ]]; then
Expand All @@ -53,6 +59,7 @@ runs:
shell: bash
if: success()
run: |
echo Checking for modified PUML files ...
set -o pipefail
modified_files='${{ steps.changed-plantuml-files.outputs.modified_files }}'
if [[ $modified_files == "" ]]; then
Expand All @@ -66,6 +73,7 @@ runs:
shell: bash
if: success() && steps.changed-plantuml-files.outputs.orphaned_files != ''
run: |
echo Removing orphaned SVG files ...
set -o pipefail
rm ${{ steps.changed-plantuml-files.outputs.orphaned_files }}
Expand Down

0 comments on commit 085aa8d

Please sign in to comment.