@gowelle/stint-agent 1.2.14 → 1.2.16
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/assets/logo.png +0 -0
- package/dist/{StatusDashboard-VYOFLJDD.js → StatusDashboard-LCGOELR4.js} +1 -1
- package/dist/{api-DJSTPHLX.js → api-IB5F32WJ.js} +2 -2
- package/dist/{chunk-QRCU33OO.js → chunk-7TIF7QZL.js} +1 -1
- package/dist/{chunk-HUQ7VJO6.js → chunk-DCY3EXDX.js} +6 -1
- package/dist/{chunk-SJMVFX5Q.js → chunk-I6DTKIFX.js} +2 -2
- package/dist/{chunk-ODHF43SC.js → chunk-Z44NPHXG.js} +22 -8
- package/dist/daemon/runner.js +12 -4
- package/dist/index.js +6 -6
- package/dist/{notify-R6CUXTEF.js → notify-NXUEEO7M.js} +1 -1
- package/package.json +2 -1
package/assets/logo.png
ADDED
|
Binary file
|
|
@@ -71,7 +71,7 @@ var AuthServiceImpl = class {
|
|
|
71
71
|
return null;
|
|
72
72
|
}
|
|
73
73
|
try {
|
|
74
|
-
const { apiService } = await import("./api-
|
|
74
|
+
const { apiService } = await import("./api-IB5F32WJ.js");
|
|
75
75
|
const user = await apiService.getCurrentUser();
|
|
76
76
|
logger.info("auth", `Token validated for user: ${user.email}`);
|
|
77
77
|
return user;
|
|
@@ -5,6 +5,11 @@ import {
|
|
|
5
5
|
|
|
6
6
|
// src/utils/notify.ts
|
|
7
7
|
import notifier from "node-notifier";
|
|
8
|
+
import path from "path";
|
|
9
|
+
import { fileURLToPath } from "url";
|
|
10
|
+
var __filename = fileURLToPath(import.meta.url);
|
|
11
|
+
var __dirname = path.dirname(__filename);
|
|
12
|
+
var DEFAULT_ICON = path.resolve(__dirname, "../assets/logo.png");
|
|
8
13
|
function notify(options) {
|
|
9
14
|
if (!config.areNotificationsEnabled()) {
|
|
10
15
|
logger.debug("notify", "Notifications disabled, skipping notification");
|
|
@@ -15,7 +20,7 @@ function notify(options) {
|
|
|
15
20
|
title: options.title,
|
|
16
21
|
message: options.message,
|
|
17
22
|
open: options.open,
|
|
18
|
-
icon: options.icon,
|
|
23
|
+
icon: options.icon || DEFAULT_ICON,
|
|
19
24
|
sound: true,
|
|
20
25
|
wait: false,
|
|
21
26
|
appID: "Stint Agent"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
authService
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-7TIF7QZL.js";
|
|
4
4
|
import {
|
|
5
5
|
config,
|
|
6
6
|
logger
|
|
@@ -100,7 +100,7 @@ var CircuitBreaker = class {
|
|
|
100
100
|
};
|
|
101
101
|
|
|
102
102
|
// src/services/api.ts
|
|
103
|
-
var AGENT_VERSION = "1.2.
|
|
103
|
+
var AGENT_VERSION = "1.2.16";
|
|
104
104
|
var ApiServiceImpl = class {
|
|
105
105
|
sessionId = null;
|
|
106
106
|
circuitBreaker = new CircuitBreaker({
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
apiService
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-I6DTKIFX.js";
|
|
4
4
|
import {
|
|
5
5
|
gitService,
|
|
6
6
|
projectService
|
|
7
7
|
} from "./chunk-QQP6IASS.js";
|
|
8
8
|
import {
|
|
9
9
|
authService
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-7TIF7QZL.js";
|
|
11
11
|
import {
|
|
12
12
|
notify
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-DCY3EXDX.js";
|
|
14
14
|
import {
|
|
15
15
|
config,
|
|
16
16
|
logger
|
|
@@ -99,6 +99,10 @@ var CommitQueueProcessor = class {
|
|
|
99
99
|
await gitService.push(projectPath);
|
|
100
100
|
pushed = true;
|
|
101
101
|
logger.success("queue", `Pushed commit ${sha} to remote`);
|
|
102
|
+
notify({
|
|
103
|
+
title: "Commit Executed & Pushed",
|
|
104
|
+
message: `Commit "${commit.message}" successfully pushed.`
|
|
105
|
+
});
|
|
102
106
|
} catch (error) {
|
|
103
107
|
pushError = error.message;
|
|
104
108
|
const isConflict = pushError.includes("rejected") || pushError.includes("non-fast-forward") || pushError.includes("failed to push") || pushError.includes("Updates were rejected");
|
|
@@ -120,11 +124,21 @@ Run "git pull --rebase && git push" to resolve.`
|
|
|
120
124
|
}
|
|
121
125
|
onProgress?.("Reporting to server...");
|
|
122
126
|
await this.reportSuccess(commit.id, sha, pushed, pushError);
|
|
127
|
+
if (!pushed && !pushError) {
|
|
128
|
+
notify({
|
|
129
|
+
title: "Commit Executed",
|
|
130
|
+
message: `Commit "${commit.message}" created locally.`
|
|
131
|
+
});
|
|
132
|
+
}
|
|
123
133
|
return sha;
|
|
124
134
|
} catch (error) {
|
|
125
|
-
|
|
126
|
-
logger.error("queue", `Commit execution failed: ${
|
|
127
|
-
|
|
135
|
+
msg = error.message;
|
|
136
|
+
logger.error("queue", `Commit execution failed: ${msg}`);
|
|
137
|
+
notify({
|
|
138
|
+
title: "Commit Failed",
|
|
139
|
+
message: `Failed to execute commit "${commit.message}": ${msg}`
|
|
140
|
+
});
|
|
141
|
+
await this.reportFailure(commit.id, msg);
|
|
128
142
|
throw error;
|
|
129
143
|
}
|
|
130
144
|
}
|
|
@@ -294,7 +308,7 @@ var WebSocketServiceImpl = class {
|
|
|
294
308
|
* Get authentication signature for private channel from Laravel backend
|
|
295
309
|
*/
|
|
296
310
|
async getChannelAuth(channel, socketId) {
|
|
297
|
-
const { apiService: apiService2 } = await import("./api-
|
|
311
|
+
const { apiService: apiService2 } = await import("./api-IB5F32WJ.js");
|
|
298
312
|
const response = await apiService2.request("/api/broadcasting/auth", {
|
|
299
313
|
method: "POST",
|
|
300
314
|
body: JSON.stringify({
|
|
@@ -367,7 +381,7 @@ var WebSocketServiceImpl = class {
|
|
|
367
381
|
logger.error("websocket", "Application does not exist - check Reverb app key configuration");
|
|
368
382
|
} else if (errorCode === 4009) {
|
|
369
383
|
logger.error("websocket", "Connection is unauthorized - authentication token may be invalid or expired");
|
|
370
|
-
const { notify: notify2 } = await import("./notify-
|
|
384
|
+
const { notify: notify2 } = await import("./notify-NXUEEO7M.js");
|
|
371
385
|
notify2({
|
|
372
386
|
title: "Stint Agent - Connection Issue",
|
|
373
387
|
message: "WebSocket authentication failed. Notifications may be delayed (falling back to polling)."
|
package/dist/daemon/runner.js
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
commitQueue,
|
|
4
4
|
websocketService
|
|
5
|
-
} from "../chunk-
|
|
5
|
+
} from "../chunk-Z44NPHXG.js";
|
|
6
6
|
import {
|
|
7
7
|
apiService
|
|
8
|
-
} from "../chunk-
|
|
8
|
+
} from "../chunk-I6DTKIFX.js";
|
|
9
9
|
import {
|
|
10
10
|
gitService,
|
|
11
11
|
projectService,
|
|
@@ -14,10 +14,10 @@ import {
|
|
|
14
14
|
} from "../chunk-QQP6IASS.js";
|
|
15
15
|
import {
|
|
16
16
|
authService
|
|
17
|
-
} from "../chunk-
|
|
17
|
+
} from "../chunk-7TIF7QZL.js";
|
|
18
18
|
import {
|
|
19
19
|
notify
|
|
20
|
-
} from "../chunk-
|
|
20
|
+
} from "../chunk-DCY3EXDX.js";
|
|
21
21
|
import {
|
|
22
22
|
logger
|
|
23
23
|
} from "../chunk-XHXSWLUC.js";
|
|
@@ -286,6 +286,10 @@ var FileWatcher = class {
|
|
|
286
286
|
const repoInfo = await gitService.getRepoInfo(projectPath);
|
|
287
287
|
await apiService.syncProject(projectId, repoInfo);
|
|
288
288
|
logger.success("watcher", `Synced project ${projectId}`);
|
|
289
|
+
notify({
|
|
290
|
+
title: "Sync Complete",
|
|
291
|
+
message: `Project ${projectId} synced successfully.`
|
|
292
|
+
});
|
|
289
293
|
} catch (error) {
|
|
290
294
|
logger.error("watcher", `Failed to sync project ${projectId}`, error);
|
|
291
295
|
}
|
|
@@ -432,6 +436,10 @@ Priority: ${suggestion.priority}`,
|
|
|
432
436
|
websocketService.onSyncRequested(async (projectId) => {
|
|
433
437
|
logger.info("daemon", `Server requested sync for project: ${projectId}`);
|
|
434
438
|
try {
|
|
439
|
+
notify({
|
|
440
|
+
title: "Sync Requested",
|
|
441
|
+
message: `Syncing project ${projectId}...`
|
|
442
|
+
});
|
|
435
443
|
await fileWatcher.syncProjectById(projectId);
|
|
436
444
|
} catch (error) {
|
|
437
445
|
logger.error("daemon", `Failed to sync project ${projectId}`, error);
|
package/dist/index.js
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
commitQueue,
|
|
4
4
|
websocketService
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-Z44NPHXG.js";
|
|
6
6
|
import {
|
|
7
7
|
apiService
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-I6DTKIFX.js";
|
|
9
9
|
import {
|
|
10
10
|
getPidFilePath,
|
|
11
11
|
gitService,
|
|
@@ -17,8 +17,8 @@ import {
|
|
|
17
17
|
} from "./chunk-QQP6IASS.js";
|
|
18
18
|
import {
|
|
19
19
|
authService
|
|
20
|
-
} from "./chunk-
|
|
21
|
-
import "./chunk-
|
|
20
|
+
} from "./chunk-7TIF7QZL.js";
|
|
21
|
+
import "./chunk-DCY3EXDX.js";
|
|
22
22
|
import {
|
|
23
23
|
config,
|
|
24
24
|
logger
|
|
@@ -623,7 +623,7 @@ function registerStatusCommand(program2) {
|
|
|
623
623
|
try {
|
|
624
624
|
const { render } = await import("ink");
|
|
625
625
|
const { createElement } = await import("react");
|
|
626
|
-
const { StatusDashboard } = await import("./StatusDashboard-
|
|
626
|
+
const { StatusDashboard } = await import("./StatusDashboard-LCGOELR4.js");
|
|
627
627
|
render(createElement(StatusDashboard, { cwd }));
|
|
628
628
|
return;
|
|
629
629
|
} catch (error) {
|
|
@@ -2003,7 +2003,7 @@ function registerDoctorCommand(program2) {
|
|
|
2003
2003
|
}
|
|
2004
2004
|
|
|
2005
2005
|
// src/index.ts
|
|
2006
|
-
var AGENT_VERSION = "1.2.
|
|
2006
|
+
var AGENT_VERSION = "1.2.16";
|
|
2007
2007
|
var program = new Command();
|
|
2008
2008
|
program.name("stint").description("Stint Agent - Local daemon for Stint Project Assistant").version(AGENT_VERSION, "-v, --version", "output the current version").addHelpText("after", `
|
|
2009
2009
|
${chalk13.bold("Examples:")}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gowelle/stint-agent",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.16",
|
|
4
4
|
"description": "Local agent for Stint - Project Assistant",
|
|
5
5
|
"author": "Gowelle John <gowelle.john@icloud.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
},
|
|
11
11
|
"files": [
|
|
12
12
|
"dist",
|
|
13
|
+
"assets",
|
|
13
14
|
"README.md",
|
|
14
15
|
"LICENSE"
|
|
15
16
|
],
|