---
title: "code2ebook"
author: "chuqingq"
date: "2015-01-18T17:57:02Z"
tags: []
categories: ["开源软件"]
slug: "code2ebook"
draft: false
lastmod: "2015-01-23T11:05:16Z"
id: 2177028
url: "https://chuqq.iteye.com/blog/2177028"
---

name=xxx

 

\## sudo apt-get install ctags

 

\## get \`src2html.pl\`: https://github.com/agentzh/code2ebook

 

src2html.pl --color --cross-reference --line-numbers . $name

 

\## sudo apt-get install calibre

 

ebook-convert html\_out/index.html $name.epub \\

    --output-profile ipad3 \\

    --no-default-epub-cover \\

    --output-profile kindle\_dx \\

    --title "$name" --publisher agentzh \\

    --language en --authors agentzh