-
Notifications
You must be signed in to change notification settings - Fork 1
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
[Feature Request] Gitea Open with IDE support #11
Comments
Cool! I have yet to try this new Gitea feature, but I imagine something like this could work:
#!/bin/bash
# Strip 'git-dev://open/?repo='
nvim -c "GitDevOpen ${1/git-dev:\/\/open\/?repo=/}"
chmod +x ~/.local/bin/git-dev
xdg-mime default gitdev.desktop x-scheme-handler/git-dev
xdg-open git-dev://open/?repo=https://github.com/moyiz/git-dev.nvim
It should work assuming Gitea does no escape I will think about generating such handler via plugin options. Let me know how it goes 🙂 |
SummaryIt works, when un- For my config, i changed it to Repository to try it out with: https://git.euph.dev/Snoweuph/Dotfiles Also, it doesn't work with also for the script to work on my System (Kinoite), I had to wrap the #!/bin/bash
function urldecode() { : "${*//+/ }"; echo -e "${_//%/\\x}"; }
git_url=$(urldecode $1)
# Strip 'git-dev://open/?repo='
toolbox run -- nvim -c "GitDevOpen ${git_url/nvim-gitdev:\/\/open\/?repo=/}" In the [Desktop Entry]
Name=Neovim GitDev Handler
Comment=Opens a Git URI in Neovim.
Exec=/home/snoweuph/.local/bin/nvim-gitdev.sh %u
Terminal=true
Type=Application
MimeType=x-scheme-handler/nvim-gitdev I suggest an option like this: opts = {
xdg_handler = {
wrapper = "toolbox run -- "
}
} xdg-handler should be |
I just forked the project, and I gonna work on adding the needed code, to handle registering x-schemes |
I would love to see
Gitea
open with <IDE>
:https://blog.gitea.com/release-of-1.22.0/#rocket-customizable-open-with-ide-menu-29320
Requirements
The text was updated successfully, but these errors were encountered: