mirror of
https://github.com/getpaseo/paseo.git
synced 2026-10-28 20:22:45 +00:00
* feat(worktrees): copy included local files before setup and agents Keep local-file materialization in one built-in lifecycle hook so workspace setup and the first agent see the completed copy. Reuse the community plugin algorithm with the source checkout supplied by the worktree hook. Co-authored-by: Carlos Precioso <github@precioso.design> * test(plugins): make worktree lifecycle checks portable on Windows Compare source checkout filesystem identity across Git and Windows path spellings. Exercise copy rollback with a destination file blocking a directory, since Git for Windows accepts directories as exclude files. --------- Co-authored-by: Carlos Precioso <github@precioso.design>
9 lines
347 B
TypeScript
9 lines
347 B
TypeScript
import type { PluginServerContext } from "@getpaseo/plugin/server";
|
|
import { copyWorktreeIncludes } from "./server/copy.js";
|
|
|
|
export default function contribute(server: PluginServerContext) {
|
|
return server.addHook("worktree.create.after", async ({ worktree }) => {
|
|
await copyWorktreeIncludes(worktree.path, worktree.sourceCheckout);
|
|
});
|
|
}
|