Some issues on Windows

0 views
Skip to first unread message

B. Brian

unread,
May 12, 2008, 12:41:23 AM5/12/08
to Insoshi
My OS is Windows XP professional.

When following the steps from the following link:
http://sites.google.com/a/insoshi.com/insoshi-guides/Git-Guides/quick-git-setup

I got following error:
u196598@WWHQ179C /c/just4fun
$ sh configure_insoshi_local.sh u196598
Cloning official insoshi repository...
Initialized empty Git repository in c:/just4fun/insoshi/.git/
remote: Generating pack...←[K
remote: Done counting 9353 objects.←[K
remote: Deltifying 9353 objects...←[K
remote: 100% (9353/9353) done←[K
remote: Total 9353 (delta 5153), reused 9353 (delta 5153)←[K
Receiving objects: 100% (9353/9353), 6.66 MiB | 77 KiB/s, done.
Resolving deltas: 100% (5153/5153), done.
Checking out files: 100% (2185/2185), done.

Adding remote connection to forked repository...

Fetching remote branch information...
Permission denied (publickey).
fatal: The remote end hung up unexpectedly
ERROR encountered fetching branches from remote u196598

u196598@WWHQ179C /c/just4fun
$

Looks like the publickey is the problem. I used puttygen to generate
the key. The instruction steps can be found from the link:
http://github.com/guides/providing-your-ssh-key

Anyway, I followed the steps from the link: http://github.com/u196598/insoshi/tree/master
to run the app on my on laptop. After installing necessary libraries
and gems and configuring MySQL database, I did following steps without
ANY errors:

rake install
rake db:test:prepare
rake spec
rake db:sample_data:reload
ruby script/server

The app is running fine on my pc without any issues.

My questions are:
1. Is my publickey not right? If not right, what is the right way to
generate it?

2. Is my Git environment not right?
I got git info from the following link: http://code.google.com/p/msysgit/
and installed git by running Git-1.5.5-preview20080413.exe file.

3. What are exact Git commands under Windows XP to do check out and
check in? These are two most important things for me now: check out so
I can get the latest updates from the repository; check in so I can
save my changes to the repository.

Thanks a lot for your help!

Brian




Long Nguyen

unread,
May 12, 2008, 1:42:39 PM5/12/08
to ins...@googlegroups.com
I haven't used PuTTY to set up an ssh keypair before.  But it looks like it might store/display the key in a format that's different than the ssh-keygen.

Did you cut and paste something that looks similar to the Linux Step 3 id_rsa.pub file on GitHub's Providing your SSH Key guide? If not, then you'll need to take a look at Sec 8.2.10 in the Putty docs

http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter8.html#pubkey-puttygen


This will tell you how to get PuTTY to display the key in the authorized_keys format that GitHub is probably expecting.

Also, "check out" and "check in" mean different things in Git than you're expecting.  What you really want are "git pull" to get changes from remote repositories (updates from the official Insoshi public repository) and "git push" to move updates to your forked repository.

Take a look at our Git Guides to get started.


2008/5/11 B. Brian <bbria...@gmail.com>:



--
Long Nguyen
long....@insoshi.com

B. Brian

unread,
May 13, 2008, 1:37:59 AM5/13/08
to Insoshi
Thank you Long for your quick/useful response.

So far I can do "git diff", "git pull" -- I got "Already up-to-date."
response when executing it because I created my local branch on 05/11
but the last committed change made by Michael was on 05/10. Hope I can
get updates in the future without any issues.

But I still cannot run "git push". I got following error: "fatal: The
remote end hung up unexpectedly". It is ok now because I do not have
any change to forked repository. Or I can put everything to my own
Subversion instead.

Brian


On May 12, 12:42 pm, "Long Nguyen" <long.ngu...@insoshi.com> wrote:
> I haven't used PuTTY to set up an ssh keypair before. But it looks like it
> might store/display the key in a format that's different than the
> ssh-keygen.
>
> Did you cut and paste something that looks similar to the Linux Step 3
> id_rsa.pub file on GitHub's Providing your SSH Key
> guide<http://github.com/guides/providing-your-ssh-key>?
> If not, then you'll need to take a look at Sec 8.2.10 in the Putty docs
>
> http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter8.html#pubkey...<http://the.earth.li/%7Esgtatham/putty/0.60/htmldoc/Chapter8.html#pubk...>
>
> This will tell you how to get PuTTY to display the key in the
> authorized_keys format that GitHub is probably expecting.
>
> Also, "check out" and "check in" mean different things in Git than you're
> expecting. What you really want are "git pull" to get changes from remote
> repositories (updates from the official Insoshi public repository) and "git
> push" to move updates to your forked repository.
>
> Take a look at our Git Guides <http://docs.insoshi.com/Git-Guides> to get
> started.
>
> 2008/5/11 B. Brian <bbrian.w...@gmail.com>:
>
>
>
>
>
> > My OS is Windows XP professional.
>
> > When following the steps from the following link:
>
> >http://sites.google.com/a/insoshi.com/insoshi-guides/Git-Guides/quick...
> long.ngu...@insoshi.com

Long Nguyen

unread,
May 13, 2008, 3:02:33 AM5/13/08
to ins...@googlegroups.com
Can you run 'git branch' and 'git config -l'? I need to see which branch you're on and where exactly you're trying to push to.


2008/5/12 B. Brian <bbria...@gmail.com>:



--
Long Nguyen
long....@insoshi.com

B. Brian

unread,
May 13, 2008, 10:09:04 AM5/13/08
to Insoshi
When running "git branch":
$ git branch
* master

When running "git config -l":
$ git config -l
core.symlinks=false
core.autocrlf=true
color.diff=auto
pack.packsizelimit=2g
core.repositoryformatversion=0
core.filemode=false
core.bare=false
core.logallrefupdates=true
core.symlinks=false
remote.origin.url=git://github.com/insoshi/insoshi.git
remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
branch.master.remote=origin
branch.master.merge=refs/heads/master
remote.u196598.url=g...@github.com:u196598/insoshi.git
remote.u196598.fetch=refs/heads/*:refs/remotes/u196598/*

From the doc, "git push" will save my local changes to my own fork
branch. So I made some changes in my local pc copy. I can see the
differences using "git diff". But when using "git push", I got the
error. I just want to test "git push" to see it works or not.

Thanks,
Brian

On May 13, 2:02 am, "Long Nguyen" <long.ngu...@insoshi.com> wrote:
> Can you run 'git branch' and 'git config -l'? I need to see which branch
> you're on and where exactly you're trying to push to.
>
> 2008/5/12 B. Brian <bbrian.w...@gmail.com>:
>
>
>
>
>
> > Thank you Long for your quick/useful response.
>
> > So far I can do "git diff", "git pull" -- I got "Already up-to-date."
> > response when executing it because I created my local branch on 05/11
> > but the last committed change made by Michael was on 05/10. Hope I can
> > get updates in the future without any issues.
>
> > But I still cannot run "git push". I got following error: "fatal: The
> > remote end hung up unexpectedly". It is ok now because I do not have
> > any change to forked repository. Or I can put everything to my own
> > Subversion instead.
>
> > Brian
>
> > On May 12, 12:42 pm, "Long Nguyen" <long.ngu...@insoshi.com> wrote:
> > > I haven't used PuTTY to set up an ssh keypair before. But it looks like
> > it
> > > might store/display the key in a format that's different than the
> > > ssh-keygen.
>
> > > Did you cut and paste something that looks similar to the Linux Step 3
> > > id_rsa.pub file on GitHub's Providing your SSH Key
> > > guide<http://github.com/guides/providing-your-ssh-key>?
> > > If not, then you'll need to take a look at Sec 8.2.10 in the Putty docs
>
> > >http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter8.html#pubkey..<http://the.earth.li/%7Esgtatham/putty/0.60/htmldoc/Chapter8.html#pubkey..>
> > .<http://the.earth.li/%7Esgtatham/putty/0.60/htmldoc/Chapter8.html#pubk..
> long.ngu...@insoshi.com

Long Nguyen

unread,
May 13, 2008, 10:57:45 PM5/13/08
to ins...@googlegroups.com
At the moment, you only have a the local branch "master" which is tracking the master branch on the offical Insoshi repository (nicknamed "origin").  When you're doing the "git push", it's trying to put push up information to "origin" via git://github.com/insoshi/insoshi.git.  GitHub is configured only to allow read access via the git protocol so you're getting the "remote end hung up unexpectedly" error.

What's happened is that your local repository set up isn't quite complete because of the ssh key issue you had (and hopefully resolved... we'll find out in one second).

Here's what you need to do:

# Get branch information from your forked repository
# If your ssh key isn't configured correctly, you'll get an error at this point
git fetch u196598

# Create a local branch off the forked master branch
git branch --track u196598 u196598/master
git checkout u196598

# Push up the new branch to your forked repository
git push u196598 u196598:refs/heads/u196598

# Set the configuration for the local branch
git config branch.u196598.remote u196598
git config branch.u196598.merge refs/heads/u196598

This completes out the remaining steps in the quick setup script.

Long

2008/5/13 B. Brian <bbria...@gmail.com>:



--
Long Nguyen
long....@insoshi.com

B. Brian

unread,
May 14, 2008, 1:53:00 AM5/14/08
to Insoshi
I still cannot make it work.

Following are steps I have done this time:
1. use msysGit to generaate ssh key. http://github.com/guides/providing-your-ssh-key
2. save the new ssh key to my github account
3. remove my fork branch.
4. generate a new fork branch.
5. download configure_insoshi_local.sh from quick setup link:
http://sites.google.com/a/insoshi.com/insoshi-guides/Git-Guides/quick-git-setup
6. run "sh configure_insoshi_local.sh u196598" from Git Bash command
line

Like I said, I can download code from master branch but somehow I
cannot fetch remote branch info:
Fetching remote branch information...
Permission denied (publickey).
fatal: The remote end hung up unexpectedly
ERROR encountered fetching branches from remote u196598

If I try "git fetch u196598", I will get the same error.
BTW, my new ssh key is:
ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAyK10wnAzBlSes45EEbtYh3URWS/
noCWEtQv1ua3EqzDHABqarCM+5RfiZ+V39nHp6I5R7VAL/+
+tvqgycX7tDFVbDgoS7KlmlAJsbPx2hhJgDlY/
HpouuEXM7WTzMOIpwm4H0Gl7xnUS1zds1yfMK6HC/8Of7g1r9J2EemwCwhVAy
+uiU8kDTeBX5Tf7DG8XQLdaJN9QnJ47tQWOiZxSD
+McuZiILJVTsLGPOAcs9F9cuR182R04BAWWkgBHtFuIy4IXlrGqMOgx/
mFvETe3LK21huzdhRDHf8CnecT6mgiSvVixGS+M/
e9uF0f3xV3SCXh9ql5F47ODkl6hisvmew== baiqin...@hotmail.com

After I save it to my account, it becomes as:
ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAyK10wnAzBlSes45EEbtYh3URWS/
noCWEtQv1ua3EqzDHABqarCM+5RfiZ+V39nHp6I5R7VAL/+
+tvqgycX7tDFVbDgoS7KlmlAJsbPx2hhJgDlY/
HpouuEXM7WTzMOIpwm4H0Gl7xnUS1zds1yfMK6HC/8Of7g1r9J2EemwCwhVAy
+uiU8kDTeBX5Tf7DG8XQLdaJN9QnJ47tQWOiZxSD
+McuZiILJVTsLGPOAcs9F9cuR182R04BAWWkgBHtFuIy4IXlrGqMOgx/
mFvETe3LK21huzdhRDHf8CnecT6mgiSvVixGS+M/
e9uF0f3xV3SCXh9ql5F47ODkl6hisvmew==

Also I tried to following steps from the link: http://kylecordes.com/
When running "git clone g...@github.com:u196598/insoshi.git", I will
get the same error:
Permission denied (publickey).
fatal: The remote end hung up unexpectedly

Can somebody help me create a new/valid ssh key and email to me? my
email address is baiqin...@hotmail.com.

Thanks,
Brian
> 2008/5/13 B. Brian <bbrian.w...@gmail.com>:
>
>
>
>
>
> > When running "git branch":
> > $ git branch
> > * master
>
> > When running "git config -l":
> > $ git config -l
> > core.symlinks=false
> > core.autocrlf=true
> > color.diff=auto
> > pack.packsizelimit=2g
> > core.repositoryformatversion=0
> > core.filemode=false
> > core.bare=false
> > core.logallrefupdates=true
> > core.symlinks=false
> > remote.origin.url=git://github.com/insoshi/insoshi.git
> > remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
> > branch.master.remote=origin
> > branch.master.merge=refs/heads/master
> > remote.u196598.url=...@github.com:u196598/insoshi.git
> >http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter8.html#pubkey.<http://the.earth.li/%7Esgtatham/putty/0.60/htmldoc/Chapter8.html#pubkey.>
> > .<http://the.earth.li/%7Esgtatham/putty/0.60/htmldoc/Chapter8.html#pubkey.
> long.ngu...@insoshi.com

Long Nguyen

unread,
May 14, 2008, 2:48:13 AM5/14/08
to ins...@googlegroups.com
Make sure that the key is all on one line.  I can't tell if it is or not based on what Google Groups might be doing to the formatting.

Sometimes cutting and pasting from a text editor/command prompt will break up the output across multiple lines.

2008/5/13 B. Brian <bbria...@gmail.com>:



--
Long Nguyen
long....@insoshi.com
Reply all
Reply to author
Forward
0 new messages