使用'git pull origin master'从git拉到服务器的问题

时间:2014-07-22 13:20:40

标签: git github webserver git-pull

我正试图从GIT转到我的网络服务器。

我通过我的Mac终端通过SSh进入我的服务器并执行以下操作:

philips-air:~ philiplocke$ ssh whatever@whatever.net
Last login: Tue Jul 22 07:47:53 2014 from 151.226.30.206
joostrap@serv01 [~]# cd public_html
joostrap@serv01 [~/public_html]# cd portfolio
joostrap@serv01 [~/public_html/portfolio]# git pull origin master
Password for 'https://whatever@github.com': 
From https://github.com/whatever/portfolio
 * branch            master     -> FETCH_HEAD
/usr/libexec/git-core/git-pull: line 263: tr: command not found
There are no candidates for merging among the refs that you just fetched.
Generally this means that you provided a wildcard refspec which had no
matches on the remote end.

这是什么意思?

/usr/libexec/git-core/git-pull: line 263: tr: command not found
There are no candidates for merging among the refs that you just fetched.
Generally this means that you provided a wildcard refspec which had no
matches on the remote end.

我的git配置设置如下:

[core]
    repositoryformatversion = 0
    filemode = true
    bare = false
    logallrefupdates = true
    ignorecase = true
    precomposeunicode = false
[remote "origin"]
    url = https://whatever@github.com/whatever/portfolio.git
    fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
    remote = origin
    merge = refs/heads/master

git fetch的结果,git remote -a& git status:

joostrap@serv01 [~/public_html/portfolio]# git fetch
Password for 'https://fastnetwebdesign@github.com': 

joostrap@serv01 [~/public_html/portfolio]# git remote -a
error: unknown switch `a'
usage: git remote [-v | --verbose]
   or: git remote add [-t <branch>] [-m <master>] [-f] [--tags|--no-tags] [--mirror=<fetch|push>] <name> <url>
   or: git remote rename <old> <new>
   or: git remote remove <name>
   or: git remote set-head <name> (-a | --auto | -d | --delete |<branch>)
   or: git remote [-v | --verbose] show [-n] <name>
   or: git remote prune [-n | --dry-run] <name>
   or: git remote [-v | --verbose] update [-p | --prune] [(<group> | <remote>)...]
   or: git remote set-branches [--add] <name> <branch>...
   or: git remote set-url [--push] <name> <newurl> [<oldurl>]
   or: git remote set-url --add <name> <newurl>
   or: git remote set-url --delete <name> <url>

    -v, --verbose         be verbose; must be placed before a subcommand

joostrap@serv01 [~/public_html/portfolio]# git status
On branch master
Your branch is up-to-date with 'origin/master'.
nothing to commit, working directory clean
joostrap@serv01 [~/public_html/portfolio]# 

git branch -a

joostrap@serv01 [~/public_html/portfolio]# git branch -a
* master
  remotes/origin/master
  remotes/origin/revert-2-master
joostrap@serv01 [~/public_html/portfolio]# 

0 个答案:

没有答案