Skip to content

namespace

namespace #291

Workflow file for this run

name: namespace
on:
schedule:
- cron: "47 3 * * *"
push:
branches:
- main
paths:
- .github/workflows/namespace.yml
workflow_dispatch:
concurrency:
group: namespace
jobs:
fetch:
name: Fetch
runs-on: ubuntu-24.04
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install uniget
uses: uniget-org/uniget-action@main
with:
prefix: helper
tools: gojq
- name: Fetch
id: fetch
run: |
VERSION="$(
curl --silent --show-error --location --fail https://github.com/namespacelabs/homebrew-namespace/raw/main/nsc.rb \
| grep version \
| cut -d'"' -f2
)"
if test -z "${VERSION}"; then
echo "Failed to fetch latest tag and extract version from GitHub"
exit 1
fi
echo "Got version <${VERSION}>"
echo "version=${VERSION}" >>${GITHUB_OUTPUT}
- name: Release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.BOT_GITHUB_TOKEN }}
allowUpdates: true
name: "namespace v${{ steps.fetch.outputs.version }}"
tag: namespace/${{ steps.fetch.outputs.version }}
draft: false
prerelease: false