<commit_before>import os

def run(cmd):
  os.system(cmd)

run('svn ruby replace_headers')

ok = input("Make sure NOW if all you need is checked in. Proceed? (Y/N):")
if ok != 'Y': 
  print "Exited on user request"
  exit(1)

ver = input("Specify the version, e.g. 1.7:")

branch = 'https://mockito.googlecode.com/svn/branches/' + ver
run('svn copy -m "branched before release" https://mockito.googlecode.com/svn/trunk ' + branch)
run('svn co ' + branch + ' ../../mockito-' + ver) 

run('svn st')

run('svn ps -R svn:mime-type text/html ../javadoc/*')
run('svn ps -R svn:mime-type text/css ../javadoc/stylesheet.css')<commit_msg>more work on release script<commit_after>import os

def run(cmd):
  print "\nRunning command: " + cmd
  assert os.system(cmd) == 0, "\nCommand failed: " + cmd

run('ruby replace_headers.rb')

ok = raw_input("Make sure NOW if all you need is checked in. Proceed? (Y/N):")
print ok
if ok != "Y": 
  print "Exited on user request"
  exit(1)
  
ver = raw_input("Specify the version, e.g. 1.7:")

branch = 'https://mockito.googlecode.com/svn/branches/' + ver
#run('svn copy -m "branched before release" https://mockito.googlecode.com/svn/trunk ' + branch)
#run('svn co ' + branch + ' ../../mockito-' + ver)

os.chdir('../../mockito-' + ver)

f = open('version.properties', 'w')
f.write('version=' + ver)
f.close()

#run('ant test.release release.javadoc')

run('svn add javadoc/*')
run('svn ps -R svn:mime-type text/html javadoc/*')
run('svn ps -R svn:mime-type text/css javadoc/stylesheet.css')
run('svn ci -m "released javadoc, updated version"')

os.chdir('releasing')
import upload_jars
{'fraction_non_alphanumeric': 0.18350898946063235, 'fraction_numerical': 0.0043397396156230625, 'mean_word_length': 3.86144578313253, 'pattern_counts': {'":': 1, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4513015', 'n_tokens_mistral': 633, 'n_tokens_neox': 596, 'n_words': 167}