Skip to content

wujood/gbdk-2020-github-builder

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GBDK GitHub Action Builder

Example Workflow

This action builds gbdk-2020 projects with gcc.

Inputs

subdirectory

The subfolder where the sources are located. Default is "./".

output-name

Rename the output file. The name should no contain special characters. Default is game.

source

Specifies the source name relative to the subdirectory. Default is main.c

Example usage

name: Example Workflow
on: [push]

jobs:
  build:
    runs-on: ubuntu-latest
    name: Build gbdk project
    steps:
    - name: Checkout project
    - uses: actions/checkout@v2
    - name: Build
      uses: wujood/gbdk-2020-github-builder@1.0.8
      with:
        subdirectory: ./test-sources # Define the source folder. Default is ./
        output-name: your-game # Rename the output file. Default is game
        source: main.c # Main source file of your project. Deafult is main.c

Upload result

name: Example Release
on:  
  release:
    types: 
      - created # This triggers once you create a release from github, not from tagging a commit
jobs:
  test:
    runs-on: ubuntu-latest
    name: Build gbdk project
    steps:
    - name: Checkout project
      uses: actions/checkout@v2
    - name: Build
      uses: wujood/gbdk-2020-github-builder@1.0.8
      with:
        subdirectory: ./test-sources
    - name: Upload binary to release
      uses: svenstaro/upload-release-action@v2
      with:
        repo_token: ${{ secrets.GITHUB_TOKEN }}
        file: ./test-sources/game.gb # Result file from build is called game.gb by default. Rename it with the output-name parameter.
        asset_name: ROM # Rename this to what ever you want
        tag: ${{ github.ref }}