From f7b32e7f73d40e7e4486b2bd541a878d351839f5 Mon Sep 17 00:00:00 2001 From: ARCJ137442 <61109168+ARCJ137442@users.noreply.github.com> Date: Sun, 4 Feb 2024 13:13:06 +0800 Subject: [PATCH] =?UTF-8?q?ci:=20:construction=5Fworker:=20=E5=88=9D?= =?UTF-8?q?=E6=AD=A5=E6=96=B0=E5=A2=9EGitHub=20CI=EF=BC=8C=E5=AE=8C?= =?UTF-8?q?=E5=96=84Julia=E5=85=BC=E5=AE=B9=EF=BC=881.5+=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/ci.yml | 55 ++++++++++++++++++++++++++++++++++++++++ Project.toml | 3 +++ 2 files changed, 58 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..0ea6514 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,55 @@ +name: CI + +on: + - push + - pull_request + +env: + JULIA_NUM_THREADS: auto + +jobs: + test: + name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + version: + # Versions below 1.5 cause of compat@`include`: + - "1.5" + - "1.6" + - "1.7" + - "1.8" + - "1.9" + - "1" # Leave this line unchanged. '1' will automatically expand to the latest stable 1.x release of Julia. + - "nightly" + os: + - ubuntu-latest + - macOS-latest + - windows-latest + arch: + - x64 + steps: + - uses: actions/checkout@v2 + - uses: julia-actions/setup-julia@latest + with: + version: ${{ matrix.version }} + arch: ${{ matrix.arch }} + # - uses: actions/cache@v1 + # env: + # cache-name: cache-artifacts + # with: + # path: ~/.julia/artifacts + # key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} + # restore-keys: | + # ${{ runner.os }}-test-${{ env.cache-name }}- + # ${{ runner.os }}-test- + # ${{ runner.os }}- + - uses: julia-actions/julia-buildpkg@latest + - uses: julia-actions/julia-runtest@latest + # continue-on-error: ${{ matrix.version == 'nightly' }} + # - uses: julia-actions/julia-processcoverage@v1 + # - name: Upload datas to Codecov + # uses: codecov/codecov-action@v1 + # with: + # file: lcov.info diff --git a/Project.toml b/Project.toml index 229527f..67d1816 100644 --- a/Project.toml +++ b/Project.toml @@ -10,5 +10,8 @@ JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6" Dates = "ade2ca70-3891-5945-98fb-dc099432e06a" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" +[compat] +julia = "1.5" + [targets] test = ["Test", "Dates"]