Workflows & CI/CD
GitHub Actions Automation
Automatically publish and cross-post Markdown articles on Git push using the official ZyVOP Action.
GitHub Actions CI/CD Integration
ZyVOP provides an official composite GitHub Action (zyvop/zyvop-publish-action@v1) that monitors your repository for new or modified Markdown files and automatically triggers multi-platform cross-posting whenever code is pushed.
Quick Setup
1. Add your ZyVOP Token as a Repository Secret
- Open your repository on GitHub.
- Navigate to Settings → Secrets and variables → Actions.
- Click New repository secret.
- Name:
ZYVOP_TOKEN. - Value: Your developer token from ZyVOP (
zv_followed by 48 hexadecimal characters).
2. Create the Workflow File
Create .github/workflows/publish.yml in your repository:
name: Publish to ZyVOP
on:
push:
branches:
- main
paths:
- 'posts/**/*.md'
- 'content/**/*.md'
permissions:
contents: read
jobs:
syndicate:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
fetch-depth: 2 # Required to detect changed files
- name: Publish changed articles
uses: zyvop/zyvop-publish-action@v1
with:
posts: 'posts/**/*.md'
changed-only: 'true'
env:
ZYVOP_TOKEN: ${{ secrets.ZYVOP_TOKEN }}Action Inputs & Configuration
| Input | Type | Default | Description |
|---|---|---|---|
posts | string | ':(glob)posts/**/*.md' | Git pathspec matching your Markdown articles |
changed-only | string | 'true' | When 'true', only publishes files modified in the latest commit |
dry-run | string | 'false' | Validates frontmatter and builds payloads without publishing |
local | string | 'false' | Uses local runner provider secrets rather than ZyVOP cloud credentials |
cli-version | string | '1.1.1' | Specific pinned version of the zyvop npm CLI |
PR Preview & Dry-Run Workflow
You can also run ZyVOP in pull requests to ensure your team's Markdown frontmatter and asset paths are valid before merging to main:
name: Validate Markdown Frontmatter
on:
pull_request:
paths:
- 'posts/**/*.md'
jobs:
validate:
runs-on: ubuntu-latest
steps:
- name: Check out repo
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Dry Run Validation
uses: zyvop/zyvop-publish-action@v1
with:
posts: 'posts/**/*.md'
changed-only: 'true'
dry-run: 'true'
env:
ZYVOP_TOKEN: ${{ secrets.ZYVOP_TOKEN }}