comparison extra/soundsoftware/create-repo-authormaps.rb @ 1545:f81fcbde7eaf feature_1136

Merge
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Tue, 12 Jan 2016 15:14:36 +0000
parents 05d639e5d59b
children fd4cc11ae096
comparison
equal deleted inserted replaced
1544:e9e55585ebf2 1545:f81fcbde7eaf
16 # /var/repo-export/authormap/authormap_repo_3 16 # /var/repo-export/authormap/authormap_repo_3
17 # 17 #
18 # This script does that, if given the two directory names as arguments 18 # This script does that, if given the two directory names as arguments
19 # to the -s and -o options. In the above example: 19 # to the -s and -o options. In the above example:
20 # 20 #
21 # script/rails runner create-repo-authormaps.rb -s /var/hg -o /var/repo-export/authormap 21 # ./script/rails runner -e production extra/soundsoftware/create-repo-authormaps.rb -s /var/hg -o /var/repo-export/authormap
22 # 22 #
23 # Note that this script will overwrite any existing authormap 23 # Note that this script will overwrite any existing authormap
24 # files. (That's why the output files are given an authormap_ prefix, 24 # files. (That's why the output files are given an authormap_ prefix,
25 # so we're less likely to clobber something else if the user gets the 25 # so we're less likely to clobber something else if the user gets the
26 # arguments wrong.) 26 # arguments wrong.)
27 27
28 require 'getoptlong' 28 require 'getoptlong'
29 29
30 opts = GetoptLong.new( 30 opts = GetoptLong.new(
31 ['--scm-dir', '-s', GetoptLong::REQUIRED_ARGUMENT], 31 ['--scm-dir', '-s', GetoptLong::REQUIRED_ARGUMENT],
32 ['--out-dir', '-o', GetoptLong::REQUIRED_ARGUMENT], 32 ['--out-dir', '-o', GetoptLong::REQUIRED_ARGUMENT],
33 ['--environment', '-e', GetoptLong::REQUIRED_ARGUMENT] 33 ['--environment', '-e', GetoptLong::OPTIONAL_ARGUMENT]
34 ) 34 )
35 35
36 $repos_base = '' 36 $repos_base = ''
37 $out_base = '' 37 $out_base = ''
38 38