Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add pattern matching to input files #4

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion entrypoint
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,15 @@ repository=${INPUT_REPOSITORY?Please specify a repository}

# "files" array:
if [ -n "$INPUT_FILES" ]; then
IFS=' ' read -r -a files <<< "$INPUT_FILES"
IFS=' ' read -r -a input_files <<<"$INPUT_FILES"

# Parse pattern matching in input files
files=()
for input_file in "${input_files[@]}"; do
for line in $(compgen -G "${input_file}"); do
files+=(${line})
done
done
else
# Use all debs in current directory
files=(*.deb)
Expand Down