致命:未启用交互式 git shell。收到致命消息:未启用交互式 git shell

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/11120399/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 07:06:16  来源:igfitidea点击:

fatal: Interactive git shell is not enabled. got the message fatal: Interactive git shell is not enabled

gitfedorafedora16

提问by sophie

I have run this command with root:

我已经用 root 运行了这个命令:

    [root@localhost git-shell-commands]# ssh [email protected]
    [email protected]'s password: 
    Last login: Wed Jun 20 15:08:26 2012 from new-host.home
    fatal: Interactive git shell is not enabled.
    hint: ~/git-shell-commands should exist and have read and execute access.
    Connection to 192.168.1.12 closed.
    [root@localhost git-shell-commands]# 

Anybody could told how to solve that problem?

任何人都可以告诉如何解决这个问题?

回答by twalberg

git help shellgives some pointers on how to set it up. The hint in the output also. The git user need a subdirectory called git-shell-commandsin its home directory, with appropriate permissions, and populated with the things you want the user to be able to run.

git help shell给出了一些关于如何设置它的指示。输出中的提示也是。git 用户需要git-shell-commands在其主目录中调用一个具有适当权限的子目录,并填充您希望用户能够运行的内容。