@misterhuydo/sentinel 1.0.10 → 1.0.12

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.
@@ -0,0 +1 @@
1
+ 2026-03-21T17:01:47.015Z
@@ -0,0 +1,7 @@
1
+ {
2
+ "message": "Auto-checkpoint at 2026-03-21T17:02:51.501Z",
3
+ "checkpoint_at": "2026-03-21T17:02:51.502Z",
4
+ "active_files": [],
5
+ "notes": [],
6
+ "mtime_snapshot": {}
7
+ }
package/bin/sentinel.js CHANGED
@@ -4,6 +4,17 @@
4
4
  const chalk = require('chalk');
5
5
  const [,, command = 'help', ...args] = process.argv;
6
6
 
7
+ // Handle flags before the main switch
8
+ if (command === '--version' || command === '-v') {
9
+ const { version } = require('../package.json');
10
+ console.log(version);
11
+ process.exit(0);
12
+ }
13
+ if (command === '--help' || command === '-h') {
14
+ printUsage();
15
+ process.exit(0);
16
+ }
17
+
7
18
  const BANNER = `
8
19
  ${chalk.cyan('███████╗███████╗███╗ ██╗████████╗██╗███╗ ██╗███████╗██╗')}
9
20
  ${chalk.cyan('██╔════╝██╔════╝████╗ ██║╚══██╔══╝██║████╗ ██║██╔════╝██║')}
@@ -26,14 +37,25 @@ async function main() {
26
37
  break;
27
38
  case 'help':
28
39
  default:
29
- console.log(`${chalk.bold('Usage:')}
40
+ printUsage();
41
+ }
42
+ }
43
+
44
+ function printUsage() {
45
+ const { version } = require('../package.json');
46
+ console.log(`${chalk.bold('sentinel')} v${version} — Autonomous DevOps Agent
47
+
48
+ ${chalk.bold('Usage:')}
30
49
  sentinel init Interactive setup — install everything and create workspace
31
50
  sentinel add <name> Add a blank project (fill config manually)
32
51
  sentinel add <git-url> Add a project pre-configured for a GitHub repo
33
52
  sentinel add <project.json> Add a project from a local JSON config file
34
53
  sentinel add <https://host/cfg.json> Add a project from a remote JSON config URL
54
+
55
+ ${chalk.bold('Options:')}
56
+ --version, -v Print version
57
+ --help, -h Print this help
35
58
  `);
36
- }
37
59
  }
38
60
 
39
61
  main().catch(err => {
package/lib/generate.js CHANGED
@@ -112,7 +112,7 @@ for project_dir in "$WORKSPACE"/*/; do
112
112
 
113
113
  # Must have at least one repo-config with a valid GitHub REPO_URL
114
114
  valid_repo=false
115
- for props in "$project_dir/config/repo-configs/"*.properties 2>/dev/null; do
115
+ for props in "$project_dir/config/repo-configs/"*.properties; do
116
116
  [[ -f "$props" ]] || continue
117
117
  if grep -qE "^REPO_URL[[:space:]]*=[[:space:]]*(git@github\.com:|https://github\.com/)" "$props"; then
118
118
  valid_repo=true
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@misterhuydo/sentinel",
3
- "version": "1.0.10",
3
+ "version": "1.0.12",
4
4
  "description": "Sentinel — Autonomous DevOps Agent installer and manager",
5
5
  "bin": {
6
6
  "sentinel": "./bin/sentinel.js"