我需要在PhpStorm中安装Gulp。
我的操作系统:ubuntu 16.04。
我的PhpStorm:2016.3.3。
如何在PhpStorm中安装Gulp?
我需要使用gulpfile.js
修改1:
运行此命令后,显示以下错误:
sudo apt-get install nodejs
显示错误:
E: Some packages could not be authenticated
编辑2:
运行sudo apt-get update
后显示此错误:
W: GPG error: https://deb.nodesource.com/node_7.x xenial InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 1655A0AB68576280
W: The repository 'https://deb.nodesource.com/node_7.x xenial InRelease' is not signed.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://ppa.launchpad.net/chris-lea/node.js/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch http://ppa.launchpad.net/chris-lea/node.js/ubuntu/dists/xenial/main/binary-amd64/Packages 404 Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.
答案 0 :(得分:2)
首先,您必须安装node和npm。使用Linux,您可以使用
sudo apt-get update
sudo apt-get install nodejs
sudo apt-get install npm
执行此操作后,您可以使用next命令安装gulp:
npm init
npm install gulp-cli -g
npm install gulp --save-dev
分别是:
gulp
命令,并且必须在您的计算机上保持全局package.json
文件已经完成了。
JavaScript的优点是您需要源代码来运行extern包或库。您甚至可以将所有内容与ASP.NET应用程序结合使用来转换SaSS或SCSS。