forked from Universal-Team/Relaunch
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-pipelines.yml
72 lines (66 loc) · 2.44 KB
/
azure-pipelines.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
trigger:
branches:
include:
- master
- patch-1
name: $[format('{0:yyyyMMdd\-HHmmss}', pipeline.startTime)]
pool:
vmImage: 'Ubuntu-16.04'
variables:
CURRENT_DATE: $[format('{0:yyyyMMdd\-HHmmss}', pipeline.startTime)]
REPOSITORY_NAME: $(Build.Repository.Name)
COMMIT_TAG: $(git log --format=%h -1)
steps:
- script: |
curl -L https://github.com/devkitPro/pacman/releases/download/devkitpro-pacman-1.0.1/devkitpro-pacman.deb -o pacman.deb
sudo apt update
sudo apt install p7zip-full haveged
sudo dpkg -i pacman.deb
sudo dkp-pacman -Sy
sudo dkp-pacman -S nds-dev --noconfirm
displayName: 'Setup environment'
- script: |
echo $(TRAVIS_COMMIT)
echo $(COMMIT_TAG)
echo $(BUILD_SOURCEVERSION)
displayName: 'Echo Variables'
- script: |
export DEVKITPRO="/opt/devkitpro"
export DEVKITARM="/opt/devkitpro/devkitARM"
chmod +x make_cia
make
export COMMIT_TAG="$(git log --format=%h -1)"
export COMMIT_MESSAGE="$(git log --pretty=format:"%an - %s" -1)"
mkdir Relaunch/
mkdir Relaunch/Flashcart/
mkdir Relaunch/3DS/
mkdir Relaunch/DSi/
mkdir Relaunch/DSi/_nds/
mkdir Relaunch/3DS/_nds/
mkdir Relaunch/Flashcart/_nds/
mkdir Relaunch/DSi/_nds/Relaunch/
mkdir Relaunch/3DS/_nds/Relaunch/
mkdir Relaunch/Flashcart/_nds/Relaunch/
mv './menu_Flashcart.bin' 'Relaunch/Flashcart/_nds/Relaunch/menu.bin'
mv './Relaunch_Flashcart.nds' 'Relaunch/Flashcart/Relaunch.nds'
mv './menu_3DS.bin' 'Relaunch/3DS/_nds/Relaunch/menu.bin'
mv './Relaunch_3DS.cia' 'Relaunch/3DS/Relaunch.cia'
mv './menu_DSi.bin' 'Relaunch/DSi/_nds/Relaunch/menu.bin'
mv './Relaunch_DSi.nds' 'Relaunch/DSi/Relaunch.nds'
7z a Relaunch.7z Relaunch/
ls
displayName: 'Build Relaunch'
- script: |
echo '##vso[task.setvariable variable=COMMIT_TAG]'$(git log --format=%h -1)
echo '##vso[task.setvariable variable=COMMIT_MESSAGE]'$(git log --pretty=format:"%an - %s" -1)
git config --global user.email "flamekat54@aol.com"
git config --global user.name "TWLBot"
git clone https://$GITHUB_TOKEN@github.com/TWLBot/overflow-builds.git
cd overflow-builds/
cp ../Relaunch.7z Relaunch.7z
git stage .
git commit -m "Relaunch | $(COMMIT_TAG)"
git push origin master
git tag v$CURRENT_DATE
echo '##vso[task.setvariable variable=TWLBOT_COMMIT]'$(git log -1 --format="%H")
displayName: "Commit to TWLBot/overflow-builds"