Skip to content

Commit

Permalink
Merge pull request #1 from JuliaConstraints/bl/gh-ci
Browse files Browse the repository at this point in the history
Add Github ci
  • Loading branch information
Azzaare authored Aug 19, 2024
2 parents cf77481 + 13e338a commit 7954bcc
Show file tree
Hide file tree
Showing 3 changed files with 141 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/CompatHelper.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
on:
schedule:
- cron: 0 0 * * *
workflow_dispatch:
permissions:
contents: write
pull-requests: write
jobs:
CompatHelper:
runs-on: ubuntu-latest
steps:
- name: Check if Julia is already available in the PATH
id: julia_in_path
run: which julia
continue-on-error: true
- name: Install Julia, but only if it is not already available in the PATH
uses: julia-actions/setup-julia@v2
with:
version: "1"
arch: ${{ runner.arch }}
if: steps.julia_in_path.outcome != 'success'
- name: "Add the General registry via Git"
run: |
import Pkg
ENV["JULIA_PKG_SERVER"] = ""
Pkg.Registry.add("General")
shell: julia --color=yes {0}
- name: "Install CompatHelper"
run: |
import Pkg
name = "CompatHelper"
uuid = "aa819f21-2bde-4658-8897-bab36330d9b7"
version = "3"
Pkg.add(; name, uuid, version)
shell: julia --color=yes {0}
- name: "Run CompatHelper"
run: |
import CompatHelper
CompatHelper.main()
shell: julia --color=yes {0}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
67 changes: 67 additions & 0 deletions .github/workflows/GitHubCI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: CI
on:
pull_request:
branches:
- master
- dev
paths-ignore:
- "docs/**"
push:
branches:
- master
paths-ignore:
- "docs/**"
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- "lts"
- "1"
- "pre"
os:
- ubuntu-latest
arch:
- x64
# - x86 # FIXME get ERROR: LoadError: InitError: could not load library "/usr/lib/jvm/temurin-11-jdk-amd64/lib/server/libjvm.so"
# /usr/lib/jvm/temurin-11-jdk-amd64/lib/server/libjvm.so: wrong ELF class: ELFCLASS64
include:
# test macOS and Windows with latest Julia only
# - os: macOS-latest # FIXME ERROR: LoadError: InitError: could not load library "/Users/runner/hostedtoolcache/Java_Temurin-Hotspot_jdk/21.0.4-7.0/arm64/Contents/Home/lib/server/libjvm.dylib"
# arch: x64
# version: 1
- os: windows-latest
arch: x64
version: 1
# - os: windows-latest # FIXME get on ci:
# arch: x86 # ERROR: LoadError: InitError: could not load library "C:\hostedtoolcache\windows\Java_Temurin-Hotspot_jdk\8.0.422-5\x64\jre\bin\server\jvm.dll"
# version: 1 # %1 is not a valid Win32 application.
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v4
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@v1
- uses: julia-actions/julia-runtest@v1
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v4
with:
file: lcov.info
- uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: lcov.info
31 changes: 31 additions & 0 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: TagBot
on:
issue_comment:
types:
- created
workflow_dispatch:
inputs:
lookback:
default: "3"
permissions:
actions: read
checks: read
contents: write
deployments: read
issues: read
discussions: read
packages: read
pages: read
pull-requests: read
repository-projects: read
security-events: read
statuses: read
jobs:
TagBot:
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
runs-on: ubuntu-latest
steps:
- uses: JuliaRegistries/TagBot@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
ssh: ${{ secrets.DOCUMENTER_KEY }}

0 comments on commit 7954bcc

Please sign in to comment.