move all scripts to scripts/

This commit is contained in:
Harvey Tindall
2021-02-17 14:32:03 +00:00
parent a1a233e74f
commit 403ad58274
13 changed files with 94 additions and 104 deletions
+22
View File
@@ -0,0 +1,22 @@
#!/usr/bin/python
import shutil
import sys
from pathlib import Path
external = ["false", "external", "no", "n"]
with open("embed.go", "w") as f:
choice = ""
try:
choice = sys.argv[1]
except IndexError:
pass
folder = Path("embed")
if choice in external:
embed = False
shutil.copy(folder / "external.go", "embed.go")
print("Embedding disabled. \"data\" must be placed alongside the executable.")
else:
shutil.copy(folder / "internal.go", "embed.go")
print("Embedding enabled.")