GitHunt
SD

sdthaker/TILvert

A simple Markdown to HTML CLI utility designed to generate web pages from simple notes

TILvert

A simple tool to convert TILs from txt files to HTML

Installation

$ npm install -g https://github.com/omalk98/TILvert.git

Uninstall

$ npm uninstall -g tilvert

Build From Source

$ git clone https://github.com/omalk98/TILvert.git
$ cd TILvert
$ npm install
$ npm run build

Usage

Installed

$ tilvert [flags/options] <path>

From Source

$ node dist/src/main.js [flags/options] <path>

OR

$ npm run start -- [flags/options] <path>
$ pnpm run start [flags/options] <path>

If no path is specified, TILvert will read the current directory recursively to find all files with the matching extension (default "txt").

Flags

Flag Description
-h, --help Displays help information.
-v, --version Displays version information.

Options

Option Description
-e, --extension Extension for the files in the input directory. (Ignored if input is file). Default (txt).
-o, --output Path to the output directory. Default (./til).
-s, --stylesheet Path to the stylesheet.
--title Title of the HTML page.
--author Author of the HTML page.
--description Description of the HTML page.
--keywords Keywords of the HTML page.
--robots Robots of the HTML page.
--generator Generator of the HTML page.
--theme-color Theme color of the HTML page.

License

TILvert is licensed under the MIT License

Features

  • Convert txt files to HTML
  • Replicate directory structure in output directory
  • Non-destructive (Does not delete files in output directory)
  • Customizable HTML page title
  • Customizable HTML page with meta tags
  • Customizable stylesheet
  • Customizable extension for input files
  • Customizable output directory
  • Convert markdown files to HTML (only supports links currently)

Examples

Installed

$ tilvert -e txt -o ./til -s https://cdn.jsdelivr.net/npm/water.css@2/out/water.css --title "TIL" --author "omalk" --description "Today I Learned" --keywords "til, today i learned" --robots "index, follow" --generator "TILvert" --theme-color "#000000" ./example

From Source

$ node dist/src/main.js --extension txt --output ./til --stylesheet https://cdn.jsdelivr.net/npm/water.css@2/out/water.css
$ npm run start -- --extension txt --output ./til --stylesheet https://cdn.jsdelivr.net/npm/water.css@2/out/water.css

Languages

TypeScript88.3%JavaScript11.7%

Contributors

MIT License
Created September 12, 2023
Updated September 14, 2023