From fc5b8ddfd8ee37bdb3d9504212ccf265d73e7004 Mon Sep 17 00:00:00 2001 From: Bensuperpc <bensuperpc@gmail.com> Date: Thu, 3 Jun 2021 17:43:30 +0200 Subject: [PATCH 1/5] Add Docker Add Docker Signed-off-by: Bensuperpc <bensuperpc@gmail.com> --- Makefile | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 98d9125..f31fb5c 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,16 @@ CC=sjasmplus CFLAGS= +OBJ=hello read_one_key -%: +DOCKER=docker + +default: docker + +all: $(OBJ) + +$(OBJ): $(CC) $@.asm --raw=$@.rom + +docker: + $(DOCKER) pull bensuperpc/sjasmplus:latest + $(DOCKER) run --rm -v "$(PWD)":/usr/src/myapp -w /usr/src/myapp bensuperpc/sjasmplus:latest make all \ No newline at end of file From 1e4f42b272df6fdc5a85df996c18d20c8bbca27d Mon Sep 17 00:00:00 2001 From: Bensuperpc <bensuperpc@gmail.com> Date: Thu, 3 Jun 2021 17:49:54 +0200 Subject: [PATCH 2/5] Add github CI Add github CI Signed-off-by: Bensuperpc <bensuperpc@gmail.com> --- .github/FUNDING.yml | 1 + .github/dependabot.yml | 9 +++++++++ .github/workflows/main.yml | 29 +++++++++++++++++++++++++++++ 3 files changed, 39 insertions(+) create mode 100644 .github/FUNDING.yml create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/main.yml diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000..50eb553 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1 @@ +github: rick-gnous diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..fe89e52 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,9 @@ +# Set update schedule for GitHub Actions + +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + schedule: + # Check for updates to GitHub Actions every weekday + interval: "daily" diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..d9b1426 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,29 @@ +name: Test-MSX + +on: + push: + branches: + - 'main' + - 'master' + - 'dev' + paths-ignore: + - '**/README.md' + pull_request: + branches: + - '*' + workflow_dispatch: + +jobs: + image: + name: Test-MSX + runs-on: ubuntu-20.04 + steps: + - name: "📥 Checkout Code" + uses: actions/checkout@v2.3.4 + with: + submodules: 'recursive' + fetch-depth: 0 + - name: "🛠️ Build" + run: make docker + - name: "🧹 Clean" + run: make clean From a6a5d31e17ef0a6e330f1f982faf65df76f6b1f1 Mon Sep 17 00:00:00 2001 From: Bensuperpc <bensuperpc@gmail.com> Date: Thu, 3 Jun 2021 17:54:31 +0200 Subject: [PATCH 3/5] Remove clean rule in github CI Remove clean rule in github CI Signed-off-by: Bensuperpc <bensuperpc@gmail.com> --- .github/workflows/main.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d9b1426..35c2bfd 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -25,5 +25,3 @@ jobs: fetch-depth: 0 - name: "🛠️ Build" run: make docker - - name: "🧹 Clean" - run: make clean From 0f4cd06e203419a153024189e1fd30d34aadc3e6 Mon Sep 17 00:00:00 2001 From: Bensuperpc <bensuperpc@gmail.com> Date: Thu, 3 Jun 2021 19:11:48 +0200 Subject: [PATCH 4/5] Improve makefile Improve makefile Signed-off-by: Bensuperpc <bensuperpc@gmail.com> --- Makefile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index f31fb5c..8bc8ebc 100644 --- a/Makefile +++ b/Makefile @@ -1,10 +1,9 @@ CC=sjasmplus -CFLAGS= -OBJ=hello read_one_key - DOCKER=docker -default: docker +CFLAGS= +SRCS = $(wildcard *.asm) +OBJ = $(patsubst %.asm,%,$(SRCS)) all: $(OBJ) From 0c43aaf858fde8f220fc7a1220b740ac5c59a201 Mon Sep 17 00:00:00 2001 From: rick <rick@gnous.eu> Date: Thu, 3 Jun 2021 19:39:25 +0200 Subject: [PATCH 5/5] =?UTF-8?q?update:=20information=20commande=20make=20d?= =?UTF-8?q?=C3=A9faut?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e9b649f..91ce7b7 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,6 @@ Le compilateur [SJASMplus](https://github.com/z00m128/sjasmplus) est utilisé af sjasmplus hello.asm --raw=hello.rom ``` -Il est aussi possible d’utiliser le Makefile avec la commande `make <nom programme>`; pour le helloworld par exemple : `make hello`. +Il est aussi possible d’utiliser le Makefile avec la commande `make <nom programme>`; pour le helloworld par exemple : `make hello`. La commande `make` compilera tous les fichiers .asm. Je m'appuie sur [les tutos de Chibiakumas](https://www.chibiakumas.com/z80/msx.php) pour l’écriture des différents programmes.