diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..4aab7a2 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,21 @@ +name: C++ CI (Make) + +on: + push: + branches: [ "main", "ci/cd" ] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install toolchain + run: | + sudo apt-get update + sudo apt-get install -y build-essential + + - name: Build (Makefile) + run: | + make -j"$(nproc)" diff --git a/README.md b/README.md index 5069483..5053442 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,9 @@ This is a basic Docker container for a C++ program + +[![C++ CI (Make)](https://github.com/jgonzalez98-software/cpp-container/actions/workflows/build.yml/badge.svg)](https://github.com/jgonzalez98-software/cpp-container/actions/workflows/build.yml) + ## Getting Started Build the image from `Dockerfile` with the command: