Fix a little annoying issue with config files
This commit is contained in:
7
main.py
7
main.py
@@ -11,7 +11,6 @@ from datetime import datetime
|
||||
from colorama import Fore
|
||||
from os.path import expanduser
|
||||
|
||||
|
||||
# Some initial variables
|
||||
version = "0.2.0"
|
||||
user = os.getlogin()
|
||||
@@ -36,7 +35,7 @@ for line in configFile:
|
||||
confArgList[confArgNumber] = confArgList[confArgNumber] + ":"
|
||||
confArgNumber = confArgNumber + 1
|
||||
elif letter == ',':
|
||||
confArgList.append(",")
|
||||
confArgList.append("")
|
||||
confArgNumber = confArgNumber + 1
|
||||
else:
|
||||
try:
|
||||
@@ -49,7 +48,7 @@ for word in confArgList:
|
||||
for word in confArgList:
|
||||
if word == "motd:":
|
||||
motd = confArgList[confArgList.index(word) + 1]
|
||||
if word == ",mashPath:":
|
||||
if word == "mashPath:":
|
||||
mashPathStr = (confArgList[confArgList.index(word) + 1])
|
||||
pathStrIndex = 0
|
||||
mashPath = [""]
|
||||
@@ -179,4 +178,4 @@ def mainLoop(startDir):
|
||||
except KeyboardInterrupt:
|
||||
print("\n")
|
||||
mainLoop(currentDirectory)
|
||||
mainLoop(initDirectory)
|
||||
mainLoop(initDirectory)
|
||||
|
Reference in New Issue
Block a user