summaryrefslogtreecommitdiff
path: root/branding/templates/windows/generate.py
diff options
context:
space:
mode:
authorkali kaneko (leap communications) <kali@leap.se>2020-10-13 19:40:09 +0200
committerkali kaneko (leap communications) <kali@leap.se>2020-10-23 23:21:57 +0200
commite9c95064992bffb331be71a89152bb3f4de763f5 (patch)
treebfb6c575f4aeb7ef8beb28bb36f2baef93bac4b8 /branding/templates/windows/generate.py
parent93a0668a02b3a280919c4881db9085d5f2a912af (diff)
[pkg] remove unused templates & scripts
Diffstat (limited to 'branding/templates/windows/generate.py')
-rwxr-xr-xbranding/templates/windows/generate.py44
1 files changed, 0 insertions, 44 deletions
diff --git a/branding/templates/windows/generate.py b/branding/templates/windows/generate.py
deleted file mode 100755
index 552f1a9..0000000
--- a/branding/templates/windows/generate.py
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/usr/bin/env python3
-"""
-generate.py
-
-Generate a NSI installer for a given provider.
-"""
-
-import json
-import os
-from string import Template
-
-
-TEMPLATE = 'template.nsi'
-
-
-def get_files(which):
- files = "\n"
- if which == 'install':
- action = "File "
- elif which == 'uninstall':
- action = "Delete $INSTDIR\\"
- else:
- action = ""
-
- # TODO get relative path
- for item in open('payload/' + which).readlines():
- files += " {action}{item}".format(
- action=action, item=item)
- return files
-
-
-here = os.path.split(os.path.realpath(__file__))[0]
-data = json.load(open(os.path.join(here, 'data.json')))
-data['extra_install_files'] = get_files('install')
-data['extra_uninstall_files'] = get_files('uninstall')
-
-INSTALLER = data['applicationName'] + '-installer.nsi'
-
-
-template = Template(open(TEMPLATE).read())
-with open(INSTALLER, 'w') as output:
- output.write(template.safe_substitute(data))
-
-print("[+] NSIS installer script written to {path}".format(path=INSTALLER))