Skip to content

Test

Test #13

# This workflow publishes the codecov-cli assets to PyPI and our GCS bucket
# when a release is created.
name: Build and publish codecov-cli
on:
push
# release:
# types: [published]
permissions:
contents: read
jobs:
publish_to_pypi:
permissions:
id-token: write # This is required for OIDC
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/codecov-cli
steps:
- name: Download pypi release assets
uses: robinraju/release-downloader@daf26c55d821e836577a15f77d86ddc078948b05 # v1.12
with:
# tag: ${{ github.ref_name }}
tag: "v11.0.6"
fileName: codecov_cli-*
out-file-path: codecov-cli/dist
- name: test
run: ls -R codecov-cli/dist
# - name: Publish package to PyPi
# uses: pypa/gh-action-pypi-publish@76f52bc884231f62b9a034ebfe128415bbaabdfc # v1.12.4
# with:
# verbose: true
# packages-dir: codecov-cli/dist
# publish_release:
# name: Publish release
# runs-on: ubuntu-latest
# permissions:
# contents: "read"
# id-token: "write"
# steps:
# - id: "auth"
# name: "Authenticate to Google Cloud"
# uses: "google-github-actions/auth@v1.0.0"
# with:
# create_credentials_file: "true"
# workload_identity_provider: ${{ secrets.CODECOV_GCP_WIDP }}
# service_account: ${{ secrets.CODECOV_GCP_WIDSA }}
#
# # Publish the release tag to a Pub/Sub topic
# - name: Publish a message to a Pub/Sub topic
# env:
# CLOUDSDK_CORE_PROJECT: ${{ secrets.GCLOUD_UPLOADER_PROJECT_ID }}
# run: |
# gcloud pubsub topics publish ${{ secrets.GCLOUD_UPLOADER_PUBSUB_TOPIC }} --message '{"release":"'"${{ github.ref_name }}"'", "latest":true}'