@appsemble/cli 0.20.28 → 0.20.29

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 (136) hide show
  1. package/README.md +4 -4
  2. package/index.js +0 -0
  3. package/package.json +5 -5
  4. package/__fixtures__/getBlockConfigFromTypeScript/comments/index.ts +0 -40
  5. package/__fixtures__/getBlockConfigFromTypeScript/comments/tsconfig.json +0 -7
  6. package/__fixtures__/getBlockConfigFromTypeScript/duplicateActions/index.ts +0 -34
  7. package/__fixtures__/getBlockConfigFromTypeScript/duplicateActions/tsconfig.json +0 -7
  8. package/__fixtures__/getBlockConfigFromTypeScript/duplicateEventEmitters/index.ts +0 -34
  9. package/__fixtures__/getBlockConfigFromTypeScript/duplicateEventEmitters/tsconfig.json +0 -7
  10. package/__fixtures__/getBlockConfigFromTypeScript/duplicateEventListeners/index.ts +0 -34
  11. package/__fixtures__/getBlockConfigFromTypeScript/duplicateEventListeners/tsconfig.json +0 -7
  12. package/__fixtures__/getBlockConfigFromTypeScript/duplicateParameters/index.ts +0 -34
  13. package/__fixtures__/getBlockConfigFromTypeScript/duplicateParameters/tsconfig.json +0 -7
  14. package/__fixtures__/getBlockConfigFromTypeScript/fontawesomeParameters/index.ts +0 -11
  15. package/__fixtures__/getBlockConfigFromTypeScript/fontawesomeParameters/tsconfig.json +0 -7
  16. package/__fixtures__/getBlockConfigFromTypeScript/tsError/index.ts +0 -4
  17. package/__fixtures__/getBlockConfigFromTypeScript/tsError/tsconfig.json +0 -8
  18. package/__fixtures__/getBlockConfigFromTypeScript/valid/index.ts +0 -28
  19. package/__fixtures__/getBlockConfigFromTypeScript/valid/tsconfig.json +0 -7
  20. package/__fixtures__/makePayload/with-icon/icon.svg +0 -2
  21. package/assets/appsemblerc.schema.json +0 -150
  22. package/changed/added/.gitkeep +0 -0
  23. package/changed/changed/.gitkeep +0 -0
  24. package/changed/deprecated/.gitkeep +0 -0
  25. package/changed/fixed/.gitkeep +0 -0
  26. package/changed/removed/.gitkeep +0 -0
  27. package/changed/security/.gitkeep +0 -0
  28. package/commands/app/create.js.map +0 -1
  29. package/commands/app/create.ts +0 -104
  30. package/commands/app/extract-messages.js.map +0 -1
  31. package/commands/app/extract-messages.ts +0 -56
  32. package/commands/app/index.js.map +0 -1
  33. package/commands/app/index.ts +0 -18
  34. package/commands/app/update.js.map +0 -1
  35. package/commands/app/update.ts +0 -111
  36. package/commands/asset/create.js.map +0 -1
  37. package/commands/asset/create.ts +0 -84
  38. package/commands/asset/index.js.map +0 -1
  39. package/commands/asset/index.ts +0 -12
  40. package/commands/block/build.js.map +0 -1
  41. package/commands/block/build.ts +0 -32
  42. package/commands/block/extract-messages.js.map +0 -1
  43. package/commands/block/extract-messages.ts +0 -41
  44. package/commands/block/index.js.map +0 -1
  45. package/commands/block/index.ts +0 -18
  46. package/commands/block/publish.js.map +0 -1
  47. package/commands/block/publish.ts +0 -58
  48. package/commands/cleanupResources.js.map +0 -1
  49. package/commands/cleanupResources.ts +0 -45
  50. package/commands/config/get.js.map +0 -1
  51. package/commands/config/get.ts +0 -27
  52. package/commands/config/index.js.map +0 -1
  53. package/commands/config/index.ts +0 -16
  54. package/commands/config/set.js.map +0 -1
  55. package/commands/config/set.ts +0 -45
  56. package/commands/login.js.map +0 -1
  57. package/commands/login.ts +0 -5
  58. package/commands/logout.js.map +0 -1
  59. package/commands/logout.ts +0 -5
  60. package/commands/migrate.js.map +0 -1
  61. package/commands/migrate.ts +0 -50
  62. package/commands/organization/create.js.map +0 -1
  63. package/commands/organization/create.ts +0 -65
  64. package/commands/organization/index.js.map +0 -1
  65. package/commands/organization/index.ts +0 -16
  66. package/commands/organization/update.js.map +0 -1
  67. package/commands/organization/update.ts +0 -65
  68. package/commands/resource/create.js.map +0 -1
  69. package/commands/resource/create.ts +0 -78
  70. package/commands/resource/index.js.map +0 -1
  71. package/commands/resource/index.ts +0 -16
  72. package/commands/resource/update.js.map +0 -1
  73. package/commands/resource/update.ts +0 -77
  74. package/commands/runCronJobs.js.map +0 -1
  75. package/commands/runCronJobs.ts +0 -45
  76. package/commands/start.js.map +0 -1
  77. package/commands/start.ts +0 -140
  78. package/commands/team/create.js.map +0 -1
  79. package/commands/team/create.ts +0 -60
  80. package/commands/team/delete.js.map +0 -1
  81. package/commands/team/delete.ts +0 -54
  82. package/commands/team/index.js.map +0 -1
  83. package/commands/team/index.ts +0 -20
  84. package/commands/team/member/delete.js.map +0 -1
  85. package/commands/team/member/delete.ts +0 -61
  86. package/commands/team/member/index.js.map +0 -1
  87. package/commands/team/member/index.ts +0 -18
  88. package/commands/team/member/invite.js.map +0 -1
  89. package/commands/team/member/invite.ts +0 -61
  90. package/commands/team/member/update.js.map +0 -1
  91. package/commands/team/member/update.ts +0 -70
  92. package/commands/team/update.js.map +0 -1
  93. package/commands/team/update.ts +0 -60
  94. package/index.js.map +0 -1
  95. package/index.ts +0 -74
  96. package/jest.config.js +0 -3
  97. package/jest.setup.js.map +0 -1
  98. package/jest.setup.ts +0 -4
  99. package/lib/__snapshots__/getBlockConfigFromTypeScript.test.ts.snap +0 -4241
  100. package/lib/app.js.map +0 -1
  101. package/lib/app.ts +0 -795
  102. package/lib/asset.js.map +0 -1
  103. package/lib/asset.ts +0 -43
  104. package/lib/authentication.js.map +0 -1
  105. package/lib/authentication.ts +0 -194
  106. package/lib/block.js.map +0 -1
  107. package/lib/block.test.js.map +0 -1
  108. package/lib/block.test.ts +0 -103
  109. package/lib/block.ts +0 -384
  110. package/lib/coercers.js.map +0 -1
  111. package/lib/coercers.test.js.map +0 -1
  112. package/lib/coercers.test.ts +0 -27
  113. package/lib/coercers.ts +0 -58
  114. package/lib/getBlockConfigFromTypeScript.js.map +0 -1
  115. package/lib/getBlockConfigFromTypeScript.test.js.map +0 -1
  116. package/lib/getBlockConfigFromTypeScript.test.ts +0 -282
  117. package/lib/getBlockConfigFromTypeScript.ts +0 -356
  118. package/lib/initAxios.js.map +0 -1
  119. package/lib/initAxios.ts +0 -16
  120. package/lib/loadWebpackConfig.js.map +0 -1
  121. package/lib/loadWebpackConfig.ts +0 -52
  122. package/lib/organization.js.map +0 -1
  123. package/lib/organization.ts +0 -105
  124. package/lib/output.js.map +0 -1
  125. package/lib/output.ts +0 -19
  126. package/lib/processCss.js.map +0 -1
  127. package/lib/processCss.ts +0 -24
  128. package/lib/resource.js.map +0 -1
  129. package/lib/resource.ts +0 -128
  130. package/lib/serverImport.js.map +0 -1
  131. package/lib/serverImport.ts +0 -42
  132. package/lib/team.js.map +0 -1
  133. package/lib/team.ts +0 -152
  134. package/tsconfig.json +0 -9
  135. package/types.js.map +0 -1
  136. package/types.ts +0 -110
package/README.md CHANGED
@@ -1,10 +1,10 @@
1
- # ![](https://gitlab.com/appsemble/appsemble/-/raw/0.20.28/config/assets/logo.svg) Appsemble CLI
1
+ # ![](https://gitlab.com/appsemble/appsemble/-/raw/0.20.29/config/assets/logo.svg) Appsemble CLI
2
2
 
3
3
  > Manage apps and blocks from the command line.
4
4
 
5
5
  [![npm](https://img.shields.io/npm/v/@appsemble/cli)](https://www.npmjs.com/package/@appsemble/cli)
6
- [![GitLab CI](https://gitlab.com/appsemble/appsemble/badges/0.20.28/pipeline.svg)](https://gitlab.com/appsemble/appsemble/-/releases/0.20.28)
7
- [![Code coverage](https://codecov.io/gl/appsemble/appsemble/branch/0.20.28/graph/badge.svg)](https://codecov.io/gl/appsemble/appsemble)
6
+ [![GitLab CI](https://gitlab.com/appsemble/appsemble/badges/0.20.29/pipeline.svg)](https://gitlab.com/appsemble/appsemble/-/releases/0.20.29)
7
+ [![Code coverage](https://codecov.io/gl/appsemble/appsemble/branch/0.20.29/graph/badge.svg)](https://codecov.io/gl/appsemble/appsemble)
8
8
  [![Prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg)](https://prettier.io)
9
9
 
10
10
  ## Installation
@@ -95,5 +95,5 @@ appsemble asset create --app-id 1 path/to/example-asset.png
95
95
 
96
96
  ## License
97
97
 
98
- [LGPL-3.0-only](https://gitlab.com/appsemble/appsemble/-/blob/0.20.28/LICENSE.md) ©
98
+ [LGPL-3.0-only](https://gitlab.com/appsemble/appsemble/-/blob/0.20.29/LICENSE.md) ©
99
99
  [Appsemble](https://appsemble.com)
package/index.js CHANGED
File without changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@appsemble/cli",
3
- "version": "0.20.28",
3
+ "version": "0.20.29",
4
4
  "description": "The CLI for developing with Appsemble apps and blocks",
5
5
  "keywords": [
6
6
  "app",
@@ -34,9 +34,9 @@
34
34
  "test": "NODE_OPTIONS=--experimental-vm-modules jest"
35
35
  },
36
36
  "dependencies": {
37
- "@appsemble/node-utils": "0.20.28",
38
- "@appsemble/types": "0.20.28",
39
- "@appsemble/utils": "0.20.28",
37
+ "@appsemble/node-utils": "0.20.29",
38
+ "@appsemble/types": "0.20.29",
39
+ "@appsemble/utils": "0.20.29",
40
40
  "@fortawesome/fontawesome-common-types": "^6.0.0",
41
41
  "axios": "^0.27.0",
42
42
  "chalk": "^4.0.0",
@@ -62,7 +62,7 @@
62
62
  "yargs": "^17.0.0"
63
63
  },
64
64
  "devDependencies": {
65
- "@appsemble/types": "0.20.28",
65
+ "@appsemble/types": "0.20.29",
66
66
  "@types/concat-stream": "^2.0.0",
67
67
  "@types/inquirer": "^9.0.0",
68
68
  "@types/normalize-path": "^3.0.0",
@@ -1,40 +0,0 @@
1
- import '@appsemble/sdk';
2
-
3
- declare module '@appsemble/sdk' {
4
- interface Actions {
5
- /**
6
- * Valid action comment
7
- */
8
- comment: never;
9
-
10
- /**
11
- * Unexpected comment
12
- */
13
- /**
14
- * Expected comment
15
- */
16
- duplicate: never;
17
-
18
- // Ignored line comment
19
- line: never;
20
- }
21
-
22
- interface EventEmitters {
23
- /**
24
- * Test event emitter.
25
- */
26
- testEmit: never;
27
- }
28
-
29
- interface EventListeners {
30
- /**
31
- * Test event listener.
32
- */
33
- testListener: never;
34
- }
35
-
36
- // Comments are extracted by typescript-json-schema
37
- interface Parameters {
38
- param: any;
39
- }
40
- }
@@ -1,7 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "types": ["jest"]
6
- }
7
- }
@@ -1,34 +0,0 @@
1
- import '@appsemble/sdk';
2
-
3
- declare module '@appsemble/sdk' {
4
- interface Actions {
5
- testAction: never;
6
- }
7
-
8
- interface EventEmitters {
9
- testEmit: never;
10
- }
11
-
12
- interface EventListeners {
13
- testListener: never;
14
- }
15
-
16
- interface Parameters {
17
- param1: string;
18
- param2: number;
19
- param3: boolean;
20
- param4?: string;
21
- param5: {
22
- nested1: string;
23
- nested2: number;
24
- nested3: boolean;
25
- };
26
- param6: string[];
27
- }
28
- }
29
-
30
- declare module '@appsemble/sdk' {
31
- interface Actions {
32
- duplicate: never;
33
- }
34
- }
@@ -1,7 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "types": ["jest"]
6
- }
7
- }
@@ -1,34 +0,0 @@
1
- import '@appsemble/sdk';
2
-
3
- declare module '@appsemble/sdk' {
4
- interface Actions {
5
- testAction: never;
6
- }
7
-
8
- interface EventEmitters {
9
- testEmit: never;
10
- }
11
-
12
- interface EventListeners {
13
- testListener: never;
14
- }
15
-
16
- interface Parameters {
17
- param1: string;
18
- param2: number;
19
- param3: boolean;
20
- param4?: string;
21
- param5: {
22
- nested1: string;
23
- nested2: number;
24
- nested3: boolean;
25
- };
26
- param6: string[];
27
- }
28
- }
29
-
30
- declare module '@appsemble/sdk' {
31
- interface EventEmitters {
32
- duplicate: never;
33
- }
34
- }
@@ -1,7 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "types": ["jest"]
6
- }
7
- }
@@ -1,34 +0,0 @@
1
- import '@appsemble/sdk';
2
-
3
- declare module '@appsemble/sdk' {
4
- interface Actions {
5
- testAction: never;
6
- }
7
-
8
- interface EventEmitters {
9
- testEmit: never;
10
- }
11
-
12
- interface EventListeners {
13
- testListener: never;
14
- }
15
-
16
- interface Parameters {
17
- param1: string;
18
- param2: number;
19
- param3: boolean;
20
- param4?: string;
21
- param5: {
22
- nested1: string;
23
- nested2: number;
24
- nested3: boolean;
25
- };
26
- param6: string[];
27
- }
28
- }
29
-
30
- declare module '@appsemble/sdk' {
31
- interface EventListeners {
32
- duplicate: never;
33
- }
34
- }
@@ -1,7 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "types": ["jest"]
6
- }
7
- }
@@ -1,34 +0,0 @@
1
- import '@appsemble/sdk';
2
-
3
- declare module '@appsemble/sdk' {
4
- interface Actions {
5
- testAction: never;
6
- }
7
-
8
- interface EventEmitters {
9
- testEmit: never;
10
- }
11
-
12
- interface EventListeners {
13
- testListener: never;
14
- }
15
-
16
- interface Parameters {
17
- param1: string;
18
- param2: number;
19
- param3: boolean;
20
- param4?: string;
21
- param5: {
22
- nested1: string;
23
- nested2: number;
24
- nested3: boolean;
25
- };
26
- param6: string[];
27
- }
28
- }
29
-
30
- declare module '@appsemble/sdk' {
31
- interface Parameters {
32
- duplicate: never;
33
- }
34
- }
@@ -1,7 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "types": ["jest"]
6
- }
7
- }
@@ -1,11 +0,0 @@
1
- import '@appsemble/sdk';
2
- import { IconName } from '@fortawesome/fontawesome-common-types';
3
-
4
- declare module '@appsemble/sdk' {
5
- interface Parameters {
6
- /**
7
- * This is an icon.
8
- */
9
- icon?: IconName;
10
- }
11
- }
@@ -1,7 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "types": ["jest"]
6
- }
7
- }
@@ -1,4 +0,0 @@
1
- import '@appsemble/sdk';
2
-
3
- // eslint-disable-next-line @typescript-eslint/no-unused-vars
4
- const unused = undefined;
@@ -1,8 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "noUnusedLocals": true,
6
- "types": ["jest"]
7
- }
8
- }
@@ -1,28 +0,0 @@
1
- import '@appsemble/sdk';
2
-
3
- declare module '@appsemble/sdk' {
4
- interface Actions {
5
- testAction: never;
6
- }
7
-
8
- interface EventEmitters {
9
- testEmit: never;
10
- }
11
-
12
- interface EventListeners {
13
- testListener: never;
14
- }
15
-
16
- interface Parameters {
17
- param1: string;
18
- param2: number;
19
- param3: boolean;
20
- param4?: string;
21
- param5: {
22
- nested1: string;
23
- nested2: number;
24
- nested3: boolean;
25
- };
26
- param6: string[];
27
- }
28
- }
@@ -1,7 +0,0 @@
1
- {
2
- "extends": "../../../../../tsconfig",
3
- "compilerOptions": {
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "types": ["jest"]
6
- }
7
- }
@@ -1,2 +0,0 @@
1
- <?xml version="1.0" standalone="no"?>
2
- <svg />
@@ -1,150 +0,0 @@
1
- {
2
- "$schema": "http://json-schema.org/draft-04/schema",
3
- "title": ".appsemblerc.yaml",
4
- "description": "A .appsemblerc.yaml file may be used to configure either an app or a block.",
5
- "type": "object",
6
- "additionalProperties": false,
7
-
8
- "properties": {
9
- "name": {
10
- "description": "The name of a block. By default the name in package.json is used.",
11
- "type": "string",
12
- "pattern": "^@([\\da-z](?:(?!.*--)[\\da-z-]*[\\da-z])?)/([\\da-z](?:(?!.*--)[\\da-z-]*[\\da-z])?)$"
13
- },
14
- "description": {
15
- "description": "A short description of the block. By default the description in package.json is used.",
16
- "maxLength": 160
17
- },
18
- "version": {
19
- "description": "A semantic version of the block representation of the block version. By default the version in package.json is used."
20
- },
21
- "longDescription": {
22
- "description": "The long description of the block. Markdown is supported. By default the content of README.md is used.",
23
- "type": "string"
24
- },
25
- "layout": {
26
- "description": "The type of layout to be used for the block.",
27
- "enum": ["float", "grow", "hidden", "static", null],
28
- "default": "static"
29
- },
30
- "output": {
31
- "description": "Where to read build output from.",
32
- "type": "string",
33
- "default": "dist"
34
- },
35
- "webpack": {
36
- "description": "The path to the webpack configuration file relative to the block project directory. By default a file named webpack.config.js is used, with a fallback to the webpack configuration from @appsemble/webpack-config.",
37
- "type": "string"
38
- },
39
- "events": {
40
- "type": "object",
41
- "description": "An object describing the names of the events the block can listen and emit to. By default this is extracted from the block’s TypeScript module augmentations.",
42
- "additionalProperties": false,
43
- "properties": {
44
- "listen": {
45
- "description": "The events the block listens on.",
46
- "type": "object",
47
- "additionalProperties": {
48
- "type": "object",
49
- "properties": {
50
- "description": {
51
- "type": "string"
52
- }
53
- }
54
- }
55
- },
56
- "emit": {
57
- "description": "The events the block may emit.",
58
- "type": "object",
59
- "additionalProperties": {
60
- "type": "object",
61
- "properties": {
62
- "description": {
63
- "type": "string"
64
- }
65
- }
66
- }
67
- }
68
- }
69
- },
70
- "actions": {
71
- "description": "An object which describes the actions a block can trigger. This will be used to validate app definitions. By default this is extracted from the block’s TypeScript module augmentations.",
72
- "type": "object",
73
- "additionalProperties": true
74
- },
75
- "parameters": {
76
- "description": "A JSON schema which describes the block parameters. By default this is extracted from the block’s TypeScript module augmentations."
77
- },
78
- "iconBackground": {
79
- "description": "The background color to use for maskable icons.",
80
- "type": "string",
81
- "pattern": "^#[a-zA-Z\\d]{6}$"
82
- },
83
- "context": {
84
- "type": "object",
85
- "description": "A context which can be specified using the --context command line parameter.",
86
- "additionalProperties": {
87
- "type": "object",
88
- "additionalProperties": false,
89
- "properties": {
90
- "remote": {
91
- "description": "If remote is specified, this will override --remote passed by the command line.",
92
- "type": "string",
93
- "format": "uri",
94
- "default": "https://appsemble.app"
95
- },
96
- "organization": {
97
- "description": "If organization is specified, this will override --organization passed by the command line when creating an app.",
98
- "type": "string",
99
- "pattern": "^([\\da-z](?:(?!.*--)[\\da-z-]*[\\da-z])?)$",
100
- "minLength": 1,
101
- "maxLength": 30
102
- },
103
- "icon": {
104
- "description": "A path to the app icon to use",
105
- "type": "string",
106
- "default": "icon.png"
107
- },
108
- "iconBackground": {
109
- "description": "The background color to use for maskable icons.",
110
- "type": "string",
111
- "pattern": "^#[a-zA-Z\\d]{6}$"
112
- },
113
- "maskableIcon": {
114
- "description": "A path to the maskable app icon to use",
115
- "type": "string",
116
- "default": "maskable-icon.png"
117
- },
118
- "id": {
119
- "description": "If id is specified, this will override --id passed by the command line when updating an app.",
120
- "type": "integer",
121
- "minimum": 1
122
- },
123
- "visibility": {
124
- "description": "Determine the app visibility of the app in the Appsemble app store.\n\nThis doesn’t affect whether or not the app can be accessed on its own domain.\n\n- **public**: The app is publicly listed in the Appsemble app store.,\n- **unlisted**: The app store page can be accessed, but the app isn’t listed publicly in the Appsemble app store.\n- **private**: The app is only visible to people who are part of the organization.",
125
- "default": "unlisted",
126
- "enum": ["public", "unlisted", "private"]
127
- },
128
- "showAppDefinition": {
129
- "description": "Whether or not people who have access to the app may see the app definition.",
130
- "type": "boolean"
131
- },
132
- "template": {
133
- "description": "If template is specified, this will override --template passed on the command line.",
134
- "type": "boolean",
135
- "default": false
136
- },
137
- "sentryDsn": {
138
- "type": "string",
139
- "format": "uri",
140
- "description": "A custom Sentry DSN to use for the app."
141
- },
142
- "sentryEnvironment": {
143
- "type": "string",
144
- "description": "A custom Sentry environment to use for the app."
145
- }
146
- }
147
- }
148
- }
149
- }
150
- }
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -1 +0,0 @@
1
- {"version":3,"file":"create.js","sourceRoot":"","sources":["create.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAE/C,OAAO,EAAE,MAAM,WAAW,CAAC;AAC3B,OAAO,aAAa,MAAM,gBAAgB,CAAC;AAG3C,OAAO,EAAE,SAAS,EAAE,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SAAS;KAChB,CAAC;SACD,MAAM,CAAC,qBAAqB,EAAE;QAC7B,QAAQ,EAAE,0CAA0C;KACrD,CAAC;SACD,MAAM,CAAC,YAAY,EAAE;QACpB,QAAQ,EAAE,oCAAoC;KAC/C,CAAC;SACD,MAAM,CAAC,oBAAoB,EAAE;QAC5B,QAAQ,EAAE,wDAAwD;QAClE,OAAO,EAAE,CAAC,YAAY,CAAC;KACxB,CAAC,CAAC;AACP,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,OAAO,CAAC,EAAE,KAAK,EAAE,GAAG,IAAI,EAAsB;IAClE,MAAM,eAAe,GAAG,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC;IACjE,MAAM,WAAW,GAAG,MAAM,EAAE,CAAC,eAAe,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,eAAe,EAAE,IAAI,EAAE,CAAC,CAAC;IAEzF,MAAM,CAAC,IAAI,CAAC,YAAY,WAAW,CAAC,MAAM,OAAO,CAAC,CAAC;IACnD,KAAK,MAAM,GAAG,IAAI,WAAW,EAAE;QAC7B,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QAChB,MAAM,SAAS,CAAC;YACd,GAAG,IAAI;YACP,IAAI,EAAE,GAAG;SACV,CAAC,CAAC;KACJ;AACH,CAAC"}
@@ -1,104 +0,0 @@
1
- import { ReadStream } from 'node:fs';
2
-
3
- import { logger } from '@appsemble/node-utils';
4
- import { AppVisibility } from '@appsemble/types';
5
- import fg from 'fast-glob';
6
- import normalizePath from 'normalize-path';
7
- import { Argv } from 'yargs';
8
-
9
- import { createApp } from '../../lib/app.js';
10
- import { coerceFile } from '../../lib/coercers.js';
11
- import { BaseArguments } from '../../types.js';
12
-
13
- interface CreateAppArguments extends BaseArguments {
14
- context: string;
15
- icon: NodeJS.ReadStream | ReadStream;
16
- iconBackground: string;
17
- maskableIcon: NodeJS.ReadStream | ReadStream;
18
- paths: string[];
19
- organization: string;
20
- template: boolean;
21
- dryRun: boolean;
22
- resources: boolean;
23
- modifyContext: boolean;
24
- visibility: AppVisibility;
25
- sentryDsn: string;
26
- sentryEnvironment: string;
27
- googleAnalyticsId: string;
28
- }
29
-
30
- export const command = 'create <paths...>';
31
- export const description = 'Create a new App based on a specified YAML file or directory.';
32
-
33
- export function builder(yargs: Argv): Argv<any> {
34
- return yargs
35
- .positional('paths', {
36
- describe: 'The paths to the apps to create.',
37
- })
38
- .option('context', {
39
- describe: 'If specified, use the specified context from .appsemblerc.yaml',
40
- })
41
- .option('organization', {
42
- describe: 'The ID the app should be created for.',
43
- })
44
- .option('icon', {
45
- describe: 'The icon to upload. By default "icon.png" in the app directory is used.',
46
- coerce: coerceFile,
47
- })
48
- .option('icon-background', {
49
- describe: 'The background color to use for the icon in opaque contexts.',
50
- default: '#ffffff',
51
- })
52
- .option('maskable-icon', {
53
- describe:
54
- 'The maskable icon to upload. By default "maskable-icon.png" in the app directory is used.',
55
- coerce: coerceFile,
56
- })
57
- .option('visibility', {
58
- describe: 'Visibility of the app in the public app store.',
59
- default: 'unlisted',
60
- choices: ['public', 'unlisted', 'private'],
61
- })
62
- .option('template', {
63
- describe: 'Whether the app should be marked as a template.',
64
- type: 'boolean',
65
- })
66
- .option('dry-run', {
67
- describe: 'Whether the API should be called to run without actually creating the app.',
68
- type: 'boolean',
69
- })
70
- .option('resources', {
71
- describe:
72
- 'Whether the resources from the `resources` directory should be created after creating the app. The names of subdirectories are used as the name of the resource, otherwise the names of top level resource .json files are used instead.',
73
- type: 'boolean',
74
- })
75
- .option('modify-context', {
76
- describe:
77
- 'If the app context is specified, modify it for the current context to include the id of the created app.',
78
- type: 'boolean',
79
- })
80
- .option('google-analytics-id', {
81
- describe: 'The ID for Google Analytics for the app.',
82
- })
83
- .option('sentry-dsn', {
84
- describe: 'The custom Sentry DSN for the app.',
85
- })
86
- .option('sentry-environment', {
87
- describe: 'The environment for the custom Sentry DSN for the app.',
88
- implies: ['sentry-dsn'],
89
- });
90
- }
91
-
92
- export async function handler({ paths, ...args }: CreateAppArguments): Promise<void> {
93
- const normalizedPaths = paths.map((path) => normalizePath(path));
94
- const directories = await fg(normalizedPaths, { absolute: true, onlyDirectories: true });
95
-
96
- logger.info(`Creating ${directories.length} apps`);
97
- for (const dir of directories) {
98
- logger.info('');
99
- await createApp({
100
- ...args,
101
- path: dir,
102
- });
103
- }
104
- }
@@ -1 +0,0 @@
1
- {"version":3,"file":"extract-messages.js","sourceRoot":"","sources":["extract-messages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAC/C,OAAO,EAAE,MAAM,WAAW,CAAC;AAC3B,OAAO,aAAa,MAAM,gBAAgB,CAAC;AAG3C,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAUpD,MAAM,CAAC,MAAM,OAAO,GAAG,6BAA6B,CAAC;AACrD,MAAM,CAAC,MAAM,WAAW,GAAG,gCAAgC,CAAC;AAE5D,MAAM,UAAU,OAAO,CAAC,KAAW;IACjC,OAAO,KAAK;SACT,UAAU,CAAC,OAAO,EAAE;QACnB,QAAQ,EAAE,iDAAiD;KAC5D,CAAC;SACD,MAAM,CAAC,WAAW,EAAE;QACnB,QAAQ,EAAE,qDAAqD;KAChE,CAAC;SACD,MAAM,CAAC,QAAQ,EAAE;QAChB,QAAQ,EAAE,gDAAgD;QAC1D,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;QACzB,OAAO,EAAE,MAAM;KAChB,CAAC;SACD,MAAM,CAAC,QAAQ,EAAE;QAChB,QAAQ,EACN,yHAAyH;KAC5H,CAAC,CAAC;AACP,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,OAAO,CAAC,EAC5B,MAAM,GAAG,MAAM,EACf,SAAS,GAAG,EAAE,EACd,KAAK,EACL,MAAM,GAAG,EAAE,GACS;IACpB,MAAM,eAAe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