Skip to content

Fix "Update Tailwind" action #48

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

Merged
merged 1 commit into from
Aug 18, 2021

Conversation

jonathanhefner
Copy link
Member

@jonathanhefner jonathanhefner commented Feb 22, 2021

tailwindcss-cli build chokes on require('tailwindcss/defaultTheme') in tailwind.config.js added by 53089c1. Example failure: https://github.com/rails/tailwindcss-rails/runs/1725407564.

tailwind build, which is invoked by yarn build, handles this properly. Running yarn upgrade tailwindcss beforehand ensures that the tailwind build command is installed, and updates the Tailwind version in yarn.lock to match the built tailwind.css.


Example success after this change: https://github.com/jonathanhefner/tailwindcss-rails/runs/1954932857. Resulting commit: jonathanhefner@9dd1367.

`tailwindcss-cli build` chokes on `require('tailwindcss/defaultTheme')`
in tailwind.config.js added by 53089c1.
Example failure: https://github.com/rails/tailwindcss-rails/runs/1725407564.

`tailwind build`, which is invoked by `yarn build`, handles this
properly.  Running `yarn upgrade tailwindcss` beforehand ensures that
the `tailwind build` command is installed, and updates the Tailwind
version in yarn.lock to match the built tailwind.css.
@dhh dhh merged commit ca9d842 into rails:main Aug 18, 2021
jonathanhefner added a commit to jonathanhefner/tailwindcss-rails that referenced this pull request Aug 31, 2021
Follow-up to rails#48.

This prevents commits that only update `yarn.lock`, such as
2338bd6.
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.

2 participants