-
Notifications
You must be signed in to change notification settings - Fork 10
/
.gitlab-ci.yml
40 lines (37 loc) · 1.11 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
stages:
- build
- publish_artifacts
build_linux:
stage: build
script:
- cargo build --release
- strip target/release/gbemulator
- mkdir gbemulator_linux_amd64
- cp target/release/gbemulator gbemulator_linux_amd64/gbemulator_linux_amd64
artifacts:
paths:
- gbemulator_linux_amd64
tags:
- linux
build_windows:
stage: build
script:
- cargo build --release
- mkdir gbemulator_windows_amd64
- cp target/release/gbemulator.exe gbemulator_windows_amd64
artifacts:
paths:
- gbemulator_windows_amd64
tags:
- windows
upload_to_share:
stage: publish_artifacts
script:
- zip -r gbemulator_linux_amd64.zip gbemulator_linux_amd64
- zip -r gbemulator_windows_amd64.zip gbemulator_windows_amd64
- mkdir ${CI_COMMIT_REF_NAME}__${CI_COMMIT_SHORT_SHA}
- mv gbemulator_linux_amd64.zip ${CI_COMMIT_REF_NAME}__${CI_COMMIT_SHORT_SHA}
- mv gbemulator_windows_amd64.zip ${CI_COMMIT_REF_NAME}__${CI_COMMIT_SHORT_SHA}
- rsync -e "ssh -p 2222" -r ${CI_COMMIT_REF_NAME}__${CI_COMMIT_SHORT_SHA} [email protected]:/www/builds/gbemulator/
tags:
- linux