Skip to content

Instantly share code, notes, and snippets.

@vjames19
Last active December 17, 2015 03:29
Show Gist options
  • Save vjames19/5543827 to your computer and use it in GitHub Desktop.
Save vjames19/5543827 to your computer and use it in GitHub Desktop.
Copies the preferences from the src workspace to the dest workspace. If the dest workspace doesn't exist it will be created. Enjoy!
'''
Created on May 8, 2013
@author: Victor J. Reventos
Copies the preferences from the src workspace to the dest workspace.
If the dest workspace doesn't exist it will be created.
Enjoy!
'''
import sys,os
from distutils.dir_util import copy_tree
if len(sys.argv) <3:
print 'Usage: <src workspace to copy settings from> <dest workspace>'
PATH = os.path.join(".metadata",".plugins","org.eclipse.core.runtime")
args = map(lambda p: os.path.join(p.strip(),PATH),sys.argv[1:])
copy_tree(args[0], args[1])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment