forked from jr-robotics/ROS.NET
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
74 lines (66 loc) · 2.29 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
stages:
- build
- generate
- publish
- deploy
build:
image: mcr.microsoft.com/dotnet/core/sdk:2.1
stage: build
script:
- dotnet build -c Release
artifacts:
paths:
- 'Uml.Robotics.Ros/bin/Release'
- 'Uml.Robotics.Ros.MessageBase/bin/Release'
- 'Uml.Robotics.Ros.Transforms/bin/Release'
- 'Uml.Robotics.XmlRpc/bin/Release'
- 'YAMLParser/bin/Release'
tags:
- docker-executor
# Create a versioned NuGet package
# This task is only executed for the branches develop and master as well as version tags
nuget-pack:
image: mcr.microsoft.com/dotnet/core/sdk:2.1
stage: publish
script:
- 'dotnet pack Uml.Robotics.Ros -c Release -o ../nuget/'
- 'dotnet pack Uml.Robotics.Ros.MessageBase -c Release -o ../nuget/'
- 'dotnet pack Uml.Robotics.Ros.Transforms -c Release -o ../nuget/'
- 'dotnet pack Uml.Robotics.XmlRpc -c Release -o ../nuget/'
- 'dotnet pack YAMLParser -c Release -o ../nuget/'
artifacts:
paths:
- 'nuget'
- 'Uml.Robotics.Ros/bin/Release/'
- 'Uml.Robotics.Ros.MessageBase/bin/Release/'
- 'Uml.Robotics.Ros.Transforms/bin/Release/'
- 'Uml.Robotics.XmlRpc/bin/Release/'
- 'YAMLParser/bin/Release/'
tags:
- docker-executor
# Deploy to JR BaGet server
# This is done for all pushes of version tags (v*) automatically
# Pushes to the master branch and web pipeline triggers must be deployed manually
.baget_base: &baget_base
image: mcr.microsoft.com/dotnet/core/sdk:2.1
stage: deploy
dependencies:
- nuget-pack
variables:
GIT_STRATEGY: none
environment:
name: JR BaGet
url: https://robotics-baget.joanneum.at/
script:
- 'cd nuget'
# MESSAGE PACKAGE COMMENTED OUT SINCE I DO NOT KNOW IF THIS VERSION IS THE LATEST.
# - 'dotnet nuget push Uml.Robotics.Ros.Messages*.nupkg -s $JR_BAGET_URL -k $JR_BAGET_API_KEY'
- 'dotnet nuget push Uml.Robotics.Ros.MessageBase*.nupkg -s $JR_BAGET_URL -k $JR_BAGET_API_KEY'
- 'dotnet nuget push Uml.Robotics.Ros.Transforms*.nupkg -s $JR_BAGET_URL -k $JR_BAGET_API_KEY'
- 'dotnet nuget push Uml.Robotics.Ros*.nupkg -s $JR_BAGET_URL -k $JR_BAGET_API_KEY'
- 'dotnet nuget push Uml.Robotics.XmlRpc*.nupkg -s $JR_BAGET_URL -k $JR_BAGET_API_KEY'
tags:
- docker-executor
baget:man:
<<: *baget_base
when: manual