Hirad on Nostr: If you use bash or zsh shells, you can access the argument of previous command by ...
If you use bash or zsh shells, you can access the argument of previous command by using $_.
For example:
mkdir folder && CD $_
systemctl restart sshd && systemctl status $_
touch file && chmod +x $_ && vim $_
#GNU #Linux #Terminal
Published at
2023-08-19 14:53:02Event JSON
{
"id": "421b4e5ee7ecdd669e293a0032067e3e48851b3a813b2127705dea1b8764d34c",
"pubkey": "d31dc07fa9dc3dde3a21b52b4acc5fdbdceceb91729f8f92a99746f7a51507ed",
"created_at": 1692456782,
"kind": 1,
"tags": [
[
"t",
"gnu"
],
[
"t",
"linux"
],
[
"t",
"terminal"
],
[
"proxy",
"https://m.hirad.it/users/hirad/statuses/110916847723845605",
"activitypub"
]
],
"content": "If you use bash or zsh shells, you can access the argument of previous command by using $_. \nFor example: \nmkdir folder \u0026\u0026 CD $_\nsystemctl restart sshd \u0026\u0026 systemctl status $_\ntouch file \u0026\u0026 chmod +x $_ \u0026\u0026 vim $_\n\n#GNU #Linux #Terminal",
"sig": "933daf9b608e3ca9ab8f0c19dfbd46432568f5a2252133117b20891aa404e427f824754eeeb7c19e9885c33d3e0318947f5ad1770b27c14bcbfce601b4f1d3e7"
}