Skip to content

Commit

Permalink
Merge pull request #137 from zachar1a/main
Browse files Browse the repository at this point in the history
Fix #123, create package for cfs-groundsystem
  • Loading branch information
astrogeco authored Mar 22, 2021
2 parents 912ecad + 18cbb52 commit 331b408
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 6 deletions.
18 changes: 12 additions & 6 deletions GroundSystem.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@
import shlex
import subprocess
import sys
from pathlib import Path
import os
import signal
import pathlib

from PyQt5.QtWidgets import QApplication, QMainWindow, QMessageBox

Expand All @@ -36,8 +38,8 @@

__version__ = _version


ROOTDIR = Path(sys.argv[0]).resolve().parent
#ROOTDIR = Path(sys.argv[0]).resolve().parent
ROOTDIR = pathlib.Path(__file__).parent.absolute()


#
Expand Down Expand Up @@ -81,7 +83,7 @@ def closeEvent(self, evnt):
if self.RoutingService:
self.RoutingService.stop()
print("Stopped routing service")

os.kill(0, signal.SIGKILL)
super().closeEvent(evnt)

# Read the selected spacecraft from combo box on GUI
Expand Down Expand Up @@ -182,9 +184,10 @@ def initRoutingService(self):

#
# Main

#
if __name__ == "__main__":
def main():

# Report Version Number upon startup
print(_version_string)

Expand All @@ -204,3 +207,6 @@ def initRoutingService(self):

# Execute the app
sys.exit(app.exec_())

if __name__ == "__main__":
main()
Empty file added Subsystems/__init__.py
Empty file.
Empty file.
Empty file added Subsystems/cmdGui/__init__.py
Empty file.
Empty file added Subsystems/cmdUtil/__init__.py
Empty file.
Empty file added Subsystems/tlmGUI/__init__.py
Empty file.
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
setuptools
13 changes: 13 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
from setuptools import setup

setup(
name='GroundSystem',
packages=['Subsystems','Subsystems.tlmGUI','Subsystems.cmdGui','Subsystems.cmdUtil'],
include_package_data=True,
version='0.0.0',
entry_points={
'console_scripts':[
'startg=GroundSystem:main'
]
},
)

0 comments on commit 331b408

Please sign in to comment.