-
Notifications
You must be signed in to change notification settings - Fork 59
revert: restore original codecov-cli release process #708
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
thomasrockhu-codecov
wants to merge
1
commit into
main
Choose a base branch
from
th/revert-release-process
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,131 @@ | ||
| name: Build Compiled Assets | ||
|
|
||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| release: | ||
| type: boolean | ||
| default: false | ||
| description: "Attach artifacts to a release" | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| build_assets: | ||
| name: Build packages - ${{ matrix.os }} | ||
| runs-on: ${{ matrix.os }} | ||
| permissions: | ||
| contents: write # needed for svenstaro/upload-release-action when inputs.release == true | ||
| strategy: | ||
| fail-fast: true | ||
| matrix: | ||
| include: | ||
| - os: macos-latest | ||
| TARGET: macos | ||
| CMD_BUILD: > | ||
| uv run pyinstaller --target-arch universal2 -F codecov_cli/main.py && | ||
| mv dist/main dist/codecovcli_macos && | ||
| lipo -archs dist/codecovcli_macos | grep 'x86_64 arm64' | ||
| OUT_FILE_NAME: codecovcli_macos | ||
| ASSET_MIME: application/octet-stream | ||
| - os: ubuntu-22.04 | ||
| TARGET: ubuntu | ||
| CMD_BUILD: > | ||
| uv run pyinstaller -F codecov_cli/main.py && | ||
| cp ./dist/main ./dist/codecovcli_linux | ||
| OUT_FILE_NAME: codecovcli_linux | ||
| ASSET_MIME: application/octet-stream | ||
| - os: windows-latest | ||
| TARGET: windows | ||
| CMD_BUILD: > | ||
| uv run pyinstaller -F .\codecov_cli\main.py && | ||
| Copy-Item -Path ".\dist\main.exe" -Destination ".\dist\codecovcli_windows.exe" | ||
| OUT_FILE_NAME: codecovcli_windows.exe | ||
| ASSET_MIME: application/vnd.microsoft.portable-executable | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up Python 3.11 | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.11" | ||
|
|
||
| - name: Install uv and dependencies | ||
| run: | | ||
| pip install uv | ||
| # Need to build pyyaml and ijson from sdists to get universal2 macos build to work | ||
| uv sync --no-binary-package pyyaml --no-binary-package ijson | ||
|
|
||
| - name: Build with pyinstaller for ${{matrix.TARGET}} | ||
| run: ${{matrix.CMD_BUILD}} | ||
|
|
||
| - name: Upload a Build Artifact | ||
| uses: actions/upload-artifact@v4 | ||
| if: inputs.release == false | ||
| with: | ||
| name: ${{ matrix.OUT_FILE_NAME }} | ||
| path: ./dist/${{ matrix.OUT_FILE_NAME }} | ||
|
|
||
| - name: Upload Release Asset | ||
| if: inputs.release == true | ||
| id: upload-release-asset | ||
| uses: svenstaro/upload-release-action@v2 | ||
| with: | ||
| repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
| file: ./dist/${{ matrix.OUT_FILE_NAME }} | ||
| asset_name: ${{ matrix.OUT_FILE_NAME }} | ||
| tag: ${{ github.ref }} | ||
| overwrite: true | ||
|
|
||
| build_assets_alpine_arm: | ||
| name: Build assets - Alpine and ARM | ||
| runs-on: ${{ matrix.runs-on }} | ||
| permissions: | ||
| contents: write # needed for svenstaro/upload-release-action when inputs.release == true | ||
| strategy: | ||
| matrix: | ||
| include: | ||
| - distro: "alpine:3.14" | ||
| arch: arm64 | ||
| distro_name: alpine | ||
| runs-on: ubuntu-24.04-arm | ||
| - distro: "alpine:3.14" | ||
| arch: x86_64 | ||
| distro_name: alpine | ||
| runs-on: ubuntu-24.04 | ||
| - distro: "ubuntu:20.04" | ||
| arch: arm64 | ||
| distro_name: linux | ||
| runs-on: ubuntu-24.04-arm | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Run in Docker | ||
| run: | | ||
| docker run \ | ||
| --rm \ | ||
| -v $(pwd):/${{ github.workspace }} \ | ||
| -w ${{ github.workspace }} \ | ||
| --platform linux/${{ matrix.arch }} \ | ||
| ${{ matrix.distro }} \ | ||
| ./scripts/build_${{ matrix.distro_name }}_arm.sh ${{ matrix.distro_name }}_${{ matrix.arch }} | ||
|
|
||
| - name: Upload a Build Artifact | ||
| uses: actions/upload-artifact@v4 | ||
| if: inputs.release == false | ||
| with: | ||
| name: codecovcli_${{ matrix.distro_name }}_${{ matrix.arch }} | ||
| path: ./dist/codecovcli_${{ matrix.distro_name }}_${{ matrix.arch }} | ||
|
|
||
| - name: Upload Release Asset | ||
| if: inputs.release == true | ||
| id: upload-release-asset | ||
| uses: svenstaro/upload-release-action@v2 | ||
| with: | ||
| repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
| file: ./dist/codecovcli_${{ matrix.distro_name }}_${{ matrix.arch }} | ||
| asset_name: codecovcli_${{ matrix.distro_name }}_${{ matrix.arch }} | ||
| tag: ${{ github.ref }} | ||
| overwrite: true | ||
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| --- | ||
| name: Build for PyPi | ||
|
|
||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| publish: | ||
| type: boolean | ||
| default: false | ||
| description: "Build for PyPi" | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| build_for_pypi: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| persist-credentials: false | ||
|
|
||
| - name: Install uv | ||
| run: pip install uv | ||
|
|
||
| - name: Build sdist and wheel | ||
| run: uv build | ||
|
|
||
| - name: Store the distribution packages | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: cibw-codecov-cli | ||
| path: ./dist/* |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.