Commit Graph

25 Commits

Author SHA1 Message Date
Kelvin Sherlock 6199944350 script parameters, move shift to the environment 2022-11-23 21:22:00 -05:00
Kelvin Sherlock ce1a36eba5 add regular expression support for evaluate, if, etc.
eg:

evaluate abc =~ /(abc)®4/ # sets the '@4' environment variable.
evaluate abc !~ /[aA]bc/

MPW regular expressions are converted to c++11 std::regex regular expressions and evaluated.
Sadly, the // regular expression syntax interferes with unix-paths (if the / count is odd).  quoting or ∂-escaping the /s is therefore necessary.

file globbing is not yet implemented.
2022-11-22 17:22:49 -05:00
Kelvin Sherlock ed96470e18 builtin_help 2016-10-08 09:54:06 -04:00
Kelvin Sherlock f125b533f7 Squashed commit of the following:
commit f0944a89f27e44b1764988806e655f09764e80df
Author: Kelvin Sherlock <ksherlock@gmail.com>
Date:   Tue Aug 30 12:24:08 2016 -0400

    exit throws execution of input error w/ possible 0 value.  catch it.

commit 9e7f9c1ae049aa26513413f4767268b47ee22e98
Author: Kelvin Sherlock <ksherlock@gmail.com>
Date:   Tue Aug 30 12:23:21 2016 -0400

    builtins - more consistent argument handling.

commit be4c1c902f5a3a3f01e92ae52c7d6cc5d8731b65
Author: Kelvin Sherlock <ksherlock@gmail.com>
Date:   Tue Aug 30 12:23:01 2016 -0400

    .

commit 68d0c29fec112c6e7bc3a672b41eb7eb758a8941
Author: Kelvin Sherlock <ksherlock@gmail.com>
Date:   Tue Aug 30 12:22:51 2016 -0400

    exit command.

commit 25b0a7f7da9220b03026123bb5072c2da1d73fde
Author: Kelvin Sherlock <ksherlock@gmail.com>
Date:   Tue Aug 30 12:21:16 2016 -0400

    builtin quit command.
2016-08-30 12:25:43 -04:00
Kelvin Sherlock 33dd3228f8 update the parser/lexer to make it more reusable. For example, subshells are now handled. 2016-08-16 16:47:20 -04:00
Kelvin Sherlock 811c8b976a ... and use the config.h 2016-08-09 15:29:28 -04:00
Kelvin Sherlock 827f49c48b solaris... 2016-08-07 14:43:18 -04:00
Kelvin Sherlock 76980a6e06 headers 2016-08-05 22:38:06 -04:00
Kelvin Sherlock 2fdca6ea9d builtin_which -- also check builtin commands. 2016-07-24 21:21:15 -04:00
Kelvin Sherlock 9b577bdbb1 builtin catenate (builtin so cr/lf conversion blocked) 2016-07-23 23:50:28 -04:00
Kelvin Sherlock 45eade7af5 builtin_alias / builtin_unalias. 2016-06-22 13:48:05 -04:00
Kelvin Sherlock 6bfad57a35 offset_range 2016-06-22 13:46:19 -04:00
Kelvin Sherlock a15c6fbd65 clean up env set via number. 2016-06-16 22:00:03 -04:00
Kelvin Sherlock ef99bb40de version bump 2016-06-16 21:55:39 -04:00
Kelvin Sherlock 8a2b9ec3cd shift builtin. 2016-06-16 16:48:04 -04:00
Kelvin Sherlock edd80fc3c5 version builtin 2016-06-15 13:25:41 -04:00
Kelvin Sherlock 7724ca0d7c add Exists builtin. 2016-06-15 11:25:25 -04:00
Kelvin Sherlock 0d0367ca08 builtin about box, bump version number. 2016-02-11 21:50:25 -05:00
Kelvin Sherlock 7d18720162 use filesystem::current_path for builtin_directoery 2016-02-11 20:50:24 -05:00
Kelvin Sherlock beb3e3813a builtin_which 2016-02-11 15:51:39 -05:00
Kelvin Sherlock 50f171d5c8 which command 2016-02-11 15:48:46 -05:00
Kelvin Sherlock 2485f08172 commentary 2016-02-10 23:51:45 -05:00
Kelvin Sherlock 6f53faeae7 fix directory return value 2016-02-10 21:57:35 -05:00
Kelvin Sherlock 3fea71d1e8 directory -- support for MacOS pathnames. 2016-02-09 23:50:33 -05:00
Kelvin Sherlock 5723656988 lots of updates! 2016-02-01 20:38:29 -05:00