alpinelab-codestyle 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/LICENSE.md +21 -0
- data/README.md +46 -0
- data/config/default.yml +17 -0
- metadata +79 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 25e5d9ac090dfa7090f47183e41db77c4204ef915c5f9e62a99ad5c07b85965e
|
4
|
+
data.tar.gz: 94d609cc4399dc91d6cd6dd974912eccdb1392cf7877296c799576d087d44857
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 1e92ec6ba82dabfc80622a2e814d519f346eb21dd33e4e55419354d6739431e00fbc5383d5769860ff2cccd42877ecb23bd1a3e266a220d168dac2976b406aa7
|
7
|
+
data.tar.gz: 59797909106f54f00d7148b1b5abeb09bb58d7497dd52465224f7e8b8e1e6e8803bed03f2ac88302ae49c4d55a67c82675f64719f98f5f4218b0df9e63e615c4
|
data/LICENSE.md
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2018 Alpine Lab
|
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,46 @@
|
|
1
|
+
# AlpineLab code style
|
2
|
+
|
3
|
+
Code style used by AlpineLab in all our projects.
|
4
|
+
|
5
|
+
## Usage
|
6
|
+
|
7
|
+
1. Add this gem to your `Gemfile` (or `gems.rb`, or `gems.deps.rb`):
|
8
|
+
|
9
|
+
```ruby
|
10
|
+
group :development do
|
11
|
+
gem "alpinelab-codestyle", "~> x.y"
|
12
|
+
end
|
13
|
+
```
|
14
|
+
|
15
|
+
or install it manually:
|
16
|
+
|
17
|
+
```shell
|
18
|
+
gem install alpinelab-codestyle
|
19
|
+
```
|
20
|
+
|
21
|
+
2. Create or prepend your Rubocop configuration (usually `.rubocop.yml`) with:
|
22
|
+
|
23
|
+
```yaml
|
24
|
+
inherit_gem:
|
25
|
+
alpinelab-codestyle:
|
26
|
+
- config/default.yml
|
27
|
+
```
|
28
|
+
|
29
|
+
## Best practices
|
30
|
+
|
31
|
+
Some conventions are adopted and enforced, in no particular order:
|
32
|
+
|
33
|
+
1. Developer-specific configuration files must be git-ignored globally, _e.g._:
|
34
|
+
|
35
|
+
* `.ruby-{version,gemset}`
|
36
|
+
* `docker-compose.override.yml`
|
37
|
+
|
38
|
+
2. Project-specific configuration files must be git-ignored per project, _e.g._:
|
39
|
+
|
40
|
+
* `config/database.yml`
|
41
|
+
|
42
|
+
## License
|
43
|
+
|
44
|
+
This project is developed by [Alpine Lab](https://www.alpine-lab.com) and released under the terms of the [MIT license](LICENSE.md).
|
45
|
+
|
46
|
+
<a href="https://www.alpine-lab.com"><img src=".github/alpinelab-logo.png" width="40%" /></a>
|
data/config/default.yml
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
Layout/AccessModifierIndentation:
|
2
|
+
EnforcedStyle: outdent
|
3
|
+
|
4
|
+
Layout/EndAlignment:
|
5
|
+
EnforcedStyleAlignWith: start_of_line
|
6
|
+
|
7
|
+
Style/AndOr:
|
8
|
+
Enabled: false
|
9
|
+
|
10
|
+
Style/Documentation:
|
11
|
+
Enabled: false
|
12
|
+
|
13
|
+
Style/DoubleNegation:
|
14
|
+
Enabled: false
|
15
|
+
|
16
|
+
Style/StringLiterals:
|
17
|
+
EnforcedStyle: double_quotes
|
metadata
ADDED
@@ -0,0 +1,79 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: alpinelab-codestyle
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.3.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- AlpineLab developers
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2018-09-25 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
description: |
|
42
|
+
This repository holds linter rules (e.g. Rubocop) that enforce our code
|
43
|
+
style in any project (thanks to Rubocop `inherit_gem' directive) as well as
|
44
|
+
other conventions not transposable as automated rules (those are explained
|
45
|
+
as plain Markdown).
|
46
|
+
email:
|
47
|
+
- dahu@alpine-lab.com
|
48
|
+
executables: []
|
49
|
+
extensions: []
|
50
|
+
extra_rdoc_files: []
|
51
|
+
files:
|
52
|
+
- LICENSE.md
|
53
|
+
- README.md
|
54
|
+
- config/default.yml
|
55
|
+
homepage: https://www.alpine-lab.com
|
56
|
+
licenses:
|
57
|
+
- MIT
|
58
|
+
metadata: {}
|
59
|
+
post_install_message:
|
60
|
+
rdoc_options: []
|
61
|
+
require_paths:
|
62
|
+
- lib
|
63
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
64
|
+
requirements:
|
65
|
+
- - ">="
|
66
|
+
- !ruby/object:Gem::Version
|
67
|
+
version: 2.3.0
|
68
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
69
|
+
requirements:
|
70
|
+
- - ">="
|
71
|
+
- !ruby/object:Gem::Version
|
72
|
+
version: '0'
|
73
|
+
requirements: []
|
74
|
+
rubyforge_project:
|
75
|
+
rubygems_version: 2.7.6
|
76
|
+
signing_key:
|
77
|
+
specification_version: 4
|
78
|
+
summary: Code style used by AlpineLab
|
79
|
+
test_files: []
|