refactor(actions): nest binary and code runners under run-vociferate/
This commit is contained in:
@@ -66,7 +66,7 @@ runs:
|
||||
- name: Run binary
|
||||
id: run-binary
|
||||
if: steps.resolve-runtime.outputs.use_binary == 'true'
|
||||
uses: ../run-vociferate.binary
|
||||
uses: ./binary
|
||||
with:
|
||||
root: ${{ inputs.root }}
|
||||
version-file: ${{ inputs.version-file }}
|
||||
@@ -81,7 +81,7 @@ runs:
|
||||
- name: Run source
|
||||
id: run-code
|
||||
if: steps.resolve-runtime.outputs.use_binary != 'true'
|
||||
uses: ../run-vociferate.code
|
||||
uses: ./code
|
||||
with:
|
||||
root: ${{ inputs.root }}
|
||||
version-file: ${{ inputs.version-file }}
|
||||
|
||||
@@ -53,8 +53,12 @@ runs:
|
||||
set -euo pipefail
|
||||
|
||||
source_root="$GITHUB_ACTION_PATH"
|
||||
while [[ ! -f "$source_root/go.mod" ]] && [[ "$source_root" != "/" ]]; do
|
||||
source_root="$(realpath "$source_root/..")"
|
||||
done
|
||||
if [[ ! -f "$source_root/go.mod" ]]; then
|
||||
source_root="$(realpath "$GITHUB_ACTION_PATH/..")"
|
||||
echo "Could not locate Go module root from $GITHUB_ACTION_PATH" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
printf 'source_root=%s\n' "$source_root" >> "$GITHUB_OUTPUT"
|
||||
Reference in New Issue
Block a user