Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
add variable to customize behavior of the magic slash on non-existing directories #998
The personal pain point this solved for me is creating files in non-existing directories. As an example, with the 'magic-slash' enabled I found it impossible to create
Is it possible to prompt the user from the ivy minibuffer? I.e. if a user were to enter
If we could do that, then I would be in favor of the magic solution. However, I don't think it'd be a great idea to create directories behind the scenes if a slash is added. If that is the case I'll just add a configuration to prevent the magic slash functionality on non-matches (case 5).
@abo-abo I've updated this pull request to allow the magic slash behavior to be customized when added to the end of a non-existing directory.
I've added the variable:
The setting defaults to the current behavior (
Also, tried out adding a y/n prompt on creating the directory, but it resulted in a pretty poor user experience. The auto creation of directories works out pretty nicely.