Fetch and display binary file when no redirection - clic - Clic is an command line interactive client for gopher written in Common LISP
HTML git clone git://bitreich.org/clic/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws65d7roiv6bfj7d652fid.onion/clic/
DIR Log
DIR Files
DIR Refs
DIR Tags
DIR README
DIR LICENSE
---
DIR commit 02fda5b5bc6564db46dde5a1a2e2f5e71a75321d
DIR parent c32b721b6e25fdc9c881d37735431966f6c7b530
HTML Author: Solene Rapenne <solene@perso.pw>
Date: Sun, 31 Dec 2017 19:03:03 +0100
Fetch and display binary file when no redirection
Diffstat:
M clic.lisp | 20 +++++++-------------
1 file changed, 7 insertions(+), 13 deletions(-)
---
DIR diff --git a/clic.lisp b/clic.lisp
@@ -98,20 +98,16 @@
;;;; END ANSI colors
;;;; is the output interactive or a pipe ?
-
(defun ttyp()
"return t if the output is a terminal"
;; we use this variable in case we don't want to be interactive
;; like when we use a cmd arg to get an image
- (if *not-interactive*
- nil
- (progn
- #+sbcl
- (interactive-stream-p *standard-output*)
- #+ecl
- (if (= 1 (c-ttyp))
- t
- nil))))
+ #+sbcl
+ (interactive-stream-p *standard-output*)
+ #+ecl
+ (if (= 1 (c-ttyp))
+ t
+ nil))
(defun copy-array(from)
"return a new array containing the same elements as the parameter"
@@ -630,9 +626,7 @@
;; if we don't ask a menu, not going interactive
(if (not (string= "1" (location-type destination)))
;; not interactive
- (progn
- (setf *not-interactive* t)
- (visit destination))
+ (visit destination)
;; if user want to drop from first page we need
;; to look it here