mirror of
https://github.com/ryanamay/inkdrop-command-palette.git
synced 2024-09-20 01:40:34 +00:00
remove old tool
This commit is contained in:
parent
ce451c1024
commit
199ba7a698
1 changed files with 0 additions and 34 deletions
|
@ -1,34 +0,0 @@
|
|||
from asyncio import current_task
|
||||
from urllib.error import ContentTooShortError
|
||||
|
||||
|
||||
with open("window.js", "a") as f:
|
||||
x = open ("source.txt", "r")
|
||||
previouseditor= ""
|
||||
currenteditor = ""
|
||||
currentselector = ""
|
||||
|
||||
f.write("\"use babel\";\n")
|
||||
f.write("export default [\n")
|
||||
|
||||
# if line starts with "editor:" add line to editor.js
|
||||
for line in x:
|
||||
print(line);
|
||||
print(currenteditor)
|
||||
print(currentselector)
|
||||
if line.startswith("window:"):
|
||||
currenteditor = line[7:]
|
||||
if line.startswith("Selector: "):
|
||||
currentselector = line[10:]
|
||||
if line.startswith("Selector:"):
|
||||
f.write("{\n")
|
||||
f.write("name: \">%s\",\n" % (currenteditor.replace("-", " ").capitalize().strip()))
|
||||
f.write("category: \"Window\",\n")
|
||||
f.write("command: \"window:%s\",\n" % (currenteditor.strip()))
|
||||
f.write("selector: \"%s\",\n" % (currentselector.strip()))
|
||||
f.write("state: \"untested\",\n")
|
||||
f.write("shortcut: [\"\"],\n")
|
||||
f.write("},\n")
|
||||
# insert values into the string
|
||||
# if currenteditor variable changes, add line to editor.js
|
||||
f.write("];")
|
Loading…
Reference in a new issue