LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

gh-preview

Preview GitHub-flavored Markdown in a browser

TLDR

Preview a markdown file (opens browser with live reload)
$ gh markdown-preview [README.md]
copy
Preview in dark mode
$ gh markdown-preview --dark-mode [file.md]
copy
Preview on a specific port
$ gh markdown-preview --port [8080] [file.md]
copy
Preview without auto-opening the browser
$ gh markdown-preview --disable-auto-open [file.md]
copy

SYNOPSIS

gh markdown-preview [options] [file]

DESCRIPTION

gh markdown-preview is a GitHub CLI extension that starts a local web server to preview Markdown files with GitHub-accurate rendering. It uses the GitHub Markdown API and CSS extracted from the GitHub website to produce output that looks exactly as it will appear on GitHub.The extension supports live reloading, so edits to the file are reflected in the browser automatically. If no file is specified, it detects and opens the README in the current directory.Install with: gh extension install yusukebe/gh-markdown-preview.

PARAMETERS

--dark-mode

Force dark mode rendering.
--light-mode
Force light mode rendering.
-p, --port port
TCP port for the local server (default: 3333).
--host hostname
Hostname to bind the server to (default: localhost).
--disable-auto-open
Do not automatically open the browser.
--disable-reload
Disable live reloading on file changes.
--verbose
Show verbose output.
--version
Show version.

INSTALL

sudo apt install gh
copy
sudo dnf install gh
copy
sudo pacman -S github-cli
copy
sudo apk add github-cli
copy
sudo zypper install gh
copy
brew install gh
copy
nix profile install nixpkgs#gh
copy

CAVEATS

Requires the GitHub CLI (gh) and an internet connection for the GitHub Markdown API. The rendered output depends on GitHub's API availability. This is a community extension, not a built-in gh command.

SEE ALSO

gh(1), glow(1)

Braincup
Open source brain training for math, memory and focus
Braincup mini-games
41 mini-games · Apache-2.0
No ads · No tracking
Play in browser
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid
276 stars
From the maker of Linux Command Library
Copied to clipboard
Braincup
Open source brain training for math, memory and focus. 41 mini-games, from mental arithmetic to Sudoku, N-Back and Solo Chess.
Apache-2.0 licensed · No ads · No tracking · No account
From the maker of Linux Command Library
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid