tweaking maturin install
This commit is contained in:
parent
37f4d8f84c
commit
29e120c9ee
@ -30,6 +30,88 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
command: test
|
command: test
|
||||||
|
|
||||||
|
buildPy:
|
||||||
|
name: Build Python
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: [ build ] # for ignoring bad builds
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4 # get source
|
||||||
|
with:
|
||||||
|
github-server-url: https://gitea.sheep-ghoul.ts.net
|
||||||
|
|
||||||
|
- name: Install Python 3
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: ${{ env.python-version }}
|
||||||
|
|
||||||
|
- name: Install Maturin
|
||||||
|
run: sudo apt update && sudo apt install -y python-maturin
|
||||||
|
|
||||||
|
- name: Build Python
|
||||||
|
working-directory: ./pyfinlib
|
||||||
|
run: maturin develop
|
||||||
|
|
||||||
|
buildWASM:
|
||||||
|
name: Build WASM
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: [ build ] # for ignoring bad builds
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
github-server-url: https://gitea.sheep-ghoul.ts.net
|
||||||
|
|
||||||
|
- name: Install Rust
|
||||||
|
uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
toolchain: stable
|
||||||
|
|
||||||
|
- name: Install wasm-pack
|
||||||
|
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
|
||||||
|
|
||||||
|
- name: Build Rust for WASM
|
||||||
|
working-directory: ./finlib-wasm
|
||||||
|
run: wasm-pack build
|
||||||
|
|
||||||
|
publishNPM:
|
||||||
|
name: Publish NPM
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: [ buildWASM ] # for ignoring bad builds
|
||||||
|
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
github-server-url: https://gitea.sheep-ghoul.ts.net
|
||||||
|
|
||||||
|
- name: Install Rust
|
||||||
|
uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
toolchain: stable
|
||||||
|
|
||||||
|
- name: Install wasm-pack
|
||||||
|
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
|
||||||
|
|
||||||
|
- name: Build Rust for WASM
|
||||||
|
working-directory: ./finlib-wasm
|
||||||
|
run: wasm-pack build --release
|
||||||
|
|
||||||
|
- name: Change Package Name
|
||||||
|
working-directory: ./finlib-wasm
|
||||||
|
run: ./rename-pkg.sh
|
||||||
|
|
||||||
|
- name: Install Node
|
||||||
|
uses: actions/setup-node@v2
|
||||||
|
with:
|
||||||
|
node-version: 22
|
||||||
|
registry-url: 'https://gitea.sheep-ghoul.ts.net/api/packages/sarsoo/npm/'
|
||||||
|
|
||||||
|
- name: Publish
|
||||||
|
working-directory: ./finlib-wasm/pkg
|
||||||
|
run: npm publish
|
||||||
|
env:
|
||||||
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||||
|
|
||||||
publishRustLib:
|
publishRustLib:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: Publish Rust Library
|
name: Publish Rust Library
|
||||||
@ -71,85 +153,3 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
command: publish
|
command: publish
|
||||||
args: --package finlib
|
args: --package finlib
|
||||||
|
|
||||||
buildWASM:
|
|
||||||
name: Build WASM
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
needs: [ build ] # for ignoring bad builds
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
github-server-url: https://gitea.sheep-ghoul.ts.net
|
|
||||||
|
|
||||||
- name: Install Rust
|
|
||||||
uses: actions-rs/toolchain@v1
|
|
||||||
with:
|
|
||||||
toolchain: stable
|
|
||||||
|
|
||||||
- name: Install wasm-pack
|
|
||||||
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
|
|
||||||
|
|
||||||
- name: Build Rust for WASM
|
|
||||||
working-directory: ./finlib-wasm
|
|
||||||
run: wasm-pack build
|
|
||||||
|
|
||||||
buildPy:
|
|
||||||
name: Build Python
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
needs: [ build ] # for ignoring bad builds
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4 # get source
|
|
||||||
with:
|
|
||||||
github-server-url: https://gitea.sheep-ghoul.ts.net
|
|
||||||
|
|
||||||
- name: Install Python 3
|
|
||||||
uses: actions/setup-python@v4
|
|
||||||
with:
|
|
||||||
python-version: ${{ env.python-version }}
|
|
||||||
|
|
||||||
- name: Install Maturin
|
|
||||||
run: pip3 install maturin
|
|
||||||
|
|
||||||
- name: Build Python
|
|
||||||
working-directory: ./pyfinlib
|
|
||||||
run: maturin develop
|
|
||||||
|
|
||||||
publishNPM:
|
|
||||||
name: Publish NPM
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
needs: [ buildWASM ] # for ignoring bad builds
|
|
||||||
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
github-server-url: https://gitea.sheep-ghoul.ts.net
|
|
||||||
|
|
||||||
- name: Install Rust
|
|
||||||
uses: actions-rs/toolchain@v1
|
|
||||||
with:
|
|
||||||
toolchain: stable
|
|
||||||
|
|
||||||
- name: Install wasm-pack
|
|
||||||
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
|
|
||||||
|
|
||||||
- name: Build Rust for WASM
|
|
||||||
working-directory: ./finlib-wasm
|
|
||||||
run: wasm-pack build --release
|
|
||||||
|
|
||||||
- name: Change Package Name
|
|
||||||
working-directory: ./finlib-wasm
|
|
||||||
run: ./rename-pkg.sh
|
|
||||||
|
|
||||||
- name: Install Node
|
|
||||||
uses: actions/setup-node@v2
|
|
||||||
with:
|
|
||||||
node-version: 22
|
|
||||||
registry-url: 'https://gitea.sheep-ghoul.ts.net/api/packages/sarsoo/npm/'
|
|
||||||
|
|
||||||
- name: Publish
|
|
||||||
working-directory: ./finlib-wasm/pkg
|
|
||||||
run: npm publish
|
|
||||||
env:
|
|
||||||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
Loading…
x
Reference in New Issue
Block a user