z360519549

1、安装bower模块:

npm install -g bower --registry=http://registry.npm.taobao.org

2、创建.bowerrc 文件存放 前端相关的模块

test_163:/home/exenode/part3/scms # more .bowerrc
{
"directory":"public/lib"
}

3、安装 angular 和 bootstrap,需要先安装git 并且把git添加到系统环境变量中:

bower install --allow-root  -g --save angular  --registry=http://registry.npm.taobao.org

 bower install --allow-root  -g --save bootstrap  --registry=http://registry.npm.taobao.org

安装完成后,在 public/lib 目录下有 angular、 bootstrap 、jquery 三个模块。

test_163:/home/exenode/part3/scms/public/lib # l
total 20
drwxr-xr-x 5 root root 4096 May 16 14:55 ./
drwxr-xr-x 3 root root 4096 May 16 14:11 ../
drwxr-xr-x 2 root root 4096 May 16 14:53 angular/
drwxr-xr-x 8 root root 4096 May 16 14:55 bootstrap/
drwxr-xr-x 5 root root 4096 May 16 14:55 jquery/

 

分类:

技术点:

相关文章: