Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit f56125d

Browse files
matskoIgorMinar
authored andcommitted
chore(ngdocs): setup bower as the package manager for the docs pages
1 parent 079bf5f commit f56125d

30 files changed

+122
-18112
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,6 @@ performance/temp*.html
1010
*~
1111
angular.js.tmproj
1212
node_modules
13+
components
1314
angular.xcodeproj
1415
.idea

Gruntfile.js

Lines changed: 15 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ module.exports = function(grunt) {
77
grunt.loadNpmTasks('grunt-contrib-copy');
88
grunt.loadNpmTasks('grunt-contrib-connect');
99
grunt.loadNpmTasks('grunt-contrib-compress');
10+
grunt.loadNpmTasks('grunt-shell');
1011
grunt.loadTasks('lib/grunt');
1112

1213
var NG_VERSION = util.getVersion();
@@ -63,11 +64,21 @@ module.exports = function(grunt) {
6364
clean: {build: ['build']},
6465

6566

67+
shell: {
68+
bower: {
69+
command: './node_modules/bower/bin/bower install',
70+
options: {
71+
stdout: false
72+
}
73+
}
74+
},
75+
76+
6677
build: {
6778
scenario: {
6879
dest: 'build/angular-scenario.js',
6980
src: [
70-
'lib/jquery/jquery.js',
81+
'components/jquery/jquery.js',
7182
util.wrap([files['angularSrc'], files['angularScenario']], 'ngScenario/angular')
7283
],
7384
styles: {
@@ -124,18 +135,6 @@ module.exports = function(grunt) {
124135
cookies: {
125136
dest: 'build/angular-cookies.js',
126137
src: util.wrap(['src/ngCookies/cookies.js'], 'module')
127-
},
128-
bootstrap: {
129-
dest: 'build/docs/components/angular-bootstrap.js',
130-
src: util.wrap(['docs/components/bootstrap/bootstrap.js'], 'module')
131-
},
132-
bootstrapPrettify: {
133-
dest: 'build/docs/components/angular-bootstrap-prettify.js',
134-
src: util.wrap(['docs/components/bootstrap/bootstrap-prettify.js', 'docs/components/bootstrap/google-prettify/prettify.js'], 'module'),
135-
styles: {
136-
css: ['docs/components/bootstrap/google-prettify/prettify.css'],
137-
minify: true
138-
}
139138
}
140139
},
141140

@@ -147,9 +146,7 @@ module.exports = function(grunt) {
147146
mobile: 'build/angular-mobile.js',
148147
resource: 'build/angular-resource.js',
149148
route: 'build/angular-route.js',
150-
sanitize: 'build/angular-sanitize.js',
151-
bootstrap: 'build/docs/components/angular-bootstrap.js',
152-
bootstrapPrettify: 'build/docs/components/angular-bootstrap-prettify.js',
149+
sanitize: 'build/angular-sanitize.js'
153150
},
154151

155152

@@ -184,9 +181,9 @@ module.exports = function(grunt) {
184181

185182
//alias tasks
186183
grunt.registerTask('test:unit', ['test:jqlite', 'test:jquery', 'test:modules']);
187-
grunt.registerTask('minify', ['clean', 'build', 'minall']);
184+
grunt.registerTask('minify', ['shell:bower','clean', 'build', 'minall']);
188185
grunt.registerTask('test:e2e', ['connect:testserver', 'test:end2end']);
189186
grunt.registerTask('webserver', ['connect:devserver']);
190-
grunt.registerTask('package', ['clean', 'buildall', 'minall', 'docs', 'copy', 'write', 'compress']);
187+
grunt.registerTask('package', ['shell:bower','clean', 'buildall', 'minall', 'docs', 'copy', 'write', 'compress']);
191188
grunt.registerTask('default', ['package']);
192189
};

angularFiles.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ angularFiles = {
7979
'src/ngMobile/directive/ngClick.js',
8080
'src/ngMobile/directive/ngSwipe.js',
8181

82-
'docs/components/bootstrap/bootstrap.js'
82+
'docs/components/angular-bootstrap/bootstrap.js'
8383
],
8484

8585
'angularScenario': [
@@ -120,7 +120,7 @@ angularFiles = {
120120
'jstd': [
121121
'lib/jasmine/jasmine.js',
122122
'lib/jasmine-jstd-adapter/JasmineAdapter.js',
123-
'lib/jquery/jquery.js',
123+
'components/jquery/jquery.js',
124124
'test/jquery_remove.js',
125125
'@angularSrc',
126126
'src/publishExternalApis.js',
@@ -180,7 +180,7 @@ angularFiles = {
180180
'jstdJquery': [
181181
'lib/jasmine/jasmine.js',
182182
'lib/jasmine-jstd-adapter/JasmineAdapter.js',
183-
'lib/jquery/jquery.js',
183+
'components/jquery/jquery.js',
184184
'test/jquery_alias.js',
185185
'@angularSrc',
186186
'src/publishExternalApis.js',

bower.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"name": "AngularJS",
3+
"devDependencies": {
4+
"jquery": "git://github.com/components/jquery.git#v1.8.3",
5+
"lunr.js": "0.3.1",
6+
"google-code-prettify": "1.0.0",
7+
"components-font-awesome": "3.1.0",
8+
"bootstrap": "https://raw.github.com/twitter/bootstrap/v2.0.2/docs/assets/bootstrap.zip"
9+
}
10+
}

0 commit comments

Comments
 (0)