mirror of
https://github.com/tomasriveral/NoteWrapper.git
synced 2026-10-10 17:03:04 +02:00
Compare commits
6
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2e301b0b52 | ||
|
|
c7a9d45a65 | ||
|
|
62da4cfb2e | ||
|
|
d56e7d9e4f | ||
|
|
449a9eaca6 | ||
|
|
edc979dccb |
No files matched your search
@@ -4,6 +4,8 @@ Note: This project fullfills all my usecases for now, so my main source for feat
|
|||||||
|
|
||||||
[](https://deepwiki.com/tomasriveral/notewrapper)
|
[](https://deepwiki.com/tomasriveral/notewrapper)
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
## Why?
|
## Why?
|
||||||
|
|
||||||
I started journaling and note-taking with **[Obsidian](https://obsidian.md/)** but wanted to use only free software. I also tried **[Logseq](https://logseq.com/)** and **[Joplin](https://github.com/laurent22/joplin)**, but I preferred a terminal-based workflow.
|
I started journaling and note-taking with **[Obsidian](https://obsidian.md/)** but wanted to use only free software. I also tried **[Logseq](https://logseq.com/)** and **[Joplin](https://github.com/laurent22/joplin)**, but I preferred a terminal-based workflow.
|
||||||
@@ -229,17 +231,18 @@ Edit `~/.config/notewrapper/config.json`. If it does not exist, it will be creat
|
|||||||
* `git.enable`: enable git version control for backups
|
* `git.enable`: enable git version control for backups
|
||||||
* `git.name` and `git.email` are for the commits signature
|
* `git.name` and `git.email` are for the commits signature
|
||||||
|
|
||||||
Note:
|
> [!NOTE]
|
||||||
* Directories must end with `/`.
|
> * The git backup implementation relies a lot on the IO speed of your drive. A low speed one (or a web mounted one) could create blanks between closing a document and the TUI opening.
|
||||||
* All directories used must exist.
|
> * Directories must end with `/`.
|
||||||
* Elements of `directory` and `backup.directory` must match exactly.
|
> * All directories used must exist.
|
||||||
* Directories set in `directory` but not in `backup.directory` won't be backed up.
|
> * Elements of `directory` and `backup.directory` must match exactly.
|
||||||
* Directories set in `backup.directory` but not in `directory` will be ignored.
|
> * Directories set in `directory` but not in `backup.directory` won't be backed up.
|
||||||
* `journalRegex` must match if the file name ends with `.md` and if it doesn't.
|
> * Directories set in `backup.directory` but not in `directory` will be ignored.
|
||||||
* It is recommended to keep `-q` or `--quiet` flag in `rsyncArgs` to avoid interference with `ncurses`.
|
> * `journalRegex` must match if the file name ends with `.md` and if it doesn't.
|
||||||
* If `rsync` fails, you will see it inside `ncurses`.
|
> * It is recommended to keep `-q` or `--quiet` flag in `rsyncArgs` to avoid interference with `ncurses`.
|
||||||
* If you want the git backup but without rsync, you can leave `backup.directory` empty or map each directory to itself. When enabled, git will apply to all your vaults.
|
> * If `rsync` fails, you will see it inside `ncurses`.
|
||||||
* Each vault gets its own git repository that will be created the first time you select the vault with the option enabled.
|
> * If you want the git backup but without rsync, you can leave `backup.directory` empty or map each directory to itself. When enabled, git will apply to all your vaults.
|
||||||
|
> * Each vault gets its own git repository that will be created the first time you select the vault with the option enabled.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,192 @@
|
|||||||
|
Require echo
|
||||||
|
|
||||||
|
Set Shell "zsh"
|
||||||
|
Set TypingSpeed 35ms
|
||||||
|
Set FontSize 18
|
||||||
|
Set Width 1800
|
||||||
|
Set Height 900
|
||||||
|
|
||||||
|
Output demo.gif
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
# Introduction
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
Type "echo 'Welcome to NoteWrapper!'"
|
||||||
|
Sleep 800ms
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
Type "notewrapper --help"
|
||||||
|
Sleep 500ms
|
||||||
|
Enter
|
||||||
|
Sleep 4000ms
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
# Create / open a unified journal
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
Type "notewrapper"
|
||||||
|
Sleep 700ms
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 700ms
|
||||||
|
|
||||||
|
Enter
|
||||||
|
Sleep 1200ms
|
||||||
|
|
||||||
|
Down
|
||||||
|
Sleep 600ms
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
# Enter the editor
|
||||||
|
Type "i"
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Type "NoteWrapper uses standard Markdown files, so you can open your notes in any other application that supports Markdown."
|
||||||
|
Sleep 700ms
|
||||||
|
Enter
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Type "This is a unified journal: all your daily entries live in the same file. You can also configure NoteWrapper to use monthly or other time-based entries."
|
||||||
|
Sleep 700ms
|
||||||
|
Enter
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Type "And, although you can't see it in this demo, this Markdown file is rendered live in my browser thanks to Vivify!"
|
||||||
|
Sleep 1500ms
|
||||||
|
Sleep 3000ms
|
||||||
|
|
||||||
|
# Leave the editor
|
||||||
|
Escape
|
||||||
|
Sleep 500ms
|
||||||
|
Type ":q!"
|
||||||
|
Sleep 800ms
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
# Create / open a divided journal
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 700ms
|
||||||
|
|
||||||
|
Enter
|
||||||
|
Sleep 2000ms
|
||||||
|
|
||||||
|
Enter
|
||||||
|
Sleep 1000ms
|
||||||
|
|
||||||
|
Type "i"
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Type "And this is a divided journal."
|
||||||
|
Sleep 500ms
|
||||||
|
Type " It uses one file per entry."
|
||||||
|
Sleep 700ms
|
||||||
|
Enter
|
||||||
|
Sleep 1000ms
|
||||||
|
|
||||||
|
Type "Find the dates and journal divisions a little too cumbersome?"
|
||||||
|
Sleep 700ms
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
Type "Don't worry: NoteWrapper also works with basic notes."
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Type "It distinguishes them using a regular expression, which defaults to `.*journal.*`."
|
||||||
|
Sleep 800ms
|
||||||
|
Enter
|
||||||
|
Sleep 700ms
|
||||||
|
|
||||||
|
Type "The unified or divided journal mode is chosen when you first create the journal."
|
||||||
|
Sleep 1000ms
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
# Search
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
Type "Let me show you one last cool feature."
|
||||||
|
Sleep 1000ms
|
||||||
|
|
||||||
|
Type "Have you ever forgotten when or where you wrote something?"
|
||||||
|
Sleep 1000ms
|
||||||
|
Enter
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Type "Well ... NoteWrapper was made for you!"
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
Escape
|
||||||
|
Sleep 500ms
|
||||||
|
Type ":q!"
|
||||||
|
Sleep 800ms
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
# Navigate to search
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Enter
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
Down
|
||||||
|
Sleep 500ms
|
||||||
|
Down
|
||||||
|
Sleep 800ms
|
||||||
|
|
||||||
|
Enter
|
||||||
|
Sleep 2000ms
|
||||||
|
|
||||||
|
# Search all notes with fzf
|
||||||
|
Type "c"
|
||||||
|
Sleep 300ms
|
||||||
|
Type "o"
|
||||||
|
Sleep 300ms
|
||||||
|
Type "o"
|
||||||
|
Sleep 300ms
|
||||||
|
Type "l"
|
||||||
|
Sleep 1500ms
|
||||||
|
|
||||||
|
# Show the search result / preview
|
||||||
|
Up
|
||||||
|
Sleep 5000ms
|
||||||
|
Enter
|
||||||
|
Sleep 1000ms
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
# Final note
|
||||||
|
# ─────────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
Type "i"
|
||||||
|
Sleep 700ms
|
||||||
|
|
||||||
|
Type "Never lose a note."
|
||||||
|
Sleep 1500ms
|
||||||
|
Enter
|
||||||
|
Sleep 1000ms
|
||||||
|
|
||||||
|
Type "P. S. Don't mind the broken fzf preview. Normally, you'll see the context around your search result, but sometimes `sed` breaks when fzf is opened for the first time."
|
||||||
|
Sleep 5000ms
|
||||||
Generated
+3
-3
@@ -20,11 +20,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1786106723,
|
"lastModified": 1786862985,
|
||||||
"narHash": "sha256-zDSUbpoeo/9ZmD2+wXnzxoo1+uhL8vxc0b8yuYMKYq0=",
|
"narHash": "sha256-FBJRXmbGXiSUDvYEbfLYRkckayyZ6SK1UEqhCrIZ2Cs=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "f13ff45afd1bb73e640eaa08a7066dbed07e3238",
|
"rev": "e5bdc4a41d4c072fe1e3787eaa0320a384741d44",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|||||||
@@ -53,6 +53,7 @@
|
|||||||
clang-tools
|
clang-tools
|
||||||
gnumake
|
gnumake
|
||||||
libgit2
|
libgit2
|
||||||
|
vhs
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
+1
-2
@@ -766,7 +766,7 @@ backup_config_end:
|
|||||||
openEditor(fullPath, editorToOpen, shouldRender, shouldJumpToEnd, shouldDebug);
|
openEditor(fullPath, editorToOpen, shouldRender, shouldJumpToEnd, shouldDebug);
|
||||||
free(fullPath);
|
free(fullPath);
|
||||||
}
|
}
|
||||||
openEditor(fullPath, editorToOpen, shouldRender, shouldJumpToEnd, shouldDebug);
|
free(returnNoteSelection);
|
||||||
if (gitEnabled) { // After closing a file, we need to update the git repo (if git is enable
|
if (gitEnabled) { // After closing a file, we need to update the git repo (if git is enable
|
||||||
char *date = getDateAndTime();
|
char *date = getDateAndTime();
|
||||||
char *commitMsg = malloc(29);
|
char *commitMsg = malloc(29);
|
||||||
@@ -775,7 +775,6 @@ backup_config_end:
|
|||||||
free(date);
|
free(date);
|
||||||
free(commitMsg);
|
free(commitMsg);
|
||||||
}
|
}
|
||||||
free(fullPath);
|
|
||||||
} else if (strcmp(noteSelected, "Create new note") == 0) {
|
} else if (strcmp(noteSelected, "Create new note") == 0) {
|
||||||
note_creation:
|
note_creation:
|
||||||
noteSelected = createNewNote(notesDirectoryString, vaultSelected, bypassSelectionNote, bypassSelectionNoteValue, journalRegex, shouldDebug);
|
noteSelected = createNewNote(notesDirectoryString, vaultSelected, bypassSelectionNote, bypassSelectionNoteValue, journalRegex, shouldDebug);
|
||||||
|
|||||||
Reference in new issue
Block a user