stages: - build - test - docs - update-assembly-info - build-release - semantic-release - release - pre_release build: stage: build script: - PowerShell .\build.ps1 -Target Build -Configuration Debug variables: GIT_STRATEGY: clone except: variables: - $GITLAB_USER_ID == $GIT_BOT_USER_ID test: stage: test script: - PowerShell .\build.ps1 -Target LinterAndTest -Configuration Debug variables: GIT_STRATEGY: none dependencies: - build artifacts: reports: junit: "./Artifacts/TestResults.xml" paths: - "./Artifacts/*" except: variables: - $GITLAB_USER_ID == $GIT_BOT_USER_ID update-assembly-info: stage: update-assembly-info script: - PowerShell .\build.ps1 -Target UpdateAssemblyInfo variables: GIT_STRATEGY: none dependencies: - test only: - master except: variables: - $GITLAB_USER_ID == $GIT_BOT_USER_ID build-release: stage: build-release script: - PowerShell .\build.ps1 -Target Build -Configuration Release - PowerShell .\build.ps1 -Configuration Release -Target NugetPack variables: GIT_STRATEGY: none dependencies: - update-assembly-info only: - master except: variables: - $GITLAB_USER_ID == $GIT_BOT_USER_ID docs: stage: docs script: - .\publishDocs.ps1 $GITLAB_TOKEN variables: GIT_STRATEGY: none dependencies: - test only: - master except: variables: - $GITLAB_USER_ID == $GIT_BOT_USER_ID semantic-release: stage: semantic-release script: - PowerShell .\build.ps1 -Target SemanticRelease variables: GIT_STRATEGY: none dependencies: - test only: - master except: variables: - $GITLAB_USER_ID == $GIT_BOT_USER_ID release: before_script: stage: release script: - PowerShell .\build.ps1 -Target Build -Configuration Release - PowerShell .\build.ps1 -Configuration Release -Target NugetPack - PowerShell .\build.ps1 -Configuration Release -Target NugetPush --nugetApiKey="$NUGET_API_KEY" variables: GIT_STRATEGY: clone artifacts: paths: - "./Artifacts/*" only: - tags pre_release: stage: pre_release script: - PowerShell .\build.ps1 -Target Build -Configuration Release variables: GIT_STRATEGY: clone artifacts: paths: - "./Artifacts/*" when: manual except: - tags - master