* by default, Git installs to C:\Program Files\Git\
* by default, CopSSH installs to C:\Program Files\ICW\
3. control panel > user accounts > create new account (for example, git)
4. copssh control panel > users > add activated account, i.e. git
* choose "Linux shell and Sftp" for access type to enable shell command execution
5. in C:\Program Files\ICW\home\gi, edit .bashrc and append below script
gitpath=/cygdrive/c/Program\ Files/Git/bin
gitcore=/cygdrive/c/Program\ Files/Git/libexec/git-core
export PATH=$gitpath:$gitcore:$PATH
6. create a remote repository
$ssh git@localhost
$git init test
$cd test; touch abc
$git add .; git commit -m 'test'
7. clone from remote
$git clone git@localhost:test mytest
8. all done :)
If you want to use public keys to access git account, collect public keys and put them into home/git/.ssh/authorized_keys. Check this to get more information.
沒有留言:
張貼留言