rails / jsbundling-rails

Bundle and transpile JavaScript in Rails with esbuild, rollup.js, or Webpack.
MIT License
831 stars 143 forks source link

Support using `SKIP_JS_INSTALL` env variable as an alias for `SKIP_YARN_INSTALL`/`SKIP_BUN_INSTALL` #190

Open Fs00 opened 7 months ago

Fs00 commented 7 months ago

Support for NPM/PNPM was recently merged, but the name of the environment variable used to skip dependencies installation still refers to Yarn or Bun. This PR introduces a new unified name for the environment variable: SKIP_JS_INSTALL (which aims to be consistent with SKIP_JS_BUILD introduced in #144), to avoid referring to a specific package manager. SKIP_YARN_INSTALL and SKIP_BUN_INSTALL are obviously still there for backwards compatibility.

Fs00 commented 1 month ago

I've just seen that cssbundling-rails checks those environment variables too.

Should we use different names for the environment variable between the two gems (e.g. SKIP_JS_INSTALL for jsbundling / SKIP_CSS_INSTALL for cssbundling) or do we want to find a common generic name that works for both (e.g. SKIP_DEPS_INSTALL)? Once we've settled on a name, I can open a PR on cssbundling-rails repo too.