Skip to content

Commit

Permalink
add docs
Browse files Browse the repository at this point in the history
  • Loading branch information
eri24816 committed Apr 22, 2024
1 parent 763af2f commit 0530593
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion backend/src/grapycal/core/workspace.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class Workspace:
"""

def __init__(self,
path,
path: str,
open_another_workspace_strategy: OpenAnotherWorkspaceStrategy|None = None,
):
self.path = path
Expand Down
9 changes: 5 additions & 4 deletions entry/launcher.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
'''
For running Grapycal in Windows CLI.
run_server.py can run the server already, but it can't be ctrl+c'd because the keyboard interrupt is handled by the runner.
To fix this, we need to capture the SIGINT in this script and close the server with SIGTERM instead of SIGINT.
Acts as a parent process to the workspace process (run.py). It handles the SIGINT signal and opens another workspace process when
the user wants to open another workspace.
'''

import os
import signal
import subprocess
import os, sys
import sys
import time


def sigint_handler(signum, frame):
print("SIGINT received, closing server")
server.terminate()
Expand Down

0 comments on commit 0530593

Please sign in to comment.