Skip to content

About

Open Markdown files from Hunk as rendered previews in your browser.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

Hunk Markdown Preview

Press lowercase o in Hunk to preview the selected Markdown file in your default browser. For macOS and Linux desktops.

Use

Requires Hunk 0.25.0 or newer with extension API 33, and Bun 1.4.4 or newer.

  1. Install the extension:

    hunk extension install mcuste/hunk-markdown-preview
  2. Open a review:

    hunk diff

Other file types do nothing. Previews show the current file on disk, not staged or historical content.

Change the shortcut

  1. Add your preferred key to ~/.config/hunk/config.toml, or $XDG_CONFIG_HOME/hunk/config.toml if set. For example, use Shift+O:

    [keybindings]
    "hunk-markdown-preview.open-preview" = "O"
  2. Restart Hunk.

The command prefix follows the checkout folder name if you rename it.

Releases

  1. Add user-visible changes to CHANGELOG.md.

  2. Preview a release from clean main:

    bun run release 0.1.0 --dry-run
  3. Prepare and publish the release:

    bun run release 0.1.0 --push

The release command runs checks, commits the version and notes, and tags the release. --push also pushes to GitHub, which verifies the tag and creates the release. Omit --push to keep the commit and tag local.

MIT.

About

Open Markdown files from Hunk as rendered previews in your browser.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages