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

Tell Heroku to build the redesign CSS, too #704

Merged
merged 1 commit into from Oct 21, 2022
Merged

Conversation

joemasilotti
Copy link
Owner

Fix attempt for #703.

@joemasilotti joemasilotti merged commit e2980cf into main Oct 21, 2022
5 checks passed
@joemasilotti joemasilotti deleted the redesign/heroku branch October 21, 2022 16:48
unless system "yarn install && yarn build:redesign"
raise "Command css:redesign failed, ensure yarn is installed and `yarn build:redesign` runs without errors"
end

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

system is able to raise a more specific and verbose error if you pass exception: true to it.

https://rubyapi.org/3.1/o/kernel#method-i-system

Suggested change
unless system "yarn install && yarn build:redesign"
raise "Command css:redesign failed, ensure yarn is installed and `yarn build:redesign` runs without errors"
end
system "yarn install && yarn build:redesign", exception: true

Rails recently made a similar change to what I'm suggesting. rails/rails@24fbbe0

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good to know! Thanks for sharing.

I copy-pasted this from cssbundling-rails and jsbundling-rails. But for custom system calls I'll make sure to use exception: true in the future.

benmercerdev added a commit to benmercerdev/railsdevs.com that referenced this pull request Oct 28, 2022
* main: (31 commits)
  Github Actions changes (joemasilotti#717)
  represent json string with multine string syntax (joemasilotti#716)
  build: minify CSS via cssnano (joemasilotti#713)
  Set request variant for redesign requests (joemasilotti#714)
  Paywall location and timezone filters (joemasilotti#674)
  Fix tailwind postcss setup (joemasilotti#710)
  New fonts for the redesign (joemasilotti#708)
  Don't track `/developers/:id/:code` to Fathom (joemasilotti#706)
  Refactor `Users::PaywalledComponent` to remove business logic (joemasilotti#705)
  Tell Heroku to build the redesign CSS, too (joemasilotti#704)
  Multiple Tailwind CSS configs (for the redesign) (joemasilotti#701)
  Update to Tailwind CSS v3.2 (joemasilotti#700)
  Publicly shareable developer profile URLs (joemasilotti#665)
  Bump nokogiri from 1.13.8 to 1.13.9 (joemasilotti#697)
  Bump Turbo Package to 7.2.2 & Gem version to 1.3.1 (joemasilotti#696)
  Compress HTML output via gzip (joemasilotti#688)
  Bring back 1x and 2x avatars and remove lazy loading (joemasilotti#680)
  Fix test settings for Rubymine (joemasilotti#679)
  RailsDevs French Version (joemasilotti#687)
  Revert manual payments (joemasilotti#681)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants