diff options
author | kotfu <kotfu@kotfu.net> | 2019-09-07 16:11:44 -0600 |
---|---|---|
committer | kotfu <kotfu@kotfu.net> | 2019-09-07 16:11:44 -0600 |
commit | 74857c34c00323c881f1669ae95788dcff6a48fa (patch) | |
tree | 359649000c2e55ea913250244db59da4b1e0cfd7 /cmd2/clipboard.py | |
parent | b9d21a222f02735be3c36be0cab8e83770619373 (diff) | |
parent | 693ec59719edc4384739392a0daea73c922b91c3 (diff) | |
download | cmd2-git-74857c34c00323c881f1669ae95788dcff6a48fa.tar.gz |
Merge branch 'master' into doc_additions
Diffstat (limited to 'cmd2/clipboard.py')
-rw-r--r-- | cmd2/clipboard.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd2/clipboard.py b/cmd2/clipboard.py index 18370f9a..deb2f5cc 100644 --- a/cmd2/clipboard.py +++ b/cmd2/clipboard.py @@ -10,8 +10,9 @@ from pyperclip import PyperclipException try: # Try getting the contents of the clipboard _ = pyperclip.paste() -except (PyperclipException, FileNotFoundError): +except (PyperclipException, FileNotFoundError, ValueError): # NOTE: FileNotFoundError is for Windows Subsystem for Linux (WSL) when Windows paths are removed from $PATH + # NOTE: ValueError is for headless Linux systems without Gtk installed can_clip = False else: can_clip = True |