We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 42ff90d commit 2f73171Copy full SHA for 2f73171
codeSnippetsLog.py
@@ -7,10 +7,10 @@
7
path = os.path.join(logDir, filename)
8
9
if text:
10
- with file(path,'a') as f:
+ with open(path,'a') as f:
11
f.write('#%% ' + '_'*25 + ' ' + datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S') + ' ' + '_'*25 + '\n\n' + text.replace('\r','').strip() + '\n\n')
12
n = len(text.splitlines())
13
Npp.notepad.messageBox('%i lines logged to %s'%(n,filename))
14
else:
15
notepad.open(path)
16
- notepad.setLangType(Npp.LANGTYPE.PYTHON)
+ notepad.setLangType(Npp.LANGTYPE.PYTHON)
0 commit comments