bump action deps - remove unmaintained rust thingy #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Upload Artifacts | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest] | |
feature: [lua54, lua53, lua52, lua51, luajit] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
- name: Build | |
run: cargo build --release --features ${{ matrix.feature }} | |
- name: Prepare artifact | |
run: | | |
if [ "${{ matrix.os }}" == "ubuntu-latest" ]; then | |
OS="linux" | |
EXT="so" | |
else | |
OS="macOS" | |
EXT="dylib" | |
fi | |
mkdir -p artifacts | |
cp target/release/libtiktoken_core.$EXT artifacts/tiktoken_core-$OS-${{ matrix.feature }}.$EXT | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: tiktoken_core-${{ matrix.os }}-${{ matrix.feature }} | |
path: artifacts/tiktoken_core-*.${{ matrix.os == 'ubuntu-latest' && 'so' || 'dylib' }} |