update_repo 0.9.5 → 0.9.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (55) hide show
  1. checksums.yaml +4 -4
  2. data/.codeclimate.yml +31 -0
  3. data/.csslintrc +2 -0
  4. data/.eslintignore +1 -0
  5. data/.eslintrc.yml +277 -0
  6. data/.gitignore +2 -0
  7. data/.reek +3 -0
  8. data/.rubocop.yml +7 -0
  9. data/.travis.yml +4 -4
  10. data/README.md +53 -2
  11. data/Vagrantfile +11 -0
  12. data/WEBSITE.md +73 -0
  13. data/docs/CNAME +2 -0
  14. data/docs/css/site.css +9485 -0
  15. data/docs/fonts/FontAwesome.otf +0 -0
  16. data/docs/fonts/fontawesome-webfont.eot +0 -0
  17. data/docs/fonts/fontawesome-webfont.svg +2671 -0
  18. data/docs/fonts/fontawesome-webfont.ttf +0 -0
  19. data/docs/fonts/fontawesome-webfont.woff +0 -0
  20. data/docs/fonts/fontawesome-webfont.woff2 +0 -0
  21. data/docs/fonts/glyphicons-halflings-regular.eot +0 -0
  22. data/docs/fonts/glyphicons-halflings-regular.svg +288 -0
  23. data/docs/fonts/glyphicons-halflings-regular.ttf +0 -0
  24. data/docs/fonts/glyphicons-halflings-regular.woff +0 -0
  25. data/docs/fonts/glyphicons-halflings-regular.woff2 +0 -0
  26. data/docs/index.html +554 -0
  27. data/docs/js/main.js +13669 -0
  28. data/lib/update_repo.rb +1 -1
  29. data/lib/update_repo/cmd_config.rb +10 -8
  30. data/lib/update_repo/console_output.rb +2 -2
  31. data/lib/update_repo/git_control.rb +27 -7
  32. data/lib/update_repo/logger.rb +1 -1
  33. data/lib/update_repo/version.rb +1 -1
  34. data/update_repo.gemspec +1 -0
  35. data/vagrant-support/bootstrap-sudo.sh +14 -0
  36. data/vagrant-support/bootstrap.sh +37 -0
  37. data/web/.nvmrc +1 -0
  38. data/web/.scss-lint.yml +45 -0
  39. data/web/gulpfile.js +133 -0
  40. data/web/index.html +260 -0
  41. data/web/js/scripts.js +2 -0
  42. data/web/js/site.js +7 -0
  43. data/web/package.json +48 -0
  44. data/web/partials/_contribute.html +22 -0
  45. data/web/partials/_footer.html +16 -0
  46. data/web/partials/_header.html +25 -0
  47. data/web/partials/_license.html +38 -0
  48. data/web/partials/_navbar.html +24 -0
  49. data/web/sass/partials/_colors.scss +36 -0
  50. data/web/sass/partials/_fonts.scss +3 -0
  51. data/web/sass/partials/_mixins.scss +8 -0
  52. data/web/sass/partials/_variables.scss +3 -0
  53. data/web/sass/site.scss +263 -0
  54. data/web/webdata.json +112 -0
  55. metadata +44 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5696a783dc964f8496706cda7909c28774600530
4
- data.tar.gz: 7b6b09f1fb471211674ed5bd83cfb48529ecf35f
3
+ metadata.gz: 44621b4533c533361926fcd49d0fbf15ed1e955a
4
+ data.tar.gz: 54fcddbea0dd35ad28c6e4e8570c4db69dc510a1
5
5
  SHA512:
6
- metadata.gz: b6c19d51e5929e3ce20d1dd8381229366d0951724a7655632c5dd60247d7336cc3660fd0d658e4d949072e6bca4025e5361ca725720b54b1fc23df61d69369d1
7
- data.tar.gz: 35ebc0cee27d2d64a95c98613f98aac5d161b28a3c50c519c1f4bb30625c2d132eae021748468f71deb19eddc5a318f4c64f6ffd8a9a9266f202d42c458f7d73
6
+ metadata.gz: d1c18bbe70b0868857cb0ea47c0b8eb025b95b2b5aa3d845bb08fdcd8be034b550915835d11f0267f144a5b5f4da515ff60fb259d2db1f66740b4cf818bd360a
7
+ data.tar.gz: 042b68c8b069a2be01303bb91f5b6ba86c569f0e792ee3c7f814266e000014ebe024523f47b1df60634dab385f6c4cdd0a0e631c1d37a79da342f9d06c1751e1
data/.codeclimate.yml ADDED
@@ -0,0 +1,31 @@
1
+ ---
2
+ engines:
3
+ csslint:
4
+ enabled: true
5
+ duplication:
6
+ enabled: true
7
+ config:
8
+ languages:
9
+ - ruby
10
+ - javascript
11
+ - python
12
+ - php
13
+ eslint:
14
+ enabled: true
15
+ fixme:
16
+ enabled: true
17
+ rubocop:
18
+ enabled: true
19
+ ratings:
20
+ paths:
21
+ - "**.css"
22
+ - "**.inc"
23
+ - "**.js"
24
+ - "**.jsx"
25
+ - "**.module"
26
+ - "**.php"
27
+ - "**.py"
28
+ - "**.rb"
29
+ exclude_paths:
30
+ - spec/
31
+ - docs/
data/.csslintrc ADDED
@@ -0,0 +1,2 @@
1
+ --exclude-exts=.min.css
2
+ --ignore=adjoining-classes,box-model,ids,order-alphabetical,unqualified-attributes
data/.eslintignore ADDED
@@ -0,0 +1 @@
1
+ **/*{.,-}min.js
data/.eslintrc.yml ADDED
@@ -0,0 +1,277 @@
1
+ ---
2
+ parserOptions:
3
+ sourceType: module
4
+ ecmaFeatures:
5
+ jsx: true
6
+
7
+ env:
8
+ amd: true
9
+ browser: true
10
+ es6: true
11
+ jquery: true
12
+ node: true
13
+
14
+ # http://eslint.org/docs/rules/
15
+ rules:
16
+ # Possible Errors
17
+ no-await-in-loop: off
18
+ no-cond-assign: error
19
+ no-console: off
20
+ no-constant-condition: error
21
+ no-control-regex: error
22
+ no-debugger: error
23
+ no-dupe-args: error
24
+ no-dupe-keys: error
25
+ no-duplicate-case: error
26
+ no-empty-character-class: error
27
+ no-empty: error
28
+ no-ex-assign: error
29
+ no-extra-boolean-cast: error
30
+ no-extra-parens: off
31
+ no-extra-semi: error
32
+ no-func-assign: error
33
+ no-inner-declarations:
34
+ - error
35
+ - functions
36
+ no-invalid-regexp: error
37
+ no-irregular-whitespace: error
38
+ no-negated-in-lhs: error
39
+ no-obj-calls: error
40
+ no-prototype-builtins: off
41
+ no-regex-spaces: error
42
+ no-sparse-arrays: error
43
+ no-template-curly-in-string: off
44
+ no-unexpected-multiline: error
45
+ no-unreachable: error
46
+ no-unsafe-finally: off
47
+ no-unsafe-negation: off
48
+ use-isnan: error
49
+ valid-jsdoc: off
50
+ valid-typeof: error
51
+
52
+ # Best Practices
53
+ accessor-pairs: error
54
+ array-callback-return: off
55
+ block-scoped-var: off
56
+ class-methods-use-this: off
57
+ complexity:
58
+ - error
59
+ - 6
60
+ consistent-return: off
61
+ curly: off
62
+ default-case: off
63
+ dot-location: off
64
+ dot-notation: off
65
+ eqeqeq: error
66
+ guard-for-in: error
67
+ no-alert: error
68
+ no-caller: error
69
+ no-case-declarations: error
70
+ no-div-regex: error
71
+ no-else-return: off
72
+ no-empty-function: off
73
+ no-empty-pattern: error
74
+ no-eq-null: error
75
+ no-eval: error
76
+ no-extend-native: error
77
+ no-extra-bind: error
78
+ no-extra-label: off
79
+ no-fallthrough: error
80
+ no-floating-decimal: off
81
+ no-global-assign: off
82
+ no-implicit-coercion: off
83
+ no-implied-eval: error
84
+ no-invalid-this: off
85
+ no-iterator: error
86
+ no-labels:
87
+ - error
88
+ - allowLoop: true
89
+ allowSwitch: true
90
+ no-lone-blocks: error
91
+ no-loop-func: error
92
+ no-magic-number: off
93
+ no-multi-spaces: off
94
+ no-multi-str: off
95
+ no-native-reassign: error
96
+ no-new-func: error
97
+ no-new-wrappers: error
98
+ no-new: error
99
+ no-octal-escape: error
100
+ no-octal: error
101
+ no-param-reassign: off
102
+ no-proto: error
103
+ no-redeclare: error
104
+ no-restricted-properties: off
105
+ no-return-assign: error
106
+ no-return-await: off
107
+ no-script-url: error
108
+ no-self-assign: off
109
+ no-self-compare: error
110
+ no-sequences: off
111
+ no-throw-literal: off
112
+ no-unmodified-loop-condition: off
113
+ no-unused-expressions: error
114
+ no-unused-labels: off
115
+ no-useless-call: error
116
+ no-useless-concat: error
117
+ no-useless-escape: off
118
+ no-useless-return: off
119
+ no-void: error
120
+ no-warning-comments: off
121
+ no-with: error
122
+ prefer-promise-reject-errors: off
123
+ radix: error
124
+ require-await: off
125
+ vars-on-top: off
126
+ wrap-iife: error
127
+ yoda: off
128
+
129
+ # Strict
130
+ strict: off
131
+
132
+ # Variables
133
+ init-declarations: off
134
+ no-catch-shadow: error
135
+ no-delete-var: error
136
+ no-label-var: error
137
+ no-restricted-globals: off
138
+ no-shadow-restricted-names: error
139
+ no-shadow: off
140
+ no-undef-init: error
141
+ no-undef: off
142
+ no-undefined: off
143
+ no-unused-vars: off
144
+ no-use-before-define: off
145
+
146
+ # Node.js and CommonJS
147
+ callback-return: error
148
+ global-require: error
149
+ handle-callback-err: error
150
+ no-mixed-requires: off
151
+ no-new-require: off
152
+ no-path-concat: error
153
+ no-process-env: off
154
+ no-process-exit: error
155
+ no-restricted-modules: off
156
+ no-sync: off
157
+
158
+ # Stylistic Issues
159
+ array-bracket-spacing: off
160
+ block-spacing: off
161
+ brace-style: off
162
+ camelcase: off
163
+ capitalized-comments: off
164
+ comma-dangle:
165
+ - error
166
+ - never
167
+ comma-spacing: off
168
+ comma-style: off
169
+ computed-property-spacing: off
170
+ consistent-this: off
171
+ eol-last: off
172
+ func-call-spacing: off
173
+ func-name-matching: off
174
+ func-names: off
175
+ func-style: off
176
+ id-length: off
177
+ id-match: off
178
+ indent: off
179
+ jsx-quotes: off
180
+ key-spacing: off
181
+ keyword-spacing: off
182
+ line-comment-position: off
183
+ linebreak-style: off
184
+ lines-around-comment: off
185
+ lines-around-directive: off
186
+ max-depth: off
187
+ max-len: off
188
+ max-nested-callbacks: off
189
+ max-params: off
190
+ max-statements-per-line: off
191
+ max-statements:
192
+ - error
193
+ - 30
194
+ multiline-ternary: off
195
+ new-cap: off
196
+ new-parens: off
197
+ newline-after-var: off
198
+ newline-before-return: off
199
+ newline-per-chained-call: off
200
+ no-array-constructor: off
201
+ no-bitwise: off
202
+ no-continue: off
203
+ no-inline-comments: off
204
+ no-lonely-if: off
205
+ no-mixed-operators: off
206
+ no-mixed-spaces-and-tabs: off
207
+ no-multi-assign: off
208
+ no-multiple-empty-lines: off
209
+ no-negated-condition: off
210
+ no-nested-ternary: off
211
+ no-new-object: off
212
+ no-plusplus: off
213
+ no-restricted-syntax: off
214
+ no-spaced-func: off
215
+ no-tabs: off
216
+ no-ternary: off
217
+ no-trailing-spaces: off
218
+ no-underscore-dangle: off
219
+ no-unneeded-ternary: off
220
+ object-curly-newline: off
221
+ object-curly-spacing: off
222
+ object-property-newline: off
223
+ one-var-declaration-per-line: off
224
+ one-var: off
225
+ operator-assignment: off
226
+ operator-linebreak: off
227
+ padded-blocks: off
228
+ quote-props: off
229
+ quotes: off
230
+ require-jsdoc: off
231
+ semi-spacing: off
232
+ semi: off
233
+ sort-keys: off
234
+ sort-vars: off
235
+ space-before-blocks: off
236
+ space-before-function-paren: off
237
+ space-in-parens: off
238
+ space-infix-ops: off
239
+ space-unary-ops: off
240
+ spaced-comment: off
241
+ template-tag-spacing: off
242
+ unicode-bom: off
243
+ wrap-regex: off
244
+
245
+ # ECMAScript 6
246
+ arrow-body-style: off
247
+ arrow-parens: off
248
+ arrow-spacing: off
249
+ constructor-super: off
250
+ generator-star-spacing: off
251
+ no-class-assign: off
252
+ no-confusing-arrow: off
253
+ no-const-assign: off
254
+ no-dupe-class-members: off
255
+ no-duplicate-imports: off
256
+ no-new-symbol: off
257
+ no-restricted-imports: off
258
+ no-this-before-super: off
259
+ no-useless-computed-key: off
260
+ no-useless-constructor: off
261
+ no-useless-rename: off
262
+ no-var: off
263
+ object-shorthand: off
264
+ prefer-arrow-callback: off
265
+ prefer-const: off
266
+ prefer-destructuring: off
267
+ prefer-numeric-literals: off
268
+ prefer-rest-params: off
269
+ prefer-reflect: off
270
+ prefer-spread: off
271
+ prefer-template: off
272
+ require-yield: off
273
+ rest-spread-spacing: off
274
+ sort-imports: off
275
+ symbol-description: off
276
+ template-curly-spacing: off
277
+ yield-star-spacing: off
data/.gitignore CHANGED
@@ -12,3 +12,5 @@
12
12
  .updatereporc
13
13
  *.log
14
14
  *.sublime*
15
+ node_modules
16
+ .vagrant
data/.reek CHANGED
@@ -15,3 +15,6 @@ DuplicateMethodCall:
15
15
 
16
16
  NestedIterators:
17
17
  max_allowed_nesting: 2
18
+
19
+ TooManyInstanceVariables:
20
+ max_instance_variables: 5
data/.rubocop.yml CHANGED
@@ -2,3 +2,10 @@ AllCops:
2
2
  DisplayCopNames: true
3
3
  DisplayStyleGuide: true
4
4
  ExtraDetails: true
5
+ Exclude:
6
+ - 'web/node_modules/**/*'
7
+ - 'Vagrantfile'
8
+ - 'update_repo.gemspec'
9
+
10
+ Style/SymbolArray:
11
+ Enabled: false
data/.travis.yml CHANGED
@@ -4,10 +4,10 @@ rvm:
4
4
  - 1.9.3-p551
5
5
  - 2.0.0-p648
6
6
  - 2.1.10
7
- - 2.2.6
8
- - 2.3.3
9
- - 2.4.0
7
+ - 2.2.7
8
+ - 2.3.4
9
+ - 2.4.1
10
10
 
11
11
  before_install:
12
12
  - gem update --system
13
- - gem install bundler -v 1.13.7
13
+ - gem install bundler -v 1.14.6
data/README.md CHANGED
@@ -79,6 +79,11 @@ timestamp: true
79
79
  verbose: true
80
80
  ```
81
81
 
82
+ `verbose_errors:` - List all the error output from a failing command in the summary, not just the first line, defaults to FALSE (optional)
83
+ ```yaml
84
+ verbose_errors: true
85
+ ```
86
+
82
87
  `quiet:` - no output at all, not even the header and footer, defaults to FALSE (optional)
83
88
  ```yaml
84
89
  quiet: true
@@ -98,9 +103,12 @@ Options:
98
103
  Any older logs will be overwritten.
99
104
  -t, --timestamp Timestamp the logfile instead of overwriting. Does nothing unless the
100
105
  --log option is also specified.
106
+ -g, --log-local Create the logfile in the current directory instead of in the users home
107
+ directory.
101
108
  -r, --dump-remote Create a dump to screen or log listing all the git remote URLS found in
102
109
  the specified directories.
103
110
  -V, --verbose Display each repository and the git output to screen
111
+ -E, --verbose-errors List all the error output from a failing command in the summary, not just the first line
104
112
  -q, --quiet Run completely silent, with no output to the terminal (except fatal errors).
105
113
  -v, --version Print version and exit
106
114
  -h, --help Show this message
@@ -119,8 +127,7 @@ Add functionality, not in any specific order :
119
127
  * ability to export a text dump of each repo location and remote as a CSV file. `[DONE]`
120
128
  * re-import the above dump on a different machine or after reinstall. Modify the '--prune' command to apply to this function also, removing the required number of directory levels before importing.
121
129
  - Add option to use alternative git command if required, either globally or on a case-by-case basis (see also comments on 'variants' above). Currently the script just uses a blanket `git pull` command on all repositories.
122
- - Implement the option `--log-local` to put log file into the local directory.
123
- - Add option to specify a completely different directory for the log file other than the 2 current (planned, local not yet implemented) options (home dir and local)
130
+ - Add option to specify a completely different directory for the log file other than the 2 current options of home dir and local dir
124
131
  - Document configuration file format and options. `[IN PROGRESS]`
125
132
 
126
133
  Internal Changes and refactoring :
@@ -130,18 +137,55 @@ Internal Changes and refactoring :
130
137
  * Ignore and report invalid or missing directories
131
138
  * Add more failure cases, there may be more git errors than "fatal:" or "error:"
132
139
  - Retry for connection issues etc (config setting).
140
+ - Fail gracefully with warning and useful information if there are no `location:` entries or that tag is missing completely
133
141
 
134
142
  ## Development
135
143
 
144
+ ### Developing for the Gem
145
+
136
146
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests (or simply `rake`). You can also run `bin/console` for an interactive prompt that will allow you to experiment.
137
147
 
138
148
  To install this gem onto your local machine, run `bundle exec rake install`.
139
149
 
140
150
  Run `rake` to run the RSpec tests, which also runs `RuboCop`, `Reek` and `inch --pedantic` too.
141
151
 
152
+ ### Developing for the Website
153
+
154
+ The source for the Gem’s website is also included in this repository. In fact, there are 2 main folders related to the website :
155
+
156
+ - [/web/](web/) folder - this is the SOURCE of the website, and all modifications should be performed here.
157
+ - [/docs/](docs/) folder - this is the GENERATED OUTPUT for the website, and this folder is served up directly and live to the web using GitHub Pages. Do not make any modifications to the files in this folder directly, your changes will be overwritten when the website is generated. Alway make changes in the `/web/` folder.
158
+
159
+ There are also a few support files to configure Node and Gulp which are used for the build process.
160
+
161
+ For full details on how to update the website properly, please see the [WEBSITE.md](WEBSITE.md) file in the root of this repository.
162
+
163
+ Any modifications that implement new functionality or user-facing API should also come with the relevant update to the website documenting the new options or modified functionality. Generally a Pull Request will not be accepted without the related additions to the website, however help can be given on that side if the process is unclear.
164
+
165
+ ### Using the provided Vagrant Box
166
+
167
+ To ease the setup of a consistent development environment under both Linux and Windows, we have provided a [Vagrantfile](Vagrantfile) with the project. This will provide a virtual machine (running Ubuntu 16.04) that is already set up with the required version of [Ruby][ruby], [Node.js][node] and the associated development deps. It will already have all the needed node packages and Ruby gems installed locally. The root of this project repository will be available under the `/vagrant/` directory on this VM for ease of development. This means that all the editing can be carried out on your normal system be it Windows, Linux or OSX, while the git control, testing, Gem building and Website generation (with Gulp) happens on the VM.
168
+
169
+ #### Setting up Vagrant and VirtalBox
170
+
171
+ The easiest VM to use for both Windows, Linux and Mac is [VirtualBox][virtualbox] which is Free and Open Source.
172
+ - Download and install Vagrant from their download pages [here][vagrantdl]. Follow the installation instructions depending on your operating system.
173
+ - Download and install VirtualBox from their download pages [here][virtualboxdl]. Follow the installation instructions depending on your operating system.
174
+ - Open a terminal (or Command Prompt in Windows) in the root directory of your checked-out copy of this project, the one containing the [Vagrantfile](Vagrantfile).
175
+ - We need to install one Vagrant plugin, otherwise the VM Guest Additions will be out of date and the `/vagrant/` share will not work. for this we install the `vagrant-vbguest` plugin. To do this run the following at the terminal prompt : `vagrant plugin install vagrant-vbguest`
176
+ - Run `vagrant up` at the terminal prompt. This will proceed to download, install and then provision an Ubuntu 16.04 Virtual Machine. For the first run, this will take some time but thereafter it will be quicker.
177
+ - Run `vagrant ssh` at the terminal prompt to ssh into the VM. Note that for the first time, it will probably say that a reboot is required, simply type `sudo reboot` at the prompt - the VM will reboot and you will be disconnected. Wait a few minutes and then run `vagrant ssh` again.
178
+ - Change to the `/vagrant` subdirectory which will contain the source for this project and then develop away as normal.
179
+ - For the first use only, if you change to `/vargrant` and there are no files listed, this is generally because the VM Guest Additions have been updated when bringing the VM up, but have not properly activated. In this case simply `exit` the VM, run `vagrant halt` then `vagrant up` again which should fix it.
180
+
181
+ #### Special comments for Windows users
182
+
183
+ There is no default ssh client installed in any version of windows, so `vagrant ssh` will fail, giving you the settings required to use a third-party ssh client (for example my preferred windows SSH client is [MobaXterm][mobaxterm]). If you prefer that `vagrant ssh` actually works from the command line, it is possible to install the ssh command line programs if you also install the [Git for Windows][git4windows] software. Install this, ensuring that you choose the option 'Use Git and optional Unix tools from the Windows Command Prompt'. After this, the ssh executable will be available from any windows Command Shell and so `vagrant ssh` will work as expected. *Please note the warning given by the installer related to this option though!*
184
+
142
185
  ## Contributing
143
186
 
144
187
  1. Fork it
188
+
145
189
  2. Create your feature branch (`git checkout -b my-new-feature`)
146
190
  3. Commit your changes (`git commit -am 'Add some feature'`)
147
191
  4. Push to the branch (`git push origin my-new-feature`)
@@ -176,4 +220,11 @@ The gem is available as open source under the terms of the [MIT License][mit].
176
220
  [pvc]: http://guides.rubygems.org/patterns/#pessimistic-version-constraint
177
221
  [confoog]: http://confoog.seapagan.net
178
222
  [mit]: http://opensource.org/licenses/MIT
223
+ [vagrant]: https://www.vagrantup.com/
224
+ [vagrantdl]: https://www.vagrantup.com/downloads.html
225
+ [virtualbox]: https://www.virtualbox.org
226
+ [virtualboxdl]: https://www.virtualbox.org/wiki/Downloads
227
+ [node]: http://nodejs.org
228
+ [mobaxterm]: http://mobaxterm.mobatek.net/
229
+ [git4windows]: https://git-scm.com/download/win
179
230