diff --git a/lib/services/gitlab.js b/lib/services/gitlab.js index 0a9923eb..2fbd1c6b 100644 --- a/lib/services/gitlab.js +++ b/lib/services/gitlab.js @@ -8,13 +8,14 @@ module.exports = { configuration : function(){ console.log(' Gitlab CI Detected'); + var remote = process.env.CI_BUILD_REPO || process.env.CI_REPOSITORY_URL || ''; return { service : 'gitlab', build : process.env.CI_BUILD_ID, commit : process.env.CI_BUILD_REF, branch : process.env.CI_BUILD_REF_NAME, root : process.env.CI_PROJECT_DIR, - slug : process.env.CI_BUILD_REPO.split('/').slice(3, 5).join('/').replace('.git', '') + slug : remote.split('/').slice(3, 5).join('/').replace('.git', '') }; }