Skip to content

jmrobles/prvideo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

PR Video Generator Action

Auto-generate demo videos from your Pull Requests to help stakeholders understand code changes.

Usage

Add this workflow to your repository (.github/workflows/pr-video.yml):

name: PR Video

on:
  pull_request:
    types: [opened, synchronize]

jobs:
  generate-video:
    runs-on: ubuntu-latest
    if: github.event.pull_request.draft == false
    steps:
      - name: Generate PR Video
        uses: jmrobles/prvideo@v1
        with:
          api-key: ${{ secrets.PRVIDEO_API_KEY }}

The action uses the public API at prvideo.dev by default. You need an API key from prvideo.dev to use the service.

Inputs

Input Description Required Default
api-endpoint URL of the PR Video API No https://prvideo.dev
api-key API key for authentication Yes -
github-token GitHub/Gitea token for API access No ${{ github.token }}
platform Git platform: github or gitea No github
base-url Base URL of Git platform (required for Gitea) No -

Outputs

Output Description
video-url URL of the generated video
summary Summary of the PR changes

Self-Hosted

To use your own PR Video server:

- uses: jmrobles/prvideo@v1
  with:
    api-endpoint: https://your-server.com
    api-key: ${{ secrets.PR_VIDEO_API_KEY }}

Gitea Support

PR Video works with Gitea instances that have Gitea Actions enabled (Gitea 1.19+):

- uses: jmrobles/prvideo@v1
  with:
    api-key: ${{ secrets.PRVIDEO_API_KEY }}
    platform: gitea
    base-url: https://your-gitea-instance.com
    github-token: ${{ secrets.GIT_TOKEN }}

Note: Gitea reserves the GITEA_ prefix for system variables, so use GIT_TOKEN instead.

How It Works

  1. When a PR is opened or updated, the action calls the PR Video API
  2. The API fetches PR data (title, description, diff, commits)
  3. A video script is generated explaining the changes
  4. The API renders an MP4 video
  5. The video is uploaded to a GitHub Release
  6. A comment is posted on the PR with the video link

License

MIT

About

GitHub Action to auto-generate demo videos from Pull Requests

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors