From e8e86dd8fd08420d04a4c749679e9ae5d1e0c705 Mon Sep 17 00:00:00 2001 From: streetcodeUa Date: Thu, 12 Sep 2024 20:56:02 +0200 Subject: [PATCH 1/2] Update Jenkinsfile --- Jenkinsfile | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index da9872984..14d5ead73 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -258,10 +258,8 @@ pipeline { steps { script { - checkout scmGit( - branches: [[name: 'master']], - userRemoteConfigs: [[credentialsId: 'StreetcodeGithubCreds', url: 'git@github.com:ita-social-projects/Streetcode.git']]) - + + git branch: 'master', credentialsId: 'test_git_user', url: 'git@github.com:ita-social-projects/Streetcode.git' sh 'echo ${BRANCH_NAME}' sh "git checkout master" sh 'echo ${BRANCH_NAME}' @@ -271,11 +269,7 @@ pipeline { } } post { - success { - checkout scmGit( - branches: [[name: 'master']], - userRemoteConfigs: [[credentialsId: 'StreetcodeGithubCreds', url: 'git@github.com:ita-social-projects/Streetcode.git']]) - + sh 'gh auth status' sh "gh release create v${vers} --generate-notes --draft" } From df968aa984462a5cb5e510dfe79478dfde82a642 Mon Sep 17 00:00:00 2001 From: streetcodeUa Date: Thu, 12 Sep 2024 20:58:29 +0200 Subject: [PATCH 2/2] Update Jenkinsfile --- Jenkinsfile | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index da9872984..48833c98c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -258,10 +258,7 @@ pipeline { steps { script { - checkout scmGit( - branches: [[name: 'master']], - userRemoteConfigs: [[credentialsId: 'StreetcodeGithubCreds', url: 'git@github.com:ita-social-projects/Streetcode.git']]) - + git branch: 'master', credentialsId: 'test_git_user', url: 'git@github.com:ita-social-projects/Streetcode.git' sh 'echo ${BRANCH_NAME}' sh "git checkout master" sh 'echo ${BRANCH_NAME}' @@ -272,10 +269,7 @@ pipeline { } post { success { - checkout scmGit( - branches: [[name: 'master']], - userRemoteConfigs: [[credentialsId: 'StreetcodeGithubCreds', url: 'git@github.com:ita-social-projects/Streetcode.git']]) - + sh 'gh auth status' sh "gh release create v${vers} --generate-notes --draft" }