GitHub Pager
pendingby Cloudac7
Selectively publish your notes and images to GitHub for Hugo/Jekyll/Hexo sites.
GitHub Pager
Treat Obsidian as a Headless CMS. Selectively publish notes and images to a GitHub repository, compatible with Hugo, Jekyll, Hexo, and other static site generators.
Features
- On-demand Publishing: Control which files to publish using Frontmatter (
share: true). - Multi-repo Support: Your vault stays local; only shared content goes to the specified GitHub repo.
- Auto-Sync: Automatically pushes changes to GitHub when you save a shared file.
- Link Transformation: Converts
[[WikiLinks]]to standard[Markdown Links](/path/to/note.md). - Image Handling: Automatically uploads embedded images
![[image.png]]to a dedicatedstatic/imagesfolder and rewrites links.
Installation
- Clone this repository.
- Run
npm installto install dependencies. - Run
npm run buildto build the plugin. - Copy
main.js,manifest.json, andstyles.cssto your vault's.obsidian/plugins/obsidian-github-pager/folder. - Enable the plugin in Obsidian Settings.
Configuration
Go to Settings > Obsidian GitHub Pager and configure:
- GitHub Token: A Personal Access Token (PAT) with
reposcope. See Creating a personal access token. Ensure the token has access to the target repository with content write permissions. - Repository Owner: Your GitHub username or organization.
- Repository Name: The name of the destination repository.
- Base Path: Folder in the repo where notes should be saved (e.g.,
content/posts). - Image Path: Folder in the repo where images should be saved (e.g.,
static/images). - Commit Message: Template for commit messages (use
{file}to include the filename). - Auto Sync: Enable to push changes automatically on save.
Usage
- You can also manually push the current file using the command in the menu or command palette:
Push Current File to GitHub - If you want to publish a note to custom path, add
remote_path: custom/path/to/dirto the Frontmatter. - When
Auto Syncis enabled, any time you save a note withshare: truein the Frontmatter, it will be automatically pushed to GitHub. - Check the Obsidian console (Ctrl+Shift+I) for logs and errors.
For plugin developers
Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.