querysub 0.271.0 → 0.272.0

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": "querysub",
3
- "version": "0.271.0",
3
+ "version": "0.272.0",
4
4
  "main": "index.js",
5
5
  "license": "MIT",
6
6
  "note1": "note on node-forge fork, see https://github.com/digitalbazaar/forge/issues/744 for details",
@@ -22,13 +22,15 @@ export class RenderGitRefInfo extends qreact.Component<{
22
22
  }> {
23
23
  render() {
24
24
  let controller = MachineServiceController(SocketFunction.browserNodeId());
25
+ let gitRef = this.props.gitRef;
25
26
  let gitRefInfo = controller.getGitRefInfo({
26
- ref: this.props.gitRef,
27
+ ref: gitRef,
27
28
  useQuerysub: this.props.isQuerysub,
28
29
  });
29
30
  if (!gitRefInfo) return undefined;
31
+ let { description, time } = gitRefInfo;
30
32
  return <div className={css.fontWeight("normal")}>
31
- {formatDateJSX(gitRefInfo.time)} AGO <span className={css.hsl(0, 0, 80).pad2(5, 2).italic}>{gitRefInfo.description}</span> ({this.props.gitRef.slice(0, 6)})
33
+ {formatDateJSX(time)} AGO <span className={css.hsl(0, 0, 80).pad2(5, 2).italic}>{description}</span> ({gitRef.slice(0, 6)})
32
34
  </div>;
33
35
  }
34
36
  }
@@ -259,6 +259,18 @@ export class MachineServiceControllerBase {
259
259
  }
260
260
 
261
261
  public async commitPushService(commitMessage: string) {
262
+ if (commitMessage.toLowerCase().includes("querysub")) {
263
+ let querysubFolder = path.resolve("../querysub");
264
+ if (fs.existsSync(querysubFolder)) {
265
+ let querysubLastCommit = await getGitRefInfo({
266
+ gitDir: querysubFolder,
267
+ ref: "origin/main",
268
+ });
269
+ if (querysubLastCommit) {
270
+ commitMessage += `\n\n(querysub commit): ${querysubLastCommit.description}`;
271
+ }
272
+ }
273
+ }
262
274
  await commitAndPush({
263
275
  gitDir: ".",
264
276
  message: commitMessage,