cocoapods-bugsnag 2.1.0 → 2.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA256:
3
- metadata.gz: 8b6be2d67d8a7328337375f824d428008832765847d254e443c524ac9eacc0e6
4
- data.tar.gz: d94c59ef08d73b5cc15c0b679bb7c40226c2c3ac8e2d1740a17d2fbe56d483ba
2
+ SHA1:
3
+ metadata.gz: 482f70c66ea52e9633b644d594c1c8ef9bdddbe5
4
+ data.tar.gz: f4a0810109c18cf8edd07bcbda48d2d84ec37d9b
5
5
  SHA512:
6
- metadata.gz: 8e1cdcba0c5564af91b44a6ef46afef0eb4a49618d7eee82cf9e3641ced0ae82043ecac4ad0f68f07d461b9fce8442f22e32bdfa8be89800f3b255b63e0349eb
7
- data.tar.gz: 2888cc1f3cecce524327ca998791e996d3919c77dbe9dc6b052183776b0f00dfe3c961747e918ebc198f093b7b53f7c319edfb21161539f88e42e87876bc607e
6
+ metadata.gz: 17a00ed6b43c406eba7390a722cf06930b32780c030efc2218b4d856a8a71981994fbc3925c87d4185b1ff988c7a2631c6445e1f45328e725b71dfa69a11e5ad
7
+ data.tar.gz: 8432e08a32cf59006b02fbe56fc846221544aaea895eea9c5eb3ae76d6e9d7a01dd3dd0c729028ef2b5899f8c25cbc276914ffca24bea94a34d722587d9c4e57
@@ -1,5 +1,15 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.2.0 (30 Sept 2020)
4
+
5
+ ### Enhancements
6
+
7
+ * This plugin now finds `Info.plist` using Xcode environment variables, rather than a `glob` operation for robustness.
8
+ | [#15](https://github.com/bugsnag/cocoapods-bugsnag/pull/15)
9
+
10
+ * This plugin will now only add itself to your Xcode project if it is explicitly added as a plugin in your `Podfile`. Previously it would install if `Bugsnag` was detected in your `Podfile`.
11
+ | [#16](https://github.com/bugsnag/cocoapods-bugsnag/pull/16)
12
+
3
13
  ## 2.1.0 (14 Aug 2020)
4
14
 
5
15
  ### Enhancements
data/README.md CHANGED
@@ -24,12 +24,21 @@ install, run:
24
24
 
25
25
  ## Usage
26
26
 
27
- To add the build phase to your project, add pod Bugsnag to your Podfile and run:
27
+ To add the build phase to your project, add `pod 'Bugsnag'`, and `plugin 'cocoapods-bugsnag'` to your `Podfile`:
28
+
29
+ ```ruby
30
+ pod 'Bugsnag'
31
+ plugin 'cocoapods-bugsnag'
32
+ ```
33
+
34
+ Then, install with:
28
35
 
29
36
  ```bash
30
37
  pod install
31
38
  ```
32
39
 
40
+ Once added, uploading your dSYM files to Bugsnag will occur automatically.
41
+
33
42
  By default, your Bugsnag API key will either be read from the `BUGSNAG_API_KEY`
34
43
  environment variable or from the `:bugsnag:apiKey` (or `BugsnagAPIKey`) value in your
35
44
  `Info.plist`. Alternatively edit the script in the new "Upload Bugsnag dSYM" build
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = "cocoapods-bugsnag"
3
- spec.version = "2.1.0"
3
+ spec.version = "2.2.0"
4
4
  spec.homepage = "https://bugsnag.com"
5
5
  spec.description = "Configures the dSYM upload phase of your project when integrated with bugsnag."
6
6
  spec.summary = "To get meaningful stacktraces from your crashes, the Bugsnag service needs your dSYM file for your build. This plugin adds an upload phase to your project where needed."
@@ -11,7 +11,7 @@ unless api_key
11
11
 
12
12
  # If not present, attempt to lookup the value from the Info.plist
13
13
  unless api_key
14
- info_plist_path = Dir.glob("./{ios/,}*/Info.plist").reject {|path| path =~ /build|test/i }.first
14
+ info_plist_path = "#{ENV["BUILT_PRODUCTS_DIR"]}/#{ENV["INFOPLIST_PATH"]}"
15
15
  plist_buddy_response = `/usr/libexec/PlistBuddy -c "print :bugsnag:apiKey" "#{info_plist_path}"`
16
16
  plist_buddy_response = `/usr/libexec/PlistBuddy -c "print :BugsnagAPIKey" "#{info_plist_path}"` if !$?.success?
17
17
  api_key = plist_buddy_response if $?.success?
@@ -40,7 +40,7 @@ RUBY
40
40
  alias_method :integrate_without_bugsnag!, :integrate!
41
41
  def integrate!
42
42
  integrate_without_bugsnag!
43
- return unless has_bugsnag_dependency?
43
+ return unless should_add_build_phase?
44
44
  return if bugsnag_native_targets.empty?
45
45
  UI.section("Integrating with Bugsnag") do
46
46
  add_bugsnag_upload_script_phase
@@ -62,10 +62,12 @@ RUBY
62
62
  end
63
63
  end
64
64
 
65
- def has_bugsnag_dependency?
66
- target.target_definition.dependencies.detect do |dep|
65
+ def should_add_build_phase?
66
+ has_bugsnag_dep = target.target_definition.dependencies.any? do |dep|
67
67
  dep.name.include?('Bugsnag')
68
- end != nil
68
+ end
69
+ uses_bugsnag_plugin = target.target_definition.podfile.plugins.key?('cocoapods-bugsnag')
70
+ return has_bugsnag_dep && uses_bugsnag_plugin
69
71
  end
70
72
 
71
73
  def bugsnag_native_targets
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cocoapods-bugsnag
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Delisa Mason
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-08-14 00:00:00.000000000 Z
11
+ date: 2020-09-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cocoapods
@@ -72,7 +72,7 @@ homepage: https://bugsnag.com
72
72
  licenses:
73
73
  - MIT
74
74
  metadata: {}
75
- post_install_message:
75
+ post_install_message:
76
76
  rdoc_options: []
77
77
  require_paths:
78
78
  - lib
@@ -87,8 +87,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
87
87
  - !ruby/object:Gem::Version
88
88
  version: '0'
89
89
  requirements: []
90
- rubygems_version: 3.1.4
91
- signing_key:
90
+ rubyforge_project:
91
+ rubygems_version: 2.6.14
92
+ signing_key:
92
93
  specification_version: 4
93
94
  summary: To get meaningful stacktraces from your crashes, the Bugsnag service needs
94
95
  your dSYM file for your build. This plugin adds an upload phase to your project