neek wrote: ⤴Thu Apr 08, 2021 5:20 am
Your script needs to check what it's being passed...
I don't understand what you mean by this.
The script works fine provided that it's used in a particular way. It doesn't give you the desired results under some other conditions.
Yes/no/true/false?
Those other conditions are caused by not invoking the script in one or more particular ways from within nemo.
Yes/no/true/false?
The script relies on the input it receives from nemo, so, in your script, you need to inspect the input that has been passed when it is called from nemo. then the script needs to take appropriate action based on that input. You need to work that out. I have now told you that three times in three different ways.
Again, my shell scripting experience is limited.
I'm not writing it for you. I've given you all the clues you need to solve it yourself. Spoon-feeding is not part of my job description.