Skip to content

Commit d248af6

Browse files
committed
store the workflow path
so we're working out of the project root in the action workspace
1 parent 90c8f92 commit d248af6

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

action.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ runs:
2121
shell: bash
2222
env:
2323
PLUGIN_PATH: ${{ inputs.plugin-path }}
24+
DRY_RUN: ${{ inputs.dry-run }}
25+
WORKFLOW_PATH: ${{ github.workspace }}
2426
run: bash bin/validate-plugin-version.sh ${{ inputs.plugin-path }}
2527
# - name: Create Pull Request
2628
# if: # something here

bin/validate-plugin-version.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@ IFS=$'\n\t'
55
main(){
66
# If $PLUGIN_PATH is defined, echo it.
77
if [[ -n "${PLUGIN_PATH:-}" ]]; then
8+
PLUGIN_PATH=${WORKFLOW_PATH}/${PLUGIN_PATH}
89
echo "Plugin path: $PLUGIN_PATH"
910
else
1011
local PLUGIN_PATH
1112
# By default, the plugin path is the root directory of the project that has this action.
12-
PLUGIN_PATH=$(pwd)
13+
PLUGIN_PATH=$WORKFLOW_PATH
1314
echo "Plugin path: $PLUGIN_PATH"
1415
fi
1516

0 commit comments

Comments
 (0)