Skip to content

Commit

Permalink
Merge pull request #6121 from Formasitchijoh/imagemagick-failure
Browse files Browse the repository at this point in the history
Fix: integrated imagemagick into github workflow and resolved build failure
  • Loading branch information
ragesoss authored Jan 14, 2025
2 parents e635147 + fc684e2 commit 63fd7d7
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
28 changes: 27 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,32 @@ jobs:
with:
pandoc-version: '2.9.2.1'

- name: install ImageMagick
uses: mfinelli/setup-imagemagick@v6
with:
cache: true

# Cache ImageMagick binaries
- name: Cache Latest ImageMagick
uses: actions/cache@v3
with:
path: /home/runner/bin/magick
key: ${{ runner.os }}-imagemagick-latest
restore-keys: |
${{ runner.os }}-imagemagick-latest
# Update PATH for ImageMagick
- name: Update PATH for ImageMagick
run: echo "/home/runner/bin" >> $GITHUB_PATH

- name: Create symlink for identify and convert
run: |
for cmd in identify convert; do
if ! [ -x "$(command -v $cmd)" ]; then
sudo ln -s $(which magick) /usr/bin/$cmd
fi
done
- name: setup Redis
uses: supercharge/[email protected]

Expand Down Expand Up @@ -91,4 +117,4 @@ jobs:
if-no-files-found: ignore

- name: Ruby linting
run: bundle exec rubocop
run: bundle exec rubocop
2 changes: 2 additions & 0 deletions config/environments/test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ def dump_js_coverage
# Settings specified here will take
# precedence over those in config/application.rb.

Paperclip.options[:command_path] = "/usr/bin"

# The test environment is used exclusively to run your application's
# test suite. You never need to work with it otherwise. Remember that
# your test database is "scratch space" for the test suite and is wiped
Expand Down

0 comments on commit 63fd7d7

Please sign in to comment.