1
0
mirror of https://github.com/nvbn/thefuck.git synced 2025-01-18 12:06:04 +00:00

Import CommandNotFound system package on Debian

This commit is contained in:
Sandro Jäckel 2020-08-02 13:29:12 +02:00
parent c196e2901c
commit 971ee69908
No known key found for this signature in database
GPG Key ID: 3AF5A43A3EECC2E5

View File

@ -1,8 +1,15 @@
import sys
from types import ModuleType
from thefuck.specific.apt import apt_available
from thefuck.utils import memoize, which
from thefuck.shells import shell
# Debian does not have a python{,3}-commandnotfound package
# and the command-not-found package places the python module in another directory
# To import it correctly append the path to the sys.path
sys.path.append('/usr/share/command-not-found/')
try:
from CommandNotFound import CommandNotFound