codify-plugin-lib 1.0.138 → 1.0.141

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.
@@ -51,6 +51,10 @@ export class Plugin {
51
51
  dependencies: resource.dependencies,
52
52
  schema: schema,
53
53
  importAndDestroy: {
54
+ preventImport: resource.settings.importAndDestroy?.preventImport,
55
+ requiredParameters: requiredPropertyNames,
56
+ },
57
+ import: {
54
58
  requiredParameters: requiredPropertyNames,
55
59
  },
56
60
  allowMultiple
@@ -87,6 +87,13 @@ export interface ResourceSettings<T extends StringIndexedObject> {
87
87
  * ```
88
88
  */
89
89
  importAndDestroy?: {
90
+ /**
91
+ * Can this resources be imported? If set to false then the codifyCLI will skip over/not consider this
92
+ * resource valid for imports. Defaults to true.
93
+ *
94
+ * Resources that can't be imported in the core library for example are: action resources
95
+ */
96
+ preventImport?: boolean;
90
97
  /**
91
98
  * Customize the required parameters needed to import this resource. By default, the `requiredParameters` are taken
92
99
  * from the JSON schema. The `requiredParameters` parameter must be declared if a complex required is declared in
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codify-plugin-lib",
3
- "version": "1.0.138",
3
+ "version": "1.0.141",
4
4
  "description": "Library plugin library",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/index.d.ts",
@@ -16,7 +16,7 @@
16
16
  "dependencies": {
17
17
  "ajv": "^8.12.0",
18
18
  "ajv-formats": "^2.1.1",
19
- "codify-schemas": "1.0.64",
19
+ "codify-schemas": "1.0.69",
20
20
  "@npmcli/promise-spawn": "^7.0.1",
21
21
  "@homebridge/node-pty-prebuilt-multiarch": "^0.12.0-beta.5",
22
22
  "uuid": "^10.0.0",
@@ -84,6 +84,10 @@ export class Plugin {
84
84
  dependencies: resource.dependencies,
85
85
  schema: schema as Record<string, unknown> | undefined,
86
86
  importAndDestroy: {
87
+ preventImport: resource.settings.importAndDestroy?.preventImport,
88
+ requiredParameters: requiredPropertyNames,
89
+ },
90
+ import: {
87
91
  requiredParameters: requiredPropertyNames,
88
92
  },
89
93
  allowMultiple
@@ -103,6 +103,13 @@ export interface ResourceSettings<T extends StringIndexedObject> {
103
103
  * ```
104
104
  */
105
105
  importAndDestroy?: {
106
+ /**
107
+ * Can this resources be imported? If set to false then the codifyCLI will skip over/not consider this
108
+ * resource valid for imports. Defaults to true.
109
+ *
110
+ * Resources that can't be imported in the core library for example are: action resources
111
+ */
112
+ preventImport?: boolean;
106
113
 
107
114
  /**
108
115
  * Customize the required parameters needed to import this resource. By default, the `requiredParameters` are taken
@@ -133,7 +140,7 @@ export interface ResourceSettings<T extends StringIndexedObject> {
133
140
  *
134
141
  * See {@link importAndDestroy} for more information on how importing works.
135
142
  */
136
- defaultRefreshValues?: Partial<T>
143
+ defaultRefreshValues?: Partial<T>;
137
144
  }
138
145
  }
139
146