gmarik / dotfiles

my `.dotfiles` nonstop WIP

Home Page:http://gmarik.info/blog/2010/05/02/tracking-dotfiles-with-git

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

not friendly with new version of git

bronson opened this issue · comments

This technique has worked amazingly well! New git seems to have some issues though... Running 1.7.6.4:

$ dotgit pull
fatal: /usr/libexec/git-core/git-pull cannot be used without a working tree.
$ dotgit stash
fatal: /usr/libexec/git-core/git-stash cannot be used without a working tree.
$ GIT_WORK_TREE=/home/bronson GIT_DIR=/home/bronson/.dotfiles.git git stash
fatal: /usr/libexec/git-core/git-stash cannot be used without a working tree.

(I call the command dotgit... my fingers couldn't get used to .git)

I've only seen failures with pull and stash so far.

I haven't looked at the code or regressed it yet... I'll report back if/when I do.

wow, that sucks!
haven't came across this one yet....
NOT UPGRADING...

The only issues i have had so far is an isssue with submodules, can't add them with "dotgit".
Now seems there are more...

It can push, it can even set up tracking branches with -u, it just can't pull or stash.

$ dotgit push -f -u
Counting objects: 5, done.
Delta compression using up to 2 threads.
...
Branch master set up to track remote branch master from origin by rebasing.
$ dotgit pull
fatal: /usr/libexec/git-core/git-pull cannot be used without a working tree.

It can fetch and merge, but it can't pull? WTF!

$ dotgit fetch
From github.com:bronson/dotfiles
 * branch            master     -> FETCH_HEAD
$ dotgit merge master
Updating c9de0f0..82653b5
Fast-forward
.bashrc |   14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)

The bad list so far is pull, stash, and rebase.

$ dotgit rebase master
fatal: /usr/libexec/git-core/git-rebase cannot be used without a working tree.

Guess I'm using your bug tracker to take notes. Sorry! :)

It can fetch and merge, but it can't pull? WTF!

I hope it's a bug...not the way new Git versions supposed work now...

Guess I'm using your bug tracker to take notes. Sorry! :)

Ha, that's fine!
Now I'm aware too, not sure if I can do smth about it though...)

FALSE ALARM. Just make sure the cwd is the same as GIT_WORK_TREE and everything works, even with new git.

I tricked myself because I found this right after upgrading. :) Sorry for the noise!

Ha! Cool, thanks for fixing it! ;))