ruby-grape-danger 0.1.1 → 0.2.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 +5 -5
- data/.rubocop_todo.yml +6 -5
- data/.travis.yml +1 -11
- data/CHANGELOG.md +6 -2
- data/Dangerfile +11 -5
- data/Gemfile +1 -1
- data/README.md +16 -6
- data/Rakefile +3 -1
- data/lib/ruby-grape-danger/version.rb +1 -1
- data/ruby-grape-danger.gemspec +3 -2
- metadata +19 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: ec847d3ab41f8dfdd3574918c3f6359ab0fc07fdbf987e07ba4122938fedc340
|
4
|
+
data.tar.gz: 0001a3c7853211985573408c7f023eea39fbdf6f18a12ce13d6c347b6a7202f8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 84a7d0f9ef511cc3a300a2989fd9647ab60a58b3a2f84abe9f2705c60134da93c9caa20f0f4333bbf4241d3df3c52bcfa6e86054f2fc7ef038b8649ea2f64a2d
|
7
|
+
data.tar.gz: 00d39f0e53db429a624c971537fbe19d12141891edbbac3e94b1462510eb96c7d9e2506cdc7aa104f0668128df1381c6914c3268535f488d07e757930cff72db
|
data/.rubocop_todo.yml
CHANGED
@@ -1,13 +1,14 @@
|
|
1
1
|
# This configuration was generated by
|
2
2
|
# `rubocop --auto-gen-config`
|
3
|
-
# on
|
3
|
+
# on 2020-05-09 10:55:58 -0400 using RuboCop version 0.82.0.
|
4
4
|
# The point is for the user to remove these configuration records
|
5
5
|
# one by one as the offenses are removed from the code base.
|
6
6
|
# Note that changes in the inspected code, or installation of new
|
7
7
|
# versions of RuboCop, may require this file to be generated again.
|
8
8
|
|
9
|
-
# Offense count:
|
10
|
-
#
|
9
|
+
# Offense count: 14
|
10
|
+
# Cop supports --auto-correct.
|
11
|
+
# Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
|
11
12
|
# URISchemes: http, https
|
12
|
-
|
13
|
-
Max:
|
13
|
+
Layout/LineLength:
|
14
|
+
Max: 169
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,10 +1,14 @@
|
|
1
1
|
### Changelog
|
2
2
|
|
3
|
-
### 0.
|
3
|
+
### 0.2.0 (2020/05/09)
|
4
|
+
|
5
|
+
* [#8](https://github.com/ruby-grape/danger/pull/8): Upgraded Danger 8.0, danger-changelog 0.6.1 and added danger-toc 0.2.0 - [@dblock](https://github.com/dblock).
|
6
|
+
|
7
|
+
### 0.1.1 (2016/12/05)
|
4
8
|
|
5
9
|
* [#7](https://github.com/ruby-grape/danger/pull/7): Upgraded to danger 4.0.1 and danger-changelog 0.2.0 - [@dblock](https://github.com/dblock).
|
6
10
|
|
7
|
-
### 0.1.0 (
|
11
|
+
### 0.1.0 (2016/09/03)
|
8
12
|
|
9
13
|
* [#5](https://github.com/ruby-grape/danger/pull/5): Initial public release as a gem for Danger 3.2.0 - [@dblock](https://github.com/dblock).
|
10
14
|
|
data/Dangerfile
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
# --------------------------------------------------------------------------------------------------------------------
|
2
4
|
# Has any changes happened inside the actual library code?
|
3
5
|
# --------------------------------------------------------------------------------------------------------------------
|
@@ -7,9 +9,7 @@ has_spec_changes = !git.modified_files.grep(/spec/).empty?
|
|
7
9
|
# --------------------------------------------------------------------------------------------------------------------
|
8
10
|
# You've made changes to lib, but didn't write any tests?
|
9
11
|
# --------------------------------------------------------------------------------------------------------------------
|
10
|
-
if has_app_changes && !has_spec_changes
|
11
|
-
warn("There're library changes, but not tests. That's OK as long as you're refactoring existing code.", sticky: false)
|
12
|
-
end
|
12
|
+
warn("There're library changes, but not tests. That's OK as long as you're refactoring existing code.", sticky: false) if has_app_changes && !has_spec_changes
|
13
13
|
|
14
14
|
# --------------------------------------------------------------------------------------------------------------------
|
15
15
|
# You've made changes to specs, but no library code has changed?
|
@@ -21,15 +21,21 @@ end
|
|
21
21
|
# --------------------------------------------------------------------------------------------------------------------
|
22
22
|
# Have you updated CHANGELOG.md?
|
23
23
|
# --------------------------------------------------------------------------------------------------------------------
|
24
|
-
changelog.check
|
24
|
+
changelog.check!
|
25
|
+
|
26
|
+
# --------------------------------------------------------------------------------------------------------------------
|
27
|
+
# Do you have a TOC?
|
28
|
+
# --------------------------------------------------------------------------------------------------------------------
|
29
|
+
toc.check!
|
25
30
|
|
26
31
|
# --------------------------------------------------------------------------------------------------------------------
|
27
32
|
# Don't let testing shortcuts get into master by accident,
|
28
33
|
# ensuring that we don't get green builds based on a subset of tests.
|
29
34
|
# --------------------------------------------------------------------------------------------------------------------
|
30
35
|
|
31
|
-
(git.modified_files + git.added_files - %w
|
36
|
+
(git.modified_files + git.added_files - %w[Dangerfile]).each do |file|
|
32
37
|
next unless File.file?(file)
|
38
|
+
|
33
39
|
contents = File.read(file)
|
34
40
|
if file.start_with?('spec')
|
35
41
|
fail("`xit` or `fit` left in tests (#{file})") if contents =~ /^\w*[xf]it/
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -4,15 +4,25 @@
|
|
4
4
|
|
5
5
|
[](https://travis-ci.org/ruby-grape/danger)
|
6
6
|
|
7
|
-
|
7
|
+
## Table of Contents
|
8
|
+
|
9
|
+
- [Setup](#setup)
|
10
|
+
- [Set DANGER_GITHUB_API_TOKEN in Travis-CI](#set-danger_github_api_token-in-travis-ci)
|
11
|
+
- [Add Danger](#add-danger)
|
12
|
+
- [Add Dangerfile](#add-dangerfile)
|
13
|
+
- [Add Danger to Travis-CI](#add-danger-to-travis-ci)
|
14
|
+
- [Commit via a Pull Request](#commit-via-a-pull-request)
|
15
|
+
- [License](#license)
|
16
|
+
|
17
|
+
## Setup
|
8
18
|
|
9
19
|
Enable Danger for a project within the [ruby-grape organization](https://github.com/ruby-grape).
|
10
20
|
|
11
|
-
|
21
|
+
### Set DANGER_GITHUB_API_TOKEN in Travis-CI
|
12
22
|
|
13
23
|
In Travis-CI, choose _Settings_ and add `DANGER_GITHUB_API_TOKEN` in _Environment Variables_. Set the value to the API key for the [grape-bot](https://github.com/grape-bot) user, look in [this build log](https://travis-ci.org/ruby-grape/danger/builds/148579641) for its value.
|
14
24
|
|
15
|
-
|
25
|
+
### Add Danger
|
16
26
|
|
17
27
|
Add `ruby-grape-danger` to `Gemfile`.
|
18
28
|
|
@@ -20,7 +30,7 @@ Add `ruby-grape-danger` to `Gemfile`.
|
|
20
30
|
gem 'ruby-grape-danger', '~> 0.1.0', require: false
|
21
31
|
```
|
22
32
|
|
23
|
-
|
33
|
+
### Add Dangerfile
|
24
34
|
|
25
35
|
Commit a `Dangerfile`, eg. [Grape's Dangerfile](https://github.com/ruby-grape/grape/blob/master/Dangerfile).
|
26
36
|
|
@@ -28,7 +38,7 @@ Commit a `Dangerfile`, eg. [Grape's Dangerfile](https://github.com/ruby-grape/gr
|
|
28
38
|
danger.import_dangerfile(gem: 'ruby-grape-danger')
|
29
39
|
```
|
30
40
|
|
31
|
-
|
41
|
+
### Add Danger to Travis-CI
|
32
42
|
|
33
43
|
Add Danger to `.travis.yml`, eg. [Grape's Travis.yml](https://github.com/ruby-grape/grape/blob/master/.travis.yml).
|
34
44
|
|
@@ -40,7 +50,7 @@ matrix:
|
|
40
50
|
- bundle exec danger
|
41
51
|
```
|
42
52
|
|
43
|
-
|
53
|
+
### Commit via a Pull Request
|
44
54
|
|
45
55
|
To test things out, make a dummy entry in `CHANGELOG.md` that doesn't match the standard format and make a pull request. Iterate until green.
|
46
56
|
|
data/Rakefile
CHANGED
data/ruby-grape-danger.gemspec
CHANGED
@@ -17,6 +17,7 @@ Gem::Specification.new do |s|
|
|
17
17
|
|
18
18
|
s.add_development_dependency 'rake'
|
19
19
|
s.add_development_dependency 'rspec'
|
20
|
-
s.add_runtime_dependency 'danger', '~>
|
21
|
-
s.add_runtime_dependency 'danger-changelog', '~> 0.
|
20
|
+
s.add_runtime_dependency 'danger', '~> 8.0.0'
|
21
|
+
s.add_runtime_dependency 'danger-changelog', '~> 0.6.1'
|
22
|
+
s.add_runtime_dependency 'danger-toc', '~> 0.2.0'
|
22
23
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-grape-danger
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- dblock
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-05-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -44,16 +44,30 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 8.0.0
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 8.0.0
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: danger-changelog
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 0.6.1
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: 0.6.1
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: danger-toc
|
57
71
|
requirement: !ruby/object:Gem::Requirement
|
58
72
|
requirements:
|
59
73
|
- - "~>"
|
@@ -109,8 +123,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
109
123
|
- !ruby/object:Gem::Version
|
110
124
|
version: '0'
|
111
125
|
requirements: []
|
112
|
-
|
113
|
-
rubygems_version: 2.5.1
|
126
|
+
rubygems_version: 3.0.3
|
114
127
|
signing_key:
|
115
128
|
specification_version: 4
|
116
129
|
summary: Danger.systems conventions for ruby-grape projects.
|