Skip to content

Commit

Permalink
fix montage flow
Browse files Browse the repository at this point in the history
  • Loading branch information
gadfort committed Jan 26, 2024
1 parent 2787050 commit ba5cd17
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions .github/workflows/montage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,25 +22,27 @@ jobs:
uses: actions/download-artifact@v4
with:
name: images
path: gallery
run-id: ${{ inputs.workflow-id }}
github-token: ${{ github.token }}

- name: Handle requirements
run: |
sudo apt-get update
sudo apt-get install -y imagemagick
SC_VERSION=$(ls)
SC_VERSION=$(ls gallery)
echo SC_VERSION="$SC_VERSION" > $GITHUB_ENV
- name: Resize
run:
cd ${{ env.SC_VERSION }}
run: |
cd gallery/${{ env.SC_VERSION }}
mkdir -p ./resized
find . -maxdepth 1 -name "*.png" -exec convert -resize 50% {} ./resized/{} \;
- name: Montage
run:
run: |
mkdir -p ./resized
montage -background '#000000' -geometry +1+1 ${{ env.SC_VERSION }}/resized/*.png montage.jpg
montage -background '#000000' -geometry +1+1 gallery/${{ env.SC_VERSION }}/resized/*.png montage.jpg
mv montage.jpg images/
- name: Upload
Expand Down

0 comments on commit ba5cd17

Please sign in to comment.