Add VAD example for Dart API (#996)
This commit is contained in:
48
.github/workflows/flutter-macos.yaml
vendored
48
.github/workflows/flutter-macos.yaml
vendored
@@ -152,6 +152,8 @@ jobs:
|
||||
- name: Build flutter
|
||||
shell: bash
|
||||
run: |
|
||||
SHERPA_ONNX_VERSION=v$(grep "SHERPA_ONNX_VERSION" ./CMakeLists.txt | cut -d " " -f 2 | cut -d '"' -f 2)
|
||||
|
||||
d=$PWD
|
||||
|
||||
pushd sherpa-onnx/flutter
|
||||
@@ -166,7 +168,7 @@ jobs:
|
||||
|
||||
tree ./sherpa_onnx.app
|
||||
|
||||
app=flutter_sherpa_onnx_macos_${{ matrix.arch }}.app
|
||||
app=sherpa-onnx-osx-${{ matrix.arch }}-$SHERPA_ONNX_VERSION.app
|
||||
mv sherpa_onnx.app $app
|
||||
tar cjfv $app.tar.bz2 $app
|
||||
ls -lh
|
||||
@@ -178,13 +180,43 @@ jobs:
|
||||
|
||||
- uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: flutter-sherpa-onnx-app-macos-${{ matrix.arch }}
|
||||
name: sherpa-onnx-osx-${{ matrix.arch }}
|
||||
path: ./*.tar.bz2
|
||||
|
||||
- name: Release android libs
|
||||
if: (github.repository_owner == 'csukuangfj' || github.repository_owner == 'k2-fsa') && github.event_name == 'push' && contains(github.ref, 'refs/tags/')
|
||||
uses: svenstaro/upload-release-action@v2
|
||||
- name: Publish to huggingface
|
||||
env:
|
||||
HF_TOKEN: ${{ secrets.HF_TOKEN }}
|
||||
uses: nick-fields/retry@v3
|
||||
with:
|
||||
file_glob: true
|
||||
overwrite: true
|
||||
file: flutter*.tar.bz2
|
||||
max_attempts: 20
|
||||
timeout_seconds: 200
|
||||
shell: bash
|
||||
command: |
|
||||
git config --global user.email "csukuangfj@gmail.com"
|
||||
git config --global user.name "Fangjun Kuang"
|
||||
|
||||
rm -rf huggingface
|
||||
export GIT_LFS_SKIP_SMUDGE=1
|
||||
export GIT_CLONE_PROTECTION_ACTIVE=false
|
||||
|
||||
git clone https://huggingface.co/csukuangfj/sherpa-onnx-flutter huggingface
|
||||
cd huggingface
|
||||
git fetch
|
||||
git pull
|
||||
git merge -m "merge remote" --ff origin main
|
||||
mkdir -p flutter
|
||||
cp -v ../*.tar.bz2 ./flutter
|
||||
|
||||
git status
|
||||
git lfs track "*.bz2"
|
||||
git add .
|
||||
git commit -m "add more files"
|
||||
git push https://csukuangfj:$HF_TOKEN@huggingface.co/csukuangfj/sherpa-onnx-flutter main
|
||||
|
||||
# - name: Release android libs
|
||||
# if: (github.repository_owner == 'csukuangfj' || github.repository_owner == 'k2-fsa') && github.event_name == 'push' && contains(github.ref, 'refs/tags/')
|
||||
# uses: svenstaro/upload-release-action@v2
|
||||
# with:
|
||||
# file_glob: true
|
||||
# overwrite: true
|
||||
# file: sherpa*.tar.bz2
|
||||
|
||||
Reference in New Issue
Block a user