是否可以创建无需安装即可运行的 NPM 脚本?
Is it possible to create an NPM script that runs without being installed?
我在 HiFaraz to easily install best-practice packages for the Atom text editor. The script 旁边制作了一个小脚本,只是 运行 一些 apm install ...
命令,不需要安装到 node_modules(或曾经使用过再次)。我们决定将它添加到 NPM 以使其更容易找到并且更容易 运行。
有没有办法 运行-一次删除 NPM 脚本?也许添加一个 post-install 脚本?
在这种情况下,更好的选择是为应该执行的脚本本身提供 link,例如 zsh installation sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
。所以在你的情况下命令应该是:
sh -c "$(curl -fsSL https://raw.githubusercontent.com/HiFaraz/atom-starter-pack/master/installer.sh)"
我在 HiFaraz to easily install best-practice packages for the Atom text editor. The script 旁边制作了一个小脚本,只是 运行 一些 apm install ...
命令,不需要安装到 node_modules(或曾经使用过再次)。我们决定将它添加到 NPM 以使其更容易找到并且更容易 运行。
有没有办法 运行-一次删除 NPM 脚本?也许添加一个 post-install 脚本?
在这种情况下,更好的选择是为应该执行的脚本本身提供 link,例如 zsh installation sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
。所以在你的情况下命令应该是:
sh -c "$(curl -fsSL https://raw.githubusercontent.com/HiFaraz/atom-starter-pack/master/installer.sh)"