Skip to content

Opening x-executables in yazi #2127

Closed Answered by sxyazi
echoborealis asked this question in 1. Q&A
Discussion options

You must be logged in to vote

run = './$0'

No, this is not valid shell syntax.

Running sh -c './$0' /tmp/my-executable.sh will cause an error:

$ sh -c './$0' /tmp/my-executable.sh
/tmp/my-executable.sh: .//tmp/my-executable.sh: No such file or directory

What you need is run = '"$0"':

$ sh -c '"$0"' /tmp/my-executable.sh
Works!!!

See #1673 (comment)

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@echoborealis
Comment options

Answer selected by echoborealis
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
1. Q&A
Labels
None yet
2 participants