@internxt/cli 1.6.7 → 1.6.8
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/README.md +36 -231
- package/dist/commands/create-folder.js +2 -6
- package/dist/commands/delete-permanently-file.js +1 -1
- package/dist/commands/delete-permanently-folder.js +1 -1
- package/dist/commands/download-file.js +3 -3
- package/dist/commands/list.d.ts +2 -0
- package/dist/commands/list.js +1 -1
- package/dist/commands/login.d.ts +0 -1
- package/dist/commands/login.js +1 -11
- package/dist/commands/move-file.d.ts +1 -0
- package/dist/commands/move-file.js +1 -1
- package/dist/commands/move-folder.js +1 -1
- package/dist/commands/rename-file.js +1 -1
- package/dist/commands/rename-folder.js +1 -1
- package/dist/commands/trash-file.js +1 -1
- package/dist/commands/trash-folder.js +1 -1
- package/dist/commands/trash-list.d.ts +2 -0
- package/dist/commands/trash-restore-file.d.ts +1 -0
- package/dist/commands/trash-restore-file.js +1 -1
- package/dist/commands/trash-restore-folder.js +1 -1
- package/dist/commands/upload-file.d.ts +1 -0
- package/dist/commands/upload-file.js +22 -13
- package/dist/hooks/prerun/auth_check.js +2 -2
- package/dist/services/auth.service.d.ts +3 -3
- package/dist/services/auth.service.js +30 -40
- package/dist/services/crypto.service.d.ts +0 -4
- package/dist/services/crypto.service.js +1 -32
- package/dist/services/database/drive-item/drive-item.model.js +1 -0
- package/dist/services/database/drive-item/drive-item.repository.js +12 -2
- package/dist/services/drive/drive-file.service.d.ts +2 -0
- package/dist/services/drive/drive-file.service.js +48 -18
- package/dist/services/drive/drive-folder.service.d.ts +2 -0
- package/dist/services/drive/drive-folder.service.js +14 -46
- package/dist/services/drive/trash.service.d.ts +2 -0
- package/dist/services/drive/trash.service.js +14 -41
- package/dist/services/network/upload/upload-file.service.js +5 -9
- package/dist/services/network/upload/upload.types.d.ts +2 -1
- package/dist/services/sdk-manager.service.d.ts +0 -2
- package/dist/services/sdk-manager.service.js +0 -7
- package/dist/services/thumbnail.service.d.ts +4 -13
- package/dist/services/thumbnail.service.js +7 -21
- package/dist/services/universal-link.service.d.ts +1 -1
- package/dist/services/universal-link.service.js +2 -2
- package/dist/services/validation.service.d.ts +1 -1
- package/dist/services/validation.service.js +3 -2
- package/dist/types/command.types.d.ts +0 -29
- package/dist/types/command.types.js +1 -15
- package/dist/types/network.types.d.ts +3 -11
- package/dist/types/webdav.types.d.ts +0 -3
- package/dist/utils/cli.utils.js +9 -22
- package/dist/utils/logger.utils.js +9 -2
- package/dist/utils/stream.utils.d.ts +2 -2
- package/dist/utils/stream.utils.js +7 -6
- package/dist/utils/thumbnail.utils.d.ts +1 -3
- package/dist/utils/thumbnail.utils.js +3 -13
- package/dist/utils/upload.utils.d.ts +1 -1
- package/dist/utils/upload.utils.js +2 -2
- package/dist/utils/webdav.utils.d.ts +2 -0
- package/dist/utils/webdav.utils.js +16 -0
- package/dist/webdav/handlers/GET.handler.js +3 -2
- package/dist/webdav/handlers/HEAD.handler.js +1 -0
- package/dist/webdav/handlers/PROPFIND.handler.js +3 -4
- package/dist/webdav/handlers/PUT.handler.js +24 -10
- package/dist/webdav/index.js +2 -2
- package/dist/webdav/middewares/auth.middleware.js +1 -1
- package/dist/webdav/middewares/errors.middleware.js +29 -5
- package/oclif.manifest.json +9 -198
- package/package.json +18 -17
- package/dist/commands/workspaces-list.d.ts +0 -20
- package/dist/commands/workspaces-list.js +0 -68
- package/dist/commands/workspaces-unset.d.ts +0 -23
- package/dist/commands/workspaces-unset.js +0 -46
- package/dist/commands/workspaces-use.d.ts +0 -27
- package/dist/commands/workspaces-use.js +0 -114
- package/dist/services/drive/workspace.service.d.ts +0 -7
- package/dist/services/drive/workspace.service.js +0 -30
package/README.md
CHANGED
|
@@ -52,7 +52,7 @@ $ npm install -g @internxt/cli
|
|
|
52
52
|
$ internxt COMMAND
|
|
53
53
|
running command...
|
|
54
54
|
$ internxt (--version)
|
|
55
|
-
@internxt/cli/1.6.
|
|
55
|
+
@internxt/cli/1.6.8 linux-x64 node-v22.23.2
|
|
56
56
|
$ internxt --help [COMMAND]
|
|
57
57
|
USAGE
|
|
58
58
|
$ internxt COMMAND
|
|
@@ -111,12 +111,6 @@ USAGE
|
|
|
111
111
|
* [`internxt webdav ACTION`](#internxt-webdav-action)
|
|
112
112
|
* [`internxt webdav-config`](#internxt-webdav-config)
|
|
113
113
|
* [`internxt whoami`](#internxt-whoami)
|
|
114
|
-
* [`internxt workspaces-list`](#internxt-workspaces-list)
|
|
115
|
-
* [`internxt workspaces-unset`](#internxt-workspaces-unset)
|
|
116
|
-
* [`internxt workspaces-use`](#internxt-workspaces-use)
|
|
117
|
-
* [`internxt workspaces list`](#internxt-workspaces-list)
|
|
118
|
-
* [`internxt workspaces unset`](#internxt-workspaces-unset)
|
|
119
|
-
* [`internxt workspaces use`](#internxt-workspaces-use)
|
|
120
114
|
|
|
121
115
|
## `internxt add-cert`
|
|
122
116
|
|
|
@@ -145,7 +139,7 @@ EXAMPLES
|
|
|
145
139
|
$ internxt add-cert
|
|
146
140
|
```
|
|
147
141
|
|
|
148
|
-
_See code: [src/commands/add-cert.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
142
|
+
_See code: [src/commands/add-cert.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/add-cert.ts)_
|
|
149
143
|
|
|
150
144
|
## `internxt add cert`
|
|
151
145
|
|
|
@@ -203,7 +197,7 @@ EXAMPLES
|
|
|
203
197
|
$ internxt autocomplete --refresh-cache
|
|
204
198
|
```
|
|
205
199
|
|
|
206
|
-
_See code: [@oclif/plugin-autocomplete](https://github.com/oclif/plugin-autocomplete/blob/v3.2.
|
|
200
|
+
_See code: [@oclif/plugin-autocomplete](https://github.com/oclif/plugin-autocomplete/blob/v3.2.56/src/commands/autocomplete/index.ts)_
|
|
207
201
|
|
|
208
202
|
## `internxt config`
|
|
209
203
|
|
|
@@ -232,7 +226,7 @@ EXAMPLES
|
|
|
232
226
|
$ internxt config
|
|
233
227
|
```
|
|
234
228
|
|
|
235
|
-
_See code: [src/commands/config.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
229
|
+
_See code: [src/commands/config.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/config.ts)_
|
|
236
230
|
|
|
237
231
|
## `internxt create-folder`
|
|
238
232
|
|
|
@@ -266,7 +260,7 @@ EXAMPLES
|
|
|
266
260
|
$ internxt create-folder
|
|
267
261
|
```
|
|
268
262
|
|
|
269
|
-
_See code: [src/commands/create-folder.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
263
|
+
_See code: [src/commands/create-folder.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/create-folder.ts)_
|
|
270
264
|
|
|
271
265
|
## `internxt create folder`
|
|
272
266
|
|
|
@@ -330,7 +324,7 @@ EXAMPLES
|
|
|
330
324
|
$ internxt delete-permanently-file
|
|
331
325
|
```
|
|
332
326
|
|
|
333
|
-
_See code: [src/commands/delete-permanently-file.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
327
|
+
_See code: [src/commands/delete-permanently-file.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/delete-permanently-file.ts)_
|
|
334
328
|
|
|
335
329
|
## `internxt delete-permanently-folder`
|
|
336
330
|
|
|
@@ -362,7 +356,7 @@ EXAMPLES
|
|
|
362
356
|
$ internxt delete-permanently-folder
|
|
363
357
|
```
|
|
364
358
|
|
|
365
|
-
_See code: [src/commands/delete-permanently-folder.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
359
|
+
_See code: [src/commands/delete-permanently-folder.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/delete-permanently-folder.ts)_
|
|
366
360
|
|
|
367
361
|
## `internxt delete permanently file`
|
|
368
362
|
|
|
@@ -457,7 +451,7 @@ EXAMPLES
|
|
|
457
451
|
$ internxt download-file
|
|
458
452
|
```
|
|
459
453
|
|
|
460
|
-
_See code: [src/commands/download-file.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
454
|
+
_See code: [src/commands/download-file.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/download-file.ts)_
|
|
461
455
|
|
|
462
456
|
## `internxt download file`
|
|
463
457
|
|
|
@@ -520,7 +514,7 @@ EXAMPLES
|
|
|
520
514
|
$ internxt list
|
|
521
515
|
```
|
|
522
516
|
|
|
523
|
-
_See code: [src/commands/list.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
517
|
+
_See code: [src/commands/list.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/list.ts)_
|
|
524
518
|
|
|
525
519
|
## `internxt login`
|
|
526
520
|
|
|
@@ -528,12 +522,9 @@ Logs into your Internxt account using the web-based login flow. A temporary loca
|
|
|
528
522
|
|
|
529
523
|
```
|
|
530
524
|
USAGE
|
|
531
|
-
$ internxt login [--json] [-x] [--debug] [-
|
|
525
|
+
$ internxt login [--json] [-x] [--debug] [-p <value>]
|
|
532
526
|
|
|
533
527
|
FLAGS
|
|
534
|
-
-h, --host=<value> [env: INXT_LOGIN_SERVER_HOST] IP address of the machine where the CLI is running. If you are
|
|
535
|
-
opening the login page in a browser on another device, set this to the IP address of the machine
|
|
536
|
-
running the CLI. Defaults to 127.0.0.1.
|
|
537
528
|
-p, --port=<value> [env: INXT_LOGIN_SERVER_PORT] Port used by the temporary local server to handle the login
|
|
538
529
|
callback. If not specified, a random available port will be used automatically.
|
|
539
530
|
|
|
@@ -554,7 +545,7 @@ EXAMPLES
|
|
|
554
545
|
$ internxt login
|
|
555
546
|
```
|
|
556
547
|
|
|
557
|
-
_See code: [src/commands/login.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
548
|
+
_See code: [src/commands/login.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/login.ts)_
|
|
558
549
|
|
|
559
550
|
## `internxt login-legacy`
|
|
560
551
|
|
|
@@ -588,7 +579,7 @@ EXAMPLES
|
|
|
588
579
|
$ internxt login-legacy
|
|
589
580
|
```
|
|
590
581
|
|
|
591
|
-
_See code: [src/commands/login-legacy.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
582
|
+
_See code: [src/commands/login-legacy.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/login-legacy.ts)_
|
|
592
583
|
|
|
593
584
|
## `internxt logout`
|
|
594
585
|
|
|
@@ -614,7 +605,7 @@ EXAMPLES
|
|
|
614
605
|
$ internxt logout
|
|
615
606
|
```
|
|
616
607
|
|
|
617
|
-
_See code: [src/commands/logout.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
608
|
+
_See code: [src/commands/logout.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/logout.ts)_
|
|
618
609
|
|
|
619
610
|
## `internxt logs`
|
|
620
611
|
|
|
@@ -640,7 +631,7 @@ EXAMPLES
|
|
|
640
631
|
$ internxt logs
|
|
641
632
|
```
|
|
642
633
|
|
|
643
|
-
_See code: [src/commands/logs.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
634
|
+
_See code: [src/commands/logs.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/logs.ts)_
|
|
644
635
|
|
|
645
636
|
## `internxt move-file`
|
|
646
637
|
|
|
@@ -674,7 +665,7 @@ EXAMPLES
|
|
|
674
665
|
$ internxt move-file
|
|
675
666
|
```
|
|
676
667
|
|
|
677
|
-
_See code: [src/commands/move-file.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
668
|
+
_See code: [src/commands/move-file.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/move-file.ts)_
|
|
678
669
|
|
|
679
670
|
## `internxt move-folder`
|
|
680
671
|
|
|
@@ -708,7 +699,7 @@ EXAMPLES
|
|
|
708
699
|
$ internxt move-folder
|
|
709
700
|
```
|
|
710
701
|
|
|
711
|
-
_See code: [src/commands/move-folder.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
702
|
+
_See code: [src/commands/move-folder.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/move-folder.ts)_
|
|
712
703
|
|
|
713
704
|
## `internxt move file`
|
|
714
705
|
|
|
@@ -805,7 +796,7 @@ EXAMPLES
|
|
|
805
796
|
$ internxt rename-file
|
|
806
797
|
```
|
|
807
798
|
|
|
808
|
-
_See code: [src/commands/rename-file.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
799
|
+
_See code: [src/commands/rename-file.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/rename-file.ts)_
|
|
809
800
|
|
|
810
801
|
## `internxt rename-folder`
|
|
811
802
|
|
|
@@ -838,7 +829,7 @@ EXAMPLES
|
|
|
838
829
|
$ internxt rename-folder
|
|
839
830
|
```
|
|
840
831
|
|
|
841
|
-
_See code: [src/commands/rename-folder.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
832
|
+
_See code: [src/commands/rename-folder.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/rename-folder.ts)_
|
|
842
833
|
|
|
843
834
|
## `internxt rename file`
|
|
844
835
|
|
|
@@ -932,7 +923,7 @@ EXAMPLES
|
|
|
932
923
|
$ internxt trash-clear
|
|
933
924
|
```
|
|
934
925
|
|
|
935
|
-
_See code: [src/commands/trash-clear.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
926
|
+
_See code: [src/commands/trash-clear.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/trash-clear.ts)_
|
|
936
927
|
|
|
937
928
|
## `internxt trash-file`
|
|
938
929
|
|
|
@@ -964,7 +955,7 @@ EXAMPLES
|
|
|
964
955
|
$ internxt trash-file
|
|
965
956
|
```
|
|
966
957
|
|
|
967
|
-
_See code: [src/commands/trash-file.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
958
|
+
_See code: [src/commands/trash-file.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/trash-file.ts)_
|
|
968
959
|
|
|
969
960
|
## `internxt trash-folder`
|
|
970
961
|
|
|
@@ -996,7 +987,7 @@ EXAMPLES
|
|
|
996
987
|
$ internxt trash-folder
|
|
997
988
|
```
|
|
998
989
|
|
|
999
|
-
_See code: [src/commands/trash-folder.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
990
|
+
_See code: [src/commands/trash-folder.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/trash-folder.ts)_
|
|
1000
991
|
|
|
1001
992
|
## `internxt trash-list`
|
|
1002
993
|
|
|
@@ -1028,7 +1019,7 @@ EXAMPLES
|
|
|
1028
1019
|
$ internxt trash-list
|
|
1029
1020
|
```
|
|
1030
1021
|
|
|
1031
|
-
_See code: [src/commands/trash-list.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1022
|
+
_See code: [src/commands/trash-list.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/trash-list.ts)_
|
|
1032
1023
|
|
|
1033
1024
|
## `internxt trash-restore-file`
|
|
1034
1025
|
|
|
@@ -1061,7 +1052,7 @@ EXAMPLES
|
|
|
1061
1052
|
$ internxt trash-restore-file
|
|
1062
1053
|
```
|
|
1063
1054
|
|
|
1064
|
-
_See code: [src/commands/trash-restore-file.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1055
|
+
_See code: [src/commands/trash-restore-file.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/trash-restore-file.ts)_
|
|
1065
1056
|
|
|
1066
1057
|
## `internxt trash-restore-folder`
|
|
1067
1058
|
|
|
@@ -1094,7 +1085,7 @@ EXAMPLES
|
|
|
1094
1085
|
$ internxt trash-restore-folder
|
|
1095
1086
|
```
|
|
1096
1087
|
|
|
1097
|
-
_See code: [src/commands/trash-restore-folder.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1088
|
+
_See code: [src/commands/trash-restore-folder.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/trash-restore-folder.ts)_
|
|
1098
1089
|
|
|
1099
1090
|
## `internxt trash clear`
|
|
1100
1091
|
|
|
@@ -1284,11 +1275,13 @@ Upload a file to Internxt Drive
|
|
|
1284
1275
|
|
|
1285
1276
|
```
|
|
1286
1277
|
USAGE
|
|
1287
|
-
$ internxt upload-file [--json] [-x] [--debug] [-f <value>] [-i <value>]
|
|
1278
|
+
$ internxt upload-file [--json] [-x] [--debug] [-f <value>] [-i <value>] [-o]
|
|
1288
1279
|
|
|
1289
1280
|
FLAGS
|
|
1290
1281
|
-f, --file=<value> The path to the file on your system.
|
|
1291
1282
|
-i, --destination=<value> The folder id where the file is going to be uploaded to. Leave empty for the root folder.
|
|
1283
|
+
-o, --overwrite Overwrite the file if a file with the same name already exists in the cloud destination
|
|
1284
|
+
folder.
|
|
1292
1285
|
|
|
1293
1286
|
HELPER FLAGS
|
|
1294
1287
|
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
@@ -1309,7 +1302,7 @@ EXAMPLES
|
|
|
1309
1302
|
$ internxt upload-file
|
|
1310
1303
|
```
|
|
1311
1304
|
|
|
1312
|
-
_See code: [src/commands/upload-file.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1305
|
+
_See code: [src/commands/upload-file.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/upload-file.ts)_
|
|
1313
1306
|
|
|
1314
1307
|
## `internxt upload-folder`
|
|
1315
1308
|
|
|
@@ -1342,7 +1335,7 @@ EXAMPLES
|
|
|
1342
1335
|
$ internxt upload-folder
|
|
1343
1336
|
```
|
|
1344
1337
|
|
|
1345
|
-
_See code: [src/commands/upload-folder.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1338
|
+
_See code: [src/commands/upload-folder.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/upload-folder.ts)_
|
|
1346
1339
|
|
|
1347
1340
|
## `internxt upload file`
|
|
1348
1341
|
|
|
@@ -1350,11 +1343,13 @@ Upload a file to Internxt Drive
|
|
|
1350
1343
|
|
|
1351
1344
|
```
|
|
1352
1345
|
USAGE
|
|
1353
|
-
$ internxt upload file [--json] [-x] [--debug] [-f <value>] [-i <value>]
|
|
1346
|
+
$ internxt upload file [--json] [-x] [--debug] [-f <value>] [-i <value>] [-o]
|
|
1354
1347
|
|
|
1355
1348
|
FLAGS
|
|
1356
1349
|
-f, --file=<value> The path to the file on your system.
|
|
1357
1350
|
-i, --destination=<value> The folder id where the file is going to be uploaded to. Leave empty for the root folder.
|
|
1351
|
+
-o, --overwrite Overwrite the file if a file with the same name already exists in the cloud destination
|
|
1352
|
+
folder.
|
|
1358
1353
|
|
|
1359
1354
|
HELPER FLAGS
|
|
1360
1355
|
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
@@ -1436,7 +1431,7 @@ EXAMPLES
|
|
|
1436
1431
|
$ internxt webdav status
|
|
1437
1432
|
```
|
|
1438
1433
|
|
|
1439
|
-
_See code: [src/commands/webdav.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1434
|
+
_See code: [src/commands/webdav.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/webdav.ts)_
|
|
1440
1435
|
|
|
1441
1436
|
## `internxt webdav-config`
|
|
1442
1437
|
|
|
@@ -1475,7 +1470,7 @@ EXAMPLES
|
|
|
1475
1470
|
$ internxt webdav-config
|
|
1476
1471
|
```
|
|
1477
1472
|
|
|
1478
|
-
_See code: [src/commands/webdav-config.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1473
|
+
_See code: [src/commands/webdav-config.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/webdav-config.ts)_
|
|
1479
1474
|
|
|
1480
1475
|
## `internxt whoami`
|
|
1481
1476
|
|
|
@@ -1501,199 +1496,9 @@ EXAMPLES
|
|
|
1501
1496
|
$ internxt whoami
|
|
1502
1497
|
```
|
|
1503
1498
|
|
|
1504
|
-
_See code: [src/commands/whoami.ts](https://github.com/internxt/cli/blob/v1.6.
|
|
1505
|
-
|
|
1506
|
-
## `internxt workspaces-list`
|
|
1507
|
-
|
|
1508
|
-
Get the list of workspaces.
|
|
1509
|
-
|
|
1510
|
-
```
|
|
1511
|
-
USAGE
|
|
1512
|
-
$ internxt workspaces-list [--json] [-x] [--debug] [-e]
|
|
1513
|
-
|
|
1514
|
-
FLAGS
|
|
1515
|
-
-e, --extended Displays additional information in the list.
|
|
1516
|
-
|
|
1517
|
-
HELPER FLAGS
|
|
1518
|
-
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
1519
|
-
not request input through the console and will throw errors directly.
|
|
1520
|
-
--debug [env: INXT_DEBUG] Enables debug mode. When enabled, the CLI will print debug messages to the
|
|
1521
|
-
console.
|
|
1522
|
-
|
|
1523
|
-
GLOBAL FLAGS
|
|
1524
|
-
--json Format output as json.
|
|
1525
|
-
|
|
1526
|
-
DESCRIPTION
|
|
1527
|
-
Get the list of workspaces.
|
|
1528
|
-
|
|
1529
|
-
ALIASES
|
|
1530
|
-
$ internxt workspaces list
|
|
1531
|
-
|
|
1532
|
-
EXAMPLES
|
|
1533
|
-
$ internxt workspaces-list
|
|
1534
|
-
```
|
|
1535
|
-
|
|
1536
|
-
_See code: [src/commands/workspaces-list.ts](https://github.com/internxt/cli/blob/v1.6.7/src/commands/workspaces-list.ts)_
|
|
1537
|
-
|
|
1538
|
-
## `internxt workspaces-unset`
|
|
1539
|
-
|
|
1540
|
-
Unset the active workspace context for the current user session. Once a workspace is unset, WebDAV and all of the subsequent CLI commands will operate within the personal drive space until it is changed or set again.
|
|
1541
|
-
|
|
1542
|
-
```
|
|
1543
|
-
USAGE
|
|
1544
|
-
$ internxt workspaces-unset [--json] [-x] [--debug]
|
|
1545
|
-
|
|
1546
|
-
HELPER FLAGS
|
|
1547
|
-
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
1548
|
-
not request input through the console and will throw errors directly.
|
|
1549
|
-
--debug [env: INXT_DEBUG] Enables debug mode. When enabled, the CLI will print debug messages to the
|
|
1550
|
-
console.
|
|
1551
|
-
|
|
1552
|
-
GLOBAL FLAGS
|
|
1553
|
-
--json Format output as json.
|
|
1554
|
-
|
|
1555
|
-
DESCRIPTION
|
|
1556
|
-
Unset the active workspace context for the current user session. Once a workspace is unset, WebDAV and all of the
|
|
1557
|
-
subsequent CLI commands will operate within the personal drive space until it is changed or set again.
|
|
1558
|
-
|
|
1559
|
-
ALIASES
|
|
1560
|
-
$ internxt workspaces unset
|
|
1561
|
-
|
|
1562
|
-
EXAMPLES
|
|
1563
|
-
$ internxt workspaces-unset
|
|
1564
|
-
```
|
|
1565
|
-
|
|
1566
|
-
_See code: [src/commands/workspaces-unset.ts](https://github.com/internxt/cli/blob/v1.6.7/src/commands/workspaces-unset.ts)_
|
|
1567
|
-
|
|
1568
|
-
## `internxt workspaces-use`
|
|
1569
|
-
|
|
1570
|
-
Set the active workspace context for the current user session. Once a workspace is selected, WebDAV and all of the subsequent CLI commands will operate within that workspace until it is changed or unset.
|
|
1571
|
-
|
|
1572
|
-
```
|
|
1573
|
-
USAGE
|
|
1574
|
-
$ internxt workspaces-use [--json] [-x] [--debug] [-i <value> | -p]
|
|
1575
|
-
|
|
1576
|
-
FLAGS
|
|
1577
|
-
-i, --id=<value> The id of the workspace to activate. Use internxt workspaces list to view your available workspace
|
|
1578
|
-
ids.
|
|
1579
|
-
-p, --personal Change to the personal drive space. It unsets the active workspace context for the current user
|
|
1580
|
-
session.
|
|
1581
|
-
|
|
1582
|
-
HELPER FLAGS
|
|
1583
|
-
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
1584
|
-
not request input through the console and will throw errors directly.
|
|
1585
|
-
--debug [env: INXT_DEBUG] Enables debug mode. When enabled, the CLI will print debug messages to the
|
|
1586
|
-
console.
|
|
1587
|
-
|
|
1588
|
-
GLOBAL FLAGS
|
|
1589
|
-
--json Format output as json.
|
|
1590
|
-
|
|
1591
|
-
DESCRIPTION
|
|
1592
|
-
Set the active workspace context for the current user session. Once a workspace is selected, WebDAV and all of the
|
|
1593
|
-
subsequent CLI commands will operate within that workspace until it is changed or unset.
|
|
1594
|
-
|
|
1595
|
-
ALIASES
|
|
1596
|
-
$ internxt workspaces use
|
|
1597
|
-
|
|
1598
|
-
EXAMPLES
|
|
1599
|
-
$ internxt workspaces-use
|
|
1600
|
-
```
|
|
1601
|
-
|
|
1602
|
-
_See code: [src/commands/workspaces-use.ts](https://github.com/internxt/cli/blob/v1.6.7/src/commands/workspaces-use.ts)_
|
|
1603
|
-
|
|
1604
|
-
## `internxt workspaces list`
|
|
1605
|
-
|
|
1606
|
-
Get the list of workspaces.
|
|
1607
|
-
|
|
1608
|
-
```
|
|
1609
|
-
USAGE
|
|
1610
|
-
$ internxt workspaces list [--json] [-x] [--debug] [-e]
|
|
1611
|
-
|
|
1612
|
-
FLAGS
|
|
1613
|
-
-e, --extended Displays additional information in the list.
|
|
1614
|
-
|
|
1615
|
-
HELPER FLAGS
|
|
1616
|
-
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
1617
|
-
not request input through the console and will throw errors directly.
|
|
1618
|
-
--debug [env: INXT_DEBUG] Enables debug mode. When enabled, the CLI will print debug messages to the
|
|
1619
|
-
console.
|
|
1620
|
-
|
|
1621
|
-
GLOBAL FLAGS
|
|
1622
|
-
--json Format output as json.
|
|
1623
|
-
|
|
1624
|
-
DESCRIPTION
|
|
1625
|
-
Get the list of workspaces.
|
|
1626
|
-
|
|
1627
|
-
ALIASES
|
|
1628
|
-
$ internxt workspaces list
|
|
1629
|
-
|
|
1630
|
-
EXAMPLES
|
|
1631
|
-
$ internxt workspaces list
|
|
1632
|
-
```
|
|
1633
|
-
|
|
1634
|
-
## `internxt workspaces unset`
|
|
1635
|
-
|
|
1636
|
-
Unset the active workspace context for the current user session. Once a workspace is unset, WebDAV and all of the subsequent CLI commands will operate within the personal drive space until it is changed or set again.
|
|
1637
|
-
|
|
1638
|
-
```
|
|
1639
|
-
USAGE
|
|
1640
|
-
$ internxt workspaces unset [--json] [-x] [--debug]
|
|
1641
|
-
|
|
1642
|
-
HELPER FLAGS
|
|
1643
|
-
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
1644
|
-
not request input through the console and will throw errors directly.
|
|
1645
|
-
--debug [env: INXT_DEBUG] Enables debug mode. When enabled, the CLI will print debug messages to the
|
|
1646
|
-
console.
|
|
1647
|
-
|
|
1648
|
-
GLOBAL FLAGS
|
|
1649
|
-
--json Format output as json.
|
|
1650
|
-
|
|
1651
|
-
DESCRIPTION
|
|
1652
|
-
Unset the active workspace context for the current user session. Once a workspace is unset, WebDAV and all of the
|
|
1653
|
-
subsequent CLI commands will operate within the personal drive space until it is changed or set again.
|
|
1654
|
-
|
|
1655
|
-
ALIASES
|
|
1656
|
-
$ internxt workspaces unset
|
|
1657
|
-
|
|
1658
|
-
EXAMPLES
|
|
1659
|
-
$ internxt workspaces unset
|
|
1660
|
-
```
|
|
1661
|
-
|
|
1662
|
-
## `internxt workspaces use`
|
|
1663
|
-
|
|
1664
|
-
Set the active workspace context for the current user session. Once a workspace is selected, WebDAV and all of the subsequent CLI commands will operate within that workspace until it is changed or unset.
|
|
1665
|
-
|
|
1666
|
-
```
|
|
1667
|
-
USAGE
|
|
1668
|
-
$ internxt workspaces use [--json] [-x] [--debug] [-i <value> | -p]
|
|
1669
|
-
|
|
1670
|
-
FLAGS
|
|
1671
|
-
-i, --id=<value> The id of the workspace to activate. Use internxt workspaces list to view your available workspace
|
|
1672
|
-
ids.
|
|
1673
|
-
-p, --personal Change to the personal drive space. It unsets the active workspace context for the current user
|
|
1674
|
-
session.
|
|
1675
|
-
|
|
1676
|
-
HELPER FLAGS
|
|
1677
|
-
-x, --non-interactive [env: INXT_NONINTERACTIVE] Prevents the CLI from being interactive. When enabled, the CLI will
|
|
1678
|
-
not request input through the console and will throw errors directly.
|
|
1679
|
-
--debug [env: INXT_DEBUG] Enables debug mode. When enabled, the CLI will print debug messages to the
|
|
1680
|
-
console.
|
|
1681
|
-
|
|
1682
|
-
GLOBAL FLAGS
|
|
1683
|
-
--json Format output as json.
|
|
1684
|
-
|
|
1685
|
-
DESCRIPTION
|
|
1686
|
-
Set the active workspace context for the current user session. Once a workspace is selected, WebDAV and all of the
|
|
1687
|
-
subsequent CLI commands will operate within that workspace until it is changed or unset.
|
|
1688
|
-
|
|
1689
|
-
ALIASES
|
|
1690
|
-
$ internxt workspaces use
|
|
1691
|
-
|
|
1692
|
-
EXAMPLES
|
|
1693
|
-
$ internxt workspaces use
|
|
1694
|
-
```
|
|
1499
|
+
_See code: [src/commands/whoami.ts](https://github.com/internxt/cli/blob/v1.6.8/src/commands/whoami.ts)_
|
|
1695
1500
|
<!-- commandsstop -->
|
|
1696
1501
|
|
|
1697
1502
|
# Current Limitations
|
|
1698
1503
|
|
|
1699
|
-
-
|
|
1504
|
+
- Upload size limits depend on the account's plan tier. Since the CLI is only available to Ultimate plan users, we currently have a 100GB size upload limitation per file for both, CLI and WebDAV
|
|
@@ -7,7 +7,6 @@ const config_service_1 = require("../services/config.service");
|
|
|
7
7
|
const validation_service_1 = require("../services/validation.service");
|
|
8
8
|
const command_types_1 = require("../types/command.types");
|
|
9
9
|
const async_utils_1 = require("../utils/async.utils");
|
|
10
|
-
const auth_service_1 = require("../services/auth.service");
|
|
11
10
|
class CreateFolder extends core_1.Command {
|
|
12
11
|
static args = {};
|
|
13
12
|
static description = 'Create a folder in your Internxt Drive';
|
|
@@ -49,11 +48,8 @@ class CreateFolder extends core_1.Command {
|
|
|
49
48
|
const newFolder = await createNewFolder;
|
|
50
49
|
await async_utils_1.AsyncUtils.sleep(500);
|
|
51
50
|
cli_utils_1.CLIUtils.done(flags['json']);
|
|
52
|
-
const workspace = await auth_service_1.AuthService.instance.getCurrentWorkspace();
|
|
53
|
-
const workspaceId = workspace?.workspaceData.workspace.id;
|
|
54
51
|
const message = `Folder ${newFolder.plainName} created successfully, view it at ` +
|
|
55
|
-
`${config_service_1.ConfigService.instance.get('DRIVE_WEB_URL')}/folder/${newFolder.uuid}
|
|
56
|
-
`${workspaceId ? `?workspaceid=${workspaceId}` : ''}`;
|
|
52
|
+
`${config_service_1.ConfigService.instance.get('DRIVE_WEB_URL')}/folder/${newFolder.uuid}`;
|
|
57
53
|
cli_utils_1.CLIUtils.success(this.log.bind(this), message);
|
|
58
54
|
return { success: true, message, folder: newFolder };
|
|
59
55
|
};
|
|
@@ -95,7 +91,7 @@ class CreateFolder extends core_1.Command {
|
|
|
95
91
|
options: { type: 'input' },
|
|
96
92
|
},
|
|
97
93
|
}, {
|
|
98
|
-
validate: validation_service_1.ValidationService.instance.
|
|
94
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
99
95
|
error: new command_types_1.NotValidFolderUuidError(),
|
|
100
96
|
canBeEmpty: true,
|
|
101
97
|
}, this.log.bind(this));
|
|
@@ -59,7 +59,7 @@ class DeletePermanentlyFile extends core_1.Command {
|
|
|
59
59
|
options: { type: 'input' },
|
|
60
60
|
},
|
|
61
61
|
}, {
|
|
62
|
-
validate: validation_service_1.ValidationService.instance.
|
|
62
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
63
63
|
error: new command_types_1.NotValidFileUuidError(),
|
|
64
64
|
}, this.log.bind(this));
|
|
65
65
|
return fileUuid;
|
|
@@ -59,7 +59,7 @@ class DeletePermanentlyFolder extends core_1.Command {
|
|
|
59
59
|
options: { type: 'input' },
|
|
60
60
|
},
|
|
61
61
|
}, {
|
|
62
|
-
validate: validation_service_1.ValidationService.instance.
|
|
62
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
63
63
|
error: new command_types_1.NotValidFolderUuidError(),
|
|
64
64
|
}, this.log.bind(this));
|
|
65
65
|
return folderUuid;
|
|
@@ -64,10 +64,10 @@ class DownloadFile extends core_1.Command {
|
|
|
64
64
|
}
|
|
65
65
|
const { user } = await auth_service_1.AuthService.instance.getAuthDetails();
|
|
66
66
|
cli_utils_1.CLIUtils.doing('Preparing Network', flags['json']);
|
|
67
|
-
const { networkFacade,
|
|
67
|
+
const { networkFacade, mnemonic } = await cli_utils_1.CLIUtils.prepareNetwork(user);
|
|
68
68
|
cli_utils_1.CLIUtils.done(flags['json']);
|
|
69
69
|
const fileWriteStream = (0, node_fs_1.createWriteStream)(downloadPath);
|
|
70
|
-
const [executeDownload, abortable] = await networkFacade.downloadToStream(bucket, mnemonic, driveFile.fileId, driveFile.size, stream_utils_1.StreamUtils.writeStreamToWritableStream(fileWriteStream), undefined, {
|
|
70
|
+
const [executeDownload, abortable] = await networkFacade.downloadToStream(driveFile.bucket, mnemonic, driveFile.fileId, driveFile.size, stream_utils_1.StreamUtils.writeStreamToWritableStream(fileWriteStream), undefined, {
|
|
71
71
|
abortController: new AbortController(),
|
|
72
72
|
progressCallback: (progress) => {
|
|
73
73
|
progressBar?.update(progress * 0.99);
|
|
@@ -112,7 +112,7 @@ class DownloadFile extends core_1.Command {
|
|
|
112
112
|
options: { type: 'input' },
|
|
113
113
|
},
|
|
114
114
|
}, {
|
|
115
|
-
validate: validation_service_1.ValidationService.instance.
|
|
115
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
116
116
|
error: new command_types_1.NotValidFileUuidError(),
|
|
117
117
|
}, this.log.bind(this));
|
|
118
118
|
return fileUuid;
|
package/dist/commands/list.d.ts
CHANGED
|
@@ -34,6 +34,7 @@ export default class List extends Command {
|
|
|
34
34
|
status: "EXISTS" | "TRASHED" | "DELETED";
|
|
35
35
|
removed: boolean;
|
|
36
36
|
deleted: boolean;
|
|
37
|
+
isFavorite?: boolean;
|
|
37
38
|
}[];
|
|
38
39
|
files: {
|
|
39
40
|
id: number;
|
|
@@ -53,6 +54,7 @@ export default class List extends Command {
|
|
|
53
54
|
updatedAt: string;
|
|
54
55
|
plainName: string;
|
|
55
56
|
status: "EXISTS" | "TRASHED" | "DELETED";
|
|
57
|
+
isFavorite?: boolean;
|
|
56
58
|
}[];
|
|
57
59
|
};
|
|
58
60
|
}>;
|
package/dist/commands/list.js
CHANGED
|
@@ -91,7 +91,7 @@ class List extends core_1.Command {
|
|
|
91
91
|
options: { type: 'input' },
|
|
92
92
|
},
|
|
93
93
|
}, {
|
|
94
|
-
validate: validation_service_1.ValidationService.instance.
|
|
94
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
95
95
|
error: new command_types_1.NotValidFolderUuidError(),
|
|
96
96
|
canBeEmpty: true,
|
|
97
97
|
}, this.log.bind(this));
|
package/dist/commands/login.d.ts
CHANGED
|
@@ -5,7 +5,6 @@ export default class Login extends Command {
|
|
|
5
5
|
static readonly aliases: never[];
|
|
6
6
|
static readonly examples: string[];
|
|
7
7
|
static readonly flags: {
|
|
8
|
-
host: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
9
8
|
port: import("@oclif/core/interfaces").OptionFlag<number | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
10
9
|
'non-interactive': import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
11
10
|
debug: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
package/dist/commands/login.js
CHANGED
|
@@ -14,15 +14,6 @@ class Login extends core_1.Command {
|
|
|
14
14
|
static examples = ['<%= config.bin %> <%= command.id %>'];
|
|
15
15
|
static flags = {
|
|
16
16
|
...cli_utils_1.CLIUtils.CommonFlags,
|
|
17
|
-
host: core_1.Flags.string({
|
|
18
|
-
char: 'h',
|
|
19
|
-
aliases: ['host'],
|
|
20
|
-
env: 'INXT_LOGIN_SERVER_HOST',
|
|
21
|
-
description: 'IP address of the machine where the CLI is running. ' +
|
|
22
|
-
'If you are opening the login page in a browser on another device, ' +
|
|
23
|
-
'set this to the IP address of the machine running the CLI. Defaults to 127.0.0.1.',
|
|
24
|
-
required: false,
|
|
25
|
-
}),
|
|
26
17
|
port: core_1.Flags.integer({
|
|
27
18
|
char: 'p',
|
|
28
19
|
aliases: ['port'],
|
|
@@ -35,9 +26,8 @@ class Login extends core_1.Command {
|
|
|
35
26
|
static enableJsonFlag = true;
|
|
36
27
|
run = async () => {
|
|
37
28
|
const { flags } = await this.parse(Login);
|
|
38
|
-
const host = flags['host'];
|
|
39
29
|
const port = flags['port'];
|
|
40
|
-
const loginCredentials = await universal_link_service_1.UniversalLinkService.instance.loginSSO(flags['json'] ?? false, this.log.bind(this),
|
|
30
|
+
const loginCredentials = await universal_link_service_1.UniversalLinkService.instance.loginSSO(flags['json'] ?? false, this.log.bind(this), port);
|
|
41
31
|
sdk_manager_service_1.SdkManager.init({ token: loginCredentials.token });
|
|
42
32
|
cache_service_1.CacheService.instance.clearCaches();
|
|
43
33
|
await config_service_1.ConfigService.instance.saveUser(loginCredentials);
|
|
@@ -67,7 +67,7 @@ class MoveFile extends core_1.Command {
|
|
|
67
67
|
options: { type: 'input' },
|
|
68
68
|
},
|
|
69
69
|
}, {
|
|
70
|
-
validate: validation_service_1.ValidationService.instance.
|
|
70
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
71
71
|
error: new command_types_1.NotValidFileUuidError(),
|
|
72
72
|
}, this.log.bind(this));
|
|
73
73
|
return fileUuid;
|
|
@@ -69,7 +69,7 @@ class MoveFolder extends core_1.Command {
|
|
|
69
69
|
options: { type: 'input' },
|
|
70
70
|
},
|
|
71
71
|
}, {
|
|
72
|
-
validate: validation_service_1.ValidationService.instance.
|
|
72
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
73
73
|
error: new command_types_1.NotValidFolderUuidError(),
|
|
74
74
|
}, this.log.bind(this));
|
|
75
75
|
return folderUuid;
|
|
@@ -67,7 +67,7 @@ class RenameFile extends core_1.Command {
|
|
|
67
67
|
options: { type: 'input' },
|
|
68
68
|
},
|
|
69
69
|
}, {
|
|
70
|
-
validate: validation_service_1.ValidationService.instance.
|
|
70
|
+
validate: validation_service_1.ValidationService.instance.validateUUID,
|
|
71
71
|
error: new command_types_1.NotValidFileUuidError(),
|
|
72
72
|
}, this.log.bind(this));
|
|
73
73
|
return fileUuid;
|