Skip to content

Commit 673b187

Browse files
authored
Fix #2
1 parent cbc42fb commit 673b187

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

action.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ runs:
2020
run: |
2121
sudo apt-get update -yq
2222
aptHash(){ echo "$1-$(apt-cache policy "$1" | grep -oP '(?<=Candidate:\s)(.+)')"; }
23-
echo "packagesHash=$(echo "${{ inputs.packages }}" | xargs -rn1 | tr '\n' '-' | md5sum | cut -f 1 -d ' ')" >> $GITHUB_ENV
23+
export -f aptHash
24+
hash=$(echo "${{ inputs.packages }}" | xargs -rI {} bash -c 'aptHash {}' | tr '\n' '-')
25+
echo "packagesHash=${hash%-}" >> $GITHUB_ENV
2426
- name: Cache deb files
2527
uses: actions/cache@v4
2628
with:

0 commit comments

Comments
 (0)