diff --git a/.github/workflows/publish_release.yml b/.github/workflows/publish_release.yml index 6589c0d..eb89daa 100644 --- a/.github/workflows/publish_release.yml +++ b/.github/workflows/publish_release.yml @@ -13,6 +13,11 @@ jobs: # Make sure we can lint before creating the release. - name: Cocoapods lint run: make cocoapods + # Make sure we can build with Carthage before the release + - name: Build and archive framework for Carthage users + env: + DEVELOPER_DIR: /Applications/Xcode_11.7.app/Contents/Developer + run: carthage build --no-skip-current && carthage archive - name: Create Release Commit env: GITHUB_CHANGELOG_API_KEY: ${{ secrets.GITHUB_TOKEN }} @@ -37,3 +42,15 @@ jobs: env: COCOAPODS_TRUNK_TOKEN: ${{ secrets.COCOAPODS_TRUNK_TOKEN }} run: pod trunk push + - name: Upload binary framework to release asset + id: upload-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + FRAMEWORK_NAME: PINOperation + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps + asset_path: ./${{ env.FRAMEWORK_NAME }}.framework.zip + asset_name: ${{ env.FRAMEWORK_NAME }}.framework.zip + asset_content_type: application/zip +