pmcf 4.24.3 → 4.24.5

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 CHANGED
@@ -73,11 +73,11 @@ generates config packages for:
73
73
  * [Parameters](#parameters-12)
74
74
  * [port](#port-1)
75
75
  * [id](#id)
76
- * [InitializationContext](#initializationcontext)
77
- * [Parameters](#parameters-13)
78
76
  * [SkeletonNetworkInterface](#skeletonnetworkinterface)
79
77
  * [networkAddresses](#networkaddresses)
80
- * [Parameters](#parameters-14)
78
+ * [Parameters](#parameters-13)
79
+ * [InitializationContext](#initializationcontext)
80
+ * [Parameters](#parameters-14)
81
81
  * [SystemdJournalRemoteService](#systemdjournalremoteservice)
82
82
  * [Properties](#properties)
83
83
  * [systemdConfigs](#systemdconfigs)
@@ -263,14 +263,6 @@ Returns **[number](https://developer.mozilla.org/docs/Web/JavaScript/Reference/G
263
263
 
264
264
  Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
265
265
 
266
- ## InitializationContext
267
-
268
- Keeps track of all in flight object creations and loose ends during config initialization.
269
-
270
- ### Parameters
271
-
272
- * `directory` (optional, default `"/"`)
273
-
274
266
  ## SkeletonNetworkInterface
275
267
 
276
268
  **Extends ServiceOwner**
@@ -283,6 +275,14 @@ Keeps track of all in flight object creations and loose ends during config initi
283
275
 
284
276
  Returns **Iterable<[NetworkAddress](#networkaddress)>**&#x20;
285
277
 
278
+ ## InitializationContext
279
+
280
+ Keeps track of all in flight object creations and loose ends during config initialization.
281
+
282
+ ### Parameters
283
+
284
+ * `directory` (optional, default `"/"`)
285
+
286
286
  ## SystemdJournalRemoteService
287
287
 
288
288
  **Extends Service**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pmcf",
3
- "version": "4.24.3",
3
+ "version": "4.24.5",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
package/src/base.mjs CHANGED
@@ -265,6 +265,25 @@ export class Base {
265
265
  return Object.fromEntries(this.propertyIterator(filter));
266
266
  }
267
267
 
268
+ get properties() {
269
+ return this._properties;
270
+ }
271
+
272
+ /**
273
+ *
274
+ * @param {string} name
275
+ * @returns {any}
276
+ */
277
+ property(name) {
278
+ for (const node of this.walkDirections(["this", "extends", "owner"])) {
279
+ const value = node._properties?.[name];
280
+
281
+ if (value !== undefined) {
282
+ return this.expand(value);
283
+ }
284
+ }
285
+ }
286
+
268
287
  get root() {
269
288
  return this.owner.root;
270
289
  }
@@ -459,24 +478,6 @@ export class Base {
459
478
  return globals[name];
460
479
  }
461
480
 
462
- get properties() {
463
- return this._properties;
464
- }
465
-
466
- /**
467
- *
468
- * @param {string} name
469
- * @returns {any}
470
- */
471
- property(name) {
472
- for (const node of this.walkDirections(["this", "extends", "owner"])) {
473
- const value = node._properties?.[name];
474
- if (value !== undefined) {
475
- return this.expand(value);
476
- }
477
- }
478
- }
479
-
480
481
  /**
481
482
  *
482
483
  * @param {any} object
@@ -69,6 +69,7 @@ export class SystemdJournalUploadService extends Service {
69
69
  * @returns {Object}
70
70
  */
71
71
  systemdConfigs(name) {
72
+ console.log("PROPS",this.expand(this.getProperties(filterConfigurable)));
72
73
  return {
73
74
  serviceName: this.systemdService,
74
75
  configFileName: `etc/systemd/journal-upload.conf.d/${name}.conf`,
package/src/utils.mjs CHANGED
@@ -119,10 +119,9 @@ export function asIterator(value) {
119
119
  }
120
120
 
121
121
  export const filterConfigurable = (name, attribute) =>
122
- !attribute.private & attribute.configurable;
122
+ !attribute.private && attribute.configurable;
123
123
 
124
-
125
- export function union(value, present= new Set()) {
124
+ export function union(value, present = new Set()) {
126
125
  if (value instanceof Set) {
127
126
  return present.union(value);
128
127
  } else if (value instanceof Array) {