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

Update makefile section in tailwindcss #1890

Closed
wants to merge 3 commits into from
Closed

Conversation

amitaibu
Copy link
Collaborator

No description provided.

tailwind-dev:
tailwindcss -c tailwind/tailwind.config.js -i ./tailwind/app.css -o static/app.css --watch
# Install npm packages.
node_modules:
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

image

Copy link
Member

Choose a reason for hiding this comment

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

Likely because you already have a node_modules directory. Can you delete it and try again?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I have tried again (using this PR), but the same message

image

tailwindcss -c tailwind/tailwind.config.js -i ./tailwind/app.css -o static/app.css --watch
# Install npm packages.
node_modules:
NODE_ENV=production npm ci
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Why do we need NODE_ENV=production?

Copy link
Member

Choose a reason for hiding this comment

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

So it doesn't install devDependencies

Guide/tailwindcss.markdown Outdated Show resolved Hide resolved
node_modules:
NODE_ENV=production npm ci

# We rely on the `node_modules`. So if `node_modules` directory doesn't exist, calling `make tailwind-dev` will trigger `make node_modules`.
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

So if node_modules directory doesn't exist

As make node_modules didn't work for me I wasn't able to confirm this.

@amitaibu
Copy link
Collaborator Author

@mpscholten some questions ^^

Guide/tailwindcss.markdown Outdated Show resolved Hide resolved
static/app.css:
tailwindcss -c tailwind/tailwind.config.js -i ./tailwind/app.css -o static/app.css --minify
static/app.css: node_modules
NODE_ENV=production node_modules/.bin/tailwind -c tailwind/tailwind.config.js -i ./tailwind/app.css -o static/app.css --minify
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Suggested change
NODE_ENV=production node_modules/.bin/tailwind -c tailwind/tailwind.config.js -i ./tailwind/app.css -o static/app.css --minify
node_modules/.bin/tailwindcss -c tailwind/tailwind.config.js -i ./tailwind/app.css -o static/app.css --minify

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

AFAIK NODE_ENV=production was needed before purging was automatic

@amitaibu amitaibu closed this Feb 16, 2024
@amitaibu
Copy link
Collaborator Author

Closed in favor of #1905

@amitaibu amitaibu deleted the amitaibu-patch-3 branch February 16, 2024 21:46
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