axieax / urlview.nvim

🔎 Neovim plugin for viewing all the URLs in a buffer
MIT License
231 stars 5 forks source link

Add source for Jira issues/keys #11

Closed anrie closed 2 years ago

anrie commented 2 years ago

Thanks a lot for this useful plugin!

It would be great if the plugin could also handle keys for Jira issues (e.g. PROJECT-1234), so that one can browse referenced issues and open them in the browser.

Not sure if the assumption is to simplistic, but for most projects it might suffice if one could define env vars for the JIRA_BASE_URL (e.g. https://your-jira-url.com/browse/)and a JIRA_ISSUE_PATTERN (probably along these lines).

axieax commented 2 years ago

Thanks for putting the feature request here :)) You can now register custom searches in the setup function, e.g.

require("urlview").setup({
    custom_searches = {
        jira = {
            capture = "AXIE%-%d+",
            format = "https://jira.axieax.com/browse/%s",
        },
    },
})
anrie commented 2 years ago

Now that was quick! Thanks a lot for this adding this feature!