mirror of
https://github.com/edg-l/edlang.git
synced 2024-09-07 19:35:16 +00:00
ci
This commit is contained in:
parent
acbc80ac80
commit
4d73b76b73
1
.github/FUNDING.yml
vendored
1
.github/FUNDING.yml
vendored
|
@ -1,3 +1,4 @@
|
|||
# These are supported funding model platforms
|
||||
|
||||
github: [edg-l]
|
||||
liberapay: edgl
|
||||
|
|
73
.github/workflows/ci.yml
vendored
Normal file
73
.github/workflows/ci.yml
vendored
Normal file
|
@ -0,0 +1,73 @@
|
|||
name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
merge_group:
|
||||
types: [checks_requested]
|
||||
|
||||
jobs:
|
||||
check:
|
||||
name: clippy
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
LLVM_SYS_170_PREFIX: /usr/lib/llvm-17/
|
||||
TABLEGEN_170_PREFIX: /usr/lib/llvm-17/
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: dtolnay/rust-toolchain@1.75.0
|
||||
with:
|
||||
components: rustfmt, clippy
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
- name: add llvm deb repository
|
||||
uses: myci-actions/add-deb-repo@10
|
||||
with:
|
||||
repo: deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
|
||||
repo-name: llvm-repo
|
||||
keys-asc: https://apt.llvm.org/llvm-snapshot.gpg.key
|
||||
- name: Install LLVM
|
||||
run: sudo apt-get install llvm-17 llvm-17-dev llvm-17-runtime clang-17 clang-tools-17 lld-17 libpolly-17-dev
|
||||
- name: Clippy
|
||||
run: make check
|
||||
|
||||
fmt:
|
||||
name: rustfmt
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: dtolnay/rust-toolchain@1.75.0
|
||||
with:
|
||||
components: rustfmt
|
||||
- run: cargo fmt --all -- --check
|
||||
|
||||
test:
|
||||
name: test (linux, amd64)
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
LLVM_SYS_170_PREFIX: /usr/lib/llvm-17/
|
||||
TABLEGEN_170_PREFIX: /usr/lib/llvm-17/
|
||||
RUST_LOG: debug
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: free HDD space
|
||||
run: |
|
||||
# deleting space
|
||||
sudo rm -rf /usr/share/dotnet/
|
||||
sudo rm -rf /usr/local/lib/android
|
||||
- name: Setup rust env
|
||||
uses: dtolnay/rust-toolchain@1.75.0
|
||||
- name: Retreive cached dependecies
|
||||
uses: Swatinem/rust-cache@v2
|
||||
- name: add llvm deb repository
|
||||
uses: myci-actions/add-deb-repo@10
|
||||
with:
|
||||
repo: deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
|
||||
repo-name: llvm-repo
|
||||
keys-asc: https://apt.llvm.org/llvm-snapshot.gpg.key
|
||||
- name: Install LLVM
|
||||
run: sudo apt-get install llvm-17 llvm-17-dev llvm-17-runtime clang-17 clang-tools-17 lld-17 libpolly-17-dev
|
||||
- name: Install Link deps
|
||||
run: sudo apt-get install libc-dev build-essential
|
||||
- name: test
|
||||
run: cargo test
|
42
.github/workflows/release.yml
vendored
Normal file
42
.github/workflows/release.yml
vendored
Normal file
|
@ -0,0 +1,42 @@
|
|||
name: Main
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*.*.*"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
- name: free HDD space
|
||||
run: |
|
||||
# deleting space
|
||||
sudo rm -rf /usr/share/dotnet/
|
||||
sudo rm -rf /usr/local/lib/android
|
||||
- name: Setup rust env
|
||||
uses: dtolnay/rust-toolchain@1.75.0
|
||||
- name: Retreive cached dependecies
|
||||
uses: Swatinem/rust-cache@v2
|
||||
- name: add llvm deb repository
|
||||
uses: myci-actions/add-deb-repo@10
|
||||
with:
|
||||
repo: deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
|
||||
repo-name: llvm-repo
|
||||
keys-asc: https://apt.llvm.org/llvm-snapshot.gpg.key
|
||||
- name: Install LLVM
|
||||
run: sudo apt-get install llvm-17 llvm-17-dev llvm-17-runtime clang-17 clang-tools-17 lld-17 libpolly-17-dev
|
||||
- name: Install Link deps
|
||||
run: sudo apt-get install libc-dev build-essential
|
||||
- name: build release
|
||||
run: cargo build --release
|
||||
- name: Release
|
||||
uses: softprops/action-gh-release@v1
|
||||
with:
|
||||
generate_release_notes: true
|
||||
files: |
|
||||
README.md
|
||||
LICENSE
|
||||
target/release/edlang
|
Loading…
Reference in a new issue