netsoft-danger 0.3.4 → 0.3.5
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 +4 -4
- data/.circleci/config.yml +2 -0
- data/CHANGELOG.md +17 -0
- data/Dangerfile +19 -6
- data/bin/setup-rubygems.sh +3 -0
- data/lib/netsoft-danger/version.rb +1 -1
- data/netsoft-danger.gemspec +1 -0
- metadata +18 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2b7b3e2a4fbfa992da4950813e78d8276a5f8055b4b09987d36b62b761134f8a
|
4
|
+
data.tar.gz: e7f4046f836e76a11c5fcb5e37b31acdf664e921f506f8f7312a489852418168
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2cde3fa84fa78f571710f9d52d4508410550f0e30d7795e5f925aca31902453e328ccb332db3fb003bcfd692a22a55a470eff5ed0859a87492131b5c3636aa76
|
7
|
+
data.tar.gz: 38b61ca91282d42ba78b2bd7752f0be930fc1790f751bfb7c1e53e4772d66ca74dcf3d5e756aeb8011c6da009340bbacd436c7969f1030cce123ea406aefe8d1
|
data/.circleci/config.yml
CHANGED
data/CHANGELOG.md
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# Changelog
|
2
|
+
All notable changes to this project will be documented in this file.
|
3
|
+
|
4
|
+
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
5
|
+
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
6
|
+
|
7
|
+
## [Next]
|
8
|
+
### Added
|
9
|
+
### Changed
|
10
|
+
### Fixed
|
11
|
+
|
12
|
+
## [0.3.5]
|
13
|
+
### Added
|
14
|
+
- package.json checks
|
15
|
+
### Fixed
|
16
|
+
- requie older version of faraday until octokit is fixed (https://github.com/octokit/octokit.rb/pull/1154)
|
17
|
+
|
data/Dangerfile
CHANGED
@@ -23,7 +23,7 @@ git.commits.each do |c|
|
|
23
23
|
short = " ( #{c.sha[0..7]} )"
|
24
24
|
has_migrations = c.diff_parent.any? {|f| f.path =~ /db\/migrate\// }
|
25
25
|
has_schema_changes = c.diff_parent.any? {|f| f.path =~ /db\/schema\.rb/ }
|
26
|
-
has_migration_msg = c.message =~
|
26
|
+
has_migration_msg = c.message =~ /\A\[migration\]/
|
27
27
|
no_schema_ok = ENV['DANGER_NO_SCHEMA_OK'] || false
|
28
28
|
if has_migrations || has_schema_changes
|
29
29
|
unless has_migration_msg
|
@@ -35,27 +35,27 @@ git.commits.each do |c|
|
|
35
35
|
if !has_migrations && has_schema_changes
|
36
36
|
warn '[migration] Please checkin your migrations with your schema.rb changes' + short
|
37
37
|
end
|
38
|
-
if c.diff_parent.any? {|f| !( f.path =~ /db\/migrate
|
38
|
+
if c.diff_parent.any? {|f| !( f.path =~ /db\/migrate\/|db\/schema\.rb/ ) }
|
39
39
|
fail '[migration] Migration commit contains non-migration changes' + short
|
40
40
|
end
|
41
41
|
elsif has_migration_msg
|
42
42
|
fail '[migration] Migration commit with no migrations!' + short
|
43
43
|
end
|
44
44
|
|
45
|
-
has_hubstaff_icon_changes = c.diff_parent.any? {|f| f.path =~ /hubstaff(icons|font)
|
45
|
+
has_hubstaff_icon_changes = c.diff_parent.any? {|f| f.path =~ /hubstaff(icons|font)|fontcustom-manifest/ }
|
46
46
|
if has_hubstaff_icon_changes
|
47
47
|
if c.diff_parent.any? {|f| !( f.path =~ /hubstaff-(icons|font)/ || f.path =~ /fontcustom-manifest/ ) }
|
48
48
|
fail '[hubstaff-icons] Put hubstaff-icon changes into their own commit' + short
|
49
49
|
end
|
50
50
|
end
|
51
51
|
|
52
|
-
has_gemfile_changes = c.diff_parent.any? {|f| f.path =~ /Gemfile
|
53
|
-
has_gemfile_msg = c.message =~
|
52
|
+
has_gemfile_changes = c.diff_parent.any? {|f| f.path =~ /Gemfile|gemspec/ }
|
53
|
+
has_gemfile_msg = c.message =~ /\A\[gemfile\]/
|
54
54
|
if has_gemfile_changes
|
55
55
|
unless has_gemfile_msg
|
56
56
|
fail '[gemfile] Gemfile commits need to be prefixed with [gemfile] ' + short
|
57
57
|
end
|
58
|
-
if c.diff_parent.any? {|f| !( f.path =~ /Gemfile
|
58
|
+
if c.diff_parent.any? {|f| !( f.path =~ /Gemfile|gemspec/ ) }
|
59
59
|
fail '[gemfile] Gemfile commit contains non-gemfile changes' + short
|
60
60
|
end
|
61
61
|
if c.diff_parent.any? {|f| f.path == 'Gemfile.lock' }
|
@@ -66,6 +66,19 @@ git.commits.each do |c|
|
|
66
66
|
elsif has_gemfile_msg
|
67
67
|
fail '[gemfile] Gemfile commit has no gemfile changes!' + short
|
68
68
|
end
|
69
|
+
|
70
|
+
has_package_changes = c.diff_parent.any? {|f| f.path =~ /package\.json|yarn\.lock/ }
|
71
|
+
has_package_msg = c.message =~ /\A\[package\.json\]/
|
72
|
+
if has_package_changes
|
73
|
+
unless has_package_msg
|
74
|
+
fail '[package.json] Package.json commits need to be prefixed with [package.json] ' + short
|
75
|
+
end
|
76
|
+
if c.diff_parent.any? {|f| !( f.path =~ /package\.json|yarn\.lock/ ) }
|
77
|
+
fail '[package.json] Package.json commit contains non-package changes' + short
|
78
|
+
end
|
79
|
+
elsif has_package_msg
|
80
|
+
fail '[package.json] Pacakge.json commit has no package changes!' + short
|
81
|
+
end
|
69
82
|
end
|
70
83
|
|
71
84
|
require 'open-uri'
|
data/netsoft-danger.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: netsoft-danger
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- urkle
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-09-
|
11
|
+
date: 2019-09-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -52,6 +52,20 @@ dependencies:
|
|
52
52
|
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: faraday
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 0.15.0
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: 0.15.0
|
55
69
|
description: Packages a Dangerfile to be used with Danger.
|
56
70
|
email: []
|
57
71
|
executables:
|
@@ -61,11 +75,13 @@ extra_rdoc_files: []
|
|
61
75
|
files:
|
62
76
|
- ".circleci/config.yml"
|
63
77
|
- ".gitignore"
|
78
|
+
- CHANGELOG.md
|
64
79
|
- Dangerfile
|
65
80
|
- Gemfile
|
66
81
|
- README.md
|
67
82
|
- Rakefile
|
68
83
|
- bin/netsoft-circle
|
84
|
+
- bin/setup-rubygems.sh
|
69
85
|
- bin/tag_check.sh
|
70
86
|
- dangerfiles/issue.js
|
71
87
|
- dangerfiles/pr.js
|