nitor 1.2.0 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -1
- package/README.md +62 -1
- package/package.json +1 -1
- package/services/utils.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -23,4 +23,10 @@ For a complete list of changes and discussion, see [Issue #1](https://github.com
|
|
|
23
23
|
|
|
24
24
|
- Added cleanup command to delete all local branches except master/main.
|
|
25
25
|
|
|
26
|
-
|
|
26
|
+
## [1.2.1] - 2025-11-19
|
|
27
|
+
|
|
28
|
+
### New Features
|
|
29
|
+
|
|
30
|
+
- Added time entry commands.
|
|
31
|
+
|
|
32
|
+
- [Issue #5](https://github.com/codebynithin/nitor/issues/5)
|
package/README.md
CHANGED
|
@@ -24,6 +24,8 @@ A CLI utility toolkit for automating and managing build, deploy, and status oper
|
|
|
24
24
|
- Backup and restore MongoDB
|
|
25
25
|
- Merge git branches
|
|
26
26
|
- Cleanup local git branches
|
|
27
|
+
- Time entry management with Zoho integration
|
|
28
|
+
- GitLab activity tracking
|
|
27
29
|
|
|
28
30
|
## Requirements
|
|
29
31
|
|
|
@@ -32,7 +34,7 @@ A CLI utility toolkit for automating and managing build, deploy, and status oper
|
|
|
32
34
|
- A properly configured `.env.nu` file in your `~/Desktop` directory with required tokens and URLs:
|
|
33
35
|
- `CSRF_TOKEN` - CSRF token for Gitlab (Copy from browser)
|
|
34
36
|
- `COOKIE` - Cookie for Gitlab (Copy from browser)
|
|
35
|
-
- `
|
|
37
|
+
- `GITLAB_URI` - GitLab API URL, eg: `https://gitlab.com/`
|
|
36
38
|
- `GITLAB_TOKEN` - Gitlab token
|
|
37
39
|
- `MR_PROMPT` - Merge request prompt
|
|
38
40
|
- `MR_LANG` - Merge request language
|
|
@@ -40,6 +42,17 @@ A CLI utility toolkit for automating and managing build, deploy, and status oper
|
|
|
40
42
|
- `AI_MODEL` - AI model
|
|
41
43
|
- `BACKUP_CONFIG` - Backup configuration
|
|
42
44
|
- `RESTORE_CONFIG` - Restore configuration
|
|
45
|
+
- `ZOHO_COOKIE` - Zoho cookie for authentication
|
|
46
|
+
- `ZOHO_CUSTOMVIEW_ID` - Zoho custom view ID
|
|
47
|
+
- `ZOHO_DEFAULt_PROJECT_ID` - Default Zoho project ID
|
|
48
|
+
- `ZOHO_PORTAL_ID` - Zoho portal ID
|
|
49
|
+
- `ZOHO_PROJECTS` - Zoho projects configuration
|
|
50
|
+
- `ZOHO_SESSION_ID` - Zoho session ID
|
|
51
|
+
- `ZOHO_SOURCE` - Zoho source
|
|
52
|
+
- `ZOHO_TEAM` - Zoho team ID
|
|
53
|
+
- `ZOHO_TOKEN` - Zoho CSRF token
|
|
54
|
+
- `ZOHO_URI` - Zoho API URL
|
|
55
|
+
- `ZOHO_USERID` - Zoho user ID
|
|
43
56
|
|
|
44
57
|
## Installation
|
|
45
58
|
|
|
@@ -114,6 +127,34 @@ Once enabled, you can use Tab to autocomplete:
|
|
|
114
127
|
```bash
|
|
115
128
|
nitor cleanup
|
|
116
129
|
```
|
|
130
|
+
- **Time Entry - Initialize:**
|
|
131
|
+
```bash
|
|
132
|
+
nitor time-init
|
|
133
|
+
```
|
|
134
|
+
- **Time Entry - Add:**
|
|
135
|
+
```bash
|
|
136
|
+
nitor time-add -project <project name> -sprint <sprint name> -task <task id> -date <YYYY-MM-DD> -work <work description> -duration <minutes> -remarks <remarks>
|
|
137
|
+
```
|
|
138
|
+
- **Time Entry - Update:**
|
|
139
|
+
```bash
|
|
140
|
+
nitor time-update -id <entry id> -task <task id> -work <work description> -duration <minutes> -remarks <remarks> -date <YYYY-MM-DD>
|
|
141
|
+
```
|
|
142
|
+
- **Time Entry - Delete:**
|
|
143
|
+
```bash
|
|
144
|
+
nitor time-delete -id <entry id> -date <YYYY-MM-DD>
|
|
145
|
+
```
|
|
146
|
+
- **Time Entry - View Entries:**
|
|
147
|
+
```bash
|
|
148
|
+
nitor time-entries -from <YYYY-MM-DD> -to <YYYY-MM-DD>
|
|
149
|
+
```
|
|
150
|
+
- **Time Entry - View Stats:**
|
|
151
|
+
```bash
|
|
152
|
+
nitor time-stats -from <YYYY-MM-DD> -to <YYYY-MM-DD>
|
|
153
|
+
```
|
|
154
|
+
- **Time Entry - Sync to Zoho:**
|
|
155
|
+
```bash
|
|
156
|
+
nitor time-zoho
|
|
157
|
+
```
|
|
117
158
|
|
|
118
159
|
### Command Reference
|
|
119
160
|
|
|
@@ -130,6 +171,13 @@ Once enabled, you can use Tab to autocomplete:
|
|
|
130
171
|
- `restore` : Restore specified projects
|
|
131
172
|
- `merge` : Merge source branch into target branch
|
|
132
173
|
- `cleanup` : Cleanup local git branches (checkout to master and delete all other branches)
|
|
174
|
+
- `time-init` : Initialize time entry configuration
|
|
175
|
+
- `time-add` : Add time entry with support for multiple tags
|
|
176
|
+
- `time-update` : Update existing time entry
|
|
177
|
+
- `time-delete` : Delete time entry
|
|
178
|
+
- `time-entries` : View time entries by date range
|
|
179
|
+
- `time-stats` : View daily statistics of time entries
|
|
180
|
+
- `time-zoho` : Sync time entries to Zoho
|
|
133
181
|
|
|
134
182
|
### Options
|
|
135
183
|
|
|
@@ -145,6 +193,19 @@ Once enabled, you can use Tab to autocomplete:
|
|
|
145
193
|
- `-source` or `-so` : Source branch name
|
|
146
194
|
- `-target` or `-ta` : Target branch name
|
|
147
195
|
|
|
196
|
+
#### Time Entry Options
|
|
197
|
+
|
|
198
|
+
- `-project` or `-p` : Project name
|
|
199
|
+
- `-sprint` or `-s` : Sprint name (e.g., "sprint 1")
|
|
200
|
+
- `-task` or `-t` : Task ID
|
|
201
|
+
- `-date` or `-dt` : Date in YYYY-MM-DD format
|
|
202
|
+
- `-work` or `-w` : Work description (supports multiple tags)
|
|
203
|
+
- `-duration` or `-du` : Duration in minutes
|
|
204
|
+
- `-remarks` or `-r` : Additional remarks
|
|
205
|
+
- `-id` or `-i` : Entry ID (for update/delete operations)
|
|
206
|
+
- `-from` or `-f` : Start date for filtering
|
|
207
|
+
- `-to` or `-t` : End date for filtering
|
|
208
|
+
|
|
148
209
|
## License
|
|
149
210
|
|
|
150
211
|
ISC
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nitor",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.2",
|
|
4
4
|
"description": "A comprehensive CLI toolkit for automating GitLab operations, AI-powered code review, build/deploy automation, MongoDB backup/restore, and developer productivity tools",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"author": "Nithin V <mails2nithin@gmail.com>",
|
package/services/utils.js
CHANGED
|
@@ -12,7 +12,7 @@ const openAIModel = process.env.AI_MODEL;
|
|
|
12
12
|
const backupConfig = process.env.BACKUP_CONFIG && JSON.parse(process.env.BACKUP_CONFIG);
|
|
13
13
|
const restoreConfig = process.env.RESTORE_CONFIG && JSON.parse(process.env.RESTORE_CONFIG);
|
|
14
14
|
const gitlabConfig = {
|
|
15
|
-
url: process.env.
|
|
15
|
+
url: process.env.GITLAB_URI,
|
|
16
16
|
cookie: process.env.GITLAB_COOKIE,
|
|
17
17
|
xCsrfToken: process.env.GITLAB_XCSRF_TOKEN,
|
|
18
18
|
userId: process.env.GITLAB_USERID,
|