Argh ...
My attempt at making a gnarly banner function more readable by creating lexical functions with `cl-flet` to pass to `mapconcat` was thwarted! Who would have thunk that `mapconcat' couldn't access a symbol reference to a function created by `cl-flet*'!?
This commit is contained in:
parent
3724a7decb
commit
d5e30ec98f
1 changed files with 14 additions and 7 deletions
|
@ -587,15 +587,22 @@ Whenever I open a shell, I instinctively type =ls= … so why not do that automa
|
||||||
(format padded (cond
|
(format padded (cond
|
||||||
((string-match image-rx file) (propertize file 'face '(:foreground "light pink")))
|
((string-match image-rx file) (propertize file 'face '(:foreground "light pink")))
|
||||||
((string-match code-rx file) (propertize file 'face '(:foreground "DarkSeaGreen1")))
|
((string-match code-rx file) (propertize file 'face '(:foreground "DarkSeaGreen1")))
|
||||||
;; ((string-match docs-rx file) (propertize file 'face '(:foreground "LightYellow1")))
|
|
||||||
((file-directory-p file) (propertize file 'face '(:foreground "SteelBlue")))
|
((file-directory-p file) (propertize file 'face '(:foreground "SteelBlue")))
|
||||||
(t file)))))
|
(t file)))))
|
||||||
(process-line
|
;; This nasty little function was an attempt to make
|
||||||
(files)
|
;; things readable, but who would have thunk that
|
||||||
(mapconcat 'process-file files "• ")))
|
;; `mapconcat' couldn't access a symbol reference to a
|
||||||
(concat
|
;; function created by `cl-flet*'!?
|
||||||
(mapconcat 'process-line (seq-partition files columns) "\n")
|
(process-files
|
||||||
"\n\n"))))
|
(table)
|
||||||
|
(mapconcat (lambda (line) (mapconcat
|
||||||
|
(lambda (file) (process-file file))
|
||||||
|
line
|
||||||
|
"• "))
|
||||||
|
table
|
||||||
|
"\n")))
|
||||||
|
|
||||||
|
(concat (process-files (seq-partition files columns)) "\n\n"))))
|
||||||
#+end_src
|
#+end_src
|
||||||
* Shell Windows
|
* Shell Windows
|
||||||
Now that I often need to quickly pop into remote systems to run a shell or commands, I create helper functions to create those buffer windows. Each begin with =eshell-=:
|
Now that I often need to quickly pop into remote systems to run a shell or commands, I create helper functions to create those buffer windows. Each begin with =eshell-=:
|
||||||
|
|
Loading…
Reference in a new issue