feat: add default handler for SIGINT
This prevents having a callstack when hitting Ctrl+C in the terminal.
This commit is contained in:
parent
e23cdceb80
commit
d4f2032972
|
@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||||
|
|
||||||
- Some signals weren't properly renamed from the previous GTK3 migration (@MightyCreak)
|
- Some signals weren't properly renamed from the previous GTK3 migration (@MightyCreak)
|
||||||
- The syntax menu wasn't working anymore (@MightyCreak)
|
- The syntax menu wasn't working anymore (@MightyCreak)
|
||||||
|
- Properly handles SIGINT (i.e. Ctrl+C) now (@MightyCreak)
|
||||||
|
|
||||||
## 0.8.1 - 2023-04-07
|
## 0.8.1 - 2023-04-07
|
||||||
|
|
||||||
|
|
|
@ -22,6 +22,7 @@
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import gettext
|
import gettext
|
||||||
|
import signal
|
||||||
|
|
||||||
from gi.repository import Gio
|
from gi.repository import Gio
|
||||||
|
|
||||||
|
@ -32,6 +33,10 @@ SYSCONFIGDIR = '@SYSCONFIGDIR@'
|
||||||
|
|
||||||
sys.path.insert(1, PKGDATADIR)
|
sys.path.insert(1, PKGDATADIR)
|
||||||
|
|
||||||
|
# Quietly handle SIGINT (i.e. Ctrl+C)
|
||||||
|
signal.signal(signal.SIGINT, signal.SIG_DFL)
|
||||||
|
|
||||||
|
# Initialize i18n
|
||||||
gettext.bindtextdomain('diffuse', localedir=LOCALEDIR)
|
gettext.bindtextdomain('diffuse', localedir=LOCALEDIR)
|
||||||
gettext.textdomain('diffuse')
|
gettext.textdomain('diffuse')
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue