@interopio/iocd-cli 0.0.40 โ†’ 0.0.42

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.
Files changed (86) hide show
  1. package/README.md +795 -780
  2. package/dist/services/installer/electronForge.js +2 -2
  3. package/dist/services/installer/electronForge.js.map +1 -1
  4. package/dist/services/installer/installer.service.js +7 -0
  5. package/dist/services/installer/installer.service.js.map +1 -1
  6. package/dist/services/license.service.js +14 -14
  7. package/dist/services/modifications/modifications.service.js +14 -0
  8. package/dist/services/modifications/modifications.service.js.map +1 -1
  9. package/dist/templates/groups/apps/groups/.gitignore.template +23 -23
  10. package/dist/templates/groups/apps/groups/README.md +15 -15
  11. package/dist/templates/groups/apps/groups/config/web-group-dev.json +12 -12
  12. package/dist/templates/groups/apps/groups/index.html +17 -17
  13. package/dist/templates/groups/apps/groups/iocd.app.json +19 -19
  14. package/dist/templates/groups/apps/groups/package.json +25 -25
  15. package/dist/templates/groups/apps/groups/public/manifest.json +24 -24
  16. package/dist/templates/groups/apps/groups/public/robots.txt +3 -3
  17. package/dist/templates/groups/apps/groups/src/App.css +38 -38
  18. package/dist/templates/groups/apps/groups/src/App.tsx +11 -11
  19. package/dist/templates/groups/apps/groups/src/index.css +13 -13
  20. package/dist/templates/groups/apps/groups/src/index.tsx +19 -19
  21. package/dist/templates/groups/apps/groups/vite.config.ts +8 -8
  22. package/dist/templates/groups/template.json +12 -12
  23. package/dist/templates/ioconnect-desktop/.github/actions/setup-smctl/action.yml +121 -121
  24. package/dist/templates/ioconnect-desktop/.github/workflows/build.yml +395 -395
  25. package/dist/templates/ioconnect-desktop/.gitignore.template +15 -15
  26. package/dist/templates/ioconnect-desktop/README.md +795 -780
  27. package/dist/templates/ioconnect-desktop/assets/install.gif +0 -0
  28. package/dist/templates/ioconnect-desktop/config/forge.config.js +38 -59
  29. package/dist/templates/ioconnect-desktop/config/iocd.cli.config.json +16 -16
  30. package/dist/templates/ioconnect-desktop/config/mac-build/entitlements.mac.plist +44 -44
  31. package/dist/templates/ioconnect-desktop/config/win-build/template.nuspectemplate +32 -32
  32. package/dist/templates/ioconnect-desktop/modifications/base/iocd/config/system.json.merge +2 -2
  33. package/dist/templates/ioconnect-desktop/modifications/base/iocd/config/system.json.merge-autoUpdate +9 -9
  34. package/dist/templates/ioconnect-desktop/package.json +33 -33
  35. package/dist/templates/ioconnect-desktop/template.json +6 -6
  36. package/dist/templates/launchpad/apps/launchpad/.eslintrc.json +3 -3
  37. package/dist/templates/launchpad/apps/launchpad/.gitignore.template +1 -1
  38. package/dist/templates/launchpad/apps/launchpad/config/iocd.app.def.dev.json +56 -56
  39. package/dist/templates/launchpad/apps/launchpad/config/iocd.system.build.json +2 -2
  40. package/dist/templates/launchpad/apps/launchpad/config/iocd.system.dev.json +2 -2
  41. package/dist/templates/launchpad/apps/launchpad/index.html +16 -16
  42. package/dist/templates/launchpad/apps/launchpad/iocd.app.json +27 -27
  43. package/dist/templates/launchpad/apps/launchpad/package-lock.json +2778 -2778
  44. package/dist/templates/launchpad/apps/launchpad/package.json +21 -21
  45. package/dist/templates/launchpad/apps/launchpad/src/app/app.tsx +41 -41
  46. package/dist/templates/launchpad/apps/launchpad/src/app/constants.ts +27 -27
  47. package/dist/templates/launchpad/apps/launchpad/src/components/logo.tsx +11 -11
  48. package/dist/templates/launchpad/apps/launchpad/src/components/main-context-menu.tsx +161 -161
  49. package/dist/templates/launchpad/apps/launchpad/src/components/notifications-button.tsx +44 -44
  50. package/dist/templates/launchpad/apps/launchpad/src/main.tsx +6 -6
  51. package/dist/templates/launchpad/apps/launchpad/src/styles.css +16 -16
  52. package/dist/templates/launchpad/apps/launchpad/tsconfig.json +10 -10
  53. package/dist/templates/launchpad/apps/launchpad/vite.config.ts +13 -13
  54. package/dist/templates/launchpad/template.json +12 -12
  55. package/dist/templates/splash/apps/splash/assets/styles/style.css +39 -39
  56. package/dist/templates/splash/apps/splash/iocd.app.json +7 -7
  57. package/dist/templates/splash/apps/splash/script.js +53 -53
  58. package/dist/templates/splash/apps/splash/splash.html +25 -25
  59. package/dist/templates/splash/template.json +12 -12
  60. package/dist/templates/tests/template.json +8 -8
  61. package/dist/templates/tests/tests/package-lock.json +7289 -7289
  62. package/dist/templates/tests/tests/package.json +22 -22
  63. package/dist/templates/tests/tests/tests/sample.spec.ts +30 -30
  64. package/dist/templates/tests/tests/tsconfig.json +10 -10
  65. package/dist/templates/tests/tests/wdio.config.ts +32 -32
  66. package/dist/templates/workspaces/apps/workspaces/README.md +15 -15
  67. package/dist/templates/workspaces/apps/workspaces/config/workspaces-dev.json +20 -20
  68. package/dist/templates/workspaces/apps/workspaces/index.html +17 -17
  69. package/dist/templates/workspaces/apps/workspaces/iocd.app.json +19 -19
  70. package/dist/templates/workspaces/apps/workspaces/package.json +29 -29
  71. package/dist/templates/workspaces/apps/workspaces/public/manifest.json +25 -25
  72. package/dist/templates/workspaces/apps/workspaces/public/robots.txt +3 -3
  73. package/dist/templates/workspaces/apps/workspaces/src/App.css +38 -38
  74. package/dist/templates/workspaces/apps/workspaces/src/App.tsx +102 -102
  75. package/dist/templates/workspaces/apps/workspaces/src/index.css +3 -3
  76. package/dist/templates/workspaces/apps/workspaces/src/index.tsx +28 -28
  77. package/dist/templates/workspaces/apps/workspaces/src/logo.svg +7 -7
  78. package/dist/templates/workspaces/apps/workspaces/src/reportWebVitals.ts +15 -15
  79. package/dist/templates/workspaces/apps/workspaces/src/setupTests.ts +5 -5
  80. package/dist/templates/workspaces/apps/workspaces/vite.config.ts +8 -8
  81. package/dist/templates/workspaces/template.json +12 -12
  82. package/package.json +83 -83
  83. package/scripts/copy-assets.js +19 -19
  84. package/scripts/delete-dist.js +12 -12
  85. package/scripts/generate-schema.js +50 -50
  86. package/scripts/handle-gitignore-templates.js +157 -157
@@ -1,50 +1,50 @@
1
- #!/usr/bin/env node
2
-
3
- const { execSync } = require('child_process');
4
- const fs = require('fs');
5
- const path = require('path');
6
-
7
- console.log('Generating JSON schema from CliConfig interface...');
8
-
9
- const schemaDir = path.join(__dirname, '..', 'dist', 'schemas');
10
- const schemaFile = path.join(schemaDir, 'iocd.cli.config.schema.json');
11
-
12
- // Ensure the schemas directory exists
13
- if (!fs.existsSync(schemaDir)) {
14
- fs.mkdirSync(schemaDir, { recursive: true });
15
- }
16
-
17
- try {
18
- // Generate schema using typescript-json-schema
19
- // Point directly to the source file to avoid compilation issues
20
- execSync(
21
- `npx typescript-json-schema ./src/services/config/cli.config.ts CliConfig --required --noExtraProps --out ${schemaFile}`,
22
- {
23
- cwd: path.join(__dirname, '..'),
24
- stdio: 'inherit'
25
- }
26
- );
27
-
28
- // Read the generated schema
29
- const schema = JSON.parse(fs.readFileSync(schemaFile, 'utf8'));
30
-
31
- // Add metadata at the beginning, preserving proper order
32
- const enhancedSchema = {
33
- "$schema": "http://json-schema.org/draft-07/schema#",
34
- "$id": "https://unpkg.com/@interopio/iocd-cli/schemas/iocd.cli.config.schema.json",
35
- "title": "io.Connect Desktop CLI Configuration",
36
- "description": "Configuration schema for io.Connect Desktop CLI projects",
37
- "additionalProperties": schema.additionalProperties,
38
- "properties": schema.properties,
39
- "required": schema.required,
40
- "type": schema.type || "object"
41
- };
42
-
43
- // Write back the updated schema
44
- fs.writeFileSync(schemaFile, JSON.stringify(enhancedSchema, null, 2));
45
-
46
- console.log('โœ… JSON schema generated successfully at:', schemaFile);
47
- } catch (error) {
48
- console.error('โŒ Error generating JSON schema:', error.message);
49
- process.exit(1);
50
- }
1
+ #!/usr/bin/env node
2
+
3
+ const { execSync } = require('child_process');
4
+ const fs = require('fs');
5
+ const path = require('path');
6
+
7
+ console.log('Generating JSON schema from CliConfig interface...');
8
+
9
+ const schemaDir = path.join(__dirname, '..', 'dist', 'schemas');
10
+ const schemaFile = path.join(schemaDir, 'iocd.cli.config.schema.json');
11
+
12
+ // Ensure the schemas directory exists
13
+ if (!fs.existsSync(schemaDir)) {
14
+ fs.mkdirSync(schemaDir, { recursive: true });
15
+ }
16
+
17
+ try {
18
+ // Generate schema using typescript-json-schema
19
+ // Point directly to the source file to avoid compilation issues
20
+ execSync(
21
+ `npx typescript-json-schema ./src/services/config/cli.config.ts CliConfig --required --noExtraProps --out ${schemaFile}`,
22
+ {
23
+ cwd: path.join(__dirname, '..'),
24
+ stdio: 'inherit'
25
+ }
26
+ );
27
+
28
+ // Read the generated schema
29
+ const schema = JSON.parse(fs.readFileSync(schemaFile, 'utf8'));
30
+
31
+ // Add metadata at the beginning, preserving proper order
32
+ const enhancedSchema = {
33
+ "$schema": "http://json-schema.org/draft-07/schema#",
34
+ "$id": "https://unpkg.com/@interopio/iocd-cli/schemas/iocd.cli.config.schema.json",
35
+ "title": "io.Connect Desktop CLI Configuration",
36
+ "description": "Configuration schema for io.Connect Desktop CLI projects",
37
+ "additionalProperties": schema.additionalProperties,
38
+ "properties": schema.properties,
39
+ "required": schema.required,
40
+ "type": schema.type || "object"
41
+ };
42
+
43
+ // Write back the updated schema
44
+ fs.writeFileSync(schemaFile, JSON.stringify(enhancedSchema, null, 2));
45
+
46
+ console.log('โœ… JSON schema generated successfully at:', schemaFile);
47
+ } catch (error) {
48
+ console.error('โŒ Error generating JSON schema:', error.message);
49
+ process.exit(1);
50
+ }
@@ -1,158 +1,158 @@
1
- #!/usr/bin/env node
2
-
3
- const fs = require('fs');
4
- const path = require('path');
5
-
6
- /**
7
- * Script to handle .gitignore template files for npm packaging
8
- *
9
- * Usage:
10
- * - npm run pre-package: Copies .gitignore files to .gitignore.template
11
- * - npm run post-publish: Removes .gitignore.template files
12
- * - npm run post-install: Renames .gitignore.template back to .gitignore
13
- */
14
-
15
- const templatesDir = path.join(__dirname, '..', 'src', 'templates');
16
- const distTemplatesDir = path.join(__dirname, '..', 'dist', 'templates');
17
-
18
- function findGitignoreFiles(dir) {
19
- const gitignoreFiles = [];
20
-
21
- function walk(currentDir) {
22
- if (!fs.existsSync(currentDir)) return;
23
-
24
- const files = fs.readdirSync(currentDir);
25
-
26
- for (const file of files) {
27
- const filePath = path.join(currentDir, file);
28
- const stat = fs.statSync(filePath);
29
-
30
- if (stat.isDirectory()) {
31
- walk(filePath);
32
- } else if (file === '.gitignore') {
33
- gitignoreFiles.push(filePath);
34
- }
35
- }
36
- }
37
-
38
- walk(dir);
39
- return gitignoreFiles;
40
- }
41
-
42
- function findGitignoreTemplateFiles(dir) {
43
- const templateFiles = [];
44
-
45
- function walk(currentDir) {
46
- if (!fs.existsSync(currentDir)) return;
47
-
48
- const files = fs.readdirSync(currentDir);
49
-
50
- for (const file of files) {
51
- const filePath = path.join(currentDir, file);
52
- const stat = fs.statSync(filePath);
53
-
54
- if (stat.isDirectory()) {
55
- walk(filePath);
56
- } else if (file === '.gitignore.template') {
57
- templateFiles.push(filePath);
58
- }
59
- }
60
- }
61
-
62
- walk(dir);
63
- return templateFiles;
64
- }
65
-
66
- function copyGitignoreToTemplate() {
67
- console.log('๐Ÿ“ฆ Pre-package: Converting .gitignore files to .gitignore.template files...');
68
-
69
- // Handle both src and dist directories
70
- const directories = [templatesDir, distTemplatesDir];
71
- let totalFiles = 0;
72
-
73
- for (const dir of directories) {
74
- if (!fs.existsSync(dir)) continue;
75
-
76
- const gitignoreFiles = findGitignoreFiles(dir);
77
-
78
- for (const gitignoreFile of gitignoreFiles) {
79
- const templateFile = gitignoreFile + '.template';
80
-
81
- try {
82
- fs.copyFileSync(gitignoreFile, templateFile);
83
- console.log(`โœ… Copied: ${path.relative(process.cwd(), gitignoreFile)} โ†’ ${path.relative(process.cwd(), templateFile)}`);
84
- totalFiles++;
85
- } catch (error) {
86
- console.error(`โŒ Failed to copy ${gitignoreFile}:`, error.message);
87
- }
88
- }
89
- }
90
-
91
- console.log(`๐Ÿ“ฆ Pre-package complete: ${totalFiles} .gitignore files converted to .template files`);
92
- }
93
-
94
- function removeTemplateFiles() {
95
- console.log('๐Ÿงน Post-publish: Removing .gitignore.template files...');
96
-
97
- // Handle both src and dist directories
98
- const directories = [templatesDir, distTemplatesDir];
99
- let totalFiles = 0;
100
-
101
- for (const dir of directories) {
102
- if (!fs.existsSync(dir)) continue;
103
-
104
- const templateFiles = findGitignoreTemplateFiles(dir);
105
-
106
- for (const templateFile of templateFiles) {
107
- try {
108
- fs.unlinkSync(templateFile);
109
- console.log(`๐Ÿ—‘๏ธ Removed: ${path.relative(process.cwd(), templateFile)}`);
110
- totalFiles++;
111
- } catch (error) {
112
- console.error(`โŒ Failed to remove ${templateFile}:`, error.message);
113
- }
114
- }
115
- }
116
-
117
- console.log(`๐Ÿงน Post-publish complete: ${totalFiles} .gitignore.template files removed`);
118
- }
119
-
120
- function convertTemplateToGitignore() {
121
- console.log('๐Ÿ”„ Post-install: Converting .gitignore.template files back to .gitignore...');
122
-
123
- // Only handle dist directory for post-install
124
- const templateFiles = findGitignoreTemplateFiles(distTemplatesDir);
125
- let totalFiles = 0;
126
-
127
- for (const templateFile of templateFiles) {
128
- const gitignoreFile = templateFile.replace('.template', '');
129
-
130
- try {
131
- fs.renameSync(templateFile, gitignoreFile);
132
- console.log(`โœ… Converted: ${path.relative(process.cwd(), templateFile)} โ†’ ${path.relative(process.cwd(), gitignoreFile)}`);
133
- totalFiles++;
134
- } catch (error) {
135
- console.error(`โŒ Failed to convert ${templateFile}:`, error.message);
136
- }
137
- }
138
-
139
- console.log(`๐Ÿ”„ Post-install complete: ${totalFiles} .gitignore.template files converted back to .gitignore`);
140
- }
141
-
142
- // Parse command line arguments
143
- const command = process.argv[2];
144
-
145
- switch (command) {
146
- case 'pre-package':
147
- copyGitignoreToTemplate();
148
- break;
149
- case 'post-publish':
150
- removeTemplateFiles();
151
- break;
152
- case 'post-install':
153
- convertTemplateToGitignore();
154
- break;
155
- default:
156
- console.error('Usage: node handle-gitignore-templates.js <pre-package|post-publish|post-install>');
157
- process.exit(1);
1
+ #!/usr/bin/env node
2
+
3
+ const fs = require('fs');
4
+ const path = require('path');
5
+
6
+ /**
7
+ * Script to handle .gitignore template files for npm packaging
8
+ *
9
+ * Usage:
10
+ * - npm run pre-package: Copies .gitignore files to .gitignore.template
11
+ * - npm run post-publish: Removes .gitignore.template files
12
+ * - npm run post-install: Renames .gitignore.template back to .gitignore
13
+ */
14
+
15
+ const templatesDir = path.join(__dirname, '..', 'src', 'templates');
16
+ const distTemplatesDir = path.join(__dirname, '..', 'dist', 'templates');
17
+
18
+ function findGitignoreFiles(dir) {
19
+ const gitignoreFiles = [];
20
+
21
+ function walk(currentDir) {
22
+ if (!fs.existsSync(currentDir)) return;
23
+
24
+ const files = fs.readdirSync(currentDir);
25
+
26
+ for (const file of files) {
27
+ const filePath = path.join(currentDir, file);
28
+ const stat = fs.statSync(filePath);
29
+
30
+ if (stat.isDirectory()) {
31
+ walk(filePath);
32
+ } else if (file === '.gitignore') {
33
+ gitignoreFiles.push(filePath);
34
+ }
35
+ }
36
+ }
37
+
38
+ walk(dir);
39
+ return gitignoreFiles;
40
+ }
41
+
42
+ function findGitignoreTemplateFiles(dir) {
43
+ const templateFiles = [];
44
+
45
+ function walk(currentDir) {
46
+ if (!fs.existsSync(currentDir)) return;
47
+
48
+ const files = fs.readdirSync(currentDir);
49
+
50
+ for (const file of files) {
51
+ const filePath = path.join(currentDir, file);
52
+ const stat = fs.statSync(filePath);
53
+
54
+ if (stat.isDirectory()) {
55
+ walk(filePath);
56
+ } else if (file === '.gitignore.template') {
57
+ templateFiles.push(filePath);
58
+ }
59
+ }
60
+ }
61
+
62
+ walk(dir);
63
+ return templateFiles;
64
+ }
65
+
66
+ function copyGitignoreToTemplate() {
67
+ console.log('๐Ÿ“ฆ Pre-package: Converting .gitignore files to .gitignore.template files...');
68
+
69
+ // Handle both src and dist directories
70
+ const directories = [templatesDir, distTemplatesDir];
71
+ let totalFiles = 0;
72
+
73
+ for (const dir of directories) {
74
+ if (!fs.existsSync(dir)) continue;
75
+
76
+ const gitignoreFiles = findGitignoreFiles(dir);
77
+
78
+ for (const gitignoreFile of gitignoreFiles) {
79
+ const templateFile = gitignoreFile + '.template';
80
+
81
+ try {
82
+ fs.copyFileSync(gitignoreFile, templateFile);
83
+ console.log(`โœ… Copied: ${path.relative(process.cwd(), gitignoreFile)} โ†’ ${path.relative(process.cwd(), templateFile)}`);
84
+ totalFiles++;
85
+ } catch (error) {
86
+ console.error(`โŒ Failed to copy ${gitignoreFile}:`, error.message);
87
+ }
88
+ }
89
+ }
90
+
91
+ console.log(`๐Ÿ“ฆ Pre-package complete: ${totalFiles} .gitignore files converted to .template files`);
92
+ }
93
+
94
+ function removeTemplateFiles() {
95
+ console.log('๐Ÿงน Post-publish: Removing .gitignore.template files...');
96
+
97
+ // Handle both src and dist directories
98
+ const directories = [templatesDir, distTemplatesDir];
99
+ let totalFiles = 0;
100
+
101
+ for (const dir of directories) {
102
+ if (!fs.existsSync(dir)) continue;
103
+
104
+ const templateFiles = findGitignoreTemplateFiles(dir);
105
+
106
+ for (const templateFile of templateFiles) {
107
+ try {
108
+ fs.unlinkSync(templateFile);
109
+ console.log(`๐Ÿ—‘๏ธ Removed: ${path.relative(process.cwd(), templateFile)}`);
110
+ totalFiles++;
111
+ } catch (error) {
112
+ console.error(`โŒ Failed to remove ${templateFile}:`, error.message);
113
+ }
114
+ }
115
+ }
116
+
117
+ console.log(`๐Ÿงน Post-publish complete: ${totalFiles} .gitignore.template files removed`);
118
+ }
119
+
120
+ function convertTemplateToGitignore() {
121
+ console.log('๐Ÿ”„ Post-install: Converting .gitignore.template files back to .gitignore...');
122
+
123
+ // Only handle dist directory for post-install
124
+ const templateFiles = findGitignoreTemplateFiles(distTemplatesDir);
125
+ let totalFiles = 0;
126
+
127
+ for (const templateFile of templateFiles) {
128
+ const gitignoreFile = templateFile.replace('.template', '');
129
+
130
+ try {
131
+ fs.renameSync(templateFile, gitignoreFile);
132
+ console.log(`โœ… Converted: ${path.relative(process.cwd(), templateFile)} โ†’ ${path.relative(process.cwd(), gitignoreFile)}`);
133
+ totalFiles++;
134
+ } catch (error) {
135
+ console.error(`โŒ Failed to convert ${templateFile}:`, error.message);
136
+ }
137
+ }
138
+
139
+ console.log(`๐Ÿ”„ Post-install complete: ${totalFiles} .gitignore.template files converted back to .gitignore`);
140
+ }
141
+
142
+ // Parse command line arguments
143
+ const command = process.argv[2];
144
+
145
+ switch (command) {
146
+ case 'pre-package':
147
+ copyGitignoreToTemplate();
148
+ break;
149
+ case 'post-publish':
150
+ removeTemplateFiles();
151
+ break;
152
+ case 'post-install':
153
+ convertTemplateToGitignore();
154
+ break;
155
+ default:
156
+ console.error('Usage: node handle-gitignore-templates.js <pre-package|post-publish|post-install>');
157
+ process.exit(1);
158
158
  }