repo-util 1.14.1 → 1.14.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "repo-util",
3
- "version": "1.14.1",
3
+ "version": "1.14.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -31,7 +31,12 @@ for (const o of [
31
31
  ["branch", "branches", ["fullName"]],
32
32
  ["project", "projects", ["fullName"]],
33
33
  ["milestone", "milestones", ["fullName"]],
34
- ["hook", "hooks", ["url"]],
34
+ [
35
+ "hook",
36
+ "hooks",
37
+ ["url", "events", "active"],
38
+ { create: { description: "create a hook", execute: () => {} } }
39
+ ],
35
40
  [
36
41
  "pull-request",
37
42
  "pullRequests",
@@ -105,10 +110,17 @@ async function list(provider, names, options, slot, attributes, actions) {
105
110
  json.push(object);
106
111
  } else {
107
112
  for (const a of attributes) {
113
+ let value = object[a];
114
+ if (Array.isArray(value)) {
115
+ value = value.join(" ");
116
+ } else if (value instanceof Set) {
117
+ value = [...value].join(" ");
118
+ }
119
+
108
120
  if (options.identifier === false) {
109
- console.log(object[a]);
121
+ console.log(value);
110
122
  } else {
111
- console.log(object.fullName + ":", object[a]);
123
+ console.log(object.fullName + ":", value);
112
124
  }
113
125
  }
114
126
  }