codeguard 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +2 -0
- data/.rubocop.yml +880 -0
- data/Gemfile +7 -0
- data/LICENSE +21 -0
- data/README.md +20 -0
- data/Rakefile +26 -0
- data/bin/codeguard +9 -0
- data/codeguard.gemspec +28 -0
- data/config/.gitmessage +16 -0
- data/config/.rubocop.yml +880 -0
- data/config/.scss-lint.yml +234 -0
- data/config/coffeelint.json +135 -0
- data/config/jshint.yml +21 -0
- data/eat-glitter.jpg +0 -0
- data/lib/codeguard/cli.rb +17 -0
- data/lib/codeguard/coffeelint.rb +13 -0
- data/lib/codeguard/diff.rb +44 -0
- data/lib/codeguard/git_message.rb +17 -0
- data/lib/codeguard/install.rb +46 -0
- data/lib/codeguard/js_hint.rb +13 -0
- data/lib/codeguard/rubocop.rb +13 -0
- data/lib/codeguard/scss_lint.rb +13 -0
- data/lib/codeguard/version.rb +3 -0
- data/lib/codeguard.rb +54 -0
- metadata +155 -0
data/Gemfile
ADDED
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2015 code quest
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
# Coding style @ codequest
|
2
|
+
### One stop shop for style
|
3
|
+
![Eat glitter for breakfast](eat-glitter.jpg)
|
4
|
+
|
5
|
+
At code quest we enjoy tools that standardize and improve code style. As a team,
|
6
|
+
the less menial stuff you have to worry about the better your code review is.
|
7
|
+
In essence this gem is a source of linter configs.
|
8
|
+
**Feel free to suggest improvements.**
|
9
|
+
|
10
|
+
|
11
|
+
### Installation
|
12
|
+
Add to your Gemfile:
|
13
|
+
```ruby
|
14
|
+
group :development, :test do
|
15
|
+
gem 'codeguard'
|
16
|
+
end
|
17
|
+
```
|
18
|
+
and run `bundle install`.
|
19
|
+
|
20
|
+
You can check available options by running: `codeguard help`
|
data/Rakefile
ADDED
@@ -0,0 +1,26 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
require 'rubygems'
|
3
|
+
require 'bundler'
|
4
|
+
|
5
|
+
Bundler::GemHelper.install_tasks
|
6
|
+
Bundler.setup
|
7
|
+
|
8
|
+
$LOAD_PATH.unshift(File.dirname(__FILE__) + '/lib')
|
9
|
+
|
10
|
+
require 'codeguard'
|
11
|
+
|
12
|
+
namespace :codeguard do
|
13
|
+
task :install do
|
14
|
+
Codeguard.install
|
15
|
+
end
|
16
|
+
|
17
|
+
task :help do
|
18
|
+
Codeguard.help
|
19
|
+
end
|
20
|
+
|
21
|
+
task :diff do
|
22
|
+
Codeguard.diff
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
task default: 'codeguard:help'
|
data/bin/codeguard
ADDED
data/codeguard.gemspec
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
$LOAD_PATH.push File.expand_path('../lib', __FILE__)
|
2
|
+
|
3
|
+
require 'codeguard/version'
|
4
|
+
|
5
|
+
Gem::Specification.new do |spec|
|
6
|
+
spec.name = 'codeguard'
|
7
|
+
spec.version = Codeguard::VERSION
|
8
|
+
|
9
|
+
spec.authors = ['Marcin Wyszynski', 'Michal Samluk']
|
10
|
+
spec.email = ['marcinw@codequest.com', 'michal@codequest.com']
|
11
|
+
spec.description = 'code quest styleguide'
|
12
|
+
spec.summary = 'Simple installer for configuration files used'\
|
13
|
+
'in code quest.'
|
14
|
+
spec.homepage = 'https://github.com/codequest-eu/codeguard'
|
15
|
+
spec.license = 'MIT'
|
16
|
+
|
17
|
+
spec.files = `git ls-files`.split($RS)
|
18
|
+
spec.executables = `git ls-files -- bin/*`.split("\n").map do |f|
|
19
|
+
File.basename(f)
|
20
|
+
end
|
21
|
+
|
22
|
+
spec.add_runtime_dependency 'rubocop'
|
23
|
+
spec.add_runtime_dependency 'jshint'
|
24
|
+
spec.add_runtime_dependency 'scss_lint'
|
25
|
+
spec.add_runtime_dependency 'diffy'
|
26
|
+
spec.add_development_dependency 'bundler', '>= 1.6.9'
|
27
|
+
spec.add_development_dependency 'rake', '~> 10.3'
|
28
|
+
end
|
data/config/.gitmessage
ADDED
@@ -0,0 +1,16 @@
|
|
1
|
+
|
2
|
+
|
3
|
+
# 50-character subject line
|
4
|
+
#
|
5
|
+
# 72-character wrapped longer description. This should answer:
|
6
|
+
#
|
7
|
+
# * Why was this change necessary?
|
8
|
+
# * How does it address the problem?
|
9
|
+
# * Are there any side effects?
|
10
|
+
#
|
11
|
+
# Include a link to the ticket, if any.
|
12
|
+
#
|
13
|
+
# Read about good commit messages:
|
14
|
+
# http://chris.beams.io/posts/git-commit/
|
15
|
+
#
|
16
|
+
# https://robots.thoughtbot.com/5-useful-tips-for-a-better-commit-message
|