repo-nexus 0.7.22 → 0.7.23
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/CLI.md +1 -1
- package/docs/cli/workspace.md +2 -2
- package/docs/guide/configuration.md +1 -1
- package/lib/commands/status.sh +2 -2
- package/lib/commands/sync.sh +3 -3
- package/lib/workspace.sh +3 -3
- package/package.json +1 -1
package/docs/CLI.md
CHANGED
|
@@ -41,7 +41,7 @@ rnex sync [-y|--yes] [-q|--quiet]
|
|
|
41
41
|
6. **Harness Sync**: Reconciles root `.rnex/` and member repository harnesses (`repos/<name>/.rnex/`) for all enabled member repositories where `rnex_dir: true`.
|
|
42
42
|
7. **Git Hooks**: Installs or reconciles workspace Git hooks in `.rnex/hooks` when `git_hooks: true`.
|
|
43
43
|
8. **Multi-Root Workspace**: Synchronizes `.code-workspace` folder mappings when `code_workspace: true`.
|
|
44
|
-
9. **Event-Driven Auto-Sync Scripts & Stamp**: Generates `.rnex/bin/auto-sync.sh` and updates `.rnex
|
|
44
|
+
9. **Event-Driven Auto-Sync Scripts & Stamp**: Generates `.rnex/bin/auto-sync.sh` and updates `.rnex/sync_stamp`.
|
|
45
45
|
|
|
46
46
|
---
|
|
47
47
|
|
package/docs/cli/workspace.md
CHANGED
|
@@ -71,7 +71,7 @@ rnex sync [options]
|
|
|
71
71
|
7. Reconciles automated Git hooks in `.rnex/hooks/` against `git_hooks` config.
|
|
72
72
|
8. Re-creates member `.rnex/` scaffolding in active repositories (`rnex_dir: true`).
|
|
73
73
|
9. Updates multi-root `.code-workspace` folder mappings if configured.
|
|
74
|
-
10. Generates `.rnex/bin/auto-sync.sh` and updates the checksum stamp in `.rnex
|
|
74
|
+
10. Generates `.rnex/bin/auto-sync.sh` and updates the checksum stamp in `.rnex/sync_stamp`.
|
|
75
75
|
|
|
76
76
|
---
|
|
77
77
|
|
|
@@ -86,7 +86,7 @@ rnex status
|
|
|
86
86
|
|
|
87
87
|
### Execution
|
|
88
88
|
* **Strictly Read-Only**: Inspects workspace health, active repos, loaded config files (`rnex.yaml` and `.local.rnex.yaml`), git hooks, and plugins.
|
|
89
|
-
* **Sync Diagnostics**: Compares current config checksums against `.rnex
|
|
89
|
+
* **Sync Diagnostics**: Compares current config checksums against `.rnex/sync_stamp` and suggests running `rnex sync` if configuration drift is detected.
|
|
90
90
|
|
|
91
91
|
---
|
|
92
92
|
|
|
@@ -126,5 +126,5 @@ rnex sync
|
|
|
126
126
|
```
|
|
127
127
|
|
|
128
128
|
::: tip Status & Auto-Sync
|
|
129
|
-
Running `rnex status` inspects workspace health and checks if configuration is in sync with `.rnex
|
|
129
|
+
Running `rnex status` inspects workspace health and checks if configuration is in sync with `.rnex/sync_stamp`. Running `rnex sync` applies full reconciliation and updates the sync stamp. Workspace commands (like `rnex list`) also automatically trigger auto-sync whenever configuration changes.
|
|
130
130
|
:::
|
package/lib/commands/status.sh
CHANGED
|
@@ -50,8 +50,8 @@ cmd_status() {
|
|
|
50
50
|
printf ' %b●%b Workspace: %s\n' "$_DIM" "$_NC" "$CODE_WORKSPACE_FILE"
|
|
51
51
|
fi
|
|
52
52
|
|
|
53
|
-
_stamp_file="$NEXUS_DIR/.rnex
|
|
54
|
-
[ -f "$_stamp_file" ] || _stamp_file="$NEXUS_DIR/.rnex
|
|
53
|
+
_stamp_file="$NEXUS_DIR/.rnex/sync_stamp"
|
|
54
|
+
[ -f "$_stamp_file" ] || _stamp_file="$NEXUS_DIR/.rnex/.sync_stamp"
|
|
55
55
|
_cur_sum="$(get_config_sum "$NEXUS_DIR")"
|
|
56
56
|
if [ ! -f "$_stamp_file" ] || [ "$_cur_sum" != "$(cat "$_stamp_file" 2>/dev/null)" ]; then
|
|
57
57
|
printf ' %b!%b Sync Stamp: workspace out of sync with configuration (run "rnex sync")\n' "$_Y" "$_NC"
|
package/lib/commands/sync.sh
CHANGED
|
@@ -15,8 +15,8 @@ set -e
|
|
|
15
15
|
_ws="$(cd "$(dirname "$0")/../.." 2>/dev/null && pwd -P)"
|
|
16
16
|
[ -f "$_ws/rnex.yaml" ] || exit 0
|
|
17
17
|
|
|
18
|
-
_stamp="$_ws/.rnex
|
|
19
|
-
[ -f "$_stamp" ] || _stamp="$_ws/.rnex
|
|
18
|
+
_stamp="$_ws/.rnex/sync_stamp"
|
|
19
|
+
[ -f "$_stamp" ] || _stamp="$_ws/.rnex/.sync_stamp"
|
|
20
20
|
_cur_sum="$(cd "$_ws" 2>/dev/null && cksum rnex.yaml .local.rnex.yaml 2>/dev/null | cksum | awk '{print $1, $2}')"
|
|
21
21
|
_saved_sum=""
|
|
22
22
|
[ -f "$_stamp" ] && _saved_sum="$(cat "$_stamp" 2>/dev/null)"
|
|
@@ -93,7 +93,7 @@ cmd_sync() {
|
|
|
93
93
|
# 2.1. Compile .rnex/ai-instructions.md
|
|
94
94
|
build_ai_instructions "$NEXUS_DIR"
|
|
95
95
|
|
|
96
|
-
# 2.2. Update sync stamp (.rnex
|
|
96
|
+
# 2.2. Update sync stamp (.rnex/sync_stamp)
|
|
97
97
|
update_sync_stamp "$NEXUS_DIR"
|
|
98
98
|
|
|
99
99
|
# --------------------------------------------------------------------------
|
package/lib/workspace.sh
CHANGED
|
@@ -52,8 +52,8 @@ update_sync_stamp() {
|
|
|
52
52
|
fi
|
|
53
53
|
fi
|
|
54
54
|
_csum="$(get_config_sum "$_dir")"
|
|
55
|
-
printf '%s\n' "$_csum" > "$_dir/.rnex/.sync_stamp"
|
|
56
55
|
printf '%s\n' "$_csum" > "$_dir/.rnex/sync_stamp"
|
|
56
|
+
rm -f "$_dir/.rnex/.sync_stamp"
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
check_auto_sync() {
|
|
@@ -76,8 +76,8 @@ check_auto_sync() {
|
|
|
76
76
|
_cfg_file="$(resolve_path "$CUSTOM_CONFIG" 2>/dev/null || true)"
|
|
77
77
|
fi
|
|
78
78
|
[ -f "$_cfg_file" ] || return 0
|
|
79
|
-
_stamp="$_ws/.rnex
|
|
80
|
-
[ -f "$_stamp" ] || _stamp="$_ws/.rnex
|
|
79
|
+
_stamp="$_ws/.rnex/sync_stamp"
|
|
80
|
+
[ -f "$_stamp" ] || _stamp="$_ws/.rnex/.sync_stamp"
|
|
81
81
|
if [ ! -f "$_stamp" ] || [ "$(get_config_sum "$_ws")" != "$(cat "$_stamp" 2>/dev/null)" ]; then
|
|
82
82
|
cmd_sync -y --quiet
|
|
83
83
|
fi
|
package/package.json
CHANGED