A fast, terminal-based task manager that syncs with your Todoist account. Manage your tasks efficiently without leaving the command line.
(This is a WIP, but it works. Feel free to contribute!)
- π Create, edit, and delete tasks
- β Mark tasks as complete
- π Sync with Todoist API
- πΎ Local SQLite cache for offline access
- β¨οΈ Vim-style keyboard shortcuts
- π¨ Clean terminal UI powered by Ratatui
- Rust 1.90.0 or later
- A Todoist account
- Your Todoist API token
To use this application, you'll need a Todoist API token:
-
Visit the Todoist Developer Settings
- Go to Todoist Integrations Settings
- Or navigate manually: Todoist β Settings β Integrations β Developer
-
Find Your API Token
- Scroll to the "API token" section
- Your token will be displayed (it looks like a long string of letters and numbers)
-
Copy Your Token
- Click the "Copy API token" button or select and copy the token manually
- Keep this token secure - it provides full access to your Todoist data
For more information about the Todoist API, visit the official API documentation.
- Clone the repository:
git clone https://github.com/yourusername/todoist-cli.git
cd todoist-cli
- Build the project:
cargo build --release
-
Set up your API token:
Export your Todoist API token as an environment variable:
Linux/macOS:
export TODOIST_TOKEN="your_api_token_here"
Windows (PowerShell):
$env:TODOIST_TOKEN="your_api_token_here"
Windows (Command Prompt):
set TODOIST_TOKEN=your_api_token_here
Tip: To make this permanent, add the export command to your shell's configuration file (
~/.bashrc
,~/.zshrc
, etc.) or use Windows environment variable settings.
Run the application without arguments to launch the interactive terminal interface:
cargo run
Or using the compiled binary:
./target/release/todoist-cli
Normal Mode:
j
/β
- Move downk
/β
- Move upa
- Add new taski
- Edit selected taskd
- Delete selected taskt
- Toggle task completion (mark as done)q
- Quit application
Insert Mode (Add/Edit):
- Type to enter task title
Enter
- Save taskEsc
- Cancel and return to normal modeBackspace
- Delete character
You can also use the CLI directly for quick operations:
Add a task:
cargo run -- add "Buy groceries"
Update a task:
cargo run -- update 1 "Buy groceries and cook dinner" true
Delete a task:
cargo run -- delete 1
- Sync on Startup: The app fetches your tasks from Todoist when launched
- Local Cache: Tasks are cached in a local SQLite database (
tasks.db
) - Real-time Updates: All changes are immediately synced with Todoist
- Offline Support: View cached tasks even without internet connection
todoist-cli/
βββ src/
β βββ api/ # Todoist API client
β βββ cli/ # Command-line interface
β βββ controller/ # Application state management
β βββ db/ # SQLite cache
β βββ models/ # Data structures
β βββ utils/ # Helper functions
β βββ main.rs # Entry point
βββ Cargo.toml
βββ README.md
"TODOIST_TOKEN env var required" error:
- Make sure you've set the
TODOIST_TOKEN
environment variable - Verify the token is correct by checking your Todoist settings
Tasks not syncing:
- Check your internet connection
- Verify your API token is still valid
- Check the Todoist API status page
Build errors:
- Ensure you're using Rust 1.90.0 or later:
rustc --version
- Try cleaning the build:
cargo clean && cargo build
This project is licensed under the MIT License - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.
- Built with Ratatui for the terminal UI
- Uses the Todoist REST API v1
- Inspired by the need for a fast, keyboard-driven task manager
Not associated with Todoist in any way.