Hacker News new | ask | show | jobs
by 1f60c 2044 days ago
Would `arch -x86_64 $SHELL` work?
2 comments

In theory yes, since it inherits the shell env from the parent.

Haven't got the $$$ to test though.

EDIT: you could also craft an oneliner if $SHELL is not defined, something like:

`ps -T $$ | awk 'NR==2{print $NF}' | arch -x86_64 $0`

Just tried and it works :) .. Nice.