From 0a94d279b6b7e4b81a6f5b09b5ba0c34a474349e Mon Sep 17 00:00:00 2001 From: Francisco Redondo Marchena Date: Tue, 5 Aug 2014 16:21:32 +0000 Subject: WIP: Check system morphologies --- scripts/migrate-chunks | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/scripts/migrate-chunks b/scripts/migrate-chunks index 90f5b7c0..f93619d7 100755 --- a/scripts/migrate-chunks +++ b/scripts/migrate-chunks @@ -40,10 +40,9 @@ def move_morphs(morphs, kind): for m in morph['systems']: m['morph'] = str('systems/' + m['morph'] + '.morph') #loader.save_to_file(morph.filename, morph) - new_location = os.path.join(subdir, morph.filename) loader.save_to_file(morph.filename, morph) + new_location = os.path.join(subdir, morph.filename) #subprocess.call(['git', 'mv', morph.filename, new_location]) - sys.exit(0) #morph.filename = new_location #subprocess.call(['git', 'commit', '--quiet', '-m', # 'Move %s into subdirectory' %kind]) @@ -57,11 +56,10 @@ def move_morphs(morphs, kind): stratum['morph'] = str('strata/' + stratum['morph'] + '.morph') loader.save_to_file(morph.filename,morph) new_location = os.path.join(subdir, morph.filename) - subprocess.call(['git', 'mv', morph.filename, new_location]) + #subprocess.call(['git', 'mv', morph.filename, new_location]) #morph.filename = new_location #subprocess.call(['git', 'commit', '--quiet', '-m', # 'Move %s into subdirectory' %kind]) - sys.exit(0) #for morph in morphs: # print '%s' %morph @@ -77,6 +75,7 @@ def move_morphs(morphs, kind): # 'Move %s into subdirectory' % kind]m for key in morphologies.iterkeys(): + print "Moving %s....\n" %key move_morphs(morphologies[key], key) #move_morphs(chunks, 'chunks') -- cgit v1.2.1