Test whatever
Some checks failed
Build-Chocolatey-Packages

This commit is contained in:
Adam Goldsmith 2023-03-25 17:08:05 -04:00
parent f8b37a51aa
commit 6d8b60d819
2 changed files with 21 additions and 15 deletions

View File

@ -3,26 +3,19 @@ on:
branches: branches:
- main - main
- test - test
env:
NUGET_URL: https://git.claremontmakerspace.org/api/packages/${{ github.repository_owner }}/nuget/index.json
jobs: jobs:
Build-Chocolatey-Packages: Build-Chocolatey-Packages:
runs-on: ubuntu-latest runs-on: ubuntu-latest
container: chocolatey/choco container: catthehacker/ubuntu:act-latest
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v3 uses: actions/checkout@v3
- name: Chocolatey Pack - name: Chocolatey Pack
run: | uses: docker://chocolatey/choco:latest
for package in */ with:
do args: ./build-all.sh
( env:
cd "$package" NUGET_URL: https://git.claremontmakerspace.org/api/packages/${{ github.repository_owner }}/nuget/index.json
echo "Packing $package" GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
choco pack
choco push --source "${{ env.NUGET_URL }}" --key "${{ secrets.GITHUB_TOKEN }}"
)
done

13
build-all.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/sh
set -e
for package in */
do
(
cd "$package"
echo "Packing $package"
choco pack
choco push --source "$NUGET_URL" --key "$GITHUB_TOKEN"
)
done