pumuki-ast-hooks 5.3.20 → 5.3.21
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/docs/RELEASE_NOTES.md +35 -0
- package/docs/VIOLATIONS_RESOLUTION_PLAN.md +58 -58
- package/package.json +3 -3
- package/scripts/hooks-system/.AI_TOKEN_STATUS.txt +1 -1
- package/scripts/hooks-system/.audit-reports/notifications.log +935 -0
- package/scripts/hooks-system/.audit-reports/token-monitor.log +2809 -0
- package/scripts/hooks-system/application/CompositionRoot.js +38 -22
- package/scripts/hooks-system/application/services/AutonomousOrchestrator.js +0 -18
- package/scripts/hooks-system/application/services/ContextDetectionEngine.js +0 -58
- package/scripts/hooks-system/application/services/DynamicRulesLoader.js +2 -12
- package/scripts/hooks-system/application/services/GitFlowService.js +0 -80
- package/scripts/hooks-system/application/services/GitTreeState.js +2 -5
- package/scripts/hooks-system/application/services/HookSystemScheduler.js +0 -4
- package/scripts/hooks-system/application/services/IntelligentCommitAnalyzer.js +0 -25
- package/scripts/hooks-system/application/services/IntelligentGitTreeMonitor.js +0 -11
- package/scripts/hooks-system/application/services/PlatformAnalysisService.js +0 -19
- package/scripts/hooks-system/application/services/PlatformDetectionService.js +0 -19
- package/scripts/hooks-system/application/services/PlaybookRunner.js +1 -22
- package/scripts/hooks-system/application/services/PredictiveHookAdvisor.js +0 -19
- package/scripts/hooks-system/application/services/RealtimeGuardPlugin.js +0 -25
- package/scripts/hooks-system/application/services/RealtimeGuardService.js +71 -41
- package/scripts/hooks-system/application/services/SmartDirtyTreeAnalyzer.js +0 -11
- package/scripts/hooks-system/application/services/commit/CommitMessageGenerator.js +0 -11
- package/scripts/hooks-system/application/services/commit/FeatureDetector.js +0 -11
- package/scripts/hooks-system/application/services/evidence/EvidenceContextManager.js +0 -25
- package/scripts/hooks-system/application/services/guard/GuardAutoManagerService.js +31 -21
- package/scripts/hooks-system/application/services/guard/GuardConfig.js +15 -18
- package/scripts/hooks-system/application/services/guard/GuardEventLogger.js +0 -11
- package/scripts/hooks-system/application/services/guard/GuardHealthReminder.js +0 -26
- package/scripts/hooks-system/application/services/guard/GuardHeartbeatMonitor.js +6 -20
- package/scripts/hooks-system/application/services/guard/GuardLockManager.js +0 -11
- package/scripts/hooks-system/application/services/guard/GuardMonitorLoop.js +0 -25
- package/scripts/hooks-system/application/services/guard/GuardNotificationHandler.js +0 -11
- package/scripts/hooks-system/application/services/guard/GuardProcessManager.js +23 -11
- package/scripts/hooks-system/application/services/guard/GuardRecoveryService.js +0 -11
- package/scripts/hooks-system/application/services/installation/ConfigurationGeneratorService.js +0 -18
- package/scripts/hooks-system/application/services/installation/FileSystemInstallerService.js +0 -18
- package/scripts/hooks-system/application/services/installation/GitEnvironmentService.js +1 -19
- package/scripts/hooks-system/application/services/installation/HookInstaller.js +62 -24
- package/scripts/hooks-system/application/services/installation/IdeIntegrationService.js +0 -11
- package/scripts/hooks-system/application/services/installation/InstallService.js +1 -25
- package/scripts/hooks-system/application/services/installation/McpConfigurator.js +2 -19
- package/scripts/hooks-system/application/services/installation/PlatformDetectorService.js +0 -11
- package/scripts/hooks-system/application/services/installation/VSCodeTaskConfigurator.js +0 -11
- package/scripts/hooks-system/application/services/logging/AuditLogger.js +0 -8
- package/scripts/hooks-system/application/services/logging/UnifiedLogger.js +13 -15
- package/scripts/hooks-system/application/services/monitoring/ActivityMonitor.js +0 -33
- package/scripts/hooks-system/application/services/monitoring/AstMonitor.js +0 -27
- package/scripts/hooks-system/application/services/monitoring/DevDocsMonitor.js +0 -26
- package/scripts/hooks-system/application/services/monitoring/EvidenceMonitor.js +0 -18
- package/scripts/hooks-system/application/services/monitoring/EvidenceMonitorService.js +4 -28
- package/scripts/hooks-system/application/services/monitoring/GitTreeMonitor.js +0 -28
- package/scripts/hooks-system/application/services/monitoring/GitTreeMonitorService.js +0 -26
- package/scripts/hooks-system/application/services/monitoring/HealthCheckProviders.js +0 -4
- package/scripts/hooks-system/application/services/monitoring/HealthCheckService.js +0 -25
- package/scripts/hooks-system/application/services/monitoring/HeartbeatMonitorService.js +0 -26
- package/scripts/hooks-system/application/services/monitoring/TokenMonitor.js +0 -26
- package/scripts/hooks-system/application/services/notification/MacNotificationSender.js +0 -11
- package/scripts/hooks-system/application/services/notification/NotificationCenterService.js +0 -18
- package/scripts/hooks-system/application/services/notification/NotificationDispatcher.js +0 -11
- package/scripts/hooks-system/application/services/notification/components/NotificationCooldownManager.js +0 -18
- package/scripts/hooks-system/application/services/notification/components/NotificationDeduplicator.js +0 -18
- package/scripts/hooks-system/application/services/notification/components/NotificationQueue.js +0 -11
- package/scripts/hooks-system/application/services/notification/components/NotificationRetryExecutor.js +0 -20
- package/scripts/hooks-system/application/services/platform/PlatformHeuristics.js +0 -19
- package/scripts/hooks-system/application/services/recovery/AutoRecoveryManager.js +0 -19
- package/scripts/hooks-system/application/services/smart-commit/CommitMessageSuggester.js +0 -11
- package/scripts/hooks-system/application/services/smart-commit/FileContextGrouper.js +0 -19
- package/scripts/hooks-system/application/services/smart-commit/SmartCommitSummaryBuilder.js +0 -4
- package/scripts/hooks-system/application/services/token/CursorTokenService.js +0 -20
- package/scripts/hooks-system/application/services/token/TokenMetricsService.js +2 -12
- package/scripts/hooks-system/application/services/token/TokenMonitorService.js +0 -19
- package/scripts/hooks-system/application/services/token/TokenStatusReporter.js +0 -12
- package/scripts/hooks-system/bin/cli.js +15 -1
- package/scripts/hooks-system/bin/guard-env.sh +18 -38
- package/scripts/hooks-system/bin/guard-supervisor.js +5 -515
- package/scripts/hooks-system/bin/session-loader.sh +3 -262
- package/scripts/hooks-system/bin/start-guards.sh +21 -184
- package/scripts/hooks-system/bin/update-evidence.sh +10 -1161
- package/scripts/hooks-system/config/project.config.json +1 -1
- package/scripts/hooks-system/domain/events/index.js +31 -24
- package/scripts/hooks-system/infrastructure/ast/android/analyzers/AndroidAnalysisOrchestrator.js +3 -2
- package/scripts/hooks-system/infrastructure/ast/ast-core.js +12 -20
- package/scripts/hooks-system/infrastructure/ast/ast-intelligence.js +8 -18
- package/scripts/hooks-system/infrastructure/ast/backend/analyzers/BackendPatternDetector.js +2 -1
- package/scripts/hooks-system/infrastructure/ast/backend/ast-backend.js +18 -14
- package/scripts/hooks-system/infrastructure/ast/frontend/ast-frontend.js +196 -196
- package/scripts/hooks-system/infrastructure/ast/ios/analyzers/iOSASTIntelligentAnalyzer.js +3 -2
- package/scripts/hooks-system/infrastructure/hooks/skill-activation-prompt.js +3 -2
- package/scripts/hooks-system/infrastructure/logging/UnifiedLoggerFactory.js +5 -4
- package/scripts/hooks-system/infrastructure/mcp/ast-intelligence-automation.js +88 -0
- package/scripts/hooks-system/infrastructure/orchestration/intelligent-audit.js +17 -16
- package/scripts/hooks-system/infrastructure/shell/orchestrators/audit-orchestrator.sh +92 -54
- package/scripts/hooks-system/infrastructure/telemetry/metrics-server.js +3 -2
- package/scripts/hooks-system/infrastructure/validators/enforce-english-literals.js +6 -8
|
@@ -1,20 +1,9 @@
|
|
|
1
1
|
const path = require('path');
|
|
2
2
|
|
|
3
|
-
const {
|
|
4
|
-
createMetricScope: createMetricScope
|
|
5
|
-
} = require('../../../infrastructure/telemetry/metric-scope');
|
|
6
|
-
|
|
7
3
|
class FileContextGrouper {
|
|
8
4
|
constructor(featureDetector, platformDetector = null) {
|
|
9
|
-
const m_constructor = createMetricScope({
|
|
10
|
-
hook: 'file_context_grouper',
|
|
11
|
-
operation: 'constructor'
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
m_constructor.started();
|
|
15
5
|
this.featureDetector = featureDetector;
|
|
16
6
|
this.platformDetector = platformDetector;
|
|
17
|
-
m_constructor.success();
|
|
18
7
|
}
|
|
19
8
|
|
|
20
9
|
group(files) {
|
|
@@ -100,18 +89,10 @@ class FileContextGrouper {
|
|
|
100
89
|
}
|
|
101
90
|
|
|
102
91
|
getContextDirectory(file) {
|
|
103
|
-
const m_get_context_directory = createMetricScope({
|
|
104
|
-
hook: 'file_context_grouper',
|
|
105
|
-
operation: 'get_context_directory'
|
|
106
|
-
});
|
|
107
|
-
|
|
108
|
-
m_get_context_directory.started();
|
|
109
92
|
const parts = file.split(path.sep);
|
|
110
93
|
if (parts.length <= 2) {
|
|
111
|
-
m_get_context_directory.success();
|
|
112
94
|
return parts[0] || 'root';
|
|
113
95
|
}
|
|
114
|
-
m_get_context_directory.success();
|
|
115
96
|
return parts.slice(0, 2).join(path.sep);
|
|
116
97
|
}
|
|
117
98
|
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
const CursorTokenRepository = require('../../../infrastructure/repositories/CursorTokenRepository');
|
|
2
2
|
|
|
3
|
-
const {
|
|
4
|
-
createMetricScope: createMetricScope
|
|
5
|
-
} = require('../../../infrastructure/telemetry/metric-scope');
|
|
6
|
-
|
|
7
3
|
class CursorTokenService {
|
|
8
4
|
constructor({
|
|
9
5
|
cursorTokenRepository = null,
|
|
@@ -14,12 +10,6 @@ class CursorTokenService {
|
|
|
14
10
|
fetchImpl,
|
|
15
11
|
logger = console
|
|
16
12
|
} = {}) {
|
|
17
|
-
const m_constructor = createMetricScope({
|
|
18
|
-
hook: 'cursor_token_service',
|
|
19
|
-
operation: 'constructor'
|
|
20
|
-
});
|
|
21
|
-
|
|
22
|
-
m_constructor.started();
|
|
23
13
|
this.logger = logger;
|
|
24
14
|
this.repository = cursorTokenRepository || new CursorTokenRepository({
|
|
25
15
|
repoRoot,
|
|
@@ -29,34 +19,24 @@ class CursorTokenService {
|
|
|
29
19
|
fetchImpl,
|
|
30
20
|
logger
|
|
31
21
|
});
|
|
32
|
-
m_constructor.success();
|
|
33
22
|
}
|
|
34
23
|
|
|
35
24
|
async getCurrentUsage() {
|
|
36
|
-
const m_get_current_usage = createMetricScope({
|
|
37
|
-
hook: 'cursor_token_service',
|
|
38
|
-
operation: 'get_current_usage'
|
|
39
|
-
});
|
|
40
|
-
|
|
41
|
-
m_get_current_usage.started();
|
|
42
25
|
// Strategy: First try API (most accurate), then File (fallback/offline)
|
|
43
26
|
|
|
44
27
|
const apiUsage = await this.repository.getUsageFromApi();
|
|
45
28
|
if (apiUsage) {
|
|
46
29
|
this.logger.debug?.('CURSOR_SERVICE_USING_API', { usage: apiUsage });
|
|
47
|
-
m_get_current_usage.success();
|
|
48
30
|
return apiUsage;
|
|
49
31
|
}
|
|
50
32
|
|
|
51
33
|
const fileUsage = await this.repository.getUsageFromFile();
|
|
52
34
|
if (fileUsage) {
|
|
53
35
|
this.logger.debug?.('CURSOR_SERVICE_USING_FILE', { usage: fileUsage });
|
|
54
|
-
m_get_current_usage.success();
|
|
55
36
|
return fileUsage;
|
|
56
37
|
}
|
|
57
38
|
|
|
58
39
|
this.logger.warn?.('CURSOR_SERVICE_NO_DATA_AVAILABLE');
|
|
59
|
-
m_get_current_usage.success();
|
|
60
40
|
return null;
|
|
61
41
|
}
|
|
62
42
|
}
|
|
@@ -1,22 +1,11 @@
|
|
|
1
1
|
const { execSync } = require('child_process');
|
|
2
2
|
|
|
3
|
-
const {
|
|
4
|
-
createMetricScope: createMetricScope
|
|
5
|
-
} = require('../../../infrastructure/telemetry/metric-scope');
|
|
6
|
-
|
|
7
3
|
class TokenMetricsService {
|
|
8
4
|
constructor(cursorTokenService, thresholds, logger) {
|
|
9
|
-
const m_constructor = createMetricScope({
|
|
10
|
-
hook: 'token_metrics_service',
|
|
11
|
-
operation: 'constructor'
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
m_constructor.started();
|
|
15
5
|
this.cursorTokenService = cursorTokenService;
|
|
16
6
|
this.thresholds = thresholds;
|
|
17
7
|
this.logger = logger;
|
|
18
8
|
this.repoRoot = process.cwd();
|
|
19
|
-
m_constructor.success();
|
|
20
9
|
}
|
|
21
10
|
|
|
22
11
|
async collectMetrics(fallbackEstimator) {
|
|
@@ -65,7 +54,8 @@ class TokenMetricsService {
|
|
|
65
54
|
if (untrusted) {
|
|
66
55
|
level = 'ok';
|
|
67
56
|
}
|
|
68
|
-
const
|
|
57
|
+
const env = require('../../config/env');
|
|
58
|
+
const forceLevel = (env.get('TOKEN_MONITOR_FORCE_LEVEL', '') || '').toLowerCase();
|
|
69
59
|
if (forceLevel === 'warning' || forceLevel === 'critical' || forceLevel === 'ok') {
|
|
70
60
|
level = forceLevel;
|
|
71
61
|
}
|
|
@@ -2,10 +2,6 @@ const fs = require('fs');
|
|
|
2
2
|
const path = require('path');
|
|
3
3
|
const { execSync } = require('child_process');
|
|
4
4
|
|
|
5
|
-
const {
|
|
6
|
-
createMetricScope: createMetricScope
|
|
7
|
-
} = require('../../../infrastructure/telemetry/metric-scope');
|
|
8
|
-
|
|
9
5
|
const fsPromises = fs.promises;
|
|
10
6
|
const CursorTokenService = require('./CursorTokenService');
|
|
11
7
|
const NotificationCenterService = require('../notification/NotificationCenterService');
|
|
@@ -25,12 +21,6 @@ class TokenMonitorService {
|
|
|
25
21
|
fallbackEstimator = null,
|
|
26
22
|
cursorTokenService = null
|
|
27
23
|
} = {}) {
|
|
28
|
-
const m_constructor = createMetricScope({
|
|
29
|
-
hook: 'token_monitor_service',
|
|
30
|
-
operation: 'constructor'
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
m_constructor.started();
|
|
34
24
|
this.repoRoot = repoRoot;
|
|
35
25
|
this.dataFile = dataFile || path.join(this.repoRoot, '.audit_tmp', 'token-usage.jsonl');
|
|
36
26
|
this.stateFile = stateFile || path.join(this.repoRoot, '.AI_TOKEN_STATUS.txt');
|
|
@@ -57,16 +47,9 @@ class TokenMonitorService {
|
|
|
57
47
|
|
|
58
48
|
this.metricsService = new TokenMetricsService(this.cursorTokenService, this.thresholds, this.logger);
|
|
59
49
|
this.statusReporter = new TokenStatusReporter(this.stateFile);
|
|
60
|
-
m_constructor.success();
|
|
61
50
|
}
|
|
62
51
|
|
|
63
52
|
async run() {
|
|
64
|
-
const m_run = createMetricScope({
|
|
65
|
-
hook: 'token_monitor_service',
|
|
66
|
-
operation: 'run'
|
|
67
|
-
});
|
|
68
|
-
|
|
69
|
-
m_run.started();
|
|
70
53
|
// Collect metrics
|
|
71
54
|
const metrics = await this.metricsService.collectMetrics(this.fallbackEstimator);
|
|
72
55
|
|
|
@@ -76,8 +59,6 @@ class TokenMonitorService {
|
|
|
76
59
|
// Notify
|
|
77
60
|
await this.emitNotification(metrics);
|
|
78
61
|
|
|
79
|
-
m_run.success();
|
|
80
|
-
|
|
81
62
|
return metrics;
|
|
82
63
|
}
|
|
83
64
|
|
|
@@ -1,21 +1,9 @@
|
|
|
1
1
|
const fs = require('fs');
|
|
2
|
-
|
|
3
|
-
const {
|
|
4
|
-
createMetricScope: createMetricScope
|
|
5
|
-
} = require('../../../infrastructure/telemetry/metric-scope');
|
|
6
|
-
|
|
7
2
|
const fsPromises = fs.promises;
|
|
8
3
|
|
|
9
4
|
class TokenStatusReporter {
|
|
10
5
|
constructor(stateFile) {
|
|
11
|
-
const m_constructor = createMetricScope({
|
|
12
|
-
hook: 'token_status_reporter',
|
|
13
|
-
operation: 'constructor'
|
|
14
|
-
});
|
|
15
|
-
|
|
16
|
-
m_constructor.started();
|
|
17
6
|
this.stateFile = stateFile;
|
|
18
|
-
m_constructor.success();
|
|
19
7
|
}
|
|
20
8
|
|
|
21
9
|
async writeStatusFile(metrics) {
|
|
@@ -121,7 +121,21 @@ const commands = {
|
|
|
121
121
|
},
|
|
122
122
|
|
|
123
123
|
ast: () => {
|
|
124
|
-
|
|
124
|
+
const env = { ...process.env };
|
|
125
|
+
const filteredArgs = [];
|
|
126
|
+
|
|
127
|
+
for (const arg of args) {
|
|
128
|
+
if (arg === '--staged') {
|
|
129
|
+
env.STAGING_ONLY_MODE = '1';
|
|
130
|
+
} else {
|
|
131
|
+
filteredArgs.push(arg);
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
execSync(
|
|
136
|
+
`node ${path.join(HOOKS_ROOT, 'infrastructure/ast/ast-intelligence.js')} ${filteredArgs.join(' ')}`,
|
|
137
|
+
{ stdio: 'inherit', env }
|
|
138
|
+
);
|
|
125
139
|
},
|
|
126
140
|
|
|
127
141
|
install: () => {
|
|
@@ -1,40 +1,20 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
-
#
|
|
3
|
-
#
|
|
4
|
-
|
|
2
|
+
# Script Wrapper
|
|
3
|
+
# Redirects to the centralized implementation in scripts/hooks-system
|
|
4
|
+
REPO_ROOT=$(git rev-parse --show-toplevel 2>/dev/null || echo ".")
|
|
5
|
+
IMPL="$REPO_ROOT/node_modules/@pumuki/ast-intelligence-hooks/scripts/hooks-system/bin/guard-env.sh"
|
|
6
|
+
if [[ -f "$IMPL" ]]; then
|
|
7
|
+
# shellcheck disable=SC1090
|
|
8
|
+
source "$IMPL"
|
|
9
|
+
return 0 2>/dev/null || exit 0
|
|
10
|
+
fi
|
|
5
11
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
export HOOK_GUARD_AUTORELOAD_FORCE=${HOOK_GUARD_AUTORELOAD_FORCE:-5000}
|
|
16
|
-
export HOOK_GUARD_DIRTY_TREE_LIMIT=${HOOK_GUARD_DIRTY_TREE_LIMIT:-24}
|
|
17
|
-
export HOOK_GUARD_DIRTY_TREE_WARNING=${HOOK_GUARD_DIRTY_TREE_WARNING:-12}
|
|
18
|
-
export HOOK_GUARD_DIRTY_TREE_INTERVAL=${HOOK_GUARD_DIRTY_TREE_INTERVAL:-60000}
|
|
19
|
-
export HOOK_GUARD_DIRTY_TREE_REMINDER=${HOOK_GUARD_DIRTY_TREE_REMINDER:-300000}
|
|
20
|
-
export TOKEN_MONITOR_INTERVAL=${TOKEN_MONITOR_INTERVAL:-180}
|
|
21
|
-
export TOKEN_MONITOR_REMINDER_SECONDS=${TOKEN_MONITOR_REMINDER_SECONDS:-180}
|
|
22
|
-
export TOKEN_MONITOR_MIN_DELTA=${TOKEN_MONITOR_MIN_DELTA:-25000}
|
|
23
|
-
export HOOK_GUARD_GITFLOW_AUTOSYNC=${HOOK_GUARD_GITFLOW_AUTOSYNC:-true}
|
|
24
|
-
export HOOK_GUARD_GITFLOW_AUTOSYNC_INTERVAL=${HOOK_GUARD_GITFLOW_AUTOSYNC_INTERVAL:-300000}
|
|
25
|
-
export HOOK_GUARD_GITFLOW_AUTOSYNC_COOLDOWN=${HOOK_GUARD_GITFLOW_AUTOSYNC_COOLDOWN:-900000}
|
|
26
|
-
export HOOK_GUARD_GITFLOW_AUTOCLEAN=${HOOK_GUARD_GITFLOW_AUTOCLEAN:-true}
|
|
27
|
-
export HOOK_GUARD_GITFLOW_MAIN_BRANCH=${HOOK_GUARD_GITFLOW_MAIN_BRANCH:-main}
|
|
28
|
-
export HOOK_GUARD_GITFLOW_DEVELOP_BRANCH=${HOOK_GUARD_GITFLOW_DEVELOP_BRANCH:-develop}
|
|
29
|
-
export HOOK_GUARD_GITFLOW_REQUIRE_CLEAN=${HOOK_GUARD_GITFLOW_REQUIRE_CLEAN:-true}
|
|
30
|
-
export GUARD_AUTOSTART_HEALTHY_INTERVAL=${GUARD_AUTOSTART_HEALTHY_INTERVAL:-0}
|
|
31
|
-
export GUARD_AUTOSTART_HEALTHY_COOLDOWN=${GUARD_AUTOSTART_HEALTHY_COOLDOWN:-900000}
|
|
32
|
-
export HOOK_GUARD_HEARTBEAT_PATH="${HOOK_GUARD_HEARTBEAT_PATH:-.audit_tmp/guard-heartbeat.json}"
|
|
33
|
-
export HOOK_GUARD_HEARTBEAT_INTERVAL=${HOOK_GUARD_HEARTBEAT_INTERVAL:-15000}
|
|
34
|
-
export HOOK_GUARD_HEARTBEAT_MAX_AGE=${HOOK_GUARD_HEARTBEAT_MAX_AGE:-45000}
|
|
35
|
-
export HOOK_GUARD_HEARTBEAT_CHECK_INTERVAL=${HOOK_GUARD_HEARTBEAT_CHECK_INTERVAL:-15000}
|
|
36
|
-
export HOOK_GUARD_HEARTBEAT_NOTIFY_COOLDOWN=${HOOK_GUARD_HEARTBEAT_NOTIFY_COOLDOWN:-180000}
|
|
37
|
-
export HOOK_GUARD_GITFLOW_MONITOR=${HOOK_GUARD_GITFLOW_MONITOR:-true}
|
|
38
|
-
export HOOK_GUARD_GITFLOW_MONITOR_INTERVAL=${HOOK_GUARD_GITFLOW_MONITOR_INTERVAL:-300000}
|
|
39
|
-
export HOOK_GUARD_GITFLOW_BRANCH_COOLDOWN=${HOOK_GUARD_GITFLOW_BRANCH_COOLDOWN:-900000}
|
|
40
|
-
export HOOK_GUARD_DEV_DOCS_AUTO_REFRESH=${HOOK_GUARD_DEV_DOCS_AUTO_REFRESH:-true}
|
|
12
|
+
IMPL="$REPO_ROOT/node_modules/pumuki-ast-hooks/scripts/hooks-system/bin/guard-env.sh"
|
|
13
|
+
if [[ -f "$IMPL" ]]; then
|
|
14
|
+
# shellcheck disable=SC1090
|
|
15
|
+
source "$IMPL"
|
|
16
|
+
return 0 2>/dev/null || exit 0
|
|
17
|
+
fi
|
|
18
|
+
|
|
19
|
+
echo "guard-env.sh implementation not found. Please reinstall dependencies." >&2
|
|
20
|
+
return 1 2>/dev/null || exit 1
|