diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 000000000..774a77022 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,28 @@ +name: Build for Nintendo Switch + +on: + push: + branches: + - switch # You can change this to your main branch name + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout Code + uses: actions/checkout@v2 + + - name: Set up devkitPro + run: | + git clone https://github.com/devkitPro/pacman.git $HOME/pacman + cd $HOME/pacman + makepkg -si --noconfirm + sudo pacman -S --needed --noconfirm switch-sdl2 switch-libvorbis switch-minizip switch-zlib switch-glad switch-pkg-config switch-cmake + + - name: Build for Switch + run: | + mkdir build + cd build + $DEVKITPRO/portlibs/switch/bin/aarch64-none-elf-cmake .. + make -j$(nproc)