toggl-pilot
v0.10.0
Published
Unofficial CLI for Toggl Track time management
Downloads
815
Maintainers
Readme
toggl-pilot
Unofficial CLI for Toggl Track time management, using the Toggl Track API v9.
Track your time from the terminal — start/stop timers, log entries, list projects and tags, edit and delete entries.
Install
npm install -g toggl-pilotQuick Start
tgp auth <your-api-token>
tgp me
tgp track "Working on feature" -p "My Project"
tgp stop
tgp entry-listGet your API token from your Toggl Profile (scroll to API Token section).
Running tgp auth saves your token so you don't need to pass it every time.
You can also set the TOGGL_API_TOKEN environment variable, which takes
priority over the saved config.
Run tgp without arguments to see all available commands.
Commands
General
| Command | Description | Docs |
| -------------------- | --------------------- | ------------------------------------------------ |
| tgp auth <token> | Save API token | |
| tgp version | Show CLI version | |
| tgp me | Verify authentication | docs/me.md |
| tgp workspace-list | List workspaces | docs/workspace-list.md |
Entries
| Command | Description | Docs |
| --------------------------------------- | --------------------------- | -------------------------------------------- |
| tgp entry-list | List time entries for a day | docs/entry-list.md |
| tgp track "Desc" -p "Project" -t tags | Start a timer or log time | docs/track.md |
| tgp stop | Stop running timer | docs/stop.md |
| tgp resume | Resume last stopped timer | docs/resume.md |
| tgp entry-edit <id> -d/-p/-t/--dur | Edit a time entry | docs/entry-edit.md |
| tgp week | Weekly summary by project | docs/week.md |
| tgp entry-delete <id> | Delete a time entry | docs/entry-delete.md |
Clients
| Command | Description | Docs |
| ----------------- | ---------------------- | ------------------------------------------ |
| tgp client-list | List workspace clients | docs/client-list.md |
Projects
| Command | Description | Docs |
| ------------------------------------- | ----------------------- | -------------------------------------------------- |
| tgp project-list | List workspace projects | docs/project-list.md |
| tgp project-create | Create a project | docs/project-create.md |
| tgp project-edit <project> | Edit a project | docs/project-edit.md |
| tgp project-rename <project> <name> | Rename a project | docs/project-rename.md |
| tgp project-delete <project> | Delete a project | docs/project-delete.md |
| tgp project-archive <project> | Archive a project | docs/project-archive.md |
| tgp project-restore <project> | Restore a project | docs/project-restore.md |
Tags
| Command | Description | Docs |
| -------------------------------- | ------------ | ---------------------------------------- |
| tgp tag-list | List tags | docs/tag-list.md |
| tgp tag-create "Tag Name" | Create a tag | docs/tag-create.md |
| tgp tag-rename <id> "New Name" | Rename a tag | docs/tag-rename.md |
| tgp tag-delete <id> | Delete a tag | docs/tag-delete.md |
Configuration
Run tgp auth <token> to save your API token to
~/.config/tgp/config.env (macOS/Linux) or
%APPDATA%\tgp\config.env (Windows).
You can also set environment variables, which take priority over the config file:
| Variable | Required | Description |
| -------------------- | -------- | ---------------------------------- |
| TOGGL_API_TOKEN | Yes | Your Toggl Track API token |
| TOGGL_WORKSPACE_ID | No | Defaults to your primary workspace |
License
MIT · Made by Stefano Locati
