Hello,
I have a problem with the Ci/Cd in GitLab. It always output the following message:
Running with gitlab-runner 11.5.1 (7f00c780)
on <Runner Name> ca5ecb8a
Using Shell executor...
Running on <Runner Name>...
Fetching changes...
HEAD is now at 313c12b Edited .gitlab-ci.yml
From <URL to submodule>
313c12b..17c0a3e master -> origin/master
Checking out 17c0a3e8 as master...
Updating/initializing submodules recursively...
Synchronizing submodule url for 'AppSettingsHelper'
Synchronizing submodule url for 'BackupEmailParser'
Synchronizing submodule url for 'ConsoleInputManager'
Synchronizing submodule url for 'ConsoleOutputManager'
Synchronizing submodule url for 'DatabaseManager'
Synchronizing submodule url for 'ImapDownloader'
Entering 'AppSettingsHelper'
Entering 'BackupEmailParser'
Entering 'ConsoleInputManager'
Entering 'ConsoleOutputManager'
Entering 'DatabaseManager'
Entering 'ImapDownloader'
Entering 'AppSettingsHelper'
Entering 'BackupEmailParser'
HEAD is now at bc8ce28 Edited Summarys, Updated ConsoleOutputManager
Entering 'ConsoleInputManager'
HEAD is now at 27d126f Updated ConsoleOutputManager
Entering 'ConsoleOutputManager'
HEAD is now at 5339188 Remvoed spelling mistakes
Entering 'DatabaseManager'
HEAD is now at bafdd77 Updated ConsoleOutputManager
Entering 'ImapDownloader'
HEAD is now at 7266a10 Updated ConsoleOutputManager and DatabaseManager
fatal: Needed a single revision
Unable to find current revision in submodule path 'AppSettingsHelper'
ERROR: Job failed: exit status 1
I used the same .gitlab-ci.yml file as in all projects. The code of my .gitlab-ci.yml is the following:
variables:
GIT_SUBMODULE_STRATEGY: recursive
PROJECT_NAME: 'BackupEmailReceiver'
stages:
- build
DebugBuild:
only:
- pushes
- branches
tags:
- csharp
stage: build
script:
- nuget restore
- C:\'Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin'\MSBuild.exe /consoleloggerparameters:ErrorsOnly /maxcpucount /nologo /property:Configuration=Debug $BUILD_PROJECT.sln
artifacts:
paths:
- '.\$PROJECT_NAME\bin\Debug'
name: "$PROJECT_NAME-Debug"
expire_in: 4 weeks
ReleaseBuild:
only:
- tags
tags:
- csharp
stage: build
script:
- nuget restore
- echo "$CI_COMMIT_REF_NAME"
- C:\'Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin'\MSBuild.exe /maxcpucount /nologo /property:Configuration=Release $BUILD_PROJECT.sln
artifacts:
paths:
- '.\$PROJECT_NAME\bin\Release'
name: "$PROJECT_NAME-Release"