connect backend: WIP
This commit is contained in:
parent
f6a9bb4109
commit
b68f8c3223
|
@ -31,11 +31,11 @@
|
|||
#:use-module (gash config)
|
||||
#:use-module (gash shell-utils)
|
||||
|
||||
#:use-module (gash commands basename)
|
||||
#:use-module ((gash commands basename) #:prefix gash:)
|
||||
#:use-module (gash commands cat)
|
||||
#:use-module (gash commands compress)
|
||||
#:use-module (gash commands cp)
|
||||
#:use-module (gash commands dirname)
|
||||
#:use-module ((gash commands dirname) #:prefix gash:)
|
||||
#:use-module (gash commands find)
|
||||
#:use-module (gash commands grep)
|
||||
#:use-module (gash commands ls)
|
||||
|
@ -78,11 +78,11 @@
|
|||
((quit) (car args))
|
||||
(else 1)))))))
|
||||
|
||||
(define basename-command (wrap-command basename "basename"))
|
||||
(define basename-command (wrap-command "basename" gash:basename))
|
||||
(define cat-command (wrap-command cat "cat"))
|
||||
(define compress-command (wrap-command "compress" compress))
|
||||
(define cp-command (wrap-command "cp" cp))
|
||||
(define dirname-command (wrap-command "dirname" dirname))
|
||||
(define dirname-command (wrap-command "dirname" gash:dirname))
|
||||
(define find-command (wrap-command "find" find))
|
||||
(define grep-command (wrap-command "grep" grep))
|
||||
(define ls-command (wrap-command "ls" ls))
|
||||
|
|
|
@ -168,7 +168,9 @@
|
|||
(match o
|
||||
((h t ...) (append (flatten h) (append-map flatten t)))
|
||||
(_ (list o))))
|
||||
(string-join (flatten o) ""))
|
||||
(match o
|
||||
(((? string?) ...) (string-join (flatten o) ""))
|
||||
(_ o)))
|
||||
|
||||
(define-syntax-rule (substitution commands)
|
||||
(string-trim-right (with-output-to-string (lambda _ commands))))
|
||||
|
@ -368,3 +370,14 @@
|
|||
replace
|
||||
(substring value (match:end match)))
|
||||
value))))
|
||||
|
||||
(define (compound . o)
|
||||
(match (warn 'compound o)
|
||||
((h ... t) t)
|
||||
(_ o)))
|
||||
|
||||
(define (delim o)
|
||||
o)
|
||||
|
||||
(define (name o)
|
||||
o)
|
||||
|
|
Loading…
Reference in New Issue