ich hab ein Problem mit einer Datei
die wichtigsten Codeteile sind:
Code: Alles auswählen
def read_config(self):
choice, date, dest = None, None, None
try:
file = open(self.config_file)
for line in file.readlines():
if line.lower().strip().startswith("boottime"):
choice = re.split('^boottime\s*=\s*([0-9]+)', line.lower().strip())[1]
elif line.lower().strip().startswith("destination="):
dest = re.split('^[dD][eE][sS][tT][iI][nN][aA][tT][iI][oO][nN]\s*=\s*(.+)\s*$', line.strip()
text
boottime=7
destination= \pfad\für\sicherung\
aber wenn ich die datei anhänge sie das so aus
\pfad\für\sicherung\/datei.tar
wie bekomm ichs hin das der slash geändert wird?