Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: cms/sources.py

Issue 29886648: Issue #6942 - Add XTM integration in CMS (Closed)
Patch Set: Addressed initial comments Created Sept. 25, 2018, 12:24 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: cms/sources.py
diff --git a/cms/sources.py b/cms/sources.py
index f7ebfde68a00225fa8ab6c7f777cb37400873a91..d6bdc0ebc73dec29e4b5583bbc73c50e5870ae7c 100644
--- a/cms/sources.py
+++ b/cms/sources.py
@@ -272,6 +272,11 @@ class FileSource(Source):
do_list(self.get_path(subdir), '')
return result
+ def write_to_config(self, section, option, value):
+ config = self.read_config()
+ config.set(section, option, value)
+ config.write(open(self.get_path('settings.ini'), 'w'))
Vasily Kuznetsov 2018/09/26 10:43:17 You need to close the file here. I don't think con
Tudor Avram 2018/10/04 06:48:10 Done.
+
def get_cache_dir(self):
return os.path.join(self._dir, 'cache')

Powered by Google App Engine
This is Rietveld