wuffle 0.69.0 → 0.70.1

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.
@@ -1,6 +1,5 @@
1
1
  import { promises as fs } from 'node:fs';
2
2
  import path from 'node:path';
3
- import { mkdirp } from 'mkdirp';
4
3
 
5
4
 
6
5
  /**
@@ -27,7 +26,7 @@ export default function DumpStoreLocal(logger, store, events) {
27
26
  // io helpers
28
27
 
29
28
  function upload(dump) {
30
- return mkdirp(path.dirname(storeLocation)).then(
29
+ return fs.mkdir(path.dirname(storeLocation), { recursive: true }).then(
31
30
  () => fs.writeFile(storeLocation, dump, 'utf8')
32
31
  );
33
32
  }
@@ -1,5 +1,3 @@
1
- import { mkdirp } from 'mkdirp';
2
-
3
1
  import path from 'node:path';
4
2
  import { promises as fs } from 'node:fs';
5
3
 
@@ -39,7 +37,7 @@ export default function LogEvents(logger, webhookEvents) {
39
37
 
40
38
  const data = JSON.stringify({ event, payload }, null, ' ');
41
39
 
42
- return mkdirp(eventsDir).then(() => {
40
+ return fs.mkdir(eventsDir, { recursive: true }).then(() => {
43
41
  const fileName = path.join(eventsDir, `${Date.now()}-${counter++}-${name}.json`);
44
42
 
45
43
  return fs.writeFile(fileName, data, 'utf8');
package/lib/index.js CHANGED
@@ -93,15 +93,7 @@ export default function Wuffle(app, { getRouter }) {
93
93
 
94
94
  // initialize modules ////////////
95
95
 
96
- for (const module of modules) {
97
-
98
- const init = /** @type {import('./types.js').DidiModule} */ (module).__init__ || [];
99
-
100
- for (const component of init) {
101
- await injector[typeof component === 'function' ? 'invoke' : 'get'](component);
102
- }
103
-
104
- }
96
+ await injector.init();
105
97
 
106
98
  await events.emit('wuffle.start');
107
99
 
package/lib/types.d.ts CHANGED
@@ -14,7 +14,10 @@ import type {
14
14
 
15
15
  export type Octokit = InstanceType<typeof ProbotOctokit>;
16
16
 
17
- import type { Injector } from 'async-didi';
17
+ import type {
18
+ AsyncInjector as Injector,
19
+ ModuleDefinition as DidiModule
20
+ } from 'async-didi';
18
21
 
19
22
  export {
20
23
  Logger,
@@ -22,13 +25,8 @@ export {
22
25
  Router,
23
26
  Octokit,
24
27
  Injector,
25
- ProbotApp
26
- };
27
-
28
- export type DidiModule = {
29
- __init__?: Array<String>,
30
- __depends__?: Array<String>,
31
- [propName: string]: any,
28
+ ProbotApp,
29
+ DidiModule
32
30
  };
33
31
 
34
32
  export type GitHubUser = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wuffle",
3
- "version": "0.69.0",
3
+ "version": "0.70.1",
4
4
  "description": "A multi-repository task board for GitHub issues",
5
5
  "author": {
6
6
  "name": "Nico Rehwaldt",
@@ -42,19 +42,18 @@
42
42
  "auto-test": "npm test -- --watch"
43
43
  },
44
44
  "dependencies": {
45
- "@aws-sdk/client-s3": "^3.525.0",
46
- "async-didi": "^0.3.1",
47
- "body-parser": "^2.0.0",
45
+ "@aws-sdk/client-s3": "^3.1014.0",
46
+ "async-didi": "^1.0.0",
47
+ "body-parser": "^2.2.2",
48
48
  "compression": "^1.8.1",
49
- "express-session": "^1.18.2",
49
+ "express-session": "^1.19.0",
50
50
  "fake-tag": "^5.0.0",
51
51
  "memorystore": "^1.6.7",
52
- "min-dash": "^4.2.3",
53
- "mkdirp": "^3.0.1",
52
+ "min-dash": "^5.0.0",
54
53
  "p-defer": "^4.0.1",
55
54
  "prexit": "^2.3.0",
56
- "probot": "^13.4.5",
57
- "smee-client": "^4.0.0"
55
+ "probot": "^13.4.7",
56
+ "smee-client": "^5.0.0"
58
57
  },
59
58
  "devDependencies": {
60
59
  "@graphql-eslint/eslint-plugin": "^4.4.0",
@@ -62,15 +61,15 @@
62
61
  "@types/compression": "^1.8.1",
63
62
  "@types/express-session": "^1.18.2",
64
63
  "@types/mocha": "^10.0.10",
65
- "chai": "^6.0.0",
66
- "graphql": "^16.11.0",
67
- "mocha": "^11.0.0",
68
- "nock": "^14.0.10",
69
- "nodemon": "^3.1.10",
64
+ "chai": "^6.2.2",
65
+ "graphql": "^16.13.1",
66
+ "mocha": "^11.7.5",
67
+ "nock": "^14.0.11",
68
+ "nodemon": "^3.1.14",
70
69
  "npm-run-all2": "^8.0.4",
71
- "sinon": "^21.0.0",
70
+ "sinon": "^21.0.3",
72
71
  "sinon-chai": "^4.0.0",
73
- "typescript": "^5.7.2"
72
+ "typescript": "^5.9.3"
74
73
  },
75
74
  "engines": {
76
75
  "node": ">= 20"
@@ -83,5 +82,5 @@
83
82
  "index.js",
84
83
  "wuffle.config.example.js"
85
84
  ],
86
- "gitHead": "3059393d0351b6a6109886bc4d4988e0900f32e7"
85
+ "gitHead": "e3234b1499bb1c75e3bf40c15b0c105bedeba70c"
87
86
  }