Releases: cosmos72/schemesh
Releases · cosmos72/schemesh
Version 1.0.0
New features:
- implement structured pipelines and document them
- add shell builtins
answersdirfirstfromparseprocselectskipsort-bytowherethat read and/or write structured data - add buffering to
(console-input-port)(console-output-port)and(console-error-port) - add functions
(dir)(dirs)(file)(files) - and type
process-entryand function(proc)to list active processes - add functions
(sh-start/reader1)(tty-colors)and macro(with-sh-closable) - add types
readerandwriter - add many functions for
readertypes:(all)(all/vector)(close)(constant-reader)(copy-all)(copy-all/close)(datum-reader)(empty-reader)(eof?)(first)(get)(in-reader)(iterator-reader)(list-reader)(put)(reader->list)(reader->vector)(readers)(skip)(skip-first)(vector-reader) - add some functions for
writertypes:(discard-writer)(full-writer)(list-writer)(vector-writer) - add several functions
(from-...)and(to-...) - add macros for
readerandwritertypes:(for-reader)(filter==>)(select)(sort-by)(where)(where@) - add types
field-readerfilter-readername0-readerrange-readerandsort-reader - add types
fifo-readerfifo-writerand new macro(thread==>)that uses them - add types
json-readerandjson-writer - add types
queue-readerandqueue-writer - add type
table-writer - add types
wire-readerandwire-writer - add library
(scheme2k reflect)with functions for simplifing reflection - add function
(wire-get-from-bytespan)
Improvements:
- pretty-print types
timeanddateand add convenience functions to create and convert them - delete macro
(for)and rename macro(for*)->(for) - rename functions
(...producer...)->(...queue-reader...) - rename functions
(...consumer...)->(...queue-writer...) - rename function
(...channel...)->(...wire-reader...)or(...wire-writer...) - rename library
(schemesh ipc fifo)->(scheme2k ipc queue) - rename library
(scheme2k wire)->(scheme2k io wire)and extend it serialize/deserializedateobjects andordered-hashobjects
Version 0.9.3
New features:
- change license GPLv2+ -> LGPLv2+ in all sources except
parser/*shell/*repl/*main.ctest/* - rename all LGPLv2+ C functions and LGPLv2+ Scheme libraries
schemesh*->scheme2k* - and add optional Makefile targets
scheme2k_soandscheme2k_c_soto compile LGPLv2+ sources to new librarieslibscheme2k_0.9.3.soandlibscheme2k_c_0.9.3.sothat can be loaded from vanilla Chez Scheme. - add optional Makefile target
scheme2k_http_c_so, compiles LGPLv2+ librarylibscheme2k_http_c_0.9.3.socontaining bindings for using Clibcurllibrary from Chez Scheme (requires schemesh or libscheme2k) - add shell builtin
ulimit - add macro
(for-glob), iterates on filesystem paths generated by shell glob syntax - add function
(fd-nonblock?) - add key bindings for more xterm keys
Improvements:
- improve documentation
- rename function
(channel-fd)->(channel)and extend it to also accept binary ports in alternative to file descriptors - rename function
(fd-setnonblock)->(fd-nonblock?-set!) - rename function
(in-shell-glob)->(in-glob) - rename function
(open-pipe-fds)->(pipe-fds) - rename function
(open-socketpair-fds)->(socketpair-fds) - rename function
(wildcard)->(wildcard1+)and add function(wildcard)
Fixes:
- fix issue #33: compile error on macOS due to file descriptor number higher than undocumented maximum. Note:
ulimit -ncan be raised above the actually supported maximum on macOS, so its current value may be misleading.
Version 0.9.2
New features:
- subsume functions
(sh-binary-port)and(sh-textual-port)into the new function(sh-port)for accessing redirections of Scheme jobs - add more SRFI 18 compatible functions
- add support for keywords
whileanduntilinside macros(for)(for*)(for-...)(forever)(repeat)(until)(while) - add key bindings for more xterm keys
- export more
linectxfunctions - add more documentation, including: how to define new key bindings, how to add job redirections from Scheme syntax
Improvements:
- implement autocomplete for shell paths starting with
~- supersedes pull request #29 - improve
(sh-eval)to better handle forms containing(begin ...)followed by alternating functions and macros - modify functions
(file->port)and(sh-port)to return textual ports by default - allow calling
(sh-redirect)on running jobs, and document its behavior in such case
Fixes:
- fix issue #30: bug in
(string-join) - fix wildcards
*FOOto also match directories whose name ends withFOO, instead of only matching non-directories - fix an off-by-one error in wildcard expansion
Version 0.9.1
New features:
- add functions
(sh-start/fds)(sh-start/ports) - add macro
(for-alist)and function(in-alist) - add shell builtin
threadsto list existing threads and their status - add thread management functions
(get-thread)(thread)(thread-alive?)(thread-count)(thread-find)(thread-id)(thread-initial-bindings)(thread-kill)(threads)(threads-status)
Fixes:
- fix saving history to
~/.cache/schemesh/history.txt - fix issue #26: flush all open C
FILE*streams beforefork()ing a subshell
Version 0.9.0
New features:
- add build instructions for Windows using WSL
- add build instructions for NixOS
- add functions
(sh-binary-port)(sh-textual-port)for accessing redirections of Scheme jobs - add functions
(fork-process)(repl-answers)(repl-answers-display)(repl-history)(repl-history-display) - add functions creating customized, colored prompt and document them
- add Racket-compatible functions
(port->list)(port->string)(port->bytes)(port->lines)(port->bytes-lines)
(read-line)(read-bytes-line)(lines->port)(byte-lines->port) - add macro
(==>)
Improvements:
- improve shell builtins
fgbgandwait: job-id is now optional - improve autocompletion inside single or double quotes
- display colored jobs status
- add per-job ports, needed for buffering input/output of redirected Scheme jobs
- refactor type
vscreento contain colored chars: will allow implementing syntax highlighting - install interruptible, unbuffered UTF-8b ports as
(console-input-port)(console-output-port)and(console-error-port) - continue implementing library
(schemesh ipc fifo)
Fixes:
Version 0.8.3
New features:
- add functions
(channel?) (channel-fd) (channel-pipe-pair) (channel-socket-pair) (channel-close) (channel-get) (channel-eof?) (channel-put) (in-channel)for exchanging data between different processes through a socket, pipe or analogous file descriptor. They internally serialize and deserialize data using library(schemesh wire) - add function
(wire-register-rtd-fields)to quickly create serializers and deserializers for user-defined record types
Improvements:
- improve
(sh-run/string)and(sh-run/bvector)behavior if job being executed receives a signal - define optimized versions of standard - but currently slow - functions
(bytevector-sint-ref) (bytevector-sint-set!) (bytevector-uint-ref)(bytevector-uint-set!) - add support for serializing and deserializing Chez Scheme
timeobject to library(schemesh wire)
Fixes:
- fix a visual glitch when pasting multiple lines at REPL, and last line does not end with a
#\newline - remove Apache-licensed file containers/hashtable-types.ss that was copy-pasted from Chez Scheme sources: replace it with accessor functions obtained from record-type-descriptor objects.
Version 0.8.2
New features:
- add shell builtin
wait - add macros
(shell-glob)and(shell-string)for expanding shell syntax to, respectively, a list of strings or a single string. - add macro
(in-shell-glob)as a shortcut for(in-list (shell-glob)) - rename function
(sh-version)->(sh-version-number)and add function(sh-version)that returns a string - add functions
(bytespan->bytevector0) (countdown) (chargbuffer->charspans*) (chargbuffer->string) (charlines->charspan) (charlines->string) (fd-seek) (open-socketpair-fds)and macro(with-raw-tty) - add standalone executable
countdownas an alternative tosleep - add serialization/deserialization library
(schemesh wire)that exports the functions(datum->wire) (wire->datum) (wire-get) (wire-length) (wire-put)and can also be extended to support user-defined record types
Improvements:
- extend functions
(sh-find-job)and(sh-job)to accept#fas a shortcut for(or (sh-current-job) (sh-globals)) - improve functions
(sh-fg) (sh-bg) (sh-wait)to re-raise exceptions thrown by Scheme jobs - add lots of functions that intentionally shadow standard R6RS or Chez Scheme functions with the same name:
(get-bytevector-all) (get-bytevector-n) (get-bytevector-some) (get-char) (get-datum) (get-line) (get-string-all) (get-string-n) (get-u8) (put-bytevector) (put-bytevector-some) (put-char) (put-datum) (put-string) (put-string-some) (put-u8)
They are compatible replacements, and add the ability to omit the port argument, which defaults to(current-input-port)for(get-...)functions and to(current-output-port)for(put-...)functions - add functions
(getenv) (putenv)that intentionally shadow standard R6RS or Chez Scheme functions with the same name:
They are intended as replacements, and access environment variables of job-id#fi.e. either(sh-current-job)if it's set, or as fallback(sh-globals)that represents the main schemesh process - allow getting/setting port position in ports returned by functions
(open-fd-redir-...-port) (open-file-binary-input-port) (open-file-utf8b-input-port) (current-input-port) (current-out-port) (current-error-port) (sh-stdin) (sh-stdout) (sh-stderr)if the underlying file descriptor supports seeking - improve the following functions to also accepts
bytespanpaths in addition tobytevector,stringandcharspan:
(delete-directory) (delete-file) (directory-list) (directory-list-type) (mkdir) (file-delete) (file-directory?) (file-exists?) (file-rename) (file-regular?) (file-type) (open-file-fd) (open-file-utf8b-input-port) (text->bytevector) (text->bytevector0) - improve source code conformance to R6RS, and start creating an incomplete Racket compatibility layer to use when compiling schemesh from Racket
#!r6rsmode
Fixes:
- fix issue #12: a bug in shell syntax when parsing assignment after backslash+newline
- fix macro
(in-hash-pairs)
Version 0.8.1
New features:
- replace standard Scheme textual ports
(current-input-port)(current-output-port)(current-error-port)
with interruptible ones that honor job redirections and use UTF-8b - export several new functions to iterate on lists, hashtables, strings, etc.
- add script
utils/show_system_info.shand mention it in README.md when opening an issue
Improvements:
- fix job control on Scheme jobs
$()running inside a pipeline - update Scheme binary ports
(sh-stdin)(sh-stdout)(sh-stderr)to be interruptible and honor job redirections - internally rewrite and cleanup POSIX signal handlers
Version 0.8.0
New features:
- add function
(sh-expr)to create shell jobs that execute arbitrary Scheme code, and the corresponding macro(shell-expr) - implement job control also on arbitrary Scheme code running inside a
(shell-expr) - update both shell parser and Scheme parser to expand
$( )to(shell-expr ( ))
Improvements:
- ignore newlines at the beginning of shell syntax: allows writing Scheme code in a new line under the REPL prompt
- ignore newlines after shell syntax tokens
{[!;&&&||||&<<>>>><&>&- in most cases, this removes the need to end a line with\for continuing a shell command in the next line - always queue job status change notifications for later displaying them, instead of sometimes displaying them immediately
Removed features:
- remove function
(sh-resume)and subsume it into(sh-wait) - rename shell builtin
expr->value - remove function
(sh-bool)
Version 0.7.7
Fixes:
- fix
(charhistory-save-to-path)not to raise exceptions: it was preventing schemesh
from exiting if~/.cache/schemesh/directory does not exist or is not writable