NoteMgr CLI is a lightweight command-line tool for managing personal notes. It allows you to create, tag, view, search, and sync Markdown-based notes with GitHub Gists, all from your terminal. Ideal for developers and knowledge workers, NoteMgr is modular, efficient, and easy to customize.
- Create and Organize Notes: Quickly add and tag notes in Markdown format.
- View Notes with Markdown Rendering: Display notes in a terminal-friendly Markdown format.
- Search Notes: Find notes by keywords or tags.
- Sync with GitHub Gists: Automatically back up and update notes to GitHub, with options for public or private gists.
- Real-Time Sync: Watch for changes in your notes directory and sync updates automatically.
- Configurable: Customize privacy, notifications, and GitHub token settings via
config.json
.
- Node.js (v14 or later)
- A GitHub account and personal access token with
gist
permissions
-
Clone the repository:
git clone https://github.com/austinwdigital/notemgr-cli.git cd notemgr-cli
-
Install dependencies:
npm install
-
Install globally:
npm install -g .
-
Set up
config.json
:cp config.example.json config.json
Update
config.json
with your GitHub personal access token and preferences.
notemgr <command> [options]
Command | Description |
---|---|
add <title> <content> |
Add a new note with a title and content. |
list / ls |
List all notes in the notes/ directory. |
tag <title> <tags...> |
Add tags to an existing note. |
search <keyword> |
Search for notes by a keyword or tag. |
view <title> |
Display a note with basic Markdown rendering. |
backup <title> [--private] |
Backup a note to GitHub Gists. Add --private to create a private gist. |
sync |
Watch for changes in the notes/ directory and sync updates to GitHub Gists. |
notemgr add "Meeting Notes" "Discussed project roadmap and deadlines."
notemgr tag "Meeting Notes" "work" "roadmap" "2024"
notemgr search "roadmap"
notemgr view "Meeting Notes"
notemgr backup "Meeting Notes" --private
notemgr sync
All settings are managed in the config.json
file:
Field | Description |
---|---|
githubToken |
Your GitHub personal access token with gist permissions. |
defaultPrivacy |
Set default privacy for gists (public or private ). |
notificationsEnabled |
Enable or disable notifications (true or false ). |
Example config.json
:
{
"githubToken": "YOUR_GITHUB_TOKEN",
"defaultPrivacy": "public",
"notificationsEnabled": true
}
All activity is logged in notemgr.log
:
- INFO: Successful operations (e.g., commands executed, notes backed up).
- WARNING: Non-critical issues (e.g., no notes found).
- ERROR: Critical errors (e.g., failed backups).
-
Clone the repository:
git clone https://github.com/your-username/notemgr-cli.git cd notemgr-cli
-
Install dependencies:
npm install
-
Run locally:
node notemgr.js <command> [options]
Tests can be added here if applicable.
This project was created by @austinwdigital.
Contributions are welcome! Please follow these steps:
-
Fork the repository.
-
Create a feature branch:
git checkout -b feature/new-feature
-
Commit your changes:
git commit -m "Add new feature"
-
Push to your branch:
git push origin feature/new-feature
-
Submit a pull request.
This project is licensed under the MIT License.
- Inspired by the need for efficient personal knowledge management.
- Thanks to the open-source community for providing tools and libraries.