src/init/hginit
branchdebian
changeset 172 5dd3698fad54
parent 168 f9bf8f84df7f
child 311 3cbde66305e4
equal deleted inserted replaced
118:107906bfe2c6 172:5dd3698fad54
     1 #!/bin/sh
     1 #!/bin/sh
     2 
     2 
     3 set -e
     3 set -e
     4 
     4 
     5 cd ~hg
     5 cd
       
     6 
       
     7 if [ -e .ssh/authorized_keys ] ; then
       
     8     echo "This user already exists with authorized keys, aborting"
       
     9     exit -1
       
    10 fi
       
    11 
       
    12 cp $1/init/dot-mercurial-server .mercurial-server
     6 mkdir -p repos/hgadmin .ssh
    13 mkdir -p repos/hgadmin .ssh
     7 cd repos/hgadmin
    14 cd repos/hgadmin
     8 hg init .
    15 hg init .
     9 cp $1/init/hgadmin-hgrc .hg/hgrc
    16 cp $1/init/hgadmin-hgrc .hg/hgrc
       
    17