Timothy Sample
bbcb78de14
Use built-in compress without an external file.
...
When the system does not provide a compress executable, we use our
own. Before, this was done by installing an executable named
'compress' along with Gash. This commit allows the compressed-port
functions to use our built-in compress without needing an external
executable.
* gash/config.scm.in (exec-internal-compress): New function.
(%compress): Fall back to it on systems without compress.
* gash/guix-utils.scm (filtered-port, filtered-output-port): When the
given command list begins with a procedure, apply it to its arguments
instead of using execl.
2019-01-12 11:42:26 -05:00
Timothy Sample
35444457f8
Remove unused variable from Gash config.
...
* gash/config.scm.in (%commands): Remove variable.
2019-01-12 11:42:17 -05:00
Timothy Sample
1cda08dd4a
sed: Replace blank regexes with the last regex.
2018-12-11 13:13:46 -05:00
Timothy Sample
7aa7a883e0
sed: Add basic support for script files.
2018-12-11 13:13:46 -05:00
Timothy Sample
489f092131
sed: Add quit function.
2018-12-11 13:13:46 -05:00
Timothy Sample
5be7ed331d
sed: Support command lists.
2018-12-11 13:13:46 -05:00
Timothy Sample
1302c8bf28
sed: Support single pattern addresses.
2018-12-11 13:13:46 -05:00
Timothy Sample
194c098ab7
sed: Fully parse commands before processing them.
2018-12-11 13:12:45 -05:00
Jan Nieuwenhuizen
8757ab67fb
basename: fix /, add autoconf basename, dirname tests.
2018-12-09 04:13:27 +01:00
Jan Nieuwenhuizen
5b7f85aa3d
Fix [, use \[ in tests.
2018-12-04 21:00:47 +01:00
Jan Nieuwenhuizen
179ae8cddd
grammar: Support \[ builtin.
2018-12-04 19:17:39 +01:00
Jan Nieuwenhuizen
1ce8250029
set: Ignore set -o, set +o.
2018-12-04 19:17:39 +01:00
Jan Nieuwenhuizen
42d52d1a70
tar: Support extracting of read-only archives.
2018-12-04 10:13:45 +01:00
Jan Nieuwenhuizen
53fe775de9
chmod: Recurse also chmod's directories.
2018-12-04 10:10:05 +01:00
Jan Nieuwenhuizen
f7617fce47
builtins: test: Fix a = b.
2018-12-03 21:01:37 +01:00
Jan Nieuwenhuizen
d4f58ffa19
test: 04-word-at-word.
2018-12-02 09:51:57 +01:00
Jan Nieuwenhuizen
39761c0087
test: 04-word-at.
2018-12-02 09:51:57 +01:00
Jan Nieuwenhuizen
632295fa18
fix: 100-sed-fooRbar.
2018-12-02 09:03:02 +01:00
Jan Nieuwenhuizen
f5bc1d45c4
fix: 50-redirect-in-out.
2018-12-02 09:03:02 +01:00
Jan Nieuwenhuizen
a043f9ef09
tr: New builtin.
...
* gash/commands/tr.scm: New file.
* gash/bournish-commands.scm: Use it.
* build-aux/build-guile.sh: Compile it.
* configure: Wrap it.
* .gitignore: Ignore it.
2018-12-02 09:03:02 +01:00
Jan Nieuwenhuizen
353af765eb
cp: Support -f, --force.
2018-12-02 09:03:02 +01:00
Jan Nieuwenhuizen
0679cf9903
mv: Support -f, --force (by ignoring it).
2018-12-02 09:03:02 +01:00
Jan Nieuwenhuizen
73ecccef1e
fix 01-script-$@.
2018-12-02 09:03:02 +01:00
Jan Nieuwenhuizen
1f0a7674d9
fix 01-script-$#.
2018-12-02 09:03:02 +01:00
Jan Nieuwenhuizen
d5c94e75dd
parse [ .. ] into plain command. fixes 10-if-bracket-false, 100-bracket-file.
2018-12-02 06:56:17 +01:00
Jan Nieuwenhuizen
0a09ab114a
mv: New builtin.
...
* gash/commands/mv.scm: New file.
* gash/bournish-commands.scm: Use it.
* build-aux/build-guile.sh: Compile it.
* configure: Wrap it.
* .gitignore: Ignore it.
2018-11-30 12:38:24 +01:00
Jan Nieuwenhuizen
1162f37d19
test: 07-variable-or-empty.
2018-11-25 11:53:29 +01:00
Jan Nieuwenhuizen
7f6b88c43b
implement shift.
2018-11-25 08:46:10 +01:00
Jan Nieuwenhuizen
cb05054006
fix parsing of 07-variable-or-doublequete.sh.
2018-11-24 13:10:38 +01:00
Jan Nieuwenhuizen
9ac8140cf4
test: 07-variable-or-doublequete.sh: New failing parse test.
2018-11-24 12:57:07 +01:00
Jan Nieuwenhuizen
b2f5004eb6
01-script-$0.sh, 01-script-$@.sh: add test and fix.
2018-11-24 12:25:24 +01:00
Jan Nieuwenhuizen
f81b526bd0
fix and test cd builtin.
2018-11-24 11:32:33 +01:00
Jan Nieuwenhuizen
58d1627b08
fix 60-function.sh.
2018-11-24 11:12:44 +01:00
Jan Nieuwenhuizen
43f79811aa
fix 07-variable-or-variable.sh.
2018-11-24 10:55:24 +01:00
Jan Nieuwenhuizen
bdbc29e448
transform: reduce simple commands...WIP
2018-11-17 20:08:17 +01:00
Jan Nieuwenhuizen
74454c2156
transform: handle ./source.
2018-11-17 19:27:51 +01:00
Jan Nieuwenhuizen
9d1ed9ef57
transform: if-clause->if.
2018-11-17 19:27:51 +01:00
Jan Nieuwenhuizen
df73d5421f
transform: translate script to begin or command.
2018-11-17 08:46:39 +01:00
Jan Nieuwenhuizen
b89ca17134
transform: rewrite io-redirection.
2018-11-17 08:42:54 +01:00
Jan Nieuwenhuizen
2dc0a56ff9
guix: replace recipe with guile-only (bootstrappable) build.
2018-11-16 08:03:58 +01:00
Rutger van Beusekom
d36ee815df
variable-regex: fix 70-*.sh
2018-11-16 00:24:17 +01:00
Jan Nieuwenhuizen
df605a161a
sed: Support substitution of \t, \n.
2018-11-14 22:58:32 +01:00
Jan Nieuwenhuizen
303746a4bc
io-here.
2018-11-14 22:49:06 +01:00
Jan Nieuwenhuizen
b6340bd612
io-redirect: some progress, some new tests.
2018-11-14 22:41:24 +01:00
Jan Nieuwenhuizen
049c4a20dc
cat: Oops, two fixes.
2018-11-14 22:40:52 +01:00
Jan Nieuwenhuizen
efd22ab959
fix 11-for.sh.
2018-11-14 21:09:21 +01:00
Rutger van Beusekom
bb79378e66
fix 10-if-else.sh and 10-if-elif.sh
2018-11-14 19:59:18 +01:00
Rutger van Beusekom
1fe85e2b8f
fix 10-if-word-variable.sh (HACK)
2018-11-14 19:50:43 +01:00
Rutger van Beusekom
c20ac38ace
fix 08-variable-not-and.sh
2018-11-14 19:46:02 +01:00
Rutger van Beusekom
03dcfb9a9f
fix 08-variable-and.sh
2018-11-14 19:40:46 +01:00