Open
Conversation
Owner
|
This is an excellent idea. I think a marginally better way would be to remove the new fact and its accompanying check and change this original line from: vim_plugin_name: "{{ (vim_plugin_install.repo | basename | splitext)[0] }}"...to: vim_plugin_name: "{{ vim_plugin_install.name | default((vim_plugin_install.repo | basename | splitext)[0]) }}" |
Author
|
Again, sorry that I missed the notification on this. Yeah, that seems reasonable to me. I'm unfortunately strapped for time and don't think I'll find the space to submit this fix. But I agree that this sounds better. |
Author
|
I was able to find the time to give this an update. I tried your suggestion and it worked on my machine! Let me know what you think, I'll try to be more responsive to notifications. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Very nice little ansible role!
I added a small feature - allowing to set the name of the plugin instead of using the basename of the git repo. This is handy if the plugin's repo is named something silly like "vim" - for example, the dracula plugin.
I'm not quite an expert at ansible, so there might be a better way to do this. Happy to iterate with feedback!