Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buffer Delete vs Delete Buffer #806

Closed
bhajneet opened this issue Sep 15, 2016 · 6 comments
Closed

Buffer Delete vs Delete Buffer #806

bhajneet opened this issue Sep 15, 2016 · 6 comments

Comments

@bhajneet
Copy link
Contributor

There is only one command that begins with "del", instead if someone were trying to find commands related to ":buffer" they would not see the "delbuf" or "db" command. I would personally think bd, bufdel, bufferdelete makes more sense.

@lenormf
Copy link
Contributor

lenormf commented Sep 16, 2016

Commands all have semanticaly the same form (except for buffernext and bufferprev which I think were named that way because they are standard commands across all editors): first a verb indicating what action is made, and then the subject that action applies to.

Examples: cd (change directory), nameclient, namesession, rmhooks, addhl etc.

That makes discovering commands intuitively harder in theory, but the fuzzy matching and the :doc commands command make up for that.

@bhajneet
Copy link
Contributor Author

I see that verb-subject pattern in a lot of them, that makes sense too.

What about those that are grouped up like autowrap-enable / disable? There are others too under clang, jedi, tmux but I figure those are because they are external perhaps.

Also double-verbs like grep-next, prev, jump (Or would grep be considered a subject?). Buffer can be used as a verb too, idk.

Regardless, if you want delbuf, you should probably add deletebuffer then, so that when someone types "buffer" they see the relevant commands, regardless of naming scheme. Some might not type "buf" only, or might not know if there are other commands starting with "buf". Since the commands are few, it's not a big deal, just wanted to point it out.

@lenormf
Copy link
Contributor

lenormf commented Sep 16, 2016

Non-builtin commands have the name of the "module" they were declared in as prefix, and then a verb usually follows.

Feel free to make a pull request if you want to take it up with @mawww, I personally only use the aliases to builtin commands so name changes won't impact me.

@mawww
Copy link
Owner

mawww commented Sep 16, 2016

Hi, got a quick moment with an internet connection to add my 2 cents,

So, frankly, all that naming did not follow much logic, it was whatever felt ok whenever I named the commands. I actually think it would be nice to do a proper pass on all the commands, try to get more consistency. I'd go even further than commands, options naming would also benefit a bit from more consistency.

Regarding the commands, now that we have nice auto completion, I'd favor longer and more expressive command names, using - as a word separator, for example, cd would be an alias to change-directory, addhl would be an alias to add-highlighter (or maybe change the alias to ah ?...)

Thats my current idea (that is, this evening, after a long day hiking and swimming), I'd need to think a bit more about it (as often, the existing commands/behaviours are good enough, and have the advantage of being the known ones, so that tends not to be very high priority).

Cheers,

Maxime.

@alexherbo2
Copy link
Contributor

+1 for real word command / option names.

@mawww
Copy link
Owner

mawww commented Nov 20, 2016

The rename went with mostly verb-name, there remain buffer-next and buffer-previous that do not strictly follow the pattern, but we are going in that direction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants