danger-swiftlint 0.29.3 → 0.30.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ext/swiftlint/Rakefile +1 -1
- data/ext/swiftlint/downloadSwiftlint.sh +10 -1
- data/lib/version.rb +3 -3
- data/spec/danger_plugin_spec.rb +2 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d752a2629a03d820751dadd013a5612306d79d746188a0162d83cd821fe89fa
|
4
|
+
data.tar.gz: 70dc6132f6ca69e68be576039908008af2a651485770713dcd27ed381d513059
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b9f00f2d1917aa217c7f26798f7cd559fb13a578030837d8c5571b4b7d38543dd62fb0906b993a65c4c77c0157395b806aa5ab9432db64db0c21f43435998f4f
|
7
|
+
data.tar.gz: a8615e231514973d705a332301b31e95a23a84218c9ba72b4259c718483ef4ebdd1229ec47e5b4f5d2436f476496c68eeef54023d5f64fd313c62e5ed9480704
|
data/ext/swiftlint/Rakefile
CHANGED
@@ -16,7 +16,7 @@ namespace :swiftlint do
|
|
16
16
|
SWIFTLINT_MD5_HASH = DangerSwiftlint::SWIFTLINT_HASH
|
17
17
|
|
18
18
|
puts "Downloading swiftlint@#{VERSION}"
|
19
|
-
sh "
|
19
|
+
sh "#{SCRIPT_PATH}/downloadSwiftlint.sh -u #{URL} -d #{DESTINATION} -a #{ASSET} -dh #{SWIFTLINT_MD5_HASH}"
|
20
20
|
end
|
21
21
|
end
|
22
22
|
|
@@ -34,7 +34,16 @@ done
|
|
34
34
|
### Download
|
35
35
|
mkdir -p "${destination}"
|
36
36
|
curl -s -L "${url}" -o "${asset}"
|
37
|
-
|
37
|
+
|
38
|
+
# If macOS
|
39
|
+
if [[ "$OSTYPE" == "darwin"* ]]; then
|
40
|
+
resulting_hash=`md5 -q ${asset}`
|
41
|
+
# Default to linux
|
42
|
+
else
|
43
|
+
resulting_hash=`md5sum ${asset} | awk '{ print $1 }'`
|
44
|
+
fi
|
45
|
+
|
46
|
+
if [[ ! -z "${SWIFTLINT_VERSION}" || "$resulting_hash" == "${default_hash}" ]]; then
|
38
47
|
# if another version is set || our hardcoded hash is correct
|
39
48
|
unzip -o -q "${asset}" -d "${destination}"
|
40
49
|
else
|
data/lib/version.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
module DangerSwiftlint
|
4
|
-
VERSION = '0.
|
5
|
-
SWIFTLINT_VERSION = '0.
|
6
|
-
SWIFTLINT_HASH = '
|
4
|
+
VERSION = '0.30.1'
|
5
|
+
SWIFTLINT_VERSION = '0.46.2'
|
6
|
+
SWIFTLINT_HASH = '20dbcc13788993dd27b1076a13ca647d'
|
7
7
|
end
|
data/spec/danger_plugin_spec.rb
CHANGED
@@ -220,6 +220,7 @@ module Danger
|
|
220
220
|
end
|
221
221
|
|
222
222
|
it 'crashes if renamed_files is not configured properly' do
|
223
|
+
allow_any_instance_of(Swiftlint).to receive(:lint).and_return('')
|
223
224
|
allow(@swiftlint.git).to receive(:modified_files).and_return([
|
224
225
|
'spec/fixtures/SwiftFileThatWasRenamedToSomethingElse.swift'
|
225
226
|
])
|
@@ -227,6 +228,7 @@ module Danger
|
|
227
228
|
end
|
228
229
|
|
229
230
|
it 'does not crash if a modified file was renamed' do
|
231
|
+
allow_any_instance_of(Swiftlint).to receive(:lint).and_return('')
|
230
232
|
allow(@swiftlint.git).to receive(:modified_files).and_return([
|
231
233
|
'spec/fixtures/SwiftFileThatWasRenamedToSomethingElse.swift'
|
232
234
|
])
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: danger-swiftlint
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.30.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ash Furrow
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date:
|
15
|
+
date: 2022-02-27 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: danger
|
@@ -181,7 +181,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
181
181
|
- !ruby/object:Gem::Version
|
182
182
|
version: '0'
|
183
183
|
requirements: []
|
184
|
-
rubygems_version: 3.
|
184
|
+
rubygems_version: 3.0.9
|
185
185
|
signing_key:
|
186
186
|
specification_version: 4
|
187
187
|
summary: A Danger plugin for linting Swift with SwiftLint.
|