mirror of
https://github.com/ruvnet/ruflo.git
synced 2026-11-23 21:59:14 +09:00
`memory_import_claude({ allProjects: false })` couldn't find the current
project's memory directory on a pure Win32+Win32 install, because the
slug candidates in `resolveProjectMemoryDir()` only replaced forward
slashes — never the drive-colon, backslash, or whitespace that a Win32
cwd contains.
Example:
- cwd: `C:\Users\tobia\OneDrive\Desktop\Claude Stuff`
- Claude Code's on-disk slug: `C--Users-tobia-OneDrive-Desktop-Claude-Stuff`
- Before this fix: no candidate matched, importer reported `imported: 0,
"No Claude memory files found"`.
Add a Win32-specific candidate gated on `/^[A-Za-z]:[\\/]/` that does the
full normalization (`:` / `\` / `/` / whitespace → `-`). The other four
candidates (legacy POSIX, WSL `/mnt/<drive>/`, leading-dash strip, space
rule) are unchanged, so no regression for the other setup classes.
Verified the new candidate emits
`C--Users-tobia-OneDrive-Desktop-Claude-Stuff` for the reporter's path.
Build verified clean (tsc).
Resolves #1939.
Co-authored-by: Reuven <cohen@ruv-mac-mini.local>
This commit is contained in:
1 parent
1d414b194d
commit
4e6822fa8d
1 file changed
+10
@@ -135,6 +135,16 @@ function resolveProjectMemoryDir(claudeProjectsDir: string, projectPathOverride?
|
||||
|
||||
// Candidate 4: spaces replaced with dashes (Claude Code's space rule)
|
||||
candidates.add(source.replace(/\//g, '-').replace(/ /g, '-'));
|
||||
|
||||
// Candidate 5 (#1939): native Win32 path on a Win32 Claude Code install.
|
||||
// `C:\Users\tobia\OneDrive\Desktop\Claude Stuff` →
|
||||
// `C--Users-tobia-OneDrive-Desktop-Claude-Stuff`. Claude Code's on-disk
|
||||
// slug replaces drive-colon AND backslashes AND whitespace with `-`.
|
||||
// The earlier candidates only handled forward slashes, so a Win32+Win32
|
||||
// setup never matched.
|
||||
if (/^[A-Za-z]:[\\/]/.test(source)) {
|
||||
candidates.add(source.replace(/[:\\/]/g, '-').replace(/\s+/g, '-'));
|
||||
}
|
||||
}
|
||||
|
||||
for (const projectHash of candidates) {
|
||||
|
||||
Reference in new issue
Block a user