Commit Graph

97 Commits

Author SHA1 Message Date
0371025109 completion now prefers completing variable names before trying comp specs
improved color picking for error messages
2026-03-01 11:02:13 -05:00
303e85ad29 Fixed 'C' and 'D' verbs deleting the newline character 2026-03-01 02:39:22 -05:00
dff87fd5c2 More progress on integrating ariadne's error reporting 2026-03-01 02:20:58 -05:00
792b0c21d0 Work on integrating error reporting using the ariadne crate 2026-02-28 20:30:12 -05:00
9d8d8901d7 Add array support for local/export/readonly builtins
Add array length syntax ${arr[#]}

Map read path now expands variables before splitting on ., fixing map "$node" with dotted paths

Map assignment path uses quote-aware token splitting, enabling quoted keys like "--type="

Completion errors now display above prompt instead of being overwritten

Fix nested if/fi parser bug when closing keywords appear on separate lines

Add QuoteState enum, replacing ad-hoc quote tracking booleans across lexer, highlighter, and expansion

Add split_tk_at/split_tk for quote-aware token splitting with span preservation

Refactor setup_builtin to accept optional argv for deferred expansion

Add ariadne dependency (not yet wired up)
2026-02-28 15:54:53 -05:00
0c40f17b60 added 'map', 'pop', 'push', 'fpop', 'fpush', and 'rotate' builtins 2026-02-27 20:37:58 -05:00
faae6b82be cleaned up all compiler warnings 2026-02-27 11:08:42 -05:00
6f408b3c21 ran clippy fix 2026-02-27 11:05:08 -05:00
3d47e4edd9 Added -j flag to 'complete' for completing job names/pids 2026-02-27 11:03:56 -05:00
f7e3d18502 Fixed possible refcell borrow panic related to expanding variables in an array index 2026-02-27 02:14:40 -05:00
96ea2d0ac9 Early implementation of bash-like completions with 'complete' and 'compgen' builtins 2026-02-27 01:10:52 -05:00
f9312885bd Implemented arrays and array indexing 2026-02-26 00:32:54 -05:00
b013a9513d Implemented a gutter with line numbers for multi-line editing 2026-02-25 19:55:48 -05:00
56264731c4 Fixed issue with pipeline I/O in command substitutions 2026-02-25 17:54:17 -05:00
22adbce9e4 Various line editor fixes and optimizations 2026-02-25 15:43:08 -05:00
03a435c03f implemented builtins: readonly, unset, true, false, and : (no-op) 2026-02-24 17:57:09 -05:00
16f47ad225 Fixed functions not properly forking a new process when executed in a pipeline 2026-02-24 16:03:22 -05:00
b71fca22ec subshells now fork a new process 2026-02-24 15:15:30 -05:00
930d16c5d4 Fixed 'command' builtin executing shell functions with same name as the command 2026-02-24 14:54:36 -05:00
49c6d688b6 fixed new crash caused by recent refactor 2026-02-24 14:18:36 -05:00
622e9f4a1e Refactored internals for builtins inside of pipelines 2026-02-24 10:54:24 -05:00
367218d3e8 Fixed command substitutions not expanding when used as a command name 2026-02-23 23:32:12 -05:00
f55e204c82 autocd will now prioritize running a command if a directory name is entered that matches the name of a command 2026-02-23 21:05:59 -05:00
05f731b8c5 Added auto-indent to multi-line editing -m Added shopt for enabling/disabling auto-indent -m Fixed some multi-line editing render bugs -m Scrolling up in history now preserves undo/redo history in the pending command 2026-02-23 20:52:33 -05:00
4f834e9709 Fixed some hangs in the lexer 2026-02-23 19:21:57 -05:00
aed0e6fb8c - fixed 'I' command in normal mode not moving to exact start of line
- Added disown builtin
- Fixed job table not hanging up child processes on exit
- Added target architecture and os to --version output
- Added local builtin for creating variables scoped to functions
2026-02-23 16:10:49 -05:00
88c0945e47 Implemented the exec builtin
Fixed readline and terminal interactions using stdin instead of /dev/tty
2026-02-20 12:17:48 -05:00
9b8c8d704b implemented the pushd, popd, and dirs builtins 2026-02-20 01:29:40 -05:00
74988166f0 command arguments are now underlined if they match an existing path -m ran rustfmt on the entire codebase 2026-02-19 21:32:03 -05:00
1d4c177c64 handled some unwraps in cd
error reporting now blames the function call span instead of the errored command inside the function
2026-02-19 18:27:51 -05:00
744693a89d implemented the trap builtin 2026-02-19 16:39:18 -05:00
4ea08879a1 fixed the $0 parameter not being populated correctly 2026-02-19 14:24:55 -05:00
7d0614943c Tab completion has been implemented
more small highlighter tune ups

2>&1 style redirections now work properly
2026-02-18 21:53:36 -05:00
8068b43146 Implemented syntax highlighting 2026-02-18 02:00:45 -05:00
0575616ac2 properly implemented read builtin
fixed bugs related to redirections and compound commands

improved io routing logic
2026-02-17 17:30:21 -05:00
6055f3434d fixed empty arguments being filtered out during word splitting 2026-02-16 19:09:10 -05:00
9fea0430c8 Fixed conditional block parsing not handling command chains 2026-01-29 05:01:26 -05:00
6d6e55375c Various edge case fixes for prompt expansion and command substitution 2026-01-29 04:58:04 -05:00
222e06bee6 Added prompt escape code expansion flag to echo, -p
Added non-formatted runtime to prompt escape codes

Added prompt escape code that expands to the output of a shell function

Reworked internal logic for termios control
2026-01-29 03:46:35 -05:00
2c52a3621e renamed fern.rs back to main.rs 2026-01-28 19:57:14 -05:00
ae3c9a0445 Implemented proper variable scoping
Extracted business logic out of signal handler functions

Consolidated state variables into a single struct

Implemented var types
2026-01-28 19:30:48 -05:00
5aead4fcdc Added rustfmt.toml, formatted codebase 2025-08-12 13:58:25 -04:00
2ea91555f4 work on implementing visual mode 2025-05-30 19:06:09 -04:00
f87913697f implemented autosuggestions for the line editor 2025-05-30 01:12:18 -04:00
ded3f02cf6 removed placeholder text in prompt
cd no longer panics if the given directory doesn't exist (wtf?)
2025-05-29 01:29:25 -04:00
ca6e8de50b Reduced the amount of time that file redirections stay open 2025-05-19 00:03:50 -04:00
645cf82ac9 about to implement readline myself 2025-05-15 00:53:39 -04:00
cdc9284c15 properly implemented $(( )) substitution 2025-05-14 16:35:04 -04:00
4144a15b0b more unit tests, better highlighting 2025-05-13 20:22:25 -04:00
c0743e473c added arithmetic substitution 2025-05-13 13:08:53 -04:00