fastlane-plugin-sentry 0 → 0.1.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.
@@ -1,99 +0,0 @@
1
- module Fastlane
2
- module Actions
3
- class SentrySetCommitsAction < Action
4
- def self.run(params)
5
- require 'shellwords'
6
-
7
- Helper::SentryConfig.parse_api_params(params)
8
-
9
- version = params[:version]
10
- version = "#{params[:app_identifier]}@#{params[:version]}" if params[:app_identifier]
11
- version = "#{version}+#{params[:build]}" if params[:build]
12
-
13
- command = [
14
- "releases",
15
- "set-commits",
16
- version
17
- ]
18
-
19
- command.push('--auto') if params[:auto]
20
- command.push('--clear') if params[:clear]
21
- command.push('--ignore-missing') if params[:ignore_missing]
22
- command.push('--local') if params[:local]
23
- command.push('--initial-depth').push(params[:initial_depth]) unless params[:initial_depth].nil?
24
- command.push('--commit').push(params[:commit]) unless params[:commit].nil?
25
-
26
- Helper::SentryHelper.call_sentry_cli(params, command)
27
- UI.success("Successfully set commits for release: #{version}")
28
- end
29
-
30
- #####################################################
31
- # @!group Documentation
32
- #####################################################
33
-
34
- def self.description
35
- "Set commits of a release"
36
- end
37
-
38
- def self.details
39
- [
40
- "This action allows you to set commits in a release for a project on Sentry.",
41
- "See https://docs.sentry.io/cli/releases/#sentry-cli-commit-integration for more information."
42
- ].join(" ")
43
- end
44
-
45
- def self.available_options
46
- Helper::SentryConfig.common_api_config_items + [
47
- FastlaneCore::ConfigItem.new(key: :version,
48
- description: "Release version on Sentry"),
49
- FastlaneCore::ConfigItem.new(key: :app_identifier,
50
- short_option: "-a",
51
- env_name: "SENTRY_APP_IDENTIFIER",
52
- description: "App Bundle Identifier, prepended to version",
53
- optional: true),
54
- FastlaneCore::ConfigItem.new(key: :build,
55
- short_option: "-b",
56
- description: "Release build on Sentry",
57
- optional: true),
58
- FastlaneCore::ConfigItem.new(key: :auto,
59
- description: "Enable completely automated commit management",
60
- is_string: false,
61
- default_value: false),
62
- FastlaneCore::ConfigItem.new(key: :clear,
63
- description: "Clear all current commits from the release",
64
- is_string: false,
65
- default_value: false),
66
- FastlaneCore::ConfigItem.new(key: :commit,
67
- description: "Commit spec, see `sentry-cli releases help set-commits` for more information",
68
- optional: true),
69
- FastlaneCore::ConfigItem.new(key: :ignore_missing,
70
- description: "When enabled, if the previous release commit was not found in the repository, will create a release with the default commits count (or the one specified with `--initial-depth`) instead of failing the command",
71
- is_string: false,
72
- default_value: false),
73
- FastlaneCore::ConfigItem.new(key: :local,
74
- description: "Set commits of a release from local git. This requires that the command \
75
- is run from within a git repository. sentry-cli will then automatically find \
76
- remotely configured repositories and discover commits",
77
- is_string: false,
78
- optional: true),
79
- FastlaneCore::ConfigItem.new(key: :initial_depth,
80
- description: "Set the number of commits of the initial release. The default is 20",
81
- type: Integer,
82
- optional: true)
83
- ]
84
- end
85
-
86
- def self.return_value
87
- nil
88
- end
89
-
90
- def self.authors
91
- ["brownoxford"]
92
- end
93
-
94
- def self.is_supported?(platform)
95
- true
96
- end
97
- end
98
- end
99
- end
@@ -1,132 +0,0 @@
1
- module Fastlane
2
- module Actions
3
- class SentryUploadBuildAction < Action
4
- def self.run(params)
5
- Helper::SentryConfig.parse_api_params(params)
6
-
7
- # Verify xcarchive path
8
- xcarchive_path = params[:xcarchive_path]
9
- UI.user_error!("Could not find xcarchive at path '#{xcarchive_path}'") unless File.exist?(xcarchive_path)
10
- UI.user_error!("Path '#{xcarchive_path}' is not an xcarchive") unless File.extname(xcarchive_path) == '.xcarchive'
11
-
12
- command = [
13
- "build",
14
- "upload",
15
- File.absolute_path(xcarchive_path)
16
- ]
17
-
18
- # Add git-related parameters if provided
19
- command << "--head-sha" << params[:head_sha] if params[:head_sha]
20
- command << "--base-sha" << params[:base_sha] if params[:base_sha]
21
- command << "--vcs-provider" << params[:vcs_provider] if params[:vcs_provider]
22
- command << "--head-repo-name" << params[:head_repo_name] if params[:head_repo_name]
23
- command << "--base-repo-name" << params[:base_repo_name] if params[:base_repo_name]
24
- command << "--head-ref" << params[:head_ref] if params[:head_ref]
25
- command << "--base-ref" << params[:base_ref] if params[:base_ref]
26
- command << "--pr-number" << params[:pr_number] if params[:pr_number]
27
- command << "--build-configuration" << params[:build_configuration] if params[:build_configuration]
28
- command << "--release-notes" << params[:release_notes] if params[:release_notes]
29
- command << "--force-git-metadata" if params[:force_git_metadata]
30
- command << "--no-git-metadata" if params[:no_git_metadata]
31
-
32
- Helper::SentryHelper.call_sentry_cli(params, command)
33
- UI.success("Successfully uploaded build archive: #{xcarchive_path}")
34
- end
35
-
36
- #####################################################
37
- # @!group Documentation
38
- #####################################################
39
-
40
- def self.description
41
- "Upload iOS build archive to Sentry with optional git context"
42
- end
43
-
44
- def self.details
45
- "This action allows you to upload iOS build archives (.xcarchive) to Sentry with optional git-related parameters for enhanced context including commit SHAs, branch names, repository information, and pull request details."
46
- end
47
-
48
- def self.available_options
49
- Helper::SentryConfig.common_api_config_items + [
50
- FastlaneCore::ConfigItem.new(key: :xcarchive_path,
51
- description: "Path to your iOS build archive (.xcarchive)",
52
- default_value: Actions.lane_context[SharedValues::XCODEBUILD_ARCHIVE],
53
- verify_block: proc do |value|
54
- UI.user_error!("Could not find xcarchive at path '#{value}'") unless File.exist?(value)
55
- UI.user_error!("Path '#{value}' is not an xcarchive") unless File.extname(value) == '.xcarchive'
56
- end),
57
- FastlaneCore::ConfigItem.new(key: :head_sha,
58
- env_name: "SENTRY_HEAD_SHA",
59
- description: "The SHA of the head of the current branch",
60
- optional: true,
61
- is_string: true),
62
- FastlaneCore::ConfigItem.new(key: :base_sha,
63
- env_name: "SENTRY_BASE_SHA",
64
- description: "The SHA of the base branch",
65
- optional: true,
66
- is_string: true),
67
- FastlaneCore::ConfigItem.new(key: :vcs_provider,
68
- env_name: "SENTRY_VCS_PROVIDER",
69
- description: "The version control system provider (e.g., 'github', 'gitlab')",
70
- optional: true,
71
- is_string: true),
72
- FastlaneCore::ConfigItem.new(key: :head_repo_name,
73
- env_name: "SENTRY_HEAD_REPO_NAME",
74
- description: "The name of the head repository",
75
- optional: true,
76
- is_string: true),
77
- FastlaneCore::ConfigItem.new(key: :base_repo_name,
78
- env_name: "SENTRY_BASE_REPO_NAME",
79
- description: "The name of the base repository",
80
- optional: true,
81
- is_string: true),
82
- FastlaneCore::ConfigItem.new(key: :head_ref,
83
- env_name: "SENTRY_HEAD_REF",
84
- description: "The name of the head branch",
85
- optional: true,
86
- is_string: true),
87
- FastlaneCore::ConfigItem.new(key: :base_ref,
88
- env_name: "SENTRY_BASE_REF",
89
- description: "The name of the base branch",
90
- optional: true,
91
- is_string: true),
92
- FastlaneCore::ConfigItem.new(key: :pr_number,
93
- env_name: "SENTRY_PR_NUMBER",
94
- description: "The pull request number",
95
- optional: true,
96
- is_string: true),
97
- FastlaneCore::ConfigItem.new(key: :build_configuration,
98
- env_name: "SENTRY_BUILD_CONFIGURATION",
99
- description: "The build configuration (e.g., 'Release', 'Debug')",
100
- optional: true,
101
- is_string: true),
102
- FastlaneCore::ConfigItem.new(key: :release_notes,
103
- description: "The release notes to use for the upload",
104
- optional: true,
105
- is_string: true),
106
- FastlaneCore::ConfigItem.new(key: :force_git_metadata,
107
- description: "Force collection and sending of git metadata (branch, commit, etc.). \
108
- If neither this nor --no-git-metadata is specified, git metadata is automatically \
109
- collected when running in most CI environments",
110
- is_string: false,
111
- optional: true),
112
- FastlaneCore::ConfigItem.new(key: :no_git_metadata,
113
- description: "Disable collection and sending of git metadata",
114
- is_string: false,
115
- optional: true)
116
- ]
117
- end
118
-
119
- def self.return_value
120
- nil
121
- end
122
-
123
- def self.authors
124
- ["runningcode"]
125
- end
126
-
127
- def self.is_supported?(platform)
128
- [:ios].include?(platform)
129
- end
130
- end
131
- end
132
- end
@@ -1,88 +0,0 @@
1
- module Fastlane
2
- module Actions
3
- class SentryUploadProguardAction < Action
4
- def self.run(params)
5
- Helper::SentryConfig.parse_api_params(params)
6
-
7
- mapping_path = params[:mapping_path]
8
-
9
- # Verify file exists
10
- UI.user_error!("Mapping file does not exist at path: #{mapping_path}") unless File.exist? mapping_path
11
-
12
- command = [
13
- "upload-proguard",
14
- mapping_path
15
- ]
16
-
17
- command.push('--no-upload') if params[:no_upload]
18
- command.push('--write-properties').push(params[:write_properties]) unless params[:write_properties].nil?
19
- command.push('--require-one') if params[:require_one]
20
- command.push('--uuid').push(params[:uuid]) unless params[:uuid].nil?
21
-
22
- Helper::SentryHelper.call_sentry_cli(params, command)
23
- UI.success("Successfully uploaded mapping file!")
24
- end
25
-
26
- #####################################################
27
- # @!group Documentation
28
- #####################################################
29
-
30
- def self.description
31
- "Upload mapping to a project on Sentry"
32
- end
33
-
34
- def self.details
35
- [
36
- "This action allows you to upload the proguard mapping file to Sentry.",
37
- "See https://docs.sentry.io/product/cli/dif/#proguard-mapping-upload for more information."
38
- ].join(" ")
39
- end
40
-
41
- def self.available_options
42
- Helper::SentryConfig.common_api_config_items + [
43
- FastlaneCore::ConfigItem.new(key: :mapping_path,
44
- env_name: "ANDROID_MAPPING_PATH",
45
- description: "Path to your proguard mapping.txt file",
46
- optional: false,
47
- verify_block: proc do |value|
48
- UI.user_error! "Could not find your mapping file at path '#{value}'" unless File.exist?(value)
49
- end),
50
- FastlaneCore::ConfigItem.new(key: :no_upload,
51
- description: "Disable the actual upload. This runs all steps for the processing \
52
- but does not trigger the upload. This is useful if you just want to verify the \
53
- mapping files and write the proguard UUIDs into a properties file",
54
- is_string: false,
55
- optional: true),
56
- FastlaneCore::ConfigItem.new(key: :write_properties,
57
- description: "Write the UUIDs for the processed mapping files into the given \
58
- properties file",
59
- optional: true),
60
- FastlaneCore::ConfigItem.new(key: :require_one,
61
- description: "Requires at least one file to upload or the command will error",
62
- is_string: false,
63
- optional: true),
64
- FastlaneCore::ConfigItem.new(key: :uuid,
65
- description: "Explicitly override the UUID of the mapping file with another one. \
66
- This should be used with caution as it means that you can upload multiple mapping \
67
- files if you don't take care. This however can be useful if you have a build \
68
- process in which you need to know the UUID of the proguard file before it was \
69
- created. If you upload a file with a forced UUID you can only upload a single \
70
- proguard file",
71
- optional: true)
72
- ]
73
- end
74
-
75
- def self.return_value
76
- nil
77
- end
78
-
79
- def self.authors
80
- ["mpp-anasa"]
81
- end
82
-
83
- def self.is_supported?(platform)
84
- platform == :android
85
- end
86
- end
87
- end
88
- end
@@ -1,209 +0,0 @@
1
- module Fastlane
2
- module Actions
3
- class SentryUploadSourcemapAction < Action
4
- def self.run(params)
5
- require 'shellwords'
6
-
7
- Helper::SentryConfig.parse_api_params(params)
8
-
9
- version = params[:version]
10
- version = "#{params[:app_identifier]}@#{params[:version]}" if params[:app_identifier]
11
- version = "#{version}+#{params[:build]}" if params[:build]
12
-
13
- sourcemaps = params[:sourcemap]
14
-
15
- command = [
16
- "sourcemaps",
17
- "upload",
18
- "--release",
19
- version
20
- ]
21
- command += sourcemaps
22
-
23
- command.push('--no-rewrite') unless params[:rewrite]
24
- command.push('--strip-prefix').push(params[:strip_prefix]) if params[:strip_prefix]
25
- command.push('--strip-common-prefix') if params[:strip_common_prefix]
26
- command.push('--url-prefix').push(params[:url_prefix]) unless params[:url_prefix].nil?
27
- command.push('--url-suffix').push(params[:url_suffix]) unless params[:url_suffix].nil?
28
- command.push('--dist').push(params[:dist]) unless params[:dist].nil?
29
- command.push('--note').push(params[:note]) unless params[:note].nil?
30
- command.push('--validate') if params[:validate]
31
- command.push('--decompress') if params[:decompress]
32
- command.push('--wait') if params[:wait]
33
- command.push('--wait-for').push(params[:wait_for]) unless params[:wait_for].nil?
34
- command.push('--no-sourcemap-reference') if params[:no_sourcemap_reference]
35
- command.push('--debug-id-reference') if params[:debug_id_reference]
36
- command.push('--bundle').push(params[:bundle]) unless params[:bundle].nil?
37
- command.push('--bundle-sourcemap').push(params[:bundle_sourcemap]) unless params[:bundle_sourcemap].nil?
38
- command.push('--strict') if params[:strict]
39
-
40
- unless params[:ignore].nil?
41
- # normalize to array
42
- unless params[:ignore].kind_of?(Enumerable)
43
- params[:ignore] = [params[:ignore]]
44
- end
45
- # no nil or empty strings
46
- params[:ignore].reject! do |e|
47
- e.strip.empty?
48
- rescue StandardError
49
- true
50
- end
51
- params[:ignore].each do |pattern|
52
- command.push('--ignore').push(pattern)
53
- end
54
- end
55
-
56
- command.push('--ignore-file').push(params[:ignore_file]) unless params[:ignore_file].nil?
57
-
58
- unless params[:ext].nil?
59
- # normalize to array
60
- unless params[:ext].kind_of?(Enumerable)
61
- params[:ext] = [params[:ext]]
62
- end
63
- params[:ext].each do |extension|
64
- command.push('--ext').push(extension)
65
- end
66
- end
67
-
68
- Helper::SentryHelper.call_sentry_cli(params, command)
69
- UI.success("Successfully uploaded files to release: #{version}")
70
- end
71
-
72
- #####################################################
73
- # @!group Documentation
74
- #####################################################
75
-
76
- def self.description
77
- "Upload one or more sourcemap(s) to a release of a project on Sentry"
78
- end
79
-
80
- def self.details
81
- [
82
- "This action allows you to upload one or more sourcemap(s) to a release of a project on Sentry.",
83
- "See https://docs.sentry.io/learn/cli/releases/#upload-sourcemaps for more information."
84
- ].join(" ")
85
- end
86
-
87
- def self.available_options
88
- Helper::SentryConfig.common_api_config_items + [
89
- FastlaneCore::ConfigItem.new(key: :version,
90
- description: "Release version on Sentry"),
91
- FastlaneCore::ConfigItem.new(key: :app_identifier,
92
- short_option: "-a",
93
- env_name: "SENTRY_APP_IDENTIFIER",
94
- description: "App Bundle Identifier, prepended to version",
95
- optional: true),
96
- FastlaneCore::ConfigItem.new(key: :build,
97
- short_option: "-b",
98
- description: "Release build on Sentry",
99
- optional: true),
100
- FastlaneCore::ConfigItem.new(key: :dist,
101
- description: "Distribution in release",
102
- optional: true),
103
- FastlaneCore::ConfigItem.new(key: :sourcemap,
104
- description: "Path or an array of paths to the sourcemap(s) to upload",
105
- type: Array,
106
- verify_block: proc do |values|
107
- [*values].each do |value|
108
- UI.user_error! "Could not find sourcemap at path '#{value}'" unless File.exist?(value)
109
- end
110
- end),
111
- FastlaneCore::ConfigItem.new(key: :rewrite,
112
- description: "Rewrite the sourcemaps before upload",
113
- default_value: false,
114
- is_string: false,
115
- optional: true),
116
- FastlaneCore::ConfigItem.new(key: :strip_prefix,
117
- conflicting_options: [:strip_common_prefix],
118
- description: "Chop-off a prefix from uploaded files. Strips the given prefix from all \
119
- sources references inside the upload sourcemaps (paths used within the sourcemap \
120
- content, to map minified code to it's original source). Only sources that start \
121
- with the given prefix will be stripped. This will not modify the uploaded sources \
122
- paths",
123
- optional: true),
124
- FastlaneCore::ConfigItem.new(key: :strip_common_prefix,
125
- conflicting_options: [:strip_prefix],
126
- description: "Automatically guess what the common prefix is and chop that one off",
127
- default_value: false,
128
- is_string: false,
129
- optional: true),
130
- FastlaneCore::ConfigItem.new(key: :url_prefix,
131
- description: "Sets a URL prefix in front of all files",
132
- optional: true),
133
- FastlaneCore::ConfigItem.new(key: :url_suffix,
134
- description: "Sets a URL suffix to append to all filenames",
135
- optional: true),
136
- FastlaneCore::ConfigItem.new(key: :note,
137
- description: "Adds an optional note to the uploaded artifact bundle",
138
- optional: true),
139
- FastlaneCore::ConfigItem.new(key: :validate,
140
- description: "Enable basic sourcemap validation",
141
- is_string: false,
142
- optional: true),
143
- FastlaneCore::ConfigItem.new(key: :decompress,
144
- description: "Enable files gzip decompression prior to upload",
145
- is_string: false,
146
- optional: true),
147
- FastlaneCore::ConfigItem.new(key: :wait,
148
- description: "Wait for the server to fully process uploaded files",
149
- is_string: false,
150
- optional: true),
151
- FastlaneCore::ConfigItem.new(key: :wait_for,
152
- description: "Wait for the server to fully process uploaded files, but at most \
153
- for the given number of seconds",
154
- type: Integer,
155
- optional: true),
156
- FastlaneCore::ConfigItem.new(key: :no_sourcemap_reference,
157
- description: "Disable emitting of automatic sourcemap references. By default the \
158
- tool will store a 'Sourcemap' header with minified files so that sourcemaps \
159
- are located automatically if the tool can detect a link. If this causes issues \
160
- it can be disabled",
161
- is_string: false,
162
- optional: true),
163
- FastlaneCore::ConfigItem.new(key: :debug_id_reference,
164
- description: "Enable emitting of automatic debug id references. By default Debug ID \
165
- reference has to be present both in the source and the related sourcemap. But in \
166
- cases of binary bundles, the tool can't verify presence of the Debug ID. This flag \
167
- allows use of Debug ID from the linked sourcemap",
168
- is_string: false,
169
- optional: true),
170
- FastlaneCore::ConfigItem.new(key: :bundle,
171
- description: "Path to the application bundle (indexed, file, or regular)",
172
- optional: true),
173
- FastlaneCore::ConfigItem.new(key: :bundle_sourcemap,
174
- description: "Path to the bundle sourcemap",
175
- optional: true),
176
- FastlaneCore::ConfigItem.new(key: :ext,
177
- description: "Set the file extensions that are considered for upload. This overrides \
178
- the default extensions. To add an extension, all default extensions must be repeated. \
179
- Specify once per extension. Defaults to: js, cjs, mjs, map, jsbundle, bundle",
180
- type: Array,
181
- optional: true),
182
- FastlaneCore::ConfigItem.new(key: :strict,
183
- description: "Fail with a non-zero exit code if the specified source map file cannot be uploaded",
184
- is_string: false,
185
- optional: true),
186
- FastlaneCore::ConfigItem.new(key: :ignore,
187
- description: "Ignores all files and folders matching the given glob or array of globs",
188
- is_string: false,
189
- optional: true),
190
- FastlaneCore::ConfigItem.new(key: :ignore_file,
191
- description: "Ignore all files and folders specified in the given ignore file, e.g. .gitignore",
192
- optional: true)
193
- ]
194
- end
195
-
196
- def self.return_value
197
- nil
198
- end
199
-
200
- def self.authors
201
- ["wschurman"]
202
- end
203
-
204
- def self.is_supported?(platform)
205
- true
206
- end
207
- end
208
- end
209
- end
@@ -1,100 +0,0 @@
1
- module Fastlane
2
- module Helper
3
- class SentryConfig
4
- def self.common_cli_config_items
5
- [
6
- FastlaneCore::ConfigItem.new(key: :sentry_cli_path,
7
- env_name: "SENTRY_CLI_PATH",
8
- description: "Path to your sentry-cli. Defaults to `which sentry-cli`",
9
- optional: true,
10
- verify_block: proc do |value|
11
- UI.user_error! "'#{value}' is not executable" unless FastlaneCore::Helper.executable?(value)
12
- end)
13
- ]
14
- end
15
-
16
- def self.common_api_config_items
17
- [
18
- FastlaneCore::ConfigItem.new(key: :url,
19
- env_name: "SENTRY_URL",
20
- description: "Url for Sentry",
21
- is_string: true,
22
- optional: true),
23
- FastlaneCore::ConfigItem.new(key: :auth_token,
24
- env_name: "SENTRY_AUTH_TOKEN",
25
- description: "Authentication token for Sentry",
26
- optional: true),
27
- FastlaneCore::ConfigItem.new(key: :org_slug,
28
- env_name: "SENTRY_ORG_SLUG",
29
- description: "Organization slug for Sentry project",
30
- optional: true),
31
- FastlaneCore::ConfigItem.new(key: :project_slug,
32
- env_name: "SENTRY_PROJECT_SLUG",
33
- description: "Project slug for Sentry",
34
- optional: true),
35
- FastlaneCore::ConfigItem.new(key: :log_level,
36
- env_name: "SENTRY_LOG_LEVEL",
37
- description: "Configures the log level used by sentry-cli",
38
- optional: true,
39
- verify_block: proc do |value|
40
- UI.user_error! "Invalid log level '#{value}'" unless ['trace', 'debug', 'info', 'warn', 'error'].include? value.downcase
41
- end)
42
- ] + self.common_cli_config_items
43
- end
44
-
45
- def self.parse_api_params(params)
46
- require 'shellwords'
47
-
48
- url = params[:url]
49
- auth_token = params[:auth_token]
50
- org = params[:org_slug]
51
- project = params[:project_slug]
52
- log_level = params[:log_level]
53
-
54
- has_org = !org.to_s.empty?
55
- has_project = !project.to_s.empty?
56
- has_auth_token = !auth_token.to_s.empty?
57
-
58
- ENV['SENTRY_URL'] = url unless url.to_s.empty?
59
-
60
- if log_level.to_s.empty?
61
- ENV['SENTRY_LOG_LEVEL'] = 'debug' if FastlaneCore::Globals.verbose?
62
- else
63
- ENV['SENTRY_LOG_LEVEL'] = log_level
64
- end
65
-
66
- # Fallback to .sentryclirc if possible when no auth token is provided
67
- if !has_auth_token && fallback_sentry_cli_auth(params)
68
- UI.important("No auth config provided, will fallback to .sentryclirc")
69
- else
70
- # Will fail if no authentication token is provided
71
- unless has_auth_token
72
- UI.user_error!("No authentication token found for SentryAction given, pass using `auth_token: 'token'`")
73
- end
74
- ENV['SENTRY_AUTH_TOKEN'] = auth_token unless auth_token.to_s.empty?
75
- end
76
-
77
- if has_org && has_project
78
- ENV['SENTRY_ORG'] = Shellwords.escape(org) unless org.to_s.empty?
79
- ENV['SENTRY_PROJECT'] = Shellwords.escape(project) unless project.to_s.empty?
80
- elsif !has_org
81
- UI.important("Missing 'org_slug' parameter. Provide both 'org_slug' and 'project_slug'. Falling back to .sentryclirc")
82
- elsif !has_project
83
- UI.important("Missing 'project_slug' parameter. Provide both 'org_slug' and 'project_slug'. Falling back to .sentryclirc")
84
- end
85
- end
86
-
87
- def self.fallback_sentry_cli_auth(params)
88
- sentry_cli_result = JSON.parse(SentryHelper.call_sentry_cli(
89
- params,
90
- [
91
- "info",
92
- "--config-status-json"
93
- ]
94
- ))
95
- return (sentry_cli_result["auth"]["successful"] &&
96
- !sentry_cli_result["auth"]["type"].nil?)
97
- end
98
- end
99
- end
100
- end