Skip to content

Commit

Permalink
Github action for package release
Browse files Browse the repository at this point in the history
  • Loading branch information
Jozef Volak committed Nov 14, 2023
1 parent 7de5b83 commit 006751d
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/ISSUE_TEMPLATE/bug.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
name: 🐛 Frinx Services Python Workers Bug
description: Report a bug or unexpected behavior in frinx-services-python-workers
labels: [bug, pending]

body:
- type: markdown
attributes:
value: Thank you for contributing to frinx-services-python-workers!
5 changes: 5 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#### Checklist
<!-- [Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.] -->
- [ ] Title of the PR starts with chart name (e.g. `[inventory]`)
- [ ] Update package version in principles of semantic versioning
- [ ] Update CHANGELOG.md
54 changes: 54 additions & 0 deletions .github/workflows/publish-package.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: pr-check

on:
workflow_dispatch:
inputs:
utils:
type: choice
description: Release package from utils
options:
- inventory/python
- resource-manager/python
- schellar/python
- topology-discovery/python
- uniconfig/python
- misc/python/http
- misc/python/kafka
- misc/python/influxdb
- misc/python/conductor-system-test

jobs:
build:
name: Validate api packages
runs-on: ubuntu-latest
timeout-minutes: 5
defaults:
run:
working-directory: ${{ inputs.utils }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v4
with:
python-version: "3.10"
- uses: abatilo/actions-poetry@v2
with:
poetry-version: "1.7.0"
- name: Package naming
run: |
echo "PACKAGE_NAME=$(poetry version --no-interaction | cut -d ' ' -f 1)" >> "$GITHUB_ENV"
echo "PACKAGE_VERSION=$(poetry version --no-interaction --short)" >> "$GITHUB_ENV"
echo "RELEASE_TAG=$(poetry version --no-interaction | sed 's| |_v|g')" >> "$GITHUB_ENV"
# - name: Poetry publish
# run: poetry publish -u "__token__" -p "${{ secrets.PYPI_TOKEN }}" --build
- name: Create Release
id: create_release
uses: actions/create-release@latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ env.PACKAGE_TAG }}
release_name: Release ${{ env.PACKAGE_TAG }}
body: |
- Release of ${{ env.PACKAGE_NAME }} version ${{ env.PACKAGE_VERSION }}
draft: false
prerelease: false

0 comments on commit 006751d

Please sign in to comment.