Skip to content

Enhance workflow to push NuGet package to Frends feed #12

Enhance workflow to push NuGet package to Frends feed

Enhance workflow to push NuGet package to Frends feed #12

Workflow file for this run

name: BuildMaster.yml
on:
push:
branches:
- master
jobs:
build:
name: Build master on ubuntu-latest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Pack release version
run: dotnet pack --configuration Release
- name: Get package name
id: package_name
run: |
$pkg = Get-ChildItem -Path . -Filter *.nupkg -Exclude *.symbols.nupkg -Recurse | Select-Object -First 1
echo "full_name=$($pkg.FullName)" >> $env:GITHUB_OUTPUT
echo "base_name=$($pkg.BaseName)" >> $env:GITHUB_OUTPUT
- name: Push to Frends Community Main Feed
shell: bash
run: |
curl -X POST "https://frends-fsp-cloudprod-agent.frendsapp.com/api/community-tasks/v1/push?feed_type=main" \
-H "x-api-key: ${{ secrets.FRENDS_COMMUNITY_TASKS_API_KEY }}" \
-H "Content-Type: application/octet-stream" \
--data-binary @"${{ steps.package_name.outputs.full_name }}"