Skip to content
Snippets Groups Projects
Commit 23d7e3a0 authored by Michele Maris's avatar Michele Maris
Browse files

u

parent 6c790db0
Branches
Tags
No related merge requests found
...@@ -23,7 +23,9 @@ def discoverKeys(template,kbraeket,verbose=False) : ...@@ -23,7 +23,9 @@ def discoverKeys(template,kbraeket,verbose=False) :
except : except :
raise Exception('file ended while scanning end of keyword') raise Exception('file ended while scanning end of keyword')
if verbose : print(i1,i2) if verbose : print(i1,i2)
out.append(template[i1:i2+1]) kkk=template[i1:i2+1]
if not kkk in out :
out.append(kkk)
i1=i2+1 i1=i2+1
return out return out
...@@ -108,7 +110,7 @@ class templateFiller: ...@@ -108,7 +110,7 @@ class templateFiller:
if not self.isfilled() : if not self.isfilled() :
raise Exception('Error, not all the keywords are filled') raise Exception('Error, not all the keywords are filled')
# #
tout=template tout=self._t
for ik,k in enumerate(self._k) : for ik,k in enumerate(self._k) :
keyName=self._kfill[ik] keyName=self._kfill[ik]
tout=tout.replace(keyName,self._d[k]) tout=tout.replace(keyName,self._d[k])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment