Closed leonardo-delfino closed 6 months ago
So the intention of this PR is to have similar behavior to cpb clone
but when doing cpb create
?
When using cpb create
, the tool just creates the file/s. As stated in the README, it would be a good thing to directly open them just right after the creation. The thing is that if gnome-terminal
is used as editor
, it would not be possible to edit it directly (as it is not an editor). So, in the case of terminals (konsole, gnome-terminal, etc) it would just open the path in which the files have been created.
So the intention of this PR is to have similar behavior to
cpb clone
but when doingcpb create
?
Yes, this makes it possible to open a file right after creating it, doing something similar to the cpb clone
. The separate EditorCommandBuild
is needed because of multiple files, and because of terminals (using an editor, it's better to open the file / files directly, but using a terminal that is not possible so I just need to open it in the directory in which the file/s have been created).
The flag openTerminal
makes not that much sense alone here, but it permits to not open N
instances of terminals where N
is the number of parsed problems. I've found a fix for the Windows WSL bug not downloading the whole problemset, but I'll create a separate PR for that.
Excited to see the fix for Windows WSL, thanks
After creating a new file with
cpb create
, it is opened with the selected editor (or, if it's a terminal, the terminal is opened in the path of the new created file).