summaryrefslogtreecommitdiff
path: root/scripts/api
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-10-14 21:09:20 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2022-10-14 21:09:20 +0000
commitdb2275b561bace34d90b901226d7f46d33e4cbd9 (patch)
tree7fde15815e18d0818b9be7ce61ddd90a13ea0f8c /scripts/api
parent3c6cad91a1a9d8732e8cb998f83d32dc19373b7b (diff)
downloadgitlab-ce-db2275b561bace34d90b901226d7f46d33e4cbd9.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'scripts/api')
-rwxr-xr-xscripts/api/cancel_pipeline.rb2
-rwxr-xr-xscripts/api/download_job_artifact.rb2
-rwxr-xr-xscripts/api/get_job_id.rb2
3 files changed, 3 insertions, 3 deletions
diff --git a/scripts/api/cancel_pipeline.rb b/scripts/api/cancel_pipeline.rb
index 2de50dcee80..2667cfb9733 100755
--- a/scripts/api/cancel_pipeline.rb
+++ b/scripts/api/cancel_pipeline.rb
@@ -25,7 +25,7 @@ class CancelPipeline
attr_reader :project, :pipeline_id, :client
end
-if $0 == __FILE__
+if $PROGRAM_NAME == __FILE__
options = API::DEFAULT_OPTIONS.dup
OptionParser.new do |opts|
diff --git a/scripts/api/download_job_artifact.rb b/scripts/api/download_job_artifact.rb
index 23202ad3912..394ad8f3a3d 100755
--- a/scripts/api/download_job_artifact.rb
+++ b/scripts/api/download_job_artifact.rb
@@ -60,7 +60,7 @@ class ArtifactFinder
end
end
-if $0 == __FILE__
+if $PROGRAM_NAME == __FILE__
options = API::DEFAULT_OPTIONS.dup
OptionParser.new do |opts|
diff --git a/scripts/api/get_job_id.rb b/scripts/api/get_job_id.rb
index 2ee769d58f4..12535106a4c 100755
--- a/scripts/api/get_job_id.rb
+++ b/scripts/api/get_job_id.rb
@@ -95,7 +95,7 @@ class JobFinder
end
end
-if $0 == __FILE__
+if $PROGRAM_NAME == __FILE__
options = JobFinder::DEFAULT_OPTIONS.dup
OptionParser.new do |opts|