Skip to content

guifre/notes2html

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

notes2html CI

I write notes of random topics and I wanted to keep them online for easy access. However, I hate writing HTML.

notes2html transforms my notes to basic HTML. The workflow is just writing and pushing a note. After this, a git hook triggers a notes2html job that builds the notes and synchronizes it to http://guif.re

Usage

Run with Python 3 and pass the source notes directory plus the destination HTML directory:

python3 notes2html.py path/to/notes path/to/html

The converter recursively finds .txt files under the source directory and writes matching .html files under the destination directory.

Tests

Run the unit tests with:

python3 -m unittest discover

To generate coverage locally:

python3 -m coverage run -m unittest discover
python3 -m coverage html

Optional development tools are configured in pyproject.toml. After installing the dev dependencies, run:

python3 -m tox
python3 -m ruff check .
python3 -m ruff format .

CI

GitHub Actions runs Ruff, syntax-warning checks, and the unit test suite on Python 3.10, 3.11, 3.12, and 3.13.

Syntax

*Document title*
Title one
    paragraph one *bold*
    *start of code
    end of code*
    #image#

About

Converts text files to HTML

Resources

Stars

4 stars

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages