Git Product home page Git Product logo

github's Introduction

Atom and all repositories under Atom will be archived on December 15, 2022. Learn more in our official announcement

Atom GitHub Package

Build Code Coverage
Build Status codecov

The Atom GitHub package provides Git and GitHub integration for Atom. Check out github.atom.io for more information.

GitHub for Atom

git-integration

pull request view

in-editor pull request comments

Installation

This package is bundled with Atom starting in version 1.18, and does not need to be installed separately.

License

The MIT license grant is not for GitHub's trademarks, which include the logo designs. GitHub reserves all trademark and copyright rights in and to all GitHub trademarks.

GitHubยฎ and its stylized versions and the Invertocat mark are GitHub's Trademarks or registered Trademarks. When using GitHub's logos, be sure to follow the GitHub logo guidelines.

github's People

Contributors

asturur avatar benogle avatar binarymuse avatar darangi avatar daviwil avatar deedeeg avatar dependabot-preview[bot] avatar dependabot-support avatar dependabot[bot] avatar gauravchl avatar greenkeeper[bot] avatar hubot avatar jasonrudolph avatar joshaber avatar kuychaco avatar lkashef avatar maxbrunsfeld avatar niik avatar okbel avatar orderedlist avatar robertrossmann avatar sadick254 avatar simurai avatar smashwilson avatar thedaniel avatar uzitech avatar vanessayuenn avatar wadethestealth avatar xapphire13 avatar z0al avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

github's Issues

Add some key binding to close diff + file list UIs

Usually I work like this:

  1. Stage some lines, and hunks
  2. Make a commit
  3. Loop until I have nothing more I want to commit

Then I want to get back to writing code, so I want the git UI to all hide. I often use gitx, and with it, I just quit. In the current git package, I

  1. Figure out which panel has focus (maybe diff, maybe file list)
  2. Hit escape if panel
  3. Cmd-w if diff
  4. GOTO 1 if git UI in my face

I really want a single command that's like 'hey, git package, I'm done using you, you can hide now'.

Been thinking that maybe escape when either the diff or file list is focused will hide both of them. Could try it and see if it's invasive. In the previous git prototype, escape in the diff would clear the hunk/line selection, but I think clearing the selection is fine now by just using the arrow keys.

Thoughts?

Unstaging fails in some cases?

I'm in the middle of something else so I wasn't able to dig into it. But I had a lot of hunks staged and I wanted to unstage a few lines in one of the staged hunks.

Open diff when clicking on items in the file list panel

screen shot 2016-02-18 at 2 09 48 pm

I think clicking on files should work like the treeview. So

  • Single click to open a diff in preview mode
  • Double click to open a diff in regular mode

This will be a feel thing, and we could change it. Maybe when clicking on a file, you dont want to see the diff, not sure. But I think using the same interaction as the treeview is a good place to start.

Some files don't stage/unstage cleanly

I haven't figured out what the pattern is yet, but some files still stage fine, but then unstaging leaves something behind in the index. Probably related to the \ No newline at end of file token?

Stuff we should add to core for a better git package

Rather than drag people from the core team away from their current work, it might make sense for the folks working on this package to do these:

Feel free to add more to this; these are off the top of my head.

Specs for staging

As I demonstrated in #23 (:see_no_evil:), we don't have any specs that ensure staging and unstaging actually do what they claim they do. We should fix that.

CSS naming convention

Because this packages is still somewhat young, might be worth to define some naming convention. Well, at least for the CSS classes. If it works out well, we could also start using it for other packages, like atom/github.

  • write a draft
  • test it out in a PR
  • if ok, apply to the rest

Calculate diffs on demand

We currently calculate all diffs up front. This is probably unnecessarily expensive. We should instead only calculate diffs when they're needed.

Enable/disable cleanly

Currently when you disable, the status bar tile doesn't disappear. Then when you able again, we add a new status bar tile.

Add ability to discard

I want to be able to discard files / hunks / lines. Maybe lines is a little extreme, but definitely allowing the discard of files and hunks would be nice.

  • From the keyboard, I want to use backspace. We could pop a confirmation.
  • From the UI, not sure. @simurai, have any ideas?

Dependencies spring cleaning

We have jquery and some other stuff in package.json that, AFAIK, we aren't using. We should make sure it's ๐Ÿ’€ and then apply ๐Ÿ”ฅ

Add the commit box

screen shot 2016-02-18 at 2 13 50 pm

- Dont need to do anything special in the editor for summary and description. Convention that every other git editor uses: first line summary, blank line, other lines are description. - Use the [git grammar](https://github.com/atom/language-git) in this editor for dopeness - The grammar could probably be improved for our usecase - Initial pass doesnt need to have counter, but it would be cool. Prolly just a div overlay? - Maybe counter is unnecessary due to the grammar. Will likely be clearer after using the grammar cc @simurai - Using text-editors as textareas kind of sucks right now. See https://github.com/atom/atom/issues/5503 One might be inclined to do that work as part of this, or shortly before / after.

Unexpected reserved word

  1. Install git package.

Atom Version: 1.5.4
System: Mac OS X 10.11.3
Thrown From: git package, v0.0.0

Stack Trace

Failed to load the git package

At Unexpected reserved word

SyntaxError: Unexpected reserved word
    at Module._compile (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:77:42)
    at Object.defineProperty.value [as .js] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:208:21)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Module.require (module.js:365:17)
    at require (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:50:27)
    at Package.module.exports.Package.requireMainModule (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:720:27)
    at /Applications/Atom.app/Contents/Resources/app.asar/src/package.js:116:28
    at Package.module.exports.Package.measure (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:92:15)
    at Package.module.exports.Package.load (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:106:12)
    at PackageManager.module.exports.PackageManager.loadPackage (/Applications/Atom.app/Contents/Resources/app.asar/src/package-manager.js:445:14)
    at PackageManager.module.exports.PackageManager.loadPackages (/Applications/Atom.app/Contents/Resources/app.asar/src/package-manager.js:395:14)
    at AtomEnvironment.module.exports.AtomEnvironment.startEditorWindow (/Applications/Atom.app/Contents/Resources/app.asar/src/atom-environment.js:684:21)
    at module.exports (/Applications/Atom.app/Contents/Resources/app.asar/src/initialize-application-window.js:28:10)
    at setupWindow (file:///Applications/Atom.app/Contents/Resources/app.asar/static/index.js:86:5)
    at window.onload (file:///Applications/Atom.app/Contents/Resources/app.asar/static/index.js:41:9)

Commands

Config

{
  "core": {
    "disabledPackages": [
      "git-plus"
    ],
    "themes": [
      "one-dark-ui",
      "solarized-dark-syntax"
    ]
  }
}

Installed Packages

# User
github, v0.1.0
vim-mode, v0.64.0

# Dev
git, v0.0.0

git-diff doesn't update after committing

The git-diff package (which shows the changed lines in the gutter) doesn't update after committing. We should probably be able to tell GitRepository that something changed.

Package dependencies fail to install

@BinaryMuse and I are both seeing an error installing dependencies both with apm install and npm install targeting various Node versions.

When trying to install from inside Atom and by using apm install atom/git, or from within the cloned repository via apm install (or npm install targeting older versions of Node) we see:

> [email protected] install /Users/kuychaco/github/git/node_modules/pathwatcher/node_modules/runas
> node-gyp rebuild

  CXX(target) Release/obj.target/runas/src/main.o

> [email protected] postinstall /Users/kuychaco/github/git/node_modules/flow-bin/node_modules/bin-wrapper/node_modules/bin-check/node_modules/spawn-sync
> node postinstall

Installing native dependencies (this may take up to a minute)

> [email protected] postinstall /Users/kuychaco/github/git/node_modules/flow-bin
> node lib/install.js


> [email protected] postinstall /Users/kuychaco/github/git/node_modules/standard/node_modules/standard-format/node_modules/esformatter/node_modules/npm-run/node_modules/spawn-sync
> node postinstall

Installing native dependencies (this may take up to a minute)

npm WARN engine [email protected]: wanted: {"node":"~0.8.x"} (current: {"node":"0.10.40","npm":"2.13.3"})
../src/main.cc:1:10: fatal error: 'nan.h' file not found
#include "nan.h"
         ^
1 error generated.
make: *** [Release/obj.target/runas/src/main.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm/node_modules/node-gyp/lib/build.js:269:23)
gyp ERR! stack     at ChildProcess.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:820:12)
gyp ERR! System Darwin 15.3.0
gyp ERR! command "node" "/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/kuychaco/github/git/node_modules/pathwatcher/node_modules/runas
gyp ERR! node -v v0.10.40
gyp ERR! node-gyp -v v2.0.2
gyp ERR! not ok
npm WARN deprecated [email protected]: graceful-fs version 3 and before will fail on newer node releases. Please update to graceful-fs@^4.0.0 as soon as possible.
npm WARN deprecated [email protected]: lodash@<3.0.0 is no longer maintained. Upgrade to lodash@^4.0.0.
npm WARN deprecated [email protected]: graceful-fs version 3 and before will fail on newer node releases. Please update to graceful-fs@^4.0.0 as soon as possible.
  โœ” flow binary test passed successfully
npm WARN engine [email protected]: wanted: {"node":">=0.12"} (current: {"node":"0.10.40","npm":"2.13.3"})
npm WARN engine [email protected]: wanted: {"node":">=0.12"} (current: {"node":"0.10.40","npm":"2.13.3"})
npm WARN engine [email protected]: wanted: {"node":">=0.12"} (current: {"node":"0.10.40","npm":"2.13.3"})
npm WARN engine [email protected]: wanted: {"node":">=0.12"} (current: {"node":"0.10.40","npm":"2.13.3"})
npm WARN engine [email protected]: wanted: {"node":">=0.12"} (current: {"node":"0.10.40","npm":"2.13.3"})
npm WARN engine [email protected]: wanted: {"node":">=0.12"} (current: {"node":"0.10.40","npm":"2.13.3"})
npm ERR! Darwin 15.3.0
npm ERR! argv "/Applications/Atom.app/Contents/Resources/app/apm/bin/node" "/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/Users/kuychaco/.atom/.apm/.apmrc" "--userconfig" "/Users/kuychaco/.atom/.apmrc" "install" "--target=0.36.8" "--arch=x64"
npm ERR! node v0.10.40
npm ERR! npm  v2.13.3
npm ERR! code ELIFECYCLE

npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the runas package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get their info via:
npm ERR!     npm owner ls runas
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/kuychaco/github/git/npm-debug.log

When installing with npm install in the cloned directory targeting Node 5.1.1 (same as Atom's Node) we see this in the npm-debug.log:

48654 verbose stack Error: [email protected] install: `node-gyp rebuild`
48654 verbose stack Exit status 1
48654 verbose stack     at EventEmitter.<anonymous> (/Users/kuychaco/.nvm/versions/node/v5.1.1/lib/node_modules/npm/lib/utils/lifecycle.js:232:16)
48654 verbose stack     at emitTwo (events.js:87:13)
48654 verbose stack     at EventEmitter.emit (events.js:172:7)
48654 verbose stack     at ChildProcess.<anonymous> (/Users/kuychaco/.nvm/versions/node/v5.1.1/lib/node_modules/npm/lib/utils/spawn.js:24:14)
48654 verbose stack     at emitTwo (events.js:87:13)
48654 verbose stack     at ChildProcess.emit (events.js:172:7)
48654 verbose stack     at maybeClose (internal/child_process.js:818:16)
48654 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
48655 verbose pkgid [email protected]
48656 verbose cwd /Users/kuychaco/github/git
48657 error Darwin 15.3.0
48658 error argv "/Users/kuychaco/.nvm/versions/node/v5.1.1/bin/node" "/Users/kuychaco/.nvm/versions/node/v5.1.1/bin/npm" "install"
48659 error node v5.1.1
48660 error npm  v3.3.12
48661 error code ELIFECYCLE
48662 error [email protected] install: `node-gyp rebuild`
48662 error Exit status 1
48663 error Failed at the [email protected] install script 'node-gyp rebuild'.
48663 error Make sure you have the latest version of node.js and npm installed.
48663 error If you do, this is most likely a problem with the runas package,
48663 error not with npm itself.
48663 error Tell the author that this fails on your system:
48663 error     node-gyp rebuild
48663 error You can get their info via:
48663 error     npm owner ls runas
48663 error There is likely additional logging output above.
48664 verbose exit [ 1, true ]

Atom version info is

Atom    : 1.7.0-dev-f48069c
Electron: 0.36.8
Chrome  : 47.0.2526.110
Node    : 5.1.1

Show the diff of highlighted file when arrowing through the file list

I think when there is a diff tab open, and we arrow through the file list, we should show the diff for the highlighted file:

show-diff

When the diff tab does not show, then do what it does now.

I find myself always arrowing through the list, then hitting left to show the diff, then right to get back and stage the whole file. It feels awkward.

Audit destruction

There are a lot of places we're accumulating disposables but never actually disposing of them. We need audit all the view model and component destruction and make sure the package tears down properly.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.