Switch to unified view

a/Allura/push_re.py b/Allura/push_re.py
...
...
12
from allura.lib import rest_api
12
from allura.lib import rest_api
13
13
14
DEBUG=1
14
DEBUG=1
15
CP = ConfigParser()
15
CP = ConfigParser()
16
16
17
re_ticket_ref = re.compile(r'\[#\d+\]')
17
re_ticket_ref = re.compile(r'\[#(\d+)\]')
18
18
19
CRED={}
19
CRED={}
20
20
21
def main():
21
def main():
22
    CP.read(os.path.join(os.environ['HOME'], '.forgepushrc'))
22
    CP.read(os.path.join(os.environ['HOME'], '.forgepushrc'))
...
...
24
    api_key = option('re', 'api_key', 'Forge API Key:')
24
    api_key = option('re', 'api_key', 'Forge API Key:')
25
    secret_key = option('re', 'secret_key', 'Forge Secret Key:')
25
    secret_key = option('re', 'secret_key', 'Forge Secret Key:')
26
    CRED['api_key'] = api_key
26
    CRED['api_key'] = api_key
27
    CRED['secret_key'] = secret_key
27
    CRED['secret_key'] = secret_key
28
    text, tag = make_ticket_text(engineer)
28
    text, tag = make_ticket_text(engineer)
29
    raw_input("Verify that there are no new dependencies, or RPM's are built for all deps...")
30
    raw_input("Verify that a new sandbox builds starts without engr help...")
29
    print '*** Create a ticket on SourceForge (https://sourceforge.net/p/allura/tickets/new/) with the following contents:'
31
    print '*** Create a ticket on SourceForge (https://sourceforge.net/p/allura/tickets/new/) with the following contents:'
30
    print '*** Summary: Production Push (R:%s, D:%s) - allura' % (
32
    print '*** Summary: Production Push (R:%s, D:%s) - allura' % (
31
        tag, date.today().strftime('%Y%m%d'))
33
        tag, date.today().strftime('%Y%m%d'))
32
    print '---BEGIN---'
34
    print '---BEGIN---'
33
    print text
35
    print text
34
    print '---END---'
36
    print '---END---'
35
    raw_input("Verify that there are no new dependencies, or RPM's are build for all deps...")
37
    newforge_num = raw_input('What is the newforge ticket number? ')
36
    raw_input("Verify that a new sandbox builds starts without engr help...")
38
    print '*** Create a SOG Trac ticket (https://control.sog.geek.net/sog/trac/newticket?keywords=LIAISON) with the same summary...'
37
    raw_input('When this is done, create a SOG Trac ticket'
39
    print '---BEGIN---'
38
              ' (https://control.sog.geek.net/sog/trac/newticket?keywords=LIAISON) with the'
40
    print re_ticket_ref.sub('FO:\g<1>', text)
39
              ' same contents...')
41
    print '---END---'
40
    raw_input('Now link the two tickets...')
42
    raw_input('Now link the two tickets...')
41
    newforge_num = raw_input('What is the newforge ticket number? ')
42
    command('git', 'tag', '-a', '-m', '[#%s] - Push to RE' % newforge_num, tag, 'master')
43
    command('git', 'tag', '-a', '-m', '[#%s] - Push to RE' % newforge_num, tag, 'master')
43
    command('git', 'push', 'origin', 'master')
44
    command('git', 'push', 'origin', 'master')
44
    command('git', 'push', 'live', 'master')
45
    command('git', 'push', 'live', 'master')
45
    command('git', 'push', '--tags', 'origin')
46
    command('git', 'push', '--tags', 'origin')
46
    command('git', 'push', '--tags', 'live')
47
    command('git', 'push', '--tags', 'live')