@ecmaos/types 0.6.0 → 0.7.0
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/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +60 -0
- package/dist/filesystem.d.ts +27 -0
- package/dist/filesystem.d.ts.map +1 -1
- package/dist/intervals.d.ts +35 -0
- package/dist/intervals.d.ts.map +1 -1
- package/filesystem.ts +30 -0
- package/intervals.ts +39 -0
- package/package.json +1 -1
package/.turbo/turbo-build.log
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,65 @@
|
|
|
1
1
|
# @ecmaos/types
|
|
2
2
|
|
|
3
|
+
## 0.7.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- c6d3ea8: Filesystem & Mount System
|
|
8
|
+
|
|
9
|
+
- Added fstab file processing and parsing utilities
|
|
10
|
+
- Implemented mount and umount commands with full filesystem support
|
|
11
|
+
- Changed environment variable prefix handling
|
|
12
|
+
- Enhanced filesystem configuration and mount management
|
|
13
|
+
|
|
14
|
+
Environment Management
|
|
15
|
+
|
|
16
|
+
- Added support for global /etc/env file
|
|
17
|
+
- Fixed env command argument handling
|
|
18
|
+
- New env command implementation in core/utils
|
|
19
|
+
|
|
20
|
+
Documentation & SEO
|
|
21
|
+
|
|
22
|
+
- Enhanced HTML metadata and SEO improvements
|
|
23
|
+
- Added AI and passkey tutorials
|
|
24
|
+
- Updated README with expanded documentation
|
|
25
|
+
- Added lighthouse performance report
|
|
26
|
+
- Updated project description
|
|
27
|
+
|
|
28
|
+
Bug Fixes & Enhancements
|
|
29
|
+
|
|
30
|
+
- Enhanced cron command with improved parsing and functionality
|
|
31
|
+
- Fixed readline bug in terminal
|
|
32
|
+
- Fixed less command first-line offset display issue
|
|
33
|
+
|
|
34
|
+
Miscellaneous
|
|
35
|
+
|
|
36
|
+
- Removed offers metadata from HTML
|
|
37
|
+
- Sorted package.json scripts
|
|
38
|
+
- Synced documentation across codebase
|
|
39
|
+
|
|
40
|
+
## 0.6.1
|
|
41
|
+
|
|
42
|
+
### Patch Changes
|
|
43
|
+
|
|
44
|
+
- d43d304: New Features:
|
|
45
|
+
|
|
46
|
+
- Cron/crontab system: Added scheduling system with crontab parsing and execution
|
|
47
|
+
- Web browser coreutil: New 'web' command for browsing functionality
|
|
48
|
+
- View coreutil: New 'view' command for multimedia viewing
|
|
49
|
+
- Coreutils migration: Migrated 'play' and 'video' commands from kernel to coreutils
|
|
50
|
+
|
|
51
|
+
Fixes:
|
|
52
|
+
|
|
53
|
+
- Shell command substitution parsing improvements
|
|
54
|
+
- Tar parsing improvements
|
|
55
|
+
- Web coreutil now loads credentialless
|
|
56
|
+
|
|
57
|
+
Maintenance:
|
|
58
|
+
|
|
59
|
+
- Updated documentation and types across various kernel components
|
|
60
|
+
- Enhanced coreutils and shell scripts
|
|
61
|
+
- Added 'open' and 'man' commands to coreutils
|
|
62
|
+
|
|
3
63
|
## 0.6.0
|
|
4
64
|
|
|
5
65
|
### Minor Changes
|
package/dist/filesystem.d.ts
CHANGED
|
@@ -35,6 +35,33 @@ export interface FilesystemDescriptions {
|
|
|
35
35
|
*/
|
|
36
36
|
descriptions: (t?: TFunction | ((key: string) => string)) => Map<string, string>;
|
|
37
37
|
}
|
|
38
|
+
/**
|
|
39
|
+
* Represents an entry in the fstab (filesystem table).
|
|
40
|
+
* Analogous to /etc/fstab in Linux, but simplified for our use.
|
|
41
|
+
*/
|
|
42
|
+
export interface FstabEntry {
|
|
43
|
+
/**
|
|
44
|
+
* The source of the mount, e.g., device, URL, database name, etc.
|
|
45
|
+
* For memory/webstorage/dropbox/googledrive, this may be empty/ignored.
|
|
46
|
+
*/
|
|
47
|
+
source: string;
|
|
48
|
+
/**
|
|
49
|
+
* The target mount point (absolute path in the virtual FS)
|
|
50
|
+
*/
|
|
51
|
+
target: string;
|
|
52
|
+
/**
|
|
53
|
+
* Filesystem type (e.g., 'memory', 'fetch', 'indexeddb', 'webstorage', 'zip', 'iso', 'dropbox', 'googledrive', etc.)
|
|
54
|
+
*/
|
|
55
|
+
type: string;
|
|
56
|
+
/**
|
|
57
|
+
* Optional comma-separated mount options (e.g., "size=1048576,storage=localStorage")
|
|
58
|
+
*/
|
|
59
|
+
options?: string;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* fstab table: a list of fstab entries.
|
|
63
|
+
*/
|
|
64
|
+
export type Fstab = FstabEntry[];
|
|
38
65
|
/**
|
|
39
66
|
* Interface for filesystem functionality
|
|
40
67
|
*/
|
package/dist/filesystem.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filesystem.d.ts","sourceRoot":"","sources":["../filesystem.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,EAAE,EAAE,MAAM,aAAa,CAAA;AAClE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAA;AAExC;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG,YAAY,CAAA;AAEjD;;GAEG;AACH,MAAM,MAAM,iBAAiB,CAAC,CAAC,SAAS,sBAAsB,IAAI,aAAa,CAAC,CAAC,CAAC,CAAA;AAElF;;GAEG;AACH,MAAM,MAAM,IAAI,GAAG,MAAM,CAAA;AAEzB;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,mBAAmB;IACnB,IAAI,EAAE,MAAM,CAAA;IACZ,yBAAyB;IACzB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,oBAAoB;IACpB,IAAI,CAAC,EAAE,MAAM,CAAA;CACd;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC;;OAEG;IACH,YAAY,EAAE,CAAC,CAAC,CAAC,EAAE,SAAS,GAAG,CAAC,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC,KAAK,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CACjF;A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IACH,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;IAEtC;;;;OAIG;IACH,cAAc,CAAC,WAAW,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IAEvE;;;OAGG;IACH,YAAY,CAAC,CAAC,CAAC,EAAE,SAAS,GAAG,CAAC,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CAC7E"}
|
package/dist/intervals.d.ts
CHANGED
|
@@ -5,6 +5,17 @@
|
|
|
5
5
|
* Type for mapping interval names to their timer IDs
|
|
6
6
|
*/
|
|
7
7
|
export type IntervalMap = Map<string, ReturnType<typeof setInterval>>;
|
|
8
|
+
/**
|
|
9
|
+
* Timer handle interface matching cron-schedule's ITimerHandle
|
|
10
|
+
* This matches the return type of TimerBasedCronScheduler.setInterval
|
|
11
|
+
*/
|
|
12
|
+
export interface ITimerHandle {
|
|
13
|
+
clear(): void;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Type for mapping cron job names to their timer handles
|
|
17
|
+
*/
|
|
18
|
+
export type CronMap = Map<string, ITimerHandle>;
|
|
8
19
|
/**
|
|
9
20
|
* Interface for interval management functionality
|
|
10
21
|
*/
|
|
@@ -26,5 +37,29 @@ export interface Intervals {
|
|
|
26
37
|
* @param name - Name of the interval to clear
|
|
27
38
|
*/
|
|
28
39
|
clear(name: string): void;
|
|
40
|
+
/**
|
|
41
|
+
* Get a cron job by name
|
|
42
|
+
* @param name - Name of the cron job
|
|
43
|
+
*/
|
|
44
|
+
getCron(name: string): ITimerHandle | undefined;
|
|
45
|
+
/**
|
|
46
|
+
* Set a new cron job
|
|
47
|
+
* @param name - Name for the cron job
|
|
48
|
+
* @param cronExpression - Cron expression (e.g., "0 5 * * *" for every 5 minutes past the hour)
|
|
49
|
+
* @param callback - Function to execute
|
|
50
|
+
* @param opts - Optional error handler
|
|
51
|
+
*/
|
|
52
|
+
setCron(name: string, cronExpression: string, callback: () => void, opts?: {
|
|
53
|
+
errorHandler?: (err: unknown) => unknown;
|
|
54
|
+
}): ITimerHandle;
|
|
55
|
+
/**
|
|
56
|
+
* Clear a cron job by name
|
|
57
|
+
* @param name - Name of the cron job to clear
|
|
58
|
+
*/
|
|
59
|
+
clearCron(name: string): void;
|
|
60
|
+
/**
|
|
61
|
+
* List all active cron job names
|
|
62
|
+
*/
|
|
63
|
+
listCrons(): string[];
|
|
29
64
|
}
|
|
30
65
|
//# sourceMappingURL=intervals.d.ts.map
|
package/dist/intervals.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intervals.d.ts","sourceRoot":"","sources":["../intervals.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,GAAG,CAAC,MAAM,EAAE,UAAU,CAAC,OAAO,WAAW,CAAC,CAAC,CAAA;AAErE;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB;;;OAGG;IACH,GAAG,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,CAAC,OAAO,WAAW,CAAC,GAAG,SAAS,CAAA;IAE7D;;;;;OAKG;IACH,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,UAAU,CAAC,OAAO,WAAW,CAAC,CAAA;IAEzF;;;OAGG;IACH,KAAK,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAA;
|
|
1
|
+
{"version":3,"file":"intervals.d.ts","sourceRoot":"","sources":["../intervals.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,GAAG,CAAC,MAAM,EAAE,UAAU,CAAC,OAAO,WAAW,CAAC,CAAC,CAAA;AAErE;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,KAAK,IAAI,IAAI,CAAA;CACd;AAED;;GAEG;AACH,MAAM,MAAM,OAAO,GAAG,GAAG,CAAC,MAAM,EAAE,YAAY,CAAC,CAAA;AAE/C;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB;;;OAGG;IACH,GAAG,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,CAAC,OAAO,WAAW,CAAC,GAAG,SAAS,CAAA;IAE7D;;;;;OAKG;IACH,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,UAAU,CAAC,OAAO,WAAW,CAAC,CAAA;IAEzF;;;OAGG;IACH,KAAK,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAA;IAEzB;;;OAGG;IACH,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,YAAY,GAAG,SAAS,CAAA;IAE/C;;;;;;OAMG;IACH,OAAO,CAAC,IAAI,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,IAAI,EAAE,IAAI,CAAC,EAAE;QAAE,YAAY,CAAC,EAAE,CAAC,GAAG,EAAE,OAAO,KAAK,OAAO,CAAA;KAAE,GAAG,YAAY,CAAA;IAEtI;;;OAGG;IACH,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAA;IAE7B;;OAEG;IACH,SAAS,IAAI,MAAM,EAAE,CAAA;CACtB"}
|
package/filesystem.ts
CHANGED
|
@@ -42,6 +42,36 @@ export interface FilesystemDescriptions {
|
|
|
42
42
|
descriptions: (t?: TFunction | ((key: string) => string)) => Map<string, string>
|
|
43
43
|
}
|
|
44
44
|
|
|
45
|
+
/**
|
|
46
|
+
* Represents an entry in the fstab (filesystem table).
|
|
47
|
+
* Analogous to /etc/fstab in Linux, but simplified for our use.
|
|
48
|
+
*/
|
|
49
|
+
export interface FstabEntry {
|
|
50
|
+
/**
|
|
51
|
+
* The source of the mount, e.g., device, URL, database name, etc.
|
|
52
|
+
* For memory/webstorage/dropbox/googledrive, this may be empty/ignored.
|
|
53
|
+
*/
|
|
54
|
+
source: string
|
|
55
|
+
/**
|
|
56
|
+
* The target mount point (absolute path in the virtual FS)
|
|
57
|
+
*/
|
|
58
|
+
target: string
|
|
59
|
+
/**
|
|
60
|
+
* Filesystem type (e.g., 'memory', 'fetch', 'indexeddb', 'webstorage', 'zip', 'iso', 'dropbox', 'googledrive', etc.)
|
|
61
|
+
*/
|
|
62
|
+
type: string
|
|
63
|
+
/**
|
|
64
|
+
* Optional comma-separated mount options (e.g., "size=1048576,storage=localStorage")
|
|
65
|
+
*/
|
|
66
|
+
options?: string
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* fstab table: a list of fstab entries.
|
|
71
|
+
*/
|
|
72
|
+
export type Fstab = FstabEntry[]
|
|
73
|
+
|
|
74
|
+
|
|
45
75
|
/**
|
|
46
76
|
* Interface for filesystem functionality
|
|
47
77
|
*/
|
package/intervals.ts
CHANGED
|
@@ -7,6 +7,19 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export type IntervalMap = Map<string, ReturnType<typeof setInterval>>
|
|
9
9
|
|
|
10
|
+
/**
|
|
11
|
+
* Timer handle interface matching cron-schedule's ITimerHandle
|
|
12
|
+
* This matches the return type of TimerBasedCronScheduler.setInterval
|
|
13
|
+
*/
|
|
14
|
+
export interface ITimerHandle {
|
|
15
|
+
clear(): void
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Type for mapping cron job names to their timer handles
|
|
20
|
+
*/
|
|
21
|
+
export type CronMap = Map<string, ITimerHandle>
|
|
22
|
+
|
|
10
23
|
/**
|
|
11
24
|
* Interface for interval management functionality
|
|
12
25
|
*/
|
|
@@ -30,4 +43,30 @@ export interface Intervals {
|
|
|
30
43
|
* @param name - Name of the interval to clear
|
|
31
44
|
*/
|
|
32
45
|
clear(name: string): void
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Get a cron job by name
|
|
49
|
+
* @param name - Name of the cron job
|
|
50
|
+
*/
|
|
51
|
+
getCron(name: string): ITimerHandle | undefined
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Set a new cron job
|
|
55
|
+
* @param name - Name for the cron job
|
|
56
|
+
* @param cronExpression - Cron expression (e.g., "0 5 * * *" for every 5 minutes past the hour)
|
|
57
|
+
* @param callback - Function to execute
|
|
58
|
+
* @param opts - Optional error handler
|
|
59
|
+
*/
|
|
60
|
+
setCron(name: string, cronExpression: string, callback: () => void, opts?: { errorHandler?: (err: unknown) => unknown }): ITimerHandle
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Clear a cron job by name
|
|
64
|
+
* @param name - Name of the cron job to clear
|
|
65
|
+
*/
|
|
66
|
+
clearCron(name: string): void
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* List all active cron job names
|
|
70
|
+
*/
|
|
71
|
+
listCrons(): string[]
|
|
33
72
|
}
|