Repository navigation
Commit 0009ecb
committed
Extract workspace snapshot creation and restoration logic into a shared utility module used by checkpoints and agentic search
- 'agentic search' sometimes edits some files, to prevent it: use similar approach to creating and restoring checkpoint (but don't use checkpoint feature but shared util from `apps/editor/src/features/checkpoints/utils` - make sure checkpoint creation also use this snapshotting util) [Accuracy boost]
- utils shared between features [Changes] should be moved to `apps/editor/src/utils`
└── apps
└── editor
└── src
├── commands
│ ├── agentic-search-command
│ │ ├── agentic-search-command.ts
│ │ └── index.ts
│ ├── apply-response-command
│ │ └── apply-response-command.ts
│ └── history-command
│ ├── actions
│ │ ├── clear-all-checkpoints.ts
│ │ ├── create-temporary-checkpoint.ts
│ │ ├── delete-checkpoint-with-undo.ts
│ │ ├── restore-checkpoint.ts
│ │ ├── toggle-checkpoint-pin.ts
│ │ └── update-checkpoint-description.ts
│ ├── history-command.ts
│ └── index.ts
├── constants
│ └── state-keys.ts
├── context
│ └── providers
│ └── workspace
│ └── workspace-provider.ts
├── extension.ts
├── features
│ ├── agentic-search
│ │ ├── agentic-search-state.ts
│ │ ├── agentic-search.ts
│ │ ├── index.ts
│ │ └── utils
│ │ ├── build-agent-prompt.ts
│ │ ├── index.ts
│ │ └── prompt-for-search-term.ts
│ └── checkpoints
│ ├── actions
│ │ ├── accept-checkpoint.ts
│ │ ├── create-checkpoint.ts
│ │ ├── delete-checkpoint.ts
│ │ ├── get-checkpoints.ts
│ │ └── index.ts
│ ├── types
│ │ ├── checkpoint.ts
│ │ └── index.ts
│ └── utils
│ ├── get-checkpoint-path.ts
│ ├── get-incremented-description.ts
│ └── index.ts
├── utils
│ ├── ascii-tree
│ │ ├── ascii-tree.ts
│ │ ├── index.ts
│ │ └── utils.ts
│ ├── copy-optimised-recursively.ts
│ ├── files-collector.ts
│ ├── get-error-message.ts
│ ├── git-utils.ts
│ ├── sync-directory.ts
│ ├── sync-workspace-from-dir.ts
│ └── workspace-snapshot.ts
└── views
└── prompt
└── backend
└── message-handlers
└── handle-agentic-search.ts1 parent a28a4e4 commit 0009ecb
10 files changed
Lines changed: 522 additions & 535 deletions
File tree
- apps/editor/src
- commands/history-command/actions
- features
- agentic-search
- checkpoints
- actions
- utils
- utils
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | 1 | | |
3 | 2 | | |
4 | 3 | | |
5 | | - | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
15 | 7 | | |
16 | 8 | | |
17 | 9 | | |
| |||
27 | 19 | | |
28 | 20 | | |
29 | 21 | | |
30 | | - | |
31 | 22 | | |
32 | 23 | | |
33 | 24 | | |
34 | 25 | | |
35 | 26 | | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | | - | |
88 | | - | |
89 | | - | |
90 | | - | |
91 | | - | |
92 | | - | |
93 | | - | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
109 | 30 | | |
110 | 31 | | |
111 | 32 | | |
| |||
126 | 47 | | |
127 | 48 | | |
128 | 49 | | |
129 | | - | |
130 | | - | |
| 50 | + | |
| 51 | + | |
131 | 52 | | |
132 | 53 | | |
133 | 54 | | |
| |||
0 commit comments