apple-ijk-framework #5
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: IJKMediaPlayerKit | |
on: | |
# push: | |
# branches: [master] | |
# pull_request: | |
# branches: [master] | |
workflow_dispatch: | |
jobs: | |
build: | |
name: Analyse-Publish | |
runs-on: macos-14 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Read Tag Version | |
run: | | |
grep -m 1 VERSION_NAME= version.sh | awk -F = '{printf "TAG=%s",$2}' | xargs > constants.env | |
cat constants.env | |
- name: Export Env | |
uses: cardinalby/export-env-action@v2 | |
with: | |
envFile: 'constants.env' | |
- run: brew install tree | |
- name: Download Pre Compiled Dependencies | |
run: | | |
./FFToolChain/main.sh install -p ios -l 'ass ffmpeg' | |
./FFToolChain/main.sh install -p macos -l 'ass ffmpeg' | |
./FFToolChain/main.sh install -p tvos -l 'ass ffmpeg' | |
- name: Pod Install | |
run: | | |
pod install --project-directory=examples/ios | |
pod install --project-directory=examples/macos | |
pod install --project-directory=examples/tvos | |
- name: Build iOS Framework | |
run: cd examples/ios && ./build-framework.sh | |
- name: Build macOS Framework | |
run: cd examples/macos && ./build-framework.sh | |
- name: Build tvOS Framework | |
run: cd examples/tvos && ./build-framework.sh | |
- name: Make xcframework | |
run: cd examples/xcframewrok && ./make-xcframework.sh | |
- name: Make podspec | |
run: cd examples/xcframewrok && ./make-podspec.sh | |
- name: Zip Frameworks | |
run: | | |
draft=FFToolChain/build/draft | |
dist=FFToolChain/build/dist | |
mkdir -p $draft | |
mkdir -p $dist | |
cp CHANGELOG.md $draft | |
cp README.md $draft | |
cp COPYING.LGPLv2.1 $draft | |
cp -pPR examples/xcframewrok/IJKMediaPlayerKit.xcframework $draft | |
cd $draft | |
mv COPYING.LGPLv2.1 LICENSE | |
zip -ryq IJKMediaPlayerKit.zip ./* | |
cd - | |
mv $draft/IJKMediaPlayerKit.zip $dist | |
mv examples/xcframewrok/IJKMediaPlayerKit.spec.json $dist | |
- name: Create Release | |
env: | |
GH_TOKEN: ${{ github.token }} | |
run: | | |
gh release create k${{ env.TAG }} -p -t "👏👏 IJKMediaPlayerKit k${{ env.TAG }}" FFToolChain/build/dist/*.* |