Git2pdf
print github nested markdown file all in one pdf
Install / Use
/learn @bmpi-dev/Git2pdfREADME
Git2PDF
Description
Git2PDF is a simple parser which can make github nested markdown file all in one PDF.
Notice
Parse a markdown file which has a lot of url links can lead a very long time to make a PDF. The reason is Git2PDF need check every url status, if one links is broken which can throw a exception by wkhtmltopdf and it will faliure. One another is it need sleep 500ms every url check for github anti-crawler strategy.
Installation
before you can use this lib, it need install wkhtmltopdf to parse html to pdf, install guid can found its website.
If available in Hex, the package can be installed
by adding git2pdf to your list of dependencies in mix.exs:
def deps do
[
{:git2pdf, "~> 0.3.0"}
]
end
How to use
Input
iex> GitHubParse.markdown_to_pdf "https://github.com/remoteintech/remote-jobs/blob/master/README.md", 2, false
iex> GitHubParse.markdown_to_pdf "https://github.com/remoteintech/remote-jobs/blob/master/README.md", 2, false, ["--encoding", "utf-8", "-d", "300", "--zoom", "1.5", "--user-style-sheet", "/path/to/your/custom.css"]
Git2PDF use wkhtmltopdf to generate pdf, the last param is wkhtmltopdf's params, your can find more in this link
Output
{"/var/folders/k7/w1zkb4cn0472dk8t_j699pyc0000gn/T/KXiE8hJZ.html", "/var/folders/k7/w1zkb4cn0472dk8t_j699pyc0000gn/T/KXiE8hJZ.pdf"}
You can see this project README.md parse result in this Git2PDF, and you can see it append the CHANGELOG.md to the README.md.
The first is url, sencond is deep_level which mean how deepth which you want it get, the last is whether it check every url in markdown, mostly it doesn't need to check and you don't want to wait too long time.
Related Skills
apple-reminders
343.1kManage Apple Reminders via remindctl CLI (list, add, edit, complete, delete). Supports lists, date filters, and JSON/plain output.
gh-issues
343.1kFetch GitHub issues, spawn sub-agents to implement fixes and open PRs, then monitor and address PR review comments. Usage: /gh-issues [owner/repo] [--label bug] [--limit 5] [--milestone v1.0] [--assignee @me] [--fork user/repo] [--watch] [--interval 5] [--reviews-only] [--cron] [--dry-run] [--model glm-5] [--notify-channel -1002381931352]
node-connect
343.1kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
oracle
343.1kBest practices for using the oracle CLI (prompt + file bundling, engines, sessions, and file attachment patterns).
