openshift git不工作

我已经将代码上传到了我的openshift JBoss服务器,但是当我今天上传一些代码时,在浏览器中打开页面时没有任何更改。 当我使用git时,我使用这些命令:

git add . --all git commit -m "newcomment2" git push 

当我使用git show我得到一个奇怪的回应:

 error: cannot run pager: No such file or directory commit 3e1a0025bf9746fdb1e0329819f7cf79e3e8f8e4 Author: root <[email protected]> Date: Wed Oct 8 16:02:17 2014 -0400 newbloke2 diff --git a/upload.sh b/upload.sh deleted file mode 100755 index 606b8af..0000000 --- a/upload.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -git add . --all -git commit -m "newbloke2" -git push \ No newline at end of file 

在服务器上应该有很多其他的文件,它只是显示一个,这是我做的一个SH脚本,但要删除。

这可能是您的全局.gitconfig中的寻呼机设置的结果。

你可以使用GIT_PAGER=cat参数来设置它。

正如在伊格纳西奥·巴斯克斯 – 艾布拉姆斯 stackoverflow答案中提到的,你也可以将其设置为不使用寻呼机:

git – no-pager显示

或者,您可以使用-p参数来使用less分页。

例如 git -p show

要查看你的gitconfiguration设置,请使用:

git config --list

然后检查core.pager设置。

git_config手册页

 core.pager The command that git will use to paginate output. Can be overridden with the GIT_PAGER environment variable. Note that git sets the LESS environment variable to FRSX if it is unset when it runs the pager. One can change these settings by setting the LESS variable to some other value. Alternately, these settings can be overridden on a project or global basis by setting the core.pager option. Setting core.pager has no affect on the LESS environment variable behaviour above, so if you want to override git's default settings this way, you need to be explicit. For example, to disable the S option in a backward compatible manner, set core.pager to less -+$LESS -FRX. This will be passed to the shell by git, which will translate the final command to LESS=FRSX less -+FRSX -FRX.