Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Publish gif with vhs publish directly #279

Open
Eldolfin opened this issue Jun 4, 2024 · 0 comments
Open

Publish gif with vhs publish directly #279

Eldolfin opened this issue Jun 4, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@Eldolfin
Copy link

Eldolfin commented Jun 4, 2024

Is your feature request related to a problem? Please describe.
Instead of having to create a imgur api for the comment-pr.yml example, why not directly publish it using the vhs publish command?

Describe the solution you'd like
An option on the action publish: false by default which would call vhs publish.
It would add an output to the action with the gif url.

Describe alternatives you've considered
Using any other service that allows publishing gif without an api.

Additional context
the action would look like this

name: comment gif
on:
  pull_request:
    paths:
      - vhs.tape
jobs:
  pr:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - uses: charmbracelet/vhs-action@v1
+       id: vhs_step
        with:
          path: 'vhs.tape'
+         publish: true 

-    - uses: devicons/[email protected]
-        id: imgur_step
-        with:
-          path: ./vhs.gif
-          client_id: ${{ secrets.IMGUR_CLIENT_ID }} # Make sure you have this secret set in your repo

      - uses: github-actions-up-and-running/[email protected]
        env:
-          IMG_URL: ${{ fromJSON(steps.imgur_step.outputs.imgur_urls)[0] }}
+          IMG_URL: ${{ steps.vhs_step.outputs.gif-url }}
          MESSAGE: |
            ![VHS GIF]({0})
        with:
          repo-token: ${{ secrets.GITHUB_TOKEN }}
          message: ${{ format(env.MESSAGE, env.IMG_URL) }}
          ```
@Eldolfin Eldolfin added the enhancement New feature or request label Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant