This package consumes the following services:
Atom git-diff-plus package
An alternative for git-diff
package for :atom: editor.
Features
git-diff-plus
covers every functionality provided by git-diff
, which comes with Atom by default, but also provides lots of some additional features and various improvements.
There are mainly three advantages below for you to use git-diff-plus
over git-diff
.
git-diff-plus
:
- tracks diffs for every file under .git repository, meaning you can see diffs in files outside of a current project as well as diffs in ones under the current project
git-diff
can only shows diffs in files under a current project ...
- indicates per-file diffs in status-bar as well as in editor gutters
- of course you can disable this integration via your config setting
- includes a lot of minor improvements/refactors. E.g.:
- can recognize an newly added repository
- doesn't cause error after an previously recognized repository is removed
- gutter icons don't collide with gutter elements exported by atom-ide-ui
- better disposers, minimal condition checks
- and etc...
Installation
- Install :atom:
- Install
git-diff-plus
package: Follow either way below- Run command
apm install git-diff-plus
- Follow GUI menu
File -> Settings -> Install
and search forgit-diff-plus
and clickInstall
button
- Run command
- Disable
git-diff
package: Follow either way- Run command
apm disable git-diff
- Follow the GUI menu
File -> Settings -> Packages
and search forgit-diff
and clickDisable
button
- Run command
- Open any file under .git repository
Notes:
git-diff
package is bundled with Atom by default- Disabling
git-diff
is recommended to avoid duplicated works and collisions of the commands- Don't worry,
git-diff-plus
covers every functionality provided bygit-diff
- Don't worry,
- On Atom's startup,
git-diff-plus
would automatically detect ifgit-diff
is activated and if so shows buttons to disable it, thus you can even skip step 3.
Usage
UI
Diff indicators in editor gutters:
Config: Show Icons In Editor Gutter |
false (default) |
true |
---|---|---|
Gutter |
Diff indicators in the Status-bar
- You can click the status-bar tile to invoke
Git Diff Plus: Toggle Diff List
command - Disable this tile via setting config
Show Diffs In Status Bar
tofalse
Command
Git Diff Plus: Move To Previous Diff
(Alt-G Up): move the cursor to the previous diff in the editorGit Diff Plus: Toggle Diff List
(Alt-G D): see all the diffs in a current active editorGit Diff Plus: Rebuild Repository Cache
: invoke this command when you find diffs for an newly added repository is not recognized
git-diff
?
Why not merging to There is a difficult issue around finding a correct .git repository actually, and the Atom's core team is now trying to solve this in an higher level, thus the specific issues around it are kind of pending.
But still I found the fixes for them are really useful even though they are not perfect, so git-diff-plus
is here as a community package. In a sense, this package serves as a temporal remedy for the specific issues like:
- https://github.com/atom/atom/issues/19584
- https://github.com/atom/github/issues/1035
I'm really sure the logic to find/subscribe .git repository used in git-diff-plus
is much more better than the one used in git-diff
, still it may fail to find/subscribe a repository.
Even this package works very fine as far as I've used, but in a case you encounter a problem, please help me find issues by reporting it !
License
This package is under MIT License, which is the modified version of the original one of git-diff
package.
Acknowledgements
This package is originally a clone of git-diff
package.
Author
- Shuhei Kadowaki - undergraduate @ kyoto univ. - aviatesk