diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index f8bd099..885f003 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -30,6 +30,7 @@ jobs: github-token: ${{ secrets.GITHUB_TOKEN }} - name: Check coverage percentage + id: coverage run: | if [ -f coverage.out ]; then echo "📊 Coverage Report:" @@ -37,6 +38,7 @@ jobs: coverage=$(go tool cover -func=coverage.out | grep total | awk '{print $3}' | sed 's/%//') echo "Total Coverage: ${coverage}%" + echo "percentage=${coverage}" >> $GITHUB_OUTPUT # Set threshold to 50% threshold=50 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5d881ec..de6ce2c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -243,7 +243,7 @@ jobs: name: Build and Push Docker Image needs: build runs-on: ubuntu-latest - if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') + if: (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')) || github.event_name == 'workflow_dispatch' steps: - name: Checkout code uses: actions/checkout@v4 @@ -264,7 +264,13 @@ jobs: - name: Get version id: version run: | - VERSION=${GITHUB_REF#refs/tags/v} + if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then + VERSION="${{ github.event.inputs.version }}" + # Remove 'v' prefix if present + VERSION=${VERSION#v} + else + VERSION=${GITHUB_REF#refs/tags/v} + fi echo "VERSION=${VERSION}" >> $GITHUB_OUTPUT - name: Build and push diff --git a/media.go b/media.go index e401fc4..d0fe921 100644 --- a/media.go +++ b/media.go @@ -2046,6 +2046,8 @@ func (c *Client) GetMetadataConfigurationOptions(ctx context.Context, configurat } // GetAudioOutputConfiguration retrieves audio output configuration +// +//nolint:dupl // Similar structure to GetAudioSourceConfiguration but different types and operations func (c *Client) GetAudioOutputConfiguration(ctx context.Context, configurationToken string) (*AudioOutputConfiguration, error) { endpoint := c.mediaEndpoint if endpoint == "" {