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

Git integration #6105

Closed
Abdur-rahmaanJ opened this issue Dec 31, 2017 · 11 comments
Closed

Git integration #6105

Abdur-rahmaanJ opened this issue Dec 31, 2017 · 11 comments

Comments

@Abdur-rahmaanJ
Copy link

GIT integration

Is there any way to add GIT integration to Spyder?

@CAM-Gerlach
Copy link
Member

CAM-Gerlach commented Dec 31, 2017

Thanks for reporting. Currently, Spyder has basic integration with git via its projects support; see here for more details. However, much more extensive support is planned for the future and currently in work for Spyder 4.0, which was previously planned for next (northern hemisphere) summer, though is currently on hold due to Spyder losing its funding. Better VCS integration is already the subject of issue #816 and so this, as a duplicate, will be closed.

@Abdur-rahmaanJ
Copy link
Author

ok saw it but was 2015 so now 2018. ok thank you ! hope to add it soon. else i am using git with it manual, like any other text editor !

@CAM-Gerlach
Copy link
Member

CAM-Gerlach commented Jan 2, 2018

I understand if you're frustrated, and to be honest we'd all like to see the features we want come sooner. However, this is the same issue, and therefore discussion about it belongs there to keep everything in one place, or else it takes up more of our time toward responding to the same issue over and over and away from coding those features we all want sooner :)

At the moment, you can choose files to stage and commit, and run the full gitk GUI. Personally, I've used other IDEs with built in git support, but honestly prefer the command line anyway—but that's just my preference; to each their own.

As mentioned, it is one of the major features planned for 4.0, which unfortunately has been delayed since we lost our funding; as of now, so we are all just volunteers doing this in our spare time. If you'd like to make it happen faster, we'd be glad to have your help coding, documenting, and testing it, or you can help support the project at OpenCollective. Thanks!

@Abdur-rahmaanJ
Copy link
Author

how to help with coding?

@CAM-Gerlach
Copy link
Member

CAM-Gerlach commented Jan 12, 2018

CONTRIBUTING.md

Also, see our development wiki for more details.

Thanks for your interest; if there's something particular you want to work on but need guidance or help, let us know and we'll assist where we can.

@xjdeng
Copy link

xjdeng commented Feb 18, 2018

Fyi, I only recently discovered this workaround:

First right click the tab corresponding to any file in your repository and click "set console working directory."

Then go to the Ipython window in Spyder and simply type your git commands (assuming Git is installed and its paths are configured properly) but append a "!" to the beginning of your command:

!git add "file.py"
!git commit -m "My commit"
!git push origin master

@loneharoon
Copy link

It seems most of the terminal commands work in Spyder console by appending !.

@CAM-Gerlach
Copy link
Member

CAM-Gerlach commented Mar 28, 2018

Right, using IPython escape magics...nice!

@CAM-Gerlach CAM-Gerlach changed the title GIT integration Git integration Jul 30, 2018
@PatDaoust
Copy link

Fyi, I only recently discovered this workaround:

First right click the tab corresponding to any file in your repository and click "set console working directory."

Then go to the Ipython window in Spyder and simply type your git commands (assuming Git is installed and its paths are configured properly) but append a "!" to the beginning of your command:

!git add "file.py"
!git commit -m "My commit"
!git push origin master

thank you for this!

p.s. "appending" is usually used to mean adding to the end. adding to the start is often called "prepending"

@rvelseg
Copy link

rvelseg commented Apr 26, 2022

Please add to the documentation the dependence of the git integration on git-cola. Possibly here.

In Debian 11 and Ubuntu 18.04, if git-cola is not installed, the commit button in the files sidebar does nothing, and throws no error message, even when spyder was started with the flag --debug-info verbose.

@dalthviz
Copy link
Member

Hi @rvelseg thank you for the feedback. Maybe you can create an issue in https://github.com/spyder-ide/spyder-docs

Probably the info you want added could be put in the Working with version control section here: https://docs.spyder-ide.org/current/panes/projects.html#working-with-version-control

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants