Commit c58e31e
fix: Disallow nil passing to create_dirs()
To tackle deletion and creation path issues, commit 6e1fa15 ("feat:
Enable user to get "out" of a worktree") added the possibility of passing
nil to change_dirs(). But the problems can be solved in a better way:
When deleting, check if the selection is the current tree then change dir
to gitroot_dir() if so. When creating, add gitroot_dir() as prefix.1 parent 4197927 commit c58e31e
File tree
2 files changed
+18
-34
lines changed- lua
- git-worktree
- telescope/_extensions
2 files changed
+18
-34
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | 17 | | |
27 | 18 | | |
28 | 19 | | |
| |||
72 | 63 | | |
73 | 64 | | |
74 | 65 | | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
79 | 72 | | |
80 | 73 | | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | 74 | | |
87 | | - | |
88 | | - | |
89 | | - | |
90 | | - | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
91 | 78 | | |
92 | | - | |
| 79 | + | |
93 | 80 | | |
94 | 81 | | |
95 | 82 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | 21 | | |
25 | 22 | | |
26 | 23 | | |
| |||
118 | 115 | | |
119 | 116 | | |
120 | 117 | | |
121 | | - | |
122 | | - | |
123 | | - | |
| 118 | + | |
124 | 119 | | |
125 | | - | |
126 | | - | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
127 | 126 | | |
128 | 127 | | |
129 | 128 | | |
| |||
137 | 136 | | |
138 | 137 | | |
139 | 138 | | |
140 | | - | |
141 | | - | |
| 139 | + | |
142 | 140 | | |
143 | 141 | | |
144 | 142 | | |
| |||
184 | 182 | | |
185 | 183 | | |
186 | 184 | | |
187 | | - | |
188 | 185 | | |
189 | 186 | | |
190 | 187 | | |
| |||
0 commit comments