68 lines
2.4 KiB
YAML
68 lines
2.4 KiB
YAML
name: Build StreetPass-Shop
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
branches-ignore: [translation]
|
|
paths-ignore:
|
|
- 'README.md'
|
|
pull_request:
|
|
branches: ["*"]
|
|
paths-ignore:
|
|
- 'README.md'
|
|
release:
|
|
types: [published]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
container: devkitpro/devkitarm
|
|
name: Build with Docker using devkitARM
|
|
outputs:
|
|
commit_tag: ${{ steps.build.outputs.commit_tag }}
|
|
commit_hash: ${{ steps.build.outputs.commit_hash }}
|
|
author_name: ${{ steps.build.outputs.author_name }}
|
|
committer_name: ${{ steps.build.outputs.committer_name }}
|
|
commit_subject: ${{ steps.build.outputs.commit_subject }}
|
|
commit_message: ${{ steps.build.outputs.commit_message }}
|
|
steps:
|
|
- name: Checkout repo
|
|
uses: actions/checkout@v1
|
|
with:
|
|
submodules: recursive
|
|
- name: Setup environment
|
|
run: git config --global safe.directory '*'
|
|
- name: Install tools
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install p7zip-full -y
|
|
|
|
curl -L https://github.com/Steveice10/bannertool/releases/download/1.2.0/bannertool.zip -o bannertool.zip
|
|
sudo 7z e bannertool.zip linux-x86_64/bannertool
|
|
sudo chmod +x bannertool
|
|
mv bannertool /usr/local/bin
|
|
rm bannertool.zip
|
|
curl -L https://github.com/3DSGuy/Project_CTR/releases/download/makerom-v0.17/makerom-v0.17-ubuntu_x86_64.zip -o makerom-v0.17-ubuntu_x86_64.zip
|
|
sudo 7z e makerom-v0.17-ubuntu_x86_64.zip
|
|
sudo chmod +x makerom
|
|
mv makerom /usr/local/bin
|
|
rm makerom-v0.17-ubuntu_x86_64.zip
|
|
- name: Build
|
|
id: build
|
|
run: |
|
|
make
|
|
mkdir -p ~/artifacts
|
|
cp *.3dsx ~/artifacts
|
|
cp *.cia ~/artifacts
|
|
echo ::set-output name=commit_tag::$(git describe --abbrev=0 --tags)
|
|
echo ::set-output name=commit_hash::$(git log --format=%h -1)
|
|
|
|
# Webhook info
|
|
echo "::set-output name=author_name::$(git log -1 $GITHUB_SHA --pretty=%aN)"
|
|
echo "::set-output name=committer_name::$(git log -1 $GITHUB_SHA --pretty=%cN)"
|
|
echo "::set-output name=commit_subject::$(git log -1 $GITHUB_SHA --pretty=%s)"
|
|
echo "::set-output name=commit_message::$(git log -1 $GITHUB_SHA --pretty=%b)"
|
|
- name: Publish build to GH Actions
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
path: ~/artifacts/*
|
|
name: build
|