Skip to content

Commit

Permalink
remove upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
Olivier Refalo committed Jun 7, 2012
1 parent 5a7663a commit 3e93133
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 259 deletions.
243 changes: 5 additions & 238 deletions README.md
Expand Up @@ -115,6 +115,10 @@ Usage:

On top of providing two letters acronyms for most git commands, **g2** has interesting features which enhance command line experience.

### The Prompt

TODO

###Setup

`g setup` and `g key` are two handy commands to setup username, email, keys, editor and tooling.
Expand Down Expand Up @@ -306,244 +310,7 @@ But unlike commits, wip commits **CANNOT** be **merged, pulled, pushed or synche

#List of Commands

### abort

Aborts either a rebase or a merge.

### am (?-f)

Amends last commit with contents from the staging area.
Won't amend if top commit was pushed unless the `-f` flag is given.

### br -D -M <?branch>

Displays the list of branches, local and remote.
Can create new branches if given a branch name.

* -D deleted the given branch
* -M renames the given branch

### bs / bisect

One of git best tool: `bisect`

### clone (url)

Clones a remote repository, wires to `git clone`

### co/checkout (branch)

Switches branch (either local/remote)
extremely strict - won't let you checkout if you have changes or untracked files

### continue

Resumes a conflict resolution.

### cp/cherry-pick (commit)

Cherry picks a commit from another branch, same as `git cherry-pick`

### ci/commit (?params...)

Commits the contents of the staging area. Won't commit on top of a WIP.

### df/diff (?params…)

Compares files on the console, wires to `diff`

### dt/difftool (?params…)

Compares files by opening the default diff GUI, wires to `difftool`

### freeze (?-m msg) (?file)

Takes all **modified, deleted and untracked** files to the staging area.
You may also specify which file to stage.

Note that you may also give it the file to stage.

### gc

Repository maintenance: prunes obsolete remote branches then a structure check `fsck` followed by a garbage collector `gc`

### gp/grep

Searches commits, same as `git grep`

### ig (-file)

Adds to gitignore & removes file from source control

### init (-folder)

Creates a local repository, wires to `git init`

### key (?-gen)

Displays the public ssh key.
Give it the `--gen` flag and it will generate a new key.

### mg/merge (?params...) (branch)

Merges branches, same as `git merge`

### mt/mergetool (?params...)

Fixes conflicts by opening a visual mergetool

### mv

Moves (renames) a file under source control. same as `git mv`

### lg/log

By default, displays commit log in a pretty colorized format. Any extra parameter wires to to `git log`.

```
$ git lg
* adbd444 - docs wording improvement pass (3 days ago) <David Greenspan>
* 2edb152 - make tests work in IE 6-10, MobileSafari (3 days ago) <David Greenspan>
* 7a05b13 - Merge pull request #64 from skalb/devel (3 days ago) <matt debergalis>
|\
| * 9ebb67a - Function passed to Meteor.ui.render must return a string. (3 days ago) <Sameer Kalburgi>
* | e2eadee - Use correct variable name when logging a less error (3 days ago) <Josh McArthur>
* | 32266f5 - Merge pull request #62 from milesmatthias/docupdate (3 days ago) <matt debergalis>
|\ \
| * | 6d57f14 - Added a note about how to read the docs locally, since it took me a while to figure out how to do it. (8 days ago) <Miles Matthias>
* | | d28ed89 - This is allow any user added script in their header to be able to use the libraries in Meteor. For example including a plugin would have to be always written a
* | | 7d269cd - Merge branch 'http' into devel (3 days ago) <Nick Martin>
|\ \ \
| * | | cde4a4a - (origin/http) First pass at HTTP docs. (3 days ago) <David Greenspan>
| * | | 0f2673f - initial commit of HTTP package (4 days ago) <David Greenspan>
|/ / /
* | | e1a557f - Merge branch 'test-fixups' into devel (4 days ago) <Nick Martin>
|\ \ \
| * | | d7fe7c9 - have test driver report FAIL if exception anywhere (4 days ago) <David Greenspan>
| * | | e68f9d1 - Remove old busted selenium tests, and move cli tests out of the way. (4 days ago) <Nick Martin>
| * | | b3bdb87 - async_multi: catch exceptions in expect, prevent multi-fail (4 days ago) <David Greenspan>
```

### ls/ls-files (?params…)

List files under source control, wires to `git ls-files`

### panic

Lost, confused? Can't figure what state you are in? Use `panic`!

`panic` will checkout the latest stable state (HEAD) and remove all file not under source control, leaving a fresh clean workspace.

### pull (?opts) (remote) (branch)

Merges another branch with the current.
Please use `sync` to synchronize your local branch.

### push (?-f) (?opts) (remote) (branch)

Sends commits to a remote git repository/branch

### rb/rebase (?params…) (branch)

Rebases the branch, same as `git rb`

### rm (params…)

Removes a file from source control, same as `git rm`

### rs/reset (params…)

Resets the branch to a different state. same as `git reset`

`$ g rs upstream`

### rt/remote (?params…)

Used to add/remove remotes, same as `git remote`

### rv/revert (commit)

Reverts a commit, same as `git revert`

### setup

Configures user, key, editor & tools by prompting the user.

### sh/show (?-deep) (?commit)

Shows details about the given commit, defaults to HEAD
When `-deep` is given, shows the diff.

### st/status (?params…)

Probably the most common command: give details about what changed since last commit.

```
$ git st
```

### sm/submodule (?params…)

Same as `git submodule`

### sync

Synchronizes the current branch with the one of the server.
syncs working branch: fetch, pull-rebase & push

### tg/tag

Tags a state, wires to `git tag`

### track (?upstream_branch)

Gives information about the tracking table. This table is very important: it tells how local/remote branches are interconnected.

```
$ g track
local: master <--sync--> remote: origin/master
--Remotes---
origin git@github.com:orefalo/g2.git (fetch)
origin git@github.com:orefalo/g2.git (push)
```

Should you need to change the tracking, just pass the new destination as a parameter

```
$ g track origin/NEW_branch
local: master <--sync--> remote: origin/NEW_branch
--Remotes---
origin git@github.com:orefalo/g2.git (fetch)
origin git@github.com:orefalo/g2.git (push)
```

### pull

won't pull on a WIP
won't pull from the tracking branch
Will ask to setup tracking if not set

### push

won't push a WIP
won't push to the tracking branch
Will ask to setup tracking if not set

### unfreeze (?file)

Unfreezes the files from the staging area back into the workspace.

### unwip

Unstacks a WIP from the history into the workspace.

### upgrade

Upgrades G2 by syncing with the github code repository

### wip

Easy way to save your WIP (Work In Progress). Stacks all current changes as a commit on the history.
TODO

##FAQ

Expand Down
19 changes: 0 additions & 19 deletions cmds/g2-g2upgrade.sh

This file was deleted.

2 changes: 1 addition & 1 deletion g2-completion.sh
Expand Up @@ -567,7 +567,7 @@ __git_complete_strategy ()

__git_list_all_commands ()
{
echo "abort am br branch bs bisect clone co continue checkout cp cherry-pick ci commit df diff dt difftool fetch freeze key gc gp grep gui ig init mg merge mt mergetool mv lg log ls panic pull push rb rebase rm rs reset rt remote rv revert setup sh show sm submodule st status sync tg tag track unfreeze unwip upgrade wip"
echo "abort am br branch bs bisect clone co continue checkout cp cherry-pick ci commit df diff dt difftool fetch freeze key gc gp grep gui ig init mg merge mt mergetool mv lg log ls panic pull push rb rebase rm rs reset rt remote rv revert setup sh show sm submodule st status sync tg tag track unfreeze unwip wip"
}

__git_all_commands=
Expand Down
1 change: 0 additions & 1 deletion g2.sh
Expand Up @@ -137,7 +137,6 @@ function __g2_eval() {
"tg" ""
"tag" "tg"
"track" ""
"upgrade" "g2upgrade"
"unfreeze" ""
"unwip" ""
"wip" ""
Expand Down

0 comments on commit 3e93133

Please sign in to comment.