Created
June 2, 2016 13:47
-
-
Save jaimergp/8c2efd34fb2c7eba8054eeec791bf768 to your computer and use it in GitHub Desktop.
Clear recent files in UCSF Chimera Rapid Access panel
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os | |
from shutil import copy | |
from pprint import pprint | |
path = os.path.expanduser("~/.chimera/preferences") | |
copy(path, path + ".bak") # just in case | |
with open(path) as f: | |
data = f.read() | |
pydata = eval(data) | |
pydata['Rapid Access']['data history'] = [] | |
with open(path, 'w') as f: | |
pprint(pydata, stream=f) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment