Compare commits
2 Commits
4324da1467
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| 7f66e09e9b | |||
| 201b8f189c |
@@ -1,3 +1,11 @@
|
|||||||
|
0.2.16
|
||||||
|
|
||||||
|
- Fix pregexp tab escapes in the `time` tests for Racket 9.2.
|
||||||
|
- Keep the tests on `racket/base` by using `car` and `cadr` instead of undeclared `first` and `second` bindings.
|
||||||
|
- Test `dirname` output directly instead of using an unnecessary platform path regular expression.
|
||||||
|
- Align the package, help metadata, README, and source header on version 0.2.16.
|
||||||
|
- No command API or command behavior changes.
|
||||||
|
|
||||||
0.2.14
|
0.2.14
|
||||||
|
|
||||||
- Add `rackedit` as a runtime dependency.
|
- Add `rackedit` as a runtime dependency.
|
||||||
|
|||||||
@@ -2,10 +2,10 @@
|
|||||||
|
|
||||||
Portable Unix-style commands for Rash, implemented in Racket.
|
Portable Unix-style commands for Rash, implemented in Racket.
|
||||||
|
|
||||||
Version 0.2.14 adds the `edit` command backed by the `rackedit` package and
|
Version 0.2.16 fixes the Racket 9.2 test suite and aligns package version
|
||||||
reworks the manual around the commands that are available directly in Rash.
|
metadata. Command behavior is unchanged. The package includes the `edit`
|
||||||
The manual now describes, per command, which internal `coreutils-*` Racket
|
command backed by `rackedit`, streaming `head` and `tail`, and the portable
|
||||||
procedure implements it.
|
`time` command.
|
||||||
|
|
||||||
Rash remains responsible for shell syntax such as globbing, pipelines and
|
Rash remains responsible for shell syntax such as globbing, pipelines and
|
||||||
redirection. `rash-coreutils` additionally accepts Racket regular expressions as
|
redirection. `rash-coreutils` additionally accepts Racket regular expressions as
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#lang info
|
#lang info
|
||||||
|
|
||||||
(define pkg-authors '(hnmdijkema))
|
(define pkg-authors '(hnmdijkema))
|
||||||
(define version "0.2.14")
|
(define version "0.2.16")
|
||||||
(define license 'MIT)
|
(define license 'MIT)
|
||||||
(define collection "rash-coreutils")
|
(define collection "rash-coreutils")
|
||||||
(define pkg-desc
|
(define pkg-desc
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#lang info
|
#lang info
|
||||||
|
|
||||||
(define pkg-authors '(hnmdijkema))
|
(define pkg-authors '(hnmdijkema))
|
||||||
(define version "0.2.14")
|
(define version "0.2.16")
|
||||||
(define license 'MIT)
|
(define license 'MIT)
|
||||||
(define collection "rash-coreutils")
|
(define collection "rash-coreutils")
|
||||||
(define pkg-desc
|
(define pkg-desc
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#lang racket/base
|
#lang racket/base
|
||||||
|
|
||||||
;; rash-coreutils 0.2.14
|
;; rash-coreutils 0.2.16
|
||||||
;; Streaming implementation of the extended core utilities.
|
;; Streaming implementation of the extended core utilities.
|
||||||
|
|
||||||
(require gregor
|
(require gregor
|
||||||
|
|||||||
+7
-7
@@ -107,8 +107,8 @@
|
|||||||
(λ (filename #:wait? [wait? #f])
|
(λ (filename #:wait? [wait? #f])
|
||||||
(set! edit-call (list filename wait?)))])
|
(set! edit-call (list filename wait?)))])
|
||||||
(dispatch-coreutils-command 'edit '--wait "one.txt"))
|
(dispatch-coreutils-command 'edit '--wait "one.txt"))
|
||||||
(check-equal? (path->string (first edit-call)) "one.txt")
|
(check-equal? (path->string (car edit-call)) "one.txt")
|
||||||
(check-true (second edit-call))
|
(check-true (cadr edit-call))
|
||||||
|
|
||||||
(set! edit-call #f)
|
(set! edit-call #f)
|
||||||
(parameterize
|
(parameterize
|
||||||
@@ -116,8 +116,8 @@
|
|||||||
(λ (filename #:wait? [wait? #f])
|
(λ (filename #:wait? [wait? #f])
|
||||||
(set! edit-call (list filename wait?)))])
|
(set! edit-call (list filename wait?)))])
|
||||||
(dispatch-coreutils-command 'edit "one.txt"))
|
(dispatch-coreutils-command 'edit "one.txt"))
|
||||||
(check-equal? (path->string (first edit-call)) "one.txt")
|
(check-equal? (path->string (car edit-call)) "one.txt")
|
||||||
(check-false (second edit-call))
|
(check-false (cadr edit-call))
|
||||||
|
|
||||||
(check-exn
|
(check-exn
|
||||||
exn:fail?
|
exn:fail?
|
||||||
@@ -166,8 +166,8 @@
|
|||||||
"abc\n")
|
"abc\n")
|
||||||
(check-equal? (capture-filter "a b\n" coreutils-tr "-s" " ")
|
(check-equal? (capture-filter "a b\n" coreutils-tr "-s" " ")
|
||||||
"a b\n")
|
"a b\n")
|
||||||
(check-true (regexp-match? #rx"a[/\\]b"
|
(check-equal? (capture-output coreutils-dirname "a/b/c.txt")
|
||||||
(capture-output coreutils-dirname "a/b/c.txt")))
|
"a/b/\n")
|
||||||
|
|
||||||
(define env-output
|
(define env-output
|
||||||
(parameterize ([current-coreutils-command-runner
|
(parameterize ([current-coreutils-command-runner
|
||||||
@@ -210,7 +210,7 @@
|
|||||||
(define time-output (get-output-string time-error))
|
(define time-output (get-output-string time-error))
|
||||||
(check-true
|
(check-true
|
||||||
(regexp-match?
|
(regexp-match?
|
||||||
#px"^real\\t[0-9]+[.][0-9]{3}s\ncpu\\t[0-9]+[.][0-9]{3}s\ngc\\t[0-9]+[.][0-9]{3}s\n$"
|
#px"^real\t[0-9]+[.][0-9]{3}s\ncpu\t[0-9]+[.][0-9]{3}s\ngc\t[0-9]+[.][0-9]{3}s\n$"
|
||||||
time-output))
|
time-output))
|
||||||
|
|
||||||
(check-exn
|
(check-exn
|
||||||
|
|||||||
@@ -50,15 +50,15 @@
|
|||||||
(define error-text (get-output-string errors))
|
(define error-text (get-output-string errors))
|
||||||
(check-true
|
(check-true
|
||||||
(regexp-match?
|
(regexp-match?
|
||||||
#px"^real\\t[0-9]+[.][0-9]{3}s\ncpu\\t[0-9]+[.][0-9]{3}s\ngc\\t[0-9]+[.][0-9]{3}s\n$"
|
#px"^real\t[0-9]+[.][0-9]{3}s\ncpu\t[0-9]+[.][0-9]{3}s\ngc\t[0-9]+[.][0-9]{3}s\n$"
|
||||||
error-text))
|
error-text))
|
||||||
(define text (get-output-string output))
|
(define text (get-output-string output))
|
||||||
(check-true (regexp-match? #rx"hello from rash-coreutils" text))
|
(check-true (regexp-match? #rx"hello from rash-coreutils" text))
|
||||||
(check-true (regexp-match? #rx"info[.]rkt" text))
|
(check-true (regexp-match? #rx"info[.]rkt" text))
|
||||||
(check-true (regexp-match? #rx"42" text))
|
(check-true (regexp-match? #rx"42" text))
|
||||||
(check-true (regexp-match? #rx"timed" text))
|
(check-true (regexp-match? #rx"timed" text))
|
||||||
(check-equal? (path->string (first edited)) "info.rkt")
|
(check-equal? (path->string (car edited)) "info.rkt")
|
||||||
(check-true (second edited))
|
(check-true (cadr edited))
|
||||||
(check-true (regexp-match? #rx"\n3\n" text))
|
(check-true (regexp-match? #rx"\n3\n" text))
|
||||||
(check-true (regexp-match? #px"[0-9]{4}-[0-9]{2}-[0-9]{2}T" text)))
|
(check-true (regexp-match? #px"[0-9]{4}-[0-9]{2}-[0-9]{2}T" text)))
|
||||||
(λ ()
|
(λ ()
|
||||||
|
|||||||
Reference in New Issue
Block a user