@henryqw/pi-herdr-clone 0.2.6 → 0.2.7
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/extensions/clone-tab.ts +2 -4
- package/package.json +1 -1
package/extensions/clone-tab.ts
CHANGED
|
@@ -129,14 +129,12 @@ async function createBranchedClone(
|
|
|
129
129
|
const createdClone = session.createBranchedSession(source.leafId);
|
|
130
130
|
if (!createdClone) throw new Error("Pi did not create a persisted clone session file.");
|
|
131
131
|
const cloneFile = resolve(createdClone);
|
|
132
|
-
let cloneStat;
|
|
133
132
|
try {
|
|
134
|
-
|
|
133
|
+
if ((await stat(cloneFile)).isFile()) return cloneFile;
|
|
135
134
|
} catch (error) {
|
|
136
135
|
throw new Error(`Pi clone session file was not created: ${cloneFile}`, { cause: error });
|
|
137
136
|
}
|
|
138
|
-
|
|
139
|
-
return cloneFile;
|
|
137
|
+
throw new Error(`Pi clone session path is not a file: ${cloneFile}`);
|
|
140
138
|
}
|
|
141
139
|
|
|
142
140
|
// A worktree layout plugin (e.g. herdr-plus) can start its own agent in a new
|