fix
This commit is contained in:
@@ -72,6 +72,14 @@ runs:
|
|||||||
- name: "Extract information about first file."
|
- name: "Extract information about first file."
|
||||||
id: extract
|
id: extract
|
||||||
run: |
|
run: |
|
||||||
|
NAME="Find First"
|
||||||
|
echo "::group::$NAME - Inputs"
|
||||||
|
echo "${{ toJSON(inputs) }}"
|
||||||
|
echo "::endgroup::"
|
||||||
|
|
||||||
bash "${{ github.action_path }}/find-first.sh" "${{ steps.find.outputs.files }}"
|
bash "${{ github.action_path }}/find-first.sh" "${{ steps.find.outputs.files }}"
|
||||||
|
|
||||||
|
echo "::group::$NAME - Outputs"
|
||||||
cat "$GITHUB_OUTPUT"
|
cat "$GITHUB_OUTPUT"
|
||||||
|
echo "::endgroup::"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|||||||
@@ -45,6 +45,15 @@ runs:
|
|||||||
- name: "Find files."
|
- name: "Find files."
|
||||||
id: find
|
id: find
|
||||||
run: |
|
run: |
|
||||||
|
NAME="Find"
|
||||||
|
echo "::group::$NAME - Inputs"
|
||||||
|
echo "${{ toJSON(inputs) }}"
|
||||||
|
echo "::endgroup::"
|
||||||
|
|
||||||
bash "${{ github.action_path }}/find.sh" "${{ inputs.path }}" "${{ inputs.pattern }}" "${{ inputs.type }}" \
|
bash "${{ github.action_path }}/find.sh" "${{ inputs.path }}" "${{ inputs.pattern }}" "${{ inputs.type }}" \
|
||||||
"${{ inputs.maxDepth }}" "${{ inputs.minDepth }}" "${{ inputs.size }}" "${{ inputs.modified }}" "${{ inputs.additionalArgs }}"
|
"${{ inputs.maxDepth }}" "${{ inputs.minDepth }}" "${{ inputs.size }}" "${{ inputs.modified }}" "${{ inputs.additionalArgs }}"
|
||||||
|
|
||||||
|
echo "::group::$NAME - Outputs"
|
||||||
|
cat "$GITHUB_OUTPUT"
|
||||||
|
echo "::endgroup::"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|||||||
@@ -18,11 +18,6 @@ fi
|
|||||||
# Build the find command - start with basic find and path
|
# Build the find command - start with basic find and path
|
||||||
FIND_CMD="find \"$SEARCH_PATH\""
|
FIND_CMD="find \"$SEARCH_PATH\""
|
||||||
|
|
||||||
if [[ -n "$FILE_TYPE" ]]; then
|
|
||||||
# Add type filter first
|
|
||||||
FIND_CMD="$FIND_CMD -type $FILE_TYPE"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Add depth constraints before name pattern
|
# Add depth constraints before name pattern
|
||||||
if [[ -n "$MAX_DEPTH" ]]; then
|
if [[ -n "$MAX_DEPTH" ]]; then
|
||||||
FIND_CMD="$FIND_CMD -maxdepth $MAX_DEPTH"
|
FIND_CMD="$FIND_CMD -maxdepth $MAX_DEPTH"
|
||||||
@@ -32,6 +27,11 @@ if [[ -n "$MIN_DEPTH" ]]; then
|
|||||||
FIND_CMD="$FIND_CMD -mindepth $MIN_DEPTH"
|
FIND_CMD="$FIND_CMD -mindepth $MIN_DEPTH"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ -n "$FILE_TYPE" ]]; then
|
||||||
|
# Add type filter first
|
||||||
|
FIND_CMD="$FIND_CMD -type $FILE_TYPE"
|
||||||
|
fi
|
||||||
|
|
||||||
# Add name pattern
|
# Add name pattern
|
||||||
FIND_CMD="$FIND_CMD -name \"$PATTERN\""
|
FIND_CMD="$FIND_CMD -name \"$PATTERN\""
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user