<div dir="ltr"><div dir="ltr"><div>Why don't you just use sed?</div><div>E.g. target=$(echo $source | sed "s/\/blog_web\//\/blog_src\//g")<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Mar 7, 2019 at 1:55 AM Dani <<a href="mailto:dani@damufo.com">dani@damufo.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hello:<br>
<br>
$ thunar -q && thunar<br>
<br>
The error is:<br>
<br>
/bin/sh: 1: Bad substitution<br>
<br>
The problem seems to be right where you thought, in the substitution.<br>
<br>
target="${source/\/blog_web\//$moveTo}";<br>
<br>
<br>
I even tried removing the bars in the replacement as if they were the <br>
problem and nothing.<br>
for i in %F; do source=$i; zenity --info --text=$source; <br>
moveTo="blog_src"; zenity --info --text=$moveTo; <br>
target="${source/blog_web/$moveTo}"; zenity --info --text=$target; done<br>
<br>
Very thanks<br>
<br>
Dani<br>
<br>
O 06/03/19 ás 19:29, André Miranda escribiu:<br>
> On 06/03/2019 13:05, Dani wrote:<br>
>> When run thunar from terminal, no show nothing.<br>
>> (Seems to have no verbose mode, as -> $ thunar &)<br>
> No need to append an ampersand, did you first kill the daemon <br>
> instance? Run thunar -q && thunar.<br>
><br>
>> This not work for me:<br>
>><br>
>> for i in %F; do source=$i; moveTo="/blog_src/"; <br>
>> target="${source/\/blog_web\//$moveTo}"; mv "$source $target"; done<br>
> It has to be mv "$source" "$target"<br>
><br>
>> I test with (multi select)<br>
>><br>
>> for i in %F; do source=$i; moveTo="/blog_src/"; <br>
>> target="${source/\/blog_web\//$moveTo}"; zenity --info <br>
>> --text=$source; zenity --info --text=$moveTo; zenity --info <br>
>> --text=$target; done<br>
>><br>
>> No show anything<br>
> With two files named "a" and "b", this command works for me, 6 dialogs <br>
> appear one after the other, their outputs are:<br>
> /home/andre/Downloads/blog_web/a<br>
> /blog_src/<br>
> /home/andre/Downloads/blog_src/a<br>
> /home/andre/Downloads/blog_web/b<br>
> /blog_src/<br>
> /home/andre/Downloads/blog_src/b<br>
><br>
> _______________________________________________<br>
> Thunar-dev mailing list<br>
> <a href="mailto:Thunar-dev@xfce.org" target="_blank">Thunar-dev@xfce.org</a><br>
> <a href="https://mail.xfce.org/mailman/listinfo/thunar-dev" rel="noreferrer" target="_blank">https://mail.xfce.org/mailman/listinfo/thunar-dev</a><br>
<br>
<br>
<br>
_______________________________________________<br>
Thunar-dev mailing list<br>
<a href="mailto:Thunar-dev@xfce.org" target="_blank">Thunar-dev@xfce.org</a><br>
<a href="https://mail.xfce.org/mailman/listinfo/thunar-dev" rel="noreferrer" target="_blank">https://mail.xfce.org/mailman/listinfo/thunar-dev</a><br>
</blockquote></div></div></div>