Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @rustaceans
64 changes: 64 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: CI

on:
pull_request:

jobs:
build-test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
env:
PYO3_PYTHON: python
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
cache-on-failure: true
- name: Install just
if: runner.os == 'Windows'
uses: taiki-e/install-action@v2
with:
tool: just
- name: Set OpenSSL env vars (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
$candidates = @("C:\Program Files\OpenSSL-Win64", "C:\Program Files\OpenSSL", "C:\OpenSSL-Win64")
$opensslDir = $candidates | Where-Object { Test-Path $_ } | Select-Object -First 1
if (-not $opensslDir) {
choco install openssl -y --no-progress
$opensslDir = "C:\Program Files\OpenSSL-Win64"
}
$libDir = if (Test-Path "$opensslDir\lib\VC\x64\MD") { "$opensslDir\lib\VC\x64\MD" } else { "$opensslDir\lib" }
"OPENSSL_DIR=$opensslDir" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
"OPENSSL_LIB_DIR=$libDir" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
"OPENSSL_INCLUDE_DIR=$opensslDir\include" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Install Linux dependencies
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y pkg-config nettle-dev
- name: Install macOS dependencies
if: runner.os == 'macOS'
run: brew install python@3.12 nettle pkg-config
- name: Set Python for PyO3 (macOS)
if: runner.os == 'macOS'
run: echo "PYO3_PYTHON=/opt/homebrew/opt/python@3.12/bin/python3.12" >> "$GITHUB_ENV"
- name: Build and test
if: runner.os != 'Windows'
run: cargo test --workspace
- name: Build and test (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: just windows-test
32 changes: 32 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Coverage

on:
pull_request:

jobs:
coverage:
runs-on: macos-latest
env:
PYO3_PYTHON: "/opt/homebrew/opt/python@3.12/bin/python3.12"
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Install Homebrew dependencies
run: brew install python@3.12 just llvm nettle pkg-config
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
cache-on-failure: true
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@v2
with:
tool: cargo-llvm-cov
- name: Generate coverage
run: just coverage
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
files: coverage/lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
29 changes: 29 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Publish

on:
push:
branches:
- main
workflow_dispatch:

jobs:
publish:
runs-on: ubuntu-latest
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Rust cache
uses: Swatinem/rust-cache@v2
- name: Publish crates
run: |
cargo publish -p agent_secrets
cargo publish -p shadi_sandbox
cargo publish -p shadi_memory
cargo publish -p agent_transport_slim
cargo publish -p shadi_py
cargo publish -p slim_mas
cargo publish -p shadictl
27 changes: 27 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Rust
/target/
**/*.rs.bk

# Python
.venv/
.venv-py312/
__pycache__/
**/*.py[cod]
.adk/

# MkDocs
/site/

# Coverage
/coverage/

# Local data
.tmp/
tmp/
*.db

# Editors
.vscode/

# OS
.DS_Store
Loading
Loading