Prior to the refactor performed in
https://github.com/denisidoro/navi/pull/760, cheatsheet items could have
the same tags and the same description, but a different snippet, and
they would all be listed in the finder.
After the refactor, this behavior has changed and such items will now be
treated as non-unique.
There appears to be no requirement for item descriptions to
be distinct, so this patch restores the earlier behavior.
Fixes: https://github.com/denisidoro/navi/issues/951
Signed-off-by: Erik Gabriel Carrillo <ecarrillo@alumni.utexas.net>
It seems to be working without much issues, did not have much to test though
Signed-off-by: alexis-opolka <53085471+alexis-opolka@users.noreply.github.com>
related to https://github.com/denisidoro/navi/issues/576
For the following config
cheats:
paths:
- C:\\Users\\Administrator\\AppData\\Roaming\\navi\\cheat
- C:\\Users\\Administrator\\AppData\\Roaming\\navi\\cheat
navi now gets incorrect paths on Windows, since the seperator `:` for
path join is a valid component.
[2023-05-12T08:58:26Z DEBUG navi::commands::core] Filesystem(
Some(
"C:\\\\Users\\\\Administrator\\\\AppData\\\\Roaming\\\\navi\\\\cheat:C:\\\\Users\\\\Administrator\\\\AppData\\\\Roaming\\\\navi\\\\cheat",
),
)
[2023-05-12T08:58:28Z DEBUG navi::filesystem] filesystem::Fetcher = Fetcher {
path: Some(
"C:\\\\Users\\\\Administrator\\\\AppData\\\\Roaming\\\\navi\\\\cheat:C:\\\\Users\\\\Administrator\\\\AppData\\\\Roaming\\\\navi\\\\cheat",
),
files: RefCell {
value: [],
},
}
Add support for code blocks using markdown syntax. Lines that are
part of the snippet and match the variables regex won't be interpeted as
a variable.
Additionally, add `.cheat.md` as a file extension for cheats so that it
can be rendered on GitHub with proper code formatting and syntax
highlighting.
Fixes#806
With multiple variables in the preview, each with
different «--map» options, there is an application
of the map code for the current variable to the
preview of the other variables as well.
This code fixes that.