From fdfbf550144ef69ecc6003760fbb39466ec08637 Mon Sep 17 00:00:00 2001 From: lukeflo Date: Sun, 29 Jun 2025 12:26:27 +0200 Subject: Some basic function rewriting for matching different file types --- src/config.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/config.rs') diff --git a/src/config.rs b/src/config.rs index f5f2dd0..6abcfd1 100644 --- a/src/config.rs +++ b/src/config.rs @@ -56,6 +56,12 @@ const DEFAULT_CONFIG: &str = r##" ## Use absolute paths (~ for HOME works). Otherwise, loading might not work. # pdf_path = "/path/to/pdf/folder" +## Path to folder (with subfolders) containing note files with the basename of +## the format "citekey.extension". Other basenames are not accepted. The possible +## extensions can be set through the "note_extensions" array. +# note_path = "/path/to/notes/folder" +# note_extensions = [ "md", "txt", "org" ] + # [colors] ## Default values for dark-themed terminal ## Possible values are: @@ -90,6 +96,8 @@ pub struct General { pub url_opener: String, pub file_prefix: Option, pub pdf_path: Option, + pub note_path: Option, + pub note_extensions: Option>, } /// Substruct [colors] in config.toml @@ -117,6 +125,8 @@ impl Default for BibiConfig { url_opener: select_opener(), file_prefix: None, pdf_path: None, + note_path: None, + note_extensions: None, }, colors: Self::dark_colors(), } @@ -133,6 +143,8 @@ impl BibiConfig { url_opener: select_opener(), file_prefix: None, pdf_path: None, + note_path: None, + note_extensions: None, }, colors: if args.light_theme { Self::light_colors() -- cgit v1.2.3