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

Scripting with neogit? #73

Open
gegoune opened this issue Mar 23, 2021 · 2 comments
Open

Scripting with neogit? #73

gegoune opened this issue Mar 23, 2021 · 2 comments
Labels
enhancement New feature or request

Comments

@gegoune
Copy link

gegoune commented Mar 23, 2021

Amazing plugin, only touched the surface what it can do and it seems like you have amazing plans for it! I think I will be able to replace fugitive if I could automate some workflows that I have, namely saving changes to the file, committing those changes and pushing to remote. Is it possible with current state of neogit? I guess neogit would need to expose some functions?

Thanks!

@RianFuro
Copy link
Contributor

Just to leave my thoughts on the matter: While I do think we'll expose a stable api at some point to use for scripting, it would most likely involve the use of async, so I think we should wait for nvim-lua/plenary.nvim#83 to get merged, transition our code to that and expose an api that way, just so users can have reasonable expectations about the async/await api.

(Also, that way users would need to have plenary, and by extension the async/await set of functions, already installed, so we don't have to worry about that too; and we'd have a place to point to for documentation on the matter 😁)

@TimUntersberger
Copy link
Collaborator

@cloggier for now you could look through neogit.lib.

Things that might interest you:

  • cli.lua
  • git/*.lua

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

No branches or pull requests

3 participants