Skip to content

Commit

Permalink
Update README, fix publish
Browse files Browse the repository at this point in the history
  • Loading branch information
Kidev committed Jan 22, 2025
1 parent 4d3eb3d commit 47a160c
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 14 deletions.
40 changes: 26 additions & 14 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,30 +10,42 @@ permissions:
issues: write

jobs:
publish-node:
name: Publish Custom Node to registry
check-version:
name: Check version requirements
runs-on: ubuntu-latest
if: ${{ github.repository_owner == 'Kidev' && github.ref_type == 'tag' && startsWith(github.ref, 'refs/tags/v') }}
outputs:
should_publish: ${{ steps.check.outputs.should_publish }}
steps:
- name: Check out code
uses: actions/checkout@v4
with:
submodules: true

- name: Get version from pyproject.toml
id: get_version
- name: Compare versions
id: check
run: |
VERSION=$(grep '^version = ' pyproject.toml | cut -d'"' -f2)
echo "version=$VERSION" >> $GITHUB_OUTPUT
TAG=${GITHUB_REF#refs/tags/v}
if [ "$TAG" = "$VERSION" ]; then
echo "should_publish=true" >> $GITHUB_OUTPUT
echo "Versions match ($VERSION), will proceed with publish"
else
echo "should_publish=false" >> $GITHUB_OUTPUT
echo "Tag version ($TAG) does not match pyproject.toml version ($VERSION), skipping publish"
fi
- name: Check version matches tag
if: |
github.repository_owner == 'Kidev' &&
github.ref_type == 'tag' &&
github.ref_name == format('v{0}', steps.get_version.outputs.version)
run: echo "Version matches tag, proceeding with publish"
publish-node:
name: Publish Custom Node to registry
needs: check-version
if: ${{ needs.check-version.outputs.should_publish == 'true' }}
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
with:
submodules: true
fetch-tags: true

- name: Publish Custom Node
if: success()
uses: Comfy-Org/publish-node-action@v1
with:
personal_access_token: ${{ secrets.REGISTRY_ACCESS_TOKEN }}
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

Provides tools for applying and removing fisheye lens effects from images.

![Example](examples/CircularGrid.png)

## Features

- FisheyeNode: Apply fisheye distortion to images
Expand Down

0 comments on commit 47a160c

Please sign in to comment.