projects
/
rainbowstream.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
check config and little refactoring
[rainbowstream.git]
/
rainbowstream
/
config.py
diff --git
a/rainbowstream/config.py
b/rainbowstream/config.py
index de15655cfe3c0890334a32cb79d46c810bb9ee07..ff2d17df7e51db45591898f5ca442f46d5e853de 100644
(file)
--- a/
rainbowstream/config.py
+++ b/
rainbowstream/config.py
@@
-25,6
+25,16
@@
def load_config(filepath):
# Config dictionary
c = {}
# Config dictionary
c = {}
+# Load the initial config
+config = os.path.dirname(
+ __file__) + '/colorset/config'
+try:
+ data = load_config(config)
+ for d in data:
+ c[d] = data[d]
+except:
+ pass
+
# Load user's config
rainbow_config = os.environ.get(
'HOME',
# Load user's config
rainbow_config = os.environ.get(
'HOME',
@@
-36,7
+46,7
@@
try:
for d in data:
c[d] = data[d]
except:
for d in data:
c[d] = data[d]
except:
- p
ass
+ p
rint('It seems that ~/.rainbow_config.json has wrong format :(')
# Load default theme
theme_file = os.path.dirname(
# Load default theme
theme_file = os.path.dirname(