Initial commit n push

This commit is contained in:
2020-05-07 19:07:33 -05:00
parent 9c642bfba4
commit 4ceb32f7b7
9 changed files with 195 additions and 0 deletions

32
src/__main__.py Normal file
View File

@@ -0,0 +1,32 @@
#!/usr/bin/python3
# Python imports
import argparse
from setproctitle import setproctitle
# Gtk imports
import gi, faulthandler, signal
gi.require_version('Gtk', '3.0')
from gi.repository import Gtk as gtk
from gi.repository import GLib
# Application imports
from __init__ import Main
if __name__ == "__main__":
try:
setproctitle('<replace this>')
GLib.unix_signal_add(GLib.PRIORITY_DEFAULT, signal.SIGINT, gtk.main_quit)
faulthandler.enable() # For better debug info
parser = argparse.ArgumentParser()
# Add long and short arguments
parser.add_argument("--file", "-f", default="default", help="JUST SOME FILE ARG.")
# Read arguments (If any...)
args = parser.parse_args()
main = Main(args)
gtk.main()
except Exception as e:
print( repr(e) )