You are not logged in.
Pages: 1
Hi,
I might be missing something but I can not figure out how to pass "Only" the selected directories either directly or to a bash script. It always seems to grab "All" the directories in the current directory I'm working in.
In this case, it works on all directories even using %d.
<action>
<icon>/home/akovia/bin/FontRename4/FontRename4_48x.png</icon>
<name>FontRename4</name>
<unique-id>1447892031263855-26</unique-id>
<command>terminator --profile stayopen --geometry 1280x720+820+150 --borderless -x java -jar /home/akovia/bin/FontRename4.jar -h1 -m3 -s %d | tee -a fontrename4.log</command>
<description>Rename Fonts </description>
<patterns>*</patterns>
<directories/>
</action>
Also,
I am having a hard time following the logic of how these commands flow as I can't seem to send stdout to both the terminal and to a log file. I tried using ">>" before piping with tee, but in both cases it creates an empty file.
Lastly,
not sure if it's possible, but I would also like to be able to work on only selected Directories OR selected files with the same CA.
Help with any of these would be greatly appreciated.
Arch Linux
Offline
Hi,
I might be missing something but I can not figure out how to pass "Only" the selected directories either directly or to a bash script. It always seems to grab "All" the directories in the current directory I'm working in.
In this case, it works on all directories even using %d.
Use %F to get only the selected directories.
Also,
I am having a hard time following the logic of how these commands flow as I can't seem to send stdout to both the terminal and to a log file. I tried using ">>" before piping with tee, but in both cases it creates an empty file.
I can't get the tee to work either. I'll see if I can figure out why.
Lastly,
not sure if it's possible, but I would also like to be able to work on only selected Directories OR selected files with the same CA.
%F will do this provided that you select all of the check boxes in the "Appearance Conditions" tab and set "File Pattern" to "*"
Consider the following example:
<action>
<icon></icon>
<name>dir par test</name>
<unique-id>1447895896531597-7</unique-id>
<command>/home/toz/Downloads/tmp/ca %F</command>
<description>dir par test</description>
<patterns>*</patterns>
<directories/>
<audio-files/>
<image-files/>
<other-files/>
<text-files/>
<video-files/>
</action>
...where the ca executable contains:
#!/bin/bash
for par in $@
do
echo "$par" >> /tmp/par.log
done
This will print out all the selected files and directories.
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Offline
Thank you so much ToZ!
I'm eager to hear if you come up with anything on the tee problem, but you've already been infinitely helpful.
Cheers
Arch Linux
Offline
Pages: 1
[ Generated in 0.011 seconds, 7 queries executed - Memory usage: 529.71 KiB (Peak: 531.85 KiB) ]