danger-android_version_change 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 23ca31f593cedee62a2cf6022675f7edb4f60a80b65ba503bde17faa5a9bd3e1
4
- data.tar.gz: cd6b3ba0136c8c766e681531ec0af6fdb6b6628f11d742b7a9868698a75cd2d0
3
+ metadata.gz: 7ae3cf66485d4fa93c348e916f35e406875d728179b7ffe399f02a0fd4829c30
4
+ data.tar.gz: 6f91ba3ae0906c7bdc9bf9da8177fedf112b822874b43063524061fb7c0ea7ca
5
5
  SHA512:
6
- metadata.gz: 9b6c557b856fe751c15bd01a0b9b0fe342e5034fb9dbc12bdc25c7e8953173c29656a279465327f79dfec3336e7ed855cf876302b9c88fbd773d6d2caa68a526
7
- data.tar.gz: 837f79b58cbe0a78ad9ea53a46ef77541524d6f4e9f47443fb0b14e99d1e9cfa025712a79666568c47030d30c8377b90a77e6b4a6ffa568a8a2e82ea3ceecfa4
6
+ metadata.gz: 2e89455a45a9768c4c29f66172d06a896762a0a8f7ca8f4ff9144e0e5fbe36e58d4131e40a3d2bb18f4f6e71daf45a0378b8dfdd398b2da440c4b4bc785ffd96
7
+ data.tar.gz: 8b81e38663b8fb4856d559006b5a6e3c950791dd4749652612fa057f6cc40f8ed7412683627e62543b254269d441845093b19194ebe6514cbaac68015a5e08df
data/.circleci/config.yml CHANGED
@@ -23,7 +23,7 @@ jobs:
23
23
  - checkout
24
24
  - run: ./assert_danger_running_on_pr.sh
25
25
  - run: bundle install
26
- - run: '[ ! -z $DANGER_GITHUB_API_TOKEN ] && danger || echo "Skipping Danger for External Contributor"'
26
+ - run: '[ ! -z $DANGER_GITHUB_API_TOKEN ] && danger --fail-on-errors=true || echo "Skipping Danger for External Contributor"'
27
27
  test-lint:
28
28
  working_directory: ~/code
29
29
  docker:
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- danger-android_version_change (0.1.0)
4
+ danger-android_version_change (0.1.1)
5
5
  danger-plugin-api (~> 1.0)
6
6
 
7
7
  GEM
@@ -68,7 +68,7 @@ GEM
68
68
  notiffany (0.1.1)
69
69
  nenv (~> 0.1)
70
70
  shellany (~> 0.0)
71
- octokit (4.7.0)
71
+ octokit (4.8.0)
72
72
  sawyer (~> 0.8.0, >= 0.5.3)
73
73
  open4 (1.3.4)
74
74
  parallel (1.12.0)
@@ -132,7 +132,7 @@ DEPENDENCIES
132
132
  rspec (~> 3.4)
133
133
  rspec_junit_formatter (~> 0.3.0)
134
134
  rubocop (~> 0.49)
135
- yard (~> 0.8)
135
+ yard (~> 0.9.11)
136
136
 
137
137
  BUNDLED WITH
138
138
  1.16.0
@@ -31,7 +31,7 @@ Gem::Specification.new do |spec|
31
31
 
32
32
  # Linting code and docs
33
33
  spec.add_development_dependency "rubocop", "~> 0.49"
34
- spec.add_development_dependency "yard", "~> 0.8"
34
+ spec.add_development_dependency "yard", "~> 0.9.11"
35
35
 
36
36
  # Makes testing easy via `bundle exec guard`
37
37
  spec.add_development_dependency 'guard', '~> 2.14'
@@ -1,3 +1,3 @@
1
1
  module AndroidVersionChange
2
- VERSION = "0.1.0".freeze
2
+ VERSION = "0.1.1".freeze
3
3
  end
@@ -20,6 +20,8 @@ module Danger
20
20
  "android_version_change"
21
21
  end
22
22
 
23
+ DEFAULT_BUILD_GRADLE_FILE_PATH = "app/build.gradle".freeze
24
+
23
25
  def initialize(dangerfile)
24
26
  super(dangerfile)
25
27
  end
@@ -42,14 +44,12 @@ module Danger
42
44
  # (Internal use) Takes path to build.gradle as well as "versionName" or "versionCode" string to check for change.
43
45
  # @return [void]
44
46
  def assert_version_changed(override_build_gradle_file_path, name_or_code)
45
- build_gradle_file_path = override_build_gradle_file_path || "app/build.gradle"
46
-
47
- unless File.file?(build_gradle_file_path)
48
- fail "build.gradle file at path " + build_gradle_file_path + " does not exist."
47
+ unless File.file?(override_build_gradle_file_path)
48
+ fail "build.gradle file at path " + override_build_gradle_file_path + " does not exist."
49
49
  return # rubocop:disable UnreachableCode
50
50
  end
51
51
 
52
- unless git.diff_for_file(build_gradle_file_path) # No diff found for build.gradle file.
52
+ unless git.diff_for_file(override_build_gradle_file_path) # No diff found for build.gradle file.
53
53
  fail "You did not edit your build.gradle file at all. Therefore, you did not change the " + name_or_code + "."
54
54
  return # rubocop:disable UnreachableCode
55
55
  end
@@ -70,7 +70,7 @@ module Danger
70
70
  # @param [String] override_build_gradle_file_path
71
71
  # (optional) Path to build.gradle file for Android project that versionName is located in.
72
72
  # @return [void]
73
- def assert_version_name_changed(override_build_gradle_file_path)
73
+ def assert_version_name_changed(override_build_gradle_file_path = DEFAULT_BUILD_GRADLE_FILE_PATH)
74
74
  assert_version_changed(override_build_gradle_file_path, "versionName")
75
75
  end
76
76
 
@@ -86,7 +86,7 @@ module Danger
86
86
  # @param [String] override_build_gradle_file_path
87
87
  # (optional) Path to build.gradle file for Android project that versionCode is located in.
88
88
  # @return [void]
89
- def assert_version_code_changed(override_build_gradle_file_path)
89
+ def assert_version_code_changed(override_build_gradle_file_path = DEFAULT_BUILD_GRADLE_FILE_PATH)
90
90
  assert_version_changed(override_build_gradle_file_path, "versionCode")
91
91
  end
92
92
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: danger-android_version_change
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Levi Bostian
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-12-19 00:00:00.000000000 Z
11
+ date: 2017-12-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: danger-plugin-api
@@ -86,14 +86,14 @@ dependencies:
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: '0.8'
89
+ version: 0.9.11
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: '0.8'
96
+ version: 0.9.11
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: guard
99
99
  requirement: !ruby/object:Gem::Requirement