Skip to content

Ignore paths to watch like node_modules #512

Closed as not planned
Closed as not planned
@tom-spalding

Description

@tom-spalding

Hi is it possible to pass an ignore path param to the tailwindcss CLI? Long story short; I think it would be nice to ignore all node_modules directories.

More context:

The following is in my Procfile.dev, css: bin/rails tailwindcss:watch. My usecase is to avoid watching files in a large submodule. I have the common inotify_add_watch issue. Instead of bumping up my watchers every day like so

sudo vim /etc/sysctl.conf
sudo sysctl -p /etc/sysctl.conf

I think it would be nice to ignore all node_modules. Even without the large submodule issue, this seems like a common usecase I hope.

bin/dev
10:25:37 web.1  | started with pid 14116
10:25:37 css.1  | started with pid 14117
10:25:38 web.1  | => Booting Puma
10:25:38 web.1  | => Rails 8.0.2 application starting in development 
10:25:38 web.1  | => Run `bin/rails server --help` for more startup options
10:25:38 web.1  | Puma starting in single mode...
10:25:38 web.1  | * Puma version: 6.6.0 ("Return to Forever")
10:25:38 web.1  | * Ruby version: ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +YJIT +PRISM [x86_64-linux]
10:25:38 web.1  | *  Min threads: 3
10:25:38 web.1  | *  Max threads: 3
10:25:38 web.1  | *  Environment: development
10:25:38 web.1  | *          PID: 14116
10:25:38 web.1  | * Listening on http://127.0.0.1:3000
10:25:38 web.1  | * Listening on http://[::1]:3000
10:25:38 web.1  | Use Ctrl-C to stop
10:25:38 css.1  | sh: 1: watchman: not found
10:25:38 css.1  | error: inotify_add_watch on '/home/tom/projects/my_project/canvas/node_modules/@instructure/outcomes-ui/node_modules/@instructure/ui-flex/es/Flex/Item' failed: No space left on device
10:25:38 css.1  | 
10:25:38 css.1  | Bun v1.2.4 (Linux x64 baseline)
10:25:39 css.1  | exited with code 0
10:25:39 system | sending SIGTERM to all processes
10:25:39 web.1  | - Gracefully stopping, waiting for requests to finish
10:25:39 web.1  | Exiting
10:25:39 web.1  | terminated by SIGTERM

Thanks for the great project! - Tom

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions