Skip to content

Commit 1fcccca

Browse files
Merge pull request patternfly#432 from priley86/remove-bower
references our dependencies from node_modules instead of bower
2 parents f7f8835 + ec733ae commit 1fcccca

File tree

7 files changed

+469
-473
lines changed

7 files changed

+469
-473
lines changed

Gruntfile.js

Lines changed: 23 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -37,27 +37,27 @@ module.exports = function (grunt) {
3737
main: {
3838
files: [
3939
// copy Bootstrap font files
40-
{expand: true, cwd: 'components/bootstrap/dist/fonts/', src: ['*'], dest: 'dist/fonts/'},
40+
{expand: true, cwd: 'node_modules/bootstrap/dist/fonts/', src: ['*'], dest: 'dist/fonts/'},
4141
// copy Font Awesome font files
42-
{expand: true, cwd: 'components/font-awesome/fonts/', src: ['*'], dest: 'dist/fonts/'},
42+
{expand: true, cwd: 'node_modules/font-awesome/fonts/', src: ['*'], dest: 'dist/fonts/'},
4343
// copy Patternfly font files
4444
{expand: true, cwd: 'src/fonts/', src: ['*'], dest: 'dist/fonts/'},
4545
// copy Bootstrap less files
46-
{expand: true, cwd: 'components/bootstrap/less/', src: ['**'], dest: 'less/lib/bootstrap/'},
46+
{expand: true, cwd: 'node_modules/bootstrap/less/', src: ['**'], dest: 'less/lib/bootstrap/'},
4747
// copy Font Awesome less files
48-
{expand: true, cwd: 'components/font-awesome/less/', src: ['**'], dest: 'less/lib/font-awesome/'},
48+
{expand: true, cwd: 'node_modules/font-awesome/less/', src: ['**'], dest: 'less/lib/font-awesome/'},
4949
// copy Bootstrap-Combobox less files
50-
{expand: true, cwd: 'components/bootstrap-combobox/less/', src: ['**'], dest: 'less/lib/bootstrap-combobox/'},
50+
{expand: true, cwd: 'node_modules/patternfly-bootstrap-combobox/less/', src: ['**'], dest: 'less/lib/bootstrap-combobox/'},
5151
// copy Bootstrap-Datepicker less files
52-
{expand: true, cwd: 'components/bootstrap-datepicker/less/', src: ['**'], dest: 'less/lib/bootstrap-datepicker/'},
52+
{expand: true, cwd: 'node_modules/bootstrap-datepicker/less/', src: ['**'], dest: 'less/lib/bootstrap-datepicker/'},
5353
// copy Bootstrap-Select less files
54-
{expand: true, cwd: 'components/bootstrap-select/less/', src: ['**'], dest: 'less/lib/bootstrap-select/'},
54+
{expand: true, cwd: 'node_modules/bootstrap-select/less/', src: ['**'], dest: 'less/lib/bootstrap-select/'},
5555
// Bootstrap Switch less files must be manually copied because of edits made to source less for strict-math purposes
56-
// manually copy 'components/bootstrap-switch/src/less/bootstrap3/' and make sure any math is wrapped with parentheses
56+
// manually copy 'node_modules/bootstrap-switch/src/less/bootstrap3/' and make sure any math is wrapped with parentheses
5757
// copy Bootstrap Touchspin css file
58-
{expand: true, cwd: 'components/bootstrap-touchspin/dist/', src: ['jquery.bootstrap-touchspin.css'], dest: 'less/lib/bootstrap-touchspin/'},
58+
{expand: true, cwd: 'node_modules/bootstrap-touchspin/dist/', src: ['jquery.bootstrap-touchspin.css'], dest: 'less/lib/bootstrap-touchspin/'},
5959
// copy C3 css file
60-
{expand: true, cwd: 'components/c3/', src: ['c3.css'], dest: 'less/lib/c3/'},
60+
{expand: true, cwd: 'node_modules/c3/', src: ['c3.css'], dest: 'less/lib/c3/'},
6161
//copy images
6262
{expand: true, cwd: 'src/img/', src: ['**'], dest: 'dist/img/'}
6363
],
@@ -143,7 +143,19 @@ module.exports = function (grunt) {
143143
},
144144
watch: {
145145
copy: {
146-
files: 'components/**/*',
146+
files: [
147+
'node_modules/bootstrap/dist/fonts/**/*',
148+
'node_modules/font-awesome/fonts/**/*',
149+
'node_modules/bootstrap/less/**/*',
150+
'node_modules/font-awesome/less/**/*',
151+
'node_modules/patternfly-bootstrap-combobox/less/**/*',
152+
'node_modules/bootstrap-datepicker/less/**/*',
153+
'node_modules/bootstrap-select/less/**/*',
154+
'node_modules/bootstrap-touchspin/dist/**/*',
155+
'node_modules/c3/**/*',
156+
'src/fonts/**/*',
157+
'src/img/**/*'
158+
],
147159
tasks: ['copy']
148160
},
149161
jekyll: {

QUICKSTART.md

Lines changed: 43 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -36,133 +36,128 @@ We provide compiled CSS and JS (`patternfly.*`), as well as compiled and minifie
3636

3737
$ sudo npm install -g grunt-cli
3838

39-
- [Bower](http://bower.io/#installing-bower): a package manager for the web.
4039

4140
2. Add PatternFly as a dependency for your project and you'll receive all the libraries you'll need:
4241

43-
$ bower install patternfly --save
42+
$ npm install patternfly --save
4443

4544
For full install options see the [README](README.md)
4645

4746
3. Add the following CSS includes to your HTML file(s), adjusting path where needed:
4847

4948
<!-- PatternFly Styles -->
5049
<!-- Note: No other CSS files are needed regardless of what other JS packages located in patternfly/components that you decide to pull in -->
51-
<link rel="stylesheet" href="bower_components/patternfly/dist/css/patternfly.min.css">
52-
<link rel="stylesheet" href="bower_components/patternfly/dist/css/patternfly-additions.min.css">
50+
<link rel="stylesheet" href="node_modules/patternfly/dist/css/patternfly.min.css">
51+
<link rel="stylesheet" href="node_modules/patternfly/dist/css/patternfly-additions.min.css">
5352

5453
4. Add the following script includes to your HTML file(s), adjusting where necessary to pull in only what you need:
5554

5655
<!-- jQuery -->
57-
<script src="bower_components/jquery/dist/jquery.min.js"></script>
56+
<script src="node_modules/jquery/dist/jquery.min.js"></script>
5857

5958
<!-- Bootstrap JS -->
60-
<script src="bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
59+
<script src="node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
6160

6261
<!-- C3, D3 - Charting Libraries -->
63-
<script src="bower_components/c3/c3.min.js"></script>
64-
<script src="bower_components/d3/d3.min.js"></script>
62+
<script src="node_modules/c3/c3.min.js"></script>
63+
<script src="node_modules/d3/d3.min.js"></script>
6564

6665
<!-- Datatables, jQuery Grid Component -->
6766
<!-- Note: jquery.dataTables.js must occur in the html source before patternfly*.js.-->
68-
<script src="bower_components/datatables/media/js/jquery.dataTables.min.js"></script>
69-
<script src="bower_components/datatables-colvis/js/dataTables.colVis.js"></script>
70-
<script src="bower_components/datatables-colreorder/js/dataTables.colReorder.js"></script>
67+
<script src="node_modules/datatables/media/js/jquery.dataTables.min.js"></script>
68+
<script src="node_modules/drmonty-datatables-colvis/js/dataTables.colVis.js"></script>
69+
<script src="node_modules/datatables.net-colreorder/js/dataTables.colReorder.js"></script>
7170

7271
<!-- PatternFly Custom Componets - Sidebar, Popovers and Datatables Customizations -->
7372
<!-- Note: jquery.dataTables.js must occur in the html source before patternfly*.js.-->
74-
<script src="bower_components/patternfly/dist/js/patternfly.min.js"></script>
73+
<script src="node_modules/patternfly/dist/js/patternfly.min.js"></script>
7574

7675
<!-- Bootstrap Combobox -->
77-
<script src="bower_components/bootstrap-combobox/js/bootstrap-combobox.js"></script>
76+
<script src="node_modules/patternfly-bootstrap-combobox/js/bootstrap-combobox.js"></script>
7877

7978
<!-- Bootstrap Date Picker -->
80-
<script src="bower_components/bootstrap-datepicker/dist/js/bootstrap-datepicker.min.js"></script>
79+
<script src="node_modules/bootstrap-datepicker/dist/js/bootstrap-datepicker.min.js"></script>
8180

8281
<!-- Moment - required by Bootstrap Date Time Picker -->
83-
<script src="bower_components/moment/min/moment.min.js"></script>
82+
<script src="node_modules/moment/min/moment.min.js"></script>
8483

8584
<!-- Bootstrap Date Time Picker - requires Moment -->
86-
<script src="bower_components/eonasdan-bootstrap-datetimepicker/build/js/bootstrap-datetimepicker.min.js"></script>
85+
<script src="node_modules/eonasdan-bootstrap-datetimepicker/build/js/bootstrap-datetimepicker.min.js"></script>
8786

8887
<!-- Bootstrap Select -->
89-
<script src="bower_components/bootstrap-select/dist/js/bootstrap-select.min.js"></script>
88+
<script src="node_modules/bootstrap-select/dist/js/bootstrap-select.min.js"></script>
9089

9190
<!-- Bootstrap Switch -->
92-
<script src="bower_components/bootstrap-switch/dist/js/bootstrap-switch.min.js"></script>
91+
<script src="node_modules/bootstrap-switch/dist/js/bootstrap-switch.min.js"></script>
9392

9493
<!-- Bootstrap Touchspin -->
95-
<script src="bower_components/bootstrap-touchspin/dist/jquery.bootstrap-touchspin.min.js"></script>
94+
<script src="node_modules/bootstrap-touchspin/dist/jquery.bootstrap-touchspin.min.js"></script>
9695

9796
<!-- Bootstrap Tree View -->
98-
<script src="bower_components/patternfly-bootstrap-treeview/dist/bootstrap-treeview.min.js"></script>
97+
<script src="node_modules/patternfly-bootstrap-treeview/dist/bootstrap-treeview.min.js"></script>
9998

10099
<!-- Google Code Prettify - Syntax highlighting of code snippets -->
101-
<script src="bower_components/google-code-prettify/bin/prettify.min.js"></script>
100+
<script src="node_modules/google-code-prettify/bin/prettify.min.js"></script>
102101

103102
<!-- MatchHeight - Used to make sure dashboard cards are the same height -->
104-
<script src="bower_components/matchHeight/jquery.matchHeight-min.js"></script>
103+
<script src="node_modules/jquery-match-height/jquery.matchHeight-min.js"></script>
105104

106105
<!-- Angular Application? You May Want to Consider Pulling Angular-PatternFly And Angular-UI Bootstrap instead of bootstrap.js -->
107106
<!-- See https://github.com/patternfly/angular-patternfly for more information -->
108107

109-
5. NPM Install Only: You can install patternfly using just NPM; no need for Bower (although Bower is recommened). Add the following style and script includes from 'node_modules' to your HTML file(s), adjusting where necessary to pull in only what you need:
108+
5. Prefer to use Bower? You can install patternfly using Bower (although NPM is recommended). Add the following style and script includes from `bower_components` to your HTML file(s), adjusting where necessary to pull in only what you need:
110109

111110
<!-- PatternFly Styles -->
112111
<!-- Note: No other CSS files are needed regardless of what other JS packages located in patternfly/components that you decide to pull in -->
113-
<link rel="stylesheet" href="node_modules/patternfly/dist/css/patternfly.min.css">
114-
<link rel="stylesheet" href="node_modules/patternfly/dist/css/patternfly-additions.min.css">
112+
<link rel="stylesheet" href="bower_components/patternfly/dist/css/patternfly.min.css">
113+
<link rel="stylesheet" href="bower_components/patternfly/dist/css/patternfly-additions.min.css">
115114

116115
<!-- jQuery -->
117-
<script src="node_modules/patternfly/node_modules/jquery/dist/jquery.min.js"></script>
116+
<script src="bower_components/jquery/dist/jquery.min.js"></script>
118117

119118
<!-- Bootstrap JS -->
120-
<script src="node_modules/patternfly/node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
119+
<script src="bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
121120

122121
<!-- C3, D3 - Charting Libraries -->
123-
<script src="node_modules/patternfly/node_modules/c3/c3.min.js"></script>
124-
<script src="node_modules/patternfly/node_modules/c3/node_modules/d3/d3.min.js"></script>
122+
<script src="bower_components/c3/c3.min.js"></script>
123+
<script src="bower_components/d3/d3.min.js"></script>
125124

126125
<!-- Datatables, jQuery Grid Component -->
127126
<!-- Note: jquery.dataTables.js must occur in the html source before patternfly*.js.-->
128-
<script src="node_modules/patternfly/node_modules/datatables/media/js/jquery.dataTables.min.js"></script>
129-
<script src="node_modules/patternfly/node_modules/drmonty-datatables-colvis/js/dataTables.colVis.js"></script>
130-
<script src="node_modules/patternfly/node_modules/datatables.net-colreorder/js/dataTables.colReorder.js"></script>
127+
<script src="bower_components/datatables/media/js/jquery.dataTables.min.js"></script>
128+
<script src="bower_components/datatables-colvis/js/dataTables.colVis.js"></script>
129+
<script src="bower_components/datatables-colreorder/js/dataTables.colReorder.js"></script>
131130

132131
<!-- PatternFly Custom Componets - Sidebar, Popovers and Datatables Customizations -->
133132
<!-- Note: jquery.dataTables.js must occur in the html source before patternfly*.js.-->
134-
<script src="node_modules/patternfly/dist/js/patternfly.min.js"></script>
133+
<script src="bower_components/patternfly/dist/js/patternfly.min.js"></script>
135134

136135
<!-- Bootstrap Combobox -->
137-
<script src="node_modules/patternfly/node_modules/patternfly-bootstrap-combobox/js/bootstrap-combobox.js"></script>
138-
139-
<!-- Bootstrap Date Picker -->
140-
<script src="node_modules/patternfly/node_modules/bootstrap-datepicker/dist/js/bootstrap-datepicker.min.js"></script>
136+
<script src="bower_components/bootstrap-combobox/js/bootstrap-combobox.js"></script>
141137

142138
<!-- Bootstrap Date Time Picker - requires Moment -->
143-
<script src="node_modules/patternfly/node_modules/eonasdan-bootstrap-datetimepicker/build/js/bootstrap-datetimepicker.min.js"></script>
139+
<script src="bower_components/moment/min/moment.min.js"></script>
140+
141+
<!-- Bootstrap Date Picker -->
142+
<script src="bower_components/bootstrap-datepicker/dist/js/bootstrap-datepicker.min.js"></script>
144143

145144
<!-- Bootstrap Select -->
146-
<script src="node_modules/patternfly/node_modules/bootstrap-select/dist/js/bootstrap-select.min.js"></script>
145+
<script src="bower_components/bootstrap-select/dist/js/bootstrap-select.min.js"></script>
147146

148147
<!-- Bootstrap Switch -->
149-
<script src="node_modules/patternfly/node_modules/bootstrap-switch/dist/js/bootstrap-switch.min.js"></script>
150-
<script src="node_modules/patternfly/tests-src/bootstrap-switch.js"></script>
148+
<script src="bower_components/bootstrap-switch/dist/js/bootstrap-switch.min.js"></script>
151149

152150
<!-- Bootstrap Touchspin -->
153-
<script src="node_modules/patternfly/node_modules/bootstrap-touchspin/dist/jquery.bootstrap-touchspin.min.js"></script>
151+
<script src="bower_components/bootstrap-touchspin/dist/jquery.bootstrap-touchspin.min.js"></script>
154152

155153
<!-- Bootstrap Tree View -->
156-
<script src="node_modules/patternfly/node_modules/patternfly-bootstrap-treeview/dist/bootstrap-treeview.min.js"></script>
154+
<script src="bower_components/patternfly-bootstrap-treeview/dist/bootstrap-treeview.min.js"></script>
157155

158156
<!-- Google Code Prettify - Syntax highlighting of code snippets -->
159-
<script src="node_modules/patternfly/node_modules/google-code-prettify/bin/prettify.min.js"></script>
157+
<script src="bower_components/google-code-prettify/bin/prettify.min.js"></script>
160158

161159
<!-- MatchHeight - Used to make sure dashboard cards are the same height -->
162-
<script src="node_modules/patternfly/node_modules/jquery-match-height/jquery.matchHeight-min.js"></script>
163-
164-
<!-- Moment - required by Bootstrap Date Time Picker -->
165-
<script src="node_modules/patternfly/node_modules/moment/min/moment.min.js"></script>
160+
<script src="bower_components/matchHeight/jquery.matchHeight-min.js"></script>
166161

167162
<!-- Angular Application? You May Want to Consider Pulling Angular-PatternFly And Angular-UI Bootstrap instead of bootstrap.js -->
168163
<!-- See https://github.com/patternfly/angular-patternfly for more information -->

0 commit comments

Comments
 (0)