fastlane-plugin-sentry 1.8.1 → 1.8.2

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: 44cdcc376ab1d5eb23be4b3df42df41439d9513223d75da50dce1e2bb355b45e
4
- data.tar.gz: 2d704986551776f3541123eb35c57b1929f0ed61e43a38c4b8c246de2e84a112
3
+ metadata.gz: 997460b2dd7418643a318ce88f9ecf72e45a087e11ca1bfbb50da96ed9ec1fc6
4
+ data.tar.gz: cbfdbe73533b999f88124548a5e458989f2f599e3621fd7ab9b89500de37e573
5
5
  SHA512:
6
- metadata.gz: 77d45a74189f1150f3ede90a134f7e8b7bf1a62e637fa4631b74dcfac93b7c518593f930c2488bcde7674567b0fd0345647e8dc2379e70eca02057188b97bb84
7
- data.tar.gz: d8240c42154fe0fdc00a36c0f6cba559cddf896a1ba3d321c5ece6ee4a863c1271e03a323fa1fe3efe6e4df782716d256494cc5b0184bb389069a30971b8041e
6
+ metadata.gz: b8f36f2206339e9f133b882a2fe52fb7961488784811e3d5f1c1af311bb584c5332079a697f9aad98e05c6b3845d7057b4892a1a1c1cfbf5eec888760718c6d1
7
+ data.tar.gz: db320f54c60e647f31ab222d0190eb3c82d480726832df20ebe62638edabeecf0d5610990e5cf20e044c148defa727c947bdd665f91e9dc10b3dacac3d743653
data/README.md CHANGED
@@ -118,6 +118,27 @@ sentry_set_commits(
118
118
  )
119
119
  ```
120
120
 
121
+ #### Create deploy
122
+
123
+ Creates a new release deployment for a project on Sentry.
124
+
125
+ ```ruby
126
+ sentry_create_deploy(
127
+ api_key: '...', # Do not use if using auth_token
128
+ auth_token: '...', # Do not use if using api_key
129
+ org_slug: '...',
130
+ project_slug: '...',
131
+ version: '...',
132
+ app_identifier: '...', # pass in the bundle_identifer of your app
133
+ env: 'staging', # The environment for this deploy. Required.
134
+ name: '...', # Optional human readable name
135
+ deploy_url: '...', # Optional URL that points to the deployment
136
+ started: 1622630647, # Optional unix timestamp when the deployment started
137
+ finished: 1622630700, # Optional unix timestamp when the deployment finished
138
+ time: 180 # Optional deployment duration in seconds. This can be specified alternatively to `started` and `finished`
139
+ )
140
+ ```
141
+
121
142
  ## Issues and Feedback
122
143
 
123
144
  For any other issues and feedback about this plugin, please submit it to this repository.
@@ -0,0 +1,95 @@
1
+ module Fastlane
2
+ module Actions
3
+ class SentryCreateDeployAction < Action
4
+ def self.run(params)
5
+ require 'shellwords'
6
+
7
+ Helper::SentryHelper.check_sentry_cli!
8
+ Helper::SentryConfig.parse_api_params(params)
9
+
10
+ version = params[:version]
11
+ version = "#{params[:app_identifier]}@#{params[:version]}" if params[:app_identifier]
12
+
13
+ command = [
14
+ "sentry-cli",
15
+ "releases",
16
+ "deploys",
17
+ version,
18
+ "new"
19
+ ]
20
+ command.push('--env').push(params[:env]) unless params[:env].nil?
21
+ command.push('--name').push(params[:name]) unless params[:name].nil?
22
+ command.push('--url').push(params[:deploy_url]) unless params[:deploy_url].nil?
23
+ command.push('--started').push(params[:started]) unless params[:started].nil?
24
+ command.push('--finished').push(params[:finished]) unless params[:finished].nil?
25
+ command.push('--time').push(params[:time]) unless params[:time].nil?
26
+
27
+ Helper::SentryHelper.call_sentry_cli(command)
28
+ UI.success("Successfully created deploy: #{version}")
29
+ end
30
+
31
+ #####################################################
32
+ # @!group Documentation
33
+ #####################################################
34
+
35
+ def self.description
36
+ "Creates a new release deployment for a project on Sentry"
37
+ end
38
+
39
+ def self.details
40
+ [
41
+ "This action allows you to associate deploys to releases for a project on Sentry.",
42
+ "See https://docs.sentry.io/product/cli/releases/#creating-deploys for more information."
43
+ ].join(" ")
44
+ end
45
+
46
+ def self.available_options
47
+ Helper::SentryConfig.common_api_config_items + [
48
+ FastlaneCore::ConfigItem.new(key: :version,
49
+ description: "Release version to associate the deploy with on Sentry"),
50
+ FastlaneCore::ConfigItem.new(key: :env,
51
+ short_option: "-e",
52
+ description: "Set the environment for this release. This argument is required. Values that make sense here would be 'production' or 'staging'",
53
+ optional: false),
54
+ FastlaneCore::ConfigItem.new(key: :name,
55
+ short_option: "-n",
56
+ description: "Optional human readable name for this deployment",
57
+ optional: true),
58
+ FastlaneCore::ConfigItem.new(key: :deploy_url,
59
+ description: "Optional URL that points to the deployment",
60
+ optional: true),
61
+ FastlaneCore::ConfigItem.new(key: :started,
62
+ description: "Optional unix timestamp when the deployment started",
63
+ is_string: false,
64
+ optional: true),
65
+ FastlaneCore::ConfigItem.new(key: :finished,
66
+ description: "Optional unix timestamp when the deployment finished",
67
+ is_string: false,
68
+ optional: true),
69
+ FastlaneCore::ConfigItem.new(key: :time,
70
+ short_option: "-t",
71
+ description: "Optional deployment duration in seconds. This can be specified alternatively to `started` and `finished`",
72
+ is_string: false,
73
+ optional: true),
74
+ FastlaneCore::ConfigItem.new(key: :app_identifier,
75
+ short_option: "-a",
76
+ env_name: "SENTRY_APP_IDENTIFIER",
77
+ description: "App Bundle Identifier, prepended with the version.\nFor example bundle@version",
78
+ optional: true)
79
+ ]
80
+ end
81
+
82
+ def self.return_value
83
+ nil
84
+ end
85
+
86
+ def self.authors
87
+ ["denrase"]
88
+ end
89
+
90
+ def self.is_supported?(platform)
91
+ true
92
+ end
93
+ end
94
+ end
95
+ end
@@ -1,6 +1,6 @@
1
1
  module Fastlane
2
2
  module Sentry
3
- VERSION = "1.8.1"
3
+ VERSION = "1.8.2"
4
4
  CLI_VERSION = "1.63.1"
5
5
  end
6
6
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-sentry
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.1
4
+ version: 1.8.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sentry
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-03-03 00:00:00.000000000 Z
11
+ date: 2021-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry
@@ -89,6 +89,7 @@ files:
89
89
  - LICENSE
90
90
  - README.md
91
91
  - lib/fastlane/plugin/sentry.rb
92
+ - lib/fastlane/plugin/sentry/actions/sentry_create_deploy.rb
92
93
  - lib/fastlane/plugin/sentry/actions/sentry_create_release.rb
93
94
  - lib/fastlane/plugin/sentry/actions/sentry_finalize_release.rb
94
95
  - lib/fastlane/plugin/sentry/actions/sentry_set_commits.rb
@@ -118,7 +119,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
118
119
  - !ruby/object:Gem::Version
119
120
  version: '0'
120
121
  requirements: []
121
- rubygems_version: 3.0.3
122
+ rubygems_version: 3.1.6
122
123
  signing_key:
123
124
  specification_version: 4
124
125
  summary: Upload symbols to Sentry