slather 2.7.4 → 2.7.5

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: b43954fd6f31e519f192e32ad881197d35830912e22158ca17cf333b86f97e0d
4
- data.tar.gz: 97cf7f9b6eb50d2472aec42c3f698c3a299c38cfd8757cdb2a6e2dcad0933bc6
3
+ metadata.gz: 2c4a1059a1eae7156ac2c98e509e9cc267e6dd29fbd18332155e94b81c56c3de
4
+ data.tar.gz: b4d09bcb4d70d24e482268791c1a86f80f62a5f9206b3188931dabd1e8673b30
5
5
  SHA512:
6
- metadata.gz: f38c40172a16f8375b56cdc873e92339f1f275cef7848bc0d9947714073dd5ff93ba11dc1957781c69316eec59a213c079067b99cb48c134aeb24c20ae2cb945
7
- data.tar.gz: 1a098f9ab86b11d5c65cea0c309a99a709de76dfdc0f1171f0e100784522a74613cdb3fb06346f4fb1d6e27825250f01ece561ac07bea6e59a489837c7c0c654
6
+ metadata.gz: 2a526985aec8bbf888ccdf584c3638c97349eddaff3b905df334a88ec42e865f1012c928aa520a3471ad6aadf911e60894576f018230da63aceeb27939a00921
7
+ data.tar.gz: fa77a74cef513c27b2e09101f20b0357c1cf163c1f94b273137a0738fd163bce9700f4e48b76bdfcd2a12e72ba4c3baaf24f0ce86738143f23f87f5a806fcda5
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # CHANGELOG
2
2
 
3
+ ## v2.7.5
4
+
5
+ * Add `--cdn-assets` flag
6
+ [sushant-here](https://github.com/sushant-here)
7
+ [#537](https://github.com/SlatherOrg/slather/pull/537)
8
+
9
+ * Update nokogiri version
10
+
3
11
  ## v2.7.4
4
12
 
5
13
  * Support Ruby 3.2.0
data/README.md CHANGED
@@ -134,13 +134,14 @@ test:
134
134
 
135
135
  ### Usage with Coveralls
136
136
 
137
- Login to [Coveralls](https://coveralls.io/) and enable your repository. Right now, `slather` supports Coveralls via [Travis CI](https://travis-ci.org) and [CircleCI](https://circleci.com).
137
+ Login to [Coveralls](https://coveralls.io/) and enable your repository. Right now, `slather` supports Coveralls via [Travis CI](https://travis-ci.org), [CircleCI](https://circleci.com), [Jenkins](https://www.jenkins.io/), [Teamcity](https://www.jetbrains.com/teamcity/), [Buildkite](https://buildkite.com/), and [Bitrise](https://bitrise.io/).
138
138
 
139
- Make a `.slather.yml` file:
139
+ Make a `.slather.yml` file and specify the CI Service you're using:
140
140
 
141
141
  ```yml
142
142
  # .slather.yml
143
143
 
144
+ ci_service: circleci | travis_ci | travis_pro | jenkins | buildkite | teamcity
144
145
  coverage_service: coveralls
145
146
  xcodeproj: path/to/project.xcodeproj
146
147
  scheme: YourXcodeSchemeName
@@ -233,6 +234,8 @@ $ slather coverage --html --scheme YourXcodeSchemeName path/to/project.xcodeproj
233
234
 
234
235
  This will make a directory named `html` in your root directory (unless `--output-directory` is specified) and will generate all the reports as static html pages inside the directory. It will print out the report's path by default, but you can also specify `--show` flag to open it in your browser automatically.
235
236
 
237
+ By default, the generated HTML will reference locally hosted assets (js, css). You can specify the `--cdn-assets` to specify that you prefer for the generated HTML to use externally hosted assets. This can be useful if publishing the HTML file as a build artifact.
238
+
236
239
  ### TeamCity Reporting
237
240
 
238
241
  To report the coverage statistics to TeamCity:
@@ -19,6 +19,7 @@ class CoverageCommand < Clamp::Command
19
19
  option ["--json"], :flag, "Output coverage results as simple JSON"
20
20
  option ["--html"], :flag, "Output coverage results as static html pages"
21
21
  option ["--show"], :flag, "Indicate that the static html pages will open automatically"
22
+ option ["--cdn-assets"], :flag, "Indicate that the static html pages will load assets from a CDN"
22
23
 
23
24
  option ["--build-directory", "-b"], "BUILD_DIRECTORY", "The directory where gcno files will be written to. Defaults to derived data."
24
25
  option ["--source-directory"], "SOURCE_DIRECTORY", "The directory where your source files are located."
@@ -126,6 +127,7 @@ class CoverageCommand < Clamp::Command
126
127
  elsif html?
127
128
  project.coverage_service = :html
128
129
  project.show_html = show?
130
+ project.cdn_assets = cdn_assets?
129
131
  elsif json?
130
132
  project.coverage_service = :json
131
133
  elsif sonarqube_xml?
@@ -233,10 +233,17 @@ module Slather
233
233
  end
234
234
 
235
235
  def generate_html_template(title, is_index, is_file_empty)
236
- logo_path = "logo.jpg"
237
- css_path = "slather.css"
238
- highlight_js_path = "highlight.pack.js"
239
- list_js_path = "list.min.js"
236
+ if cdn_assets
237
+ logo_path = "https://cdn.jsdelivr.net/gh/SlatherOrg/slather/docs/logo.jpg"
238
+ css_path = "https://cdn.jsdelivr.net/gh/SlatherOrg/slather/assets/slather.css"
239
+ highlight_js_path = "https://cdn.jsdelivr.net/gh/SlatherOrg/slather/assets/highlight.pack.js"
240
+ list_js_path = "https://cdn.jsdelivr.net/gh/SlatherOrg/slather/assets/list.min.js"
241
+ else
242
+ logo_path = "logo.jpg"
243
+ css_path = "slather.css"
244
+ highlight_js_path = "highlight.pack.js"
245
+ list_js_path = "list.min.js"
246
+ end
240
247
 
241
248
  builder = Nokogiri::HTML::Builder.new do |doc|
242
249
  doc.html {
@@ -44,7 +44,7 @@ module Slather
44
44
  class Project < Xcodeproj::Project
45
45
 
46
46
  attr_accessor :build_directory, :ignore_list, :ci_service, :coverage_service, :coverage_access_token, :source_directory,
47
- :output_directory, :xcodeproj, :show_html, :verbose_mode, :input_format, :scheme, :workspace, :binary_file, :binary_basename, :arch, :source_files,
47
+ :output_directory, :xcodeproj, :show_html, :cdn_assets, :verbose_mode, :input_format, :scheme, :workspace, :binary_file, :binary_basename, :arch, :source_files,
48
48
  :decimals, :llvm_version, :configuration
49
49
 
50
50
  alias_method :setup_for_coverage, :slather_setup_for_coverage
@@ -1,3 +1,3 @@
1
1
  module Slather
2
- VERSION = '2.7.4' unless defined?(Slather::VERSION)
2
+ VERSION = '2.7.5' unless defined?(Slather::VERSION)
3
3
  end
data/slather.gemspec CHANGED
@@ -29,7 +29,7 @@ Gem::Specification.new do |spec|
29
29
 
30
30
  spec.add_dependency 'clamp', '~> 1.3'
31
31
  spec.add_dependency 'xcodeproj', '~> 1.21'
32
- spec.add_dependency 'nokogiri', '>= 1.13.9'
32
+ spec.add_dependency 'nokogiri', '>= 1.14.3'
33
33
  spec.add_dependency 'CFPropertyList', '>= 2.2', '< 4'
34
34
 
35
35
  spec.add_runtime_dependency 'activesupport'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: slather
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.7.4
4
+ version: 2.7.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mark Larsen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-01-12 00:00:00.000000000 Z
11
+ date: 2023-10-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -170,14 +170,14 @@ dependencies:
170
170
  requirements:
171
171
  - - ">="
172
172
  - !ruby/object:Gem::Version
173
- version: 1.13.9
173
+ version: 1.14.3
174
174
  type: :runtime
175
175
  prerelease: false
176
176
  version_requirements: !ruby/object:Gem::Requirement
177
177
  requirements:
178
178
  - - ">="
179
179
  - !ruby/object:Gem::Version
180
- version: 1.13.9
180
+ version: 1.14.3
181
181
  - !ruby/object:Gem::Dependency
182
182
  name: CFPropertyList
183
183
  requirement: !ruby/object:Gem::Requirement
@@ -341,7 +341,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
341
341
  - !ruby/object:Gem::Version
342
342
  version: '0'
343
343
  requirements: []
344
- rubygems_version: 3.2.22
344
+ rubygems_version: 3.4.10
345
345
  signing_key:
346
346
  specification_version: 4
347
347
  summary: Test coverage reports for Xcode projects