holzschu / a-Shell-commands

shell commands, pre-compiled to webAssembly, ready to use in a-Shell
554 stars 21 forks source link

inline command- evaluate $( command ) #51

Open macOneOone opened 2 weeks ago

macOneOone commented 2 weeks ago

Hello @holzschu,

Is there any possibility to have inline command evaluate or $() and `` or it's a bug?

Cause I've the normal behavior when I write a shell script.

I was trying to change PS1 variable by executing > PS1=$(whoami) and the result is command not found.

Best regards.

holzschu commented 2 weeks ago

The default shell is more limited, but also with a low memory cost. If you need $() or backquoted commands, you have to use dash, which is a full implementation of sh. One key limitation of dash inside a-Shell is that you can only backquote commands or files, not functions.

macOneOone commented 2 weeks ago

Thanks