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

alias feature #124

Open
MarcWeber opened this issue Jun 18, 2013 · 10 comments
Open

alias feature #124

MarcWeber opened this issue Jun 18, 2013 · 10 comments
Assignees

Comments

@MarcWeber
Copy link
Collaborator

Often snippets get renamed, so we should think about introducing an alias feature, or allow many keys to trigger a snippet.

One use case is:
honza/vim-snippets#196

@MarcWeber
Copy link
Collaborator Author

I also notified SirVer about how he thinks about aliases.

@MarcWeber
Copy link
Collaborator Author

One possible implementation is here:
https://github.com/Shougo/neosnippet.vim/blob/master/doc/neosnippet.txt
I like that those snippets have an head

Should we work on common extensible snippet syntax ?

@SirVer
Copy link

SirVer commented Jun 18, 2013

This has never been requested for UltiSnips so I am kinda meh. It would be easy enough to implement though and the use case from the merge request seems valid.

That said people would still need to clear() the trigger they don't like. So I am still meh :)

@MarcWeber
Copy link
Collaborator Author

Thinking about it again eventually making "snippet rewriting" on the fly easy is a better way to solve "all" of such cases. See hints in other issue. For "renaming" cases alias may still be useful - keeping it open for that reason

@ajzafar
Copy link
Collaborator

ajzafar commented Jun 19, 2013

This shouldn't be too hard to implement, but I'm not sure I understand the use case. I don't see any use for it outside of a name change in a snippet repository, which to me seems like a fairly limited use case. Maybe I'm alone in this, but I've always thought of snippets as a personal part of one's dotfiles, with the repositories being a nice starting point. Though I'm not entirely against this, I've always thought that one of SnipMate's strengths is its simplicity.

@MarcWeber, what do you mean by "snippet rewriting"?

@SirVer
Copy link

SirVer commented Jun 19, 2013

@ajzafar I share your opinion about snippets being something very personal, so I share your opinion of this feature. But it is easy to implement, so I am meh :)

@MarcWeber
Copy link
Collaborator Author

@kassio
Copy link

kassio commented Jul 16, 2013

I'd like alias feature too.

Sometimes, trying to be faster than I really am, I don't type the snippet last key, like: cl<tab> instead of cla<tab>, aliases could help me in this cases.

@907th
Copy link

907th commented Dec 20, 2013

+1

@dechimp
Copy link

dechimp commented Oct 26, 2014

agreed. This would be really great.

@ajzafar ajzafar self-assigned this Jan 1, 2024
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

6 participants