Skip to content

Commit

Permalink
Test only iOS downloading on GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
asus4 committed Jan 16, 2024
1 parent e8767cc commit 50a6ada
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 14 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
registry-url: 'https://registry.npmjs.org'
- run: ./download-binaries.sh v1.16.3
# Publish all packages in matrix
- run: npm publish
working-directory: ${{ matrix.publish-packages }}
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
# - run: npm publish
# working-directory: ${{ matrix.publish-packages }}
# env:
# NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
21 changes: 11 additions & 10 deletions download-binaries.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,27 +46,28 @@ function download_github_releases() {
}

# macOS Universal
download_github_releases onnxruntime-osx-universal2-$TAG.tgz
cp -RL $TMP_DIR/onnxruntime-osx-universal2-$TAG/lib/libonnxruntime.dylib $PLUGINS_CORE_DIR/macOS/libonnxruntime.dylib
# download_github_releases onnxruntime-osx-universal2-$TAG.tgz
# cp -RL $TMP_DIR/onnxruntime-osx-universal2-$TAG/lib/libonnxruntime.dylib $PLUGINS_CORE_DIR/macOS/libonnxruntime.dylib

# Windows x64
download_github_releases Microsoft.ML.OnnxRuntime.DirectML.$TAG.zip
cp $TMP_DIR/runtimes/win-x64/native/onnxruntime.dll $PLUGINS_CORE_DIR/Windows/x64/
download_github_releases onnxruntime-win-x64-gpu-$TAG.zip
cp $TMP_DIR/onnxruntime-win-x64-gpu-$TAG/lib/onnxruntime_providers_*.dll $PROJCET_DIR/com.github.asus4.onnxruntime.win-x64-gpu/Plugins/Windows/x64/
# download_github_releases Microsoft.ML.OnnxRuntime.DirectML.$TAG.zip
# cp $TMP_DIR/runtimes/win-x64/native/onnxruntime.dll $PLUGINS_CORE_DIR/Windows/x64/
# download_github_releases onnxruntime-win-x64-gpu-$TAG.zip
# cp $TMP_DIR/onnxruntime-win-x64-gpu-$TAG/lib/onnxruntime_providers_*.dll $PROJCET_DIR/com.github.asus4.onnxruntime.win-x64-gpu/Plugins/Windows/x64/

# Linux x64
download_github_releases onnxruntime-linux-x64-gpu-$TAG.tgz
cp -RL $TMP_DIR/onnxruntime-linux-x64-gpu-$TAG/lib/libonnxruntime.so $PLUGINS_CORE_DIR/Linux/x64/
cp $TMP_DIR/onnxruntime-linux-x64-gpu-$TAG/lib/libonnxruntime_providers_*.so $PROJCET_DIR/com.github.asus4.onnxruntime.linux-x64-gpu/Plugins/Linux/x64/
# download_github_releases onnxruntime-linux-x64-gpu-$TAG.tgz
# cp -RL $TMP_DIR/onnxruntime-linux-x64-gpu-$TAG/lib/libonnxruntime.so $PLUGINS_CORE_DIR/Linux/x64/
# cp $TMP_DIR/onnxruntime-linux-x64-gpu-$TAG/lib/libonnxruntime_providers_*.so $PROJCET_DIR/com.github.asus4.onnxruntime.linux-x64-gpu/Plugins/Linux/x64/

# iOS
download_package pod-archive-onnxruntime-c-$TAG.zip https://onnxruntimepackages.z14.web.core.windows.net
mkdir -p $TMP_DIR/onnxruntime.xcframework
cp -R $TMP_DIR/onnxruntime.xcframework/* $PLUGINS_CORE_DIR/iOS~/onnxruntime.xcframework/
ls $PLUGINS_CORE_DIR/iOS~/onnxruntime.xcframework/

# Android
curl -L https://repo1.maven.org/maven2/com/microsoft/onnxruntime/onnxruntime-android/$TAG/onnxruntime-android-$TAG.aar -o $PLUGINS_CORE_DIR/Android/onnxruntime-android.aar
# curl -L https://repo1.maven.org/maven2/com/microsoft/onnxruntime/onnxruntime-android/$TAG/onnxruntime-android-$TAG.aar -o $PLUGINS_CORE_DIR/Android/onnxruntime-android.aar

echo "Done."
exit 0

0 comments on commit 50a6ada

Please sign in to comment.