Skip to content

Commit fc75314

Browse files
committed
CI: Generate sprockets manifest before installing Solidus
This needs be done before we are able to run any rails commands in the rails apps folder. See rails/sprockets-rails#546
1 parent 364116e commit fc75314

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/actions/install_solidus/action.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,4 +56,14 @@ runs:
5656
cd $RUNNER_TEMP/my_app
5757
bundle add solidus --path "$(ruby -e"puts File.expand_path ENV['GITHUB_WORKSPACE']")"
5858
unset RAILS_ENV # avoid doing everything on the test environment
59+
60+
# Due to [a bug in `sprockets-rails`](https://github.com/rails/sprockets-rails/pull/546) we need to manually add
61+
# the sprockets manifest into the generated rails app **before** running any rails commands inside the rails app folder.
62+
mkdir -p app/assets/config
63+
cat <<MANIFEST > app/assets/config/manifest.js
64+
//= link_tree ../images
65+
//= link_directory ../javascripts .js
66+
//= link_directory ../stylesheets .css
67+
MANIFEST
68+
5969
bin/rails generate solidus:install --auto-accept ${{ inputs.flags }}

0 commit comments

Comments
 (0)