aboutsummaryrefslogtreecommitdiff
path: root/gitosis/ssh.py
diff options
context:
space:
mode:
authorTommi Virtanen <tv@eagain.net>2007-09-03 17:04:41 -0700
committerTommi Virtanen <tv@eagain.net>2007-09-03 17:09:12 -0700
commit8a0654abe2db919b04683d40100b469e8c3adc4b (patch)
tree57903f32603cc57bd894c62ec2a0fa87d0985e15 /gitosis/ssh.py
parentMake setuptools include templates in the egg. (diff)
downloadgitosis-dakkar-8a0654abe2db919b04683d40100b469e8c3adc4b.tar.gz
gitosis-dakkar-8a0654abe2db919b04683d40100b469e8c3adc4b.tar.bz2
gitosis-dakkar-8a0654abe2db919b04683d40100b469e8c3adc4b.zip
Refactor command line utilities to share setup.
Hide internal gitosis-ssh and gitosis-gitweb, it's all in gitosis-run-hook.
Diffstat (limited to 'gitosis/ssh.py')
-rw-r--r--gitosis/ssh.py25
1 files changed, 0 insertions, 25 deletions
diff --git a/gitosis/ssh.py b/gitosis/ssh.py
index 21f351a..7a70ed4 100644
--- a/gitosis/ssh.py
+++ b/gitosis/ssh.py
@@ -77,28 +77,3 @@ def writeAuthorizedKeys(path, keydir):
if in_ is not None:
in_.close()
os.rename(tmp, path)
-
-def _getParser():
- import optparse
- parser = optparse.OptionParser(
- usage="%prog [--authkeys=FILE] KEYDIR")
- parser.set_defaults(
- authkeys=os.path.expanduser('~/.ssh/authorized_keys'),
- )
- parser.add_option(
- "--authkeys",
- help="path to SSH authorized keys file")
- return parser
-
-def main():
- parser = _getParser()
- (options, args) = parser.parse_args()
-
- if len(args) != 1:
- parser.error('Need one argument on the command line.')
-
- keydir, = args
-
- writeAuthorizedKeys(
- path=options.authkeys,
- keydir=keydir)