quick_notes.cli.cli module
- quick_notes.cli.cli.generate_markdown_from_filepath(toml_filepath: str) str[source]
Generate markdown quick-note from a toml quick-note file.
- Parameters:
toml_filepath (str) – Path to the toml quick-note file.
- Returns:
String representing a markdown quick-note.
- Return type:
str
- quick_notes.cli.cli.generate_markdown_from_stream(toml_stream: TextIO) str[source]
Generate markdown quick-note from toml data.
- Parameters:
toml_stream (TextIO) – String stream serving toml data.
- Returns:
String representing a markdown quick-note.
- Return type:
str
- quick_notes.cli.cli.generate_quick_note(id: int, date: str, title: str, text: str) str[source]
Generate a toml quick-note.
- Parameters:
id (int) – Unique identifier.
date (str) – Creation date.
title (str) – Title of the quick-note.
text (str) – Content of the quick-note.
- Returns:
Toml quick-note filled up with the given parameters.
- Return type:
str
- quick_notes.cli.cli.generate_toml_from_filepath(markdown_filepath: str) QuickNoteList[source]
Generate toml quick-note from a markdown quick-note file.
- Parameters:
markdown_filepath (str) – Path to the markdown quick-note file.
- Returns:
String representing a toml quick-note.
- Return type:
QuickNoteList
- quick_notes.cli.cli.generate_toml_from_stream(markdown_stream: TextIO) QuickNoteList[source]
Generate toml quick-note from markdown data.
- Parameters:
markdown_stream (TextIO) – String stream serving markdown data.
- Returns:
String representing a toml quick-note.
- Return type:
QuickNoteList
- quick_notes.cli.cli.validate_files(toml_filepath: str, markdown_filepath: str) bool[source]
Check consistency between a toml quick-note and a markdown quick-note.
- Parameters:
toml_filepath (str) – Path to the toml quick-note file.
markdown_filepath (str) – Path to the markdown quick-note file.
- Returns:
True if the files are consistent; and False otherwise.
- Return type:
bool