Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

$_ should be set to the last argument #696

Closed
Crestwave opened this issue Apr 7, 2020 · 2 comments
Closed

$_ should be set to the last argument #696

Crestwave opened this issue Apr 7, 2020 · 2 comments

Comments

@Crestwave
Copy link
Contributor

Crestwave commented Apr 7, 2020

Required for #679. I'm not sure if I already had a discussion with you about this, but:

$ : 1
$ echo $_
1
osh$ : 1
osh$ echo $_
/home/usr/bin/osh
@andychu
Copy link
Contributor

andychu commented Apr 7, 2020

OK I just wrote some tests, and this is implemented in both bash and zsh. For some reason I thought it was only an interactive thing but it's not.

@andychu
Copy link
Contributor

andychu commented Apr 7, 2020

#262 is a dupe and has more info

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants