Subversion Repositories wimsdev

Rev

Rev 11388 | Rev 13728 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 11388 Rev 13570
Line 1... Line 1...
1
We use `Bower` to automatically download JS packages/plugins,
1
We use `Yarn` to automatically download JS packages/plugins,
2
And then we use `Grunt` to perform special tasks (concat, minify, verify ...)
2
And then we use `Grunt` to perform special tasks (concat, minify, verify ...)
3
 
3
 
4
# Installation
4
# Installation
5
--------------
5
--------------
6
 
6
 
7
## Install Dependencies :
7
## Install Yarn :
8
*  You need to install node, npm and git.
-
 
9
*  See here : [install Bower](http://bower.io#install-bower)
8
*  See here : [install Yarn](https://yarnpkg.com)
10
 
-
 
11
## Install Bower :
-
 
12
    npm install -g bower
9
    brew install yarn
13
 
10
 
14
## Install Grunt :
11
## Install Grunt :
15
    npm update
12
    npm update
16
    npm install -g grunt-cli
13
    npm install -g grunt-cli
17
 
14
 
18
 
15
 
19
# Upgrade package manager
16
# Upgrade package manager
20
-------------------------
17
-------------------------
21
from `_packages` directory :
18
from `_packages` directory :
22
 
19
 
23
    npm update
20
    yarn update
24
    npm install -g bower
-
 
25
    npm install -g grunt-cli
-
 
26
    bower update -p
-
 
27
 
21
 
28
 
22
 
29
# Manage Bower Packages
23
# Manage Bower Packages
30
-----------------------
24
-----------------------
31
 
25
 
32
## List all installed plugins :
26
## Audit each dependency if there is a known issue to fix :
33
    bower list
27
    yarn audit
34
 
28
 
35
## Update Javascripts plugins via Bower :
29
## Update Javascripts plugins via Bower :
36
    bower update --save
30
    yarn upgrade
37
*nb : After each jquery-ui update, look at these URL :*
31
*nb : After each jquery-ui update, look at these URL :*
38
 
32
 
39
* Tabs : [searchform](http://localhost/wims/wims.cgi?cmd=new&module=home&search_keywords=oef&search_category=A&search_lang=fr#searchform)
33
* Tabs : [searchform](http://localhost/wims/wims.cgi?cmd=new&module=home&search_keywords=oef&search_category=A&search_lang=fr#searchform)
40
* Menu : [H6/algebra/docnatural.fr](http://localhost/wims/wims.cgi?module=H6/algebra/docnatural.fr)
34
* Menu : [H6/algebra/docnatural.fr](http://localhost/wims/wims.cgi?module=H6/algebra/docnatural.fr)
41
 
-
 
42
## Update Javascripts plugins for production (without devDepedencies) :
-
 
43
    bower update -p
-
 
44
 
35
 
45
 
36
 
46
# Download new Package(s)
37
# Download new Package(s)
47
-------------------------
38
-------------------------
48
    bower install <package> --save
39
    yarn add <package>
49
 
40
 
50
 
41
 
51
# Migrate files from _packages/ to wims/
42
# Migrate files from _packages/ to wims/
52
  #  After each update, Grunt is handy to automatically compress js + css, and move each files at is wims destination. simply call "grunt"
43
  #  After each update, Grunt is handy to automatically compress js + css, and move each files at is wims destination. simply call "grunt"
53
 
44
 
54
    grunt
45
    grunt
55
 
46
 
56
#  Documentations
47
#  Documentations
57
-----------------
48
-----------------
58
* [Bower docs](http://bower.io/docs/creating-packages/)
49
* [Yarn docs](https://yarnpkg.com/docs)
59
* [Grunt HowTo (video fr)](http://www.grafikart.fr/tutoriels/grunt/grunt-introduction-470)
50
* [Grunt HowTo (video fr)](http://www.grafikart.fr/tutoriels/grunt/grunt-introduction-470)
60
* [Grunt "getting started"](http://gruntjs.com/getting-started)
51
* [Grunt "getting started"](http://gruntjs.com/getting-started)