cli-todo-tool
v1.1.1
Published
CLI todo tool that helps you manage your daily tasks
Maintainers
Readme
Description
CLI todo tool that helps you manage your daily tasks
Installation
npm install -g cli-todo-toolUsage
Keyword: todo <command> <arguments>
Commands:
* create-todo Creates a new todo with name, description, severity and due date
-n, --name [required]
-d, --desc, --describe, --description [required]
-s, --sev, --severity [required] [choices: "low" | "medium" | "high"]
--dd, --due, --dueDate [required] [format: dd/mm/yyyy]
* complete-todo Marks the given todo as completed
-n, -t, --name, --todoName [required]
* cancel-todo Marks the given todo as canceled
-n, -t, --name, --todoName [required]
* update-severity Updates the severity of the given todo
-n, -t, --name, --todoName [required]
-s, --sev, --severity [required] [choices: "low" | "medium" | "high"]
* update-due-date Updates the due date of the given todo
-n, -t, --name, --todoName [required]
--dd, --due, --dueDate [required] [format: dd/mm/yyyy]
* delete-todo Deletes the given todo
-n, -t, --name, --todoName [required]
* group-todo Adds the given todo to a given group
-n, --todo, --todoName [required]
-n, --group, --groupName [required]
* create-group Creates a new group with the given name
-n, -g, --name, --groupName [required]
* complete-group Marks all the todos from the given group as completed
-n, -g, --name, --groupName [required]
* cancel-group Marks all the todos from the given group as canceled
-n, -g, --name, --groupName [required]
* delete-group Deletes all the todos from the given group
-n, -g, --name, --groupName [required]
* create-bulk Uploads all the data from the .json file in the todo list
-p, --path [required]
* list [option] Lists all or filtered todos
-t, --todo, --todoName [optional] [string]
-g, --group, --groupName [optional] [string]
-s, --sev, --severity [optional] [choices: "low" | "medium" | "high"]
-b, --before, --beforeDate, --beforeDue [optional] [format: dd/mm/yyyy]
-a, --after, --afterDate, --afterDue [optional] [format: dd/mm/yyyy]
--compl, --completed [optional] [boolean]
--canc, --canceled [optional] [boolean]
* start-server Http server starts listening on port 8000Bulk
A valid bulk file has to be a JSON format with the following data hierarchy:
{
"todos": Todo[],
"groups": string[]
}
____________________________________________
type Severity = "low" | "medium" | "high";
interface Todo {
name: string;
desc: string;
sev: Severity;
dueDate: number;
completed: boolean;
canceled: boolean;
group?: string;
}Server
Exposes the same functionalities as the CLI commands. Listens on port 8000.
| Request | Name | Body | Query Params | | :------ | :--------------- | :--------------------------------------------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | GET | /list | N / A | completed [boolean], canceled [boolean], severity [string] [choices: "low", "medium", "high"], before [string] [dd/mm/yyy], after [string] [dd/mm/yyyy], groupName [string], todoName [string] | | POST | /create-todo | name [string], desc [string], sev [string] [choices: "low", "medium", "high"], dueDate [string] [dd/mm/yyyy] | N / A | | POST | /create-group | name [string] | N / A | | PUT | /complete-todo | name [string] | N / A | | PUT | /cancel-todo | name [string] | N / A | | PUT | /update-severity | todoName [string], severity[string] [choices: "low", "medium", "high"] | N / A | | PUT | /update-due-date | todoName [string], newDueDate[string] [dd/mm/yyyy] | N / A | | PUT | /group-todo | todoName [string], groupName[string] | N / A | | PUT | /complete-group | name [string] | N / A | | PUT | /cancel-group | name [string] | N / A | | DELETE | /delete-todo | N / A | name [string] | | DELETE | /delete-group | N / A | name [string] |
