Add Forgejo CI workflow for botlib - Compile Rust library
Some checks failed
GBCI / build (push) Failing after 4m20s
Some checks failed
GBCI / build (push) Failing after 4m20s
This commit is contained in:
parent
f9582d3c7b
commit
3303ae4be0
1 changed files with 41 additions and 0 deletions
41
.forgejo/workflows/botlib.yaml
Normal file
41
.forgejo/workflows/botlib.yaml
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
name: GBCI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["main"]
|
||||
pull_request:
|
||||
branches: ["main"]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: gbo
|
||||
|
||||
steps:
|
||||
- name: Disable SSL verification (temporary)
|
||||
run: git config --global http.sslVerify false
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install Rust
|
||||
uses: msrd0/rust-toolchain@v1
|
||||
with:
|
||||
toolchain: stable
|
||||
|
||||
- name: Build library (default features)
|
||||
run: cargo build --locked
|
||||
|
||||
- name: Build library (full features)
|
||||
run: cargo build --locked --features full
|
||||
|
||||
- name: Run tests
|
||||
run: cargo test --locked --features full
|
||||
|
||||
- name: Build release
|
||||
run: cargo build --locked --release --features full
|
||||
|
||||
- name: Deploy library
|
||||
run: |
|
||||
sudo mkdir -p /opt/gbo/lib/botlib
|
||||
sudo cp ./target/release/libbotlib.rlib /opt/gbo/lib/botlib/ || true
|
||||
sudo cp ./target/release/libbotlib.a /opt/gbo/lib/botlib/ || true
|
||||
sudo cp ./target/release/libbotlib.so /opt/gbo/lib/botlib/ || true
|
||||
Loading…
Add table
Reference in a new issue