Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

How to? tpipe

Aug
295
1
different PC Has something changed with tpipe

: tcc v24, v25 works as expected, fails under v26 v27

set >c:\env_def_read
setlocal
unset /q *

: # Case Specific environments

set def_env=ComSpec SystemRoot path Temp TMP

do r=0 to %@dec[%@words[%def_env]]
tpipe /input=c:\env_def_read /output=c:\def_env.txt /outputappend=1 /grep=6,0,0,1,0,0,0,0,%@word[%r,,%def_env]
enddo

unset /q r def_env
set /r def_env.txt

endlocal
del /q def_env.txt env_def_read
 
This looks fishy. @WORD's first parameter is a separator list.

Code:
%@word[%r,,%def_env]
 
In v26 and v27, TPIPE apparently needs some environment variable. This one makes the output file in v24 & v25 and fails to do so in v26 & v27. It's OK in all four versions if I get rid of "unset /q *".

Code:
setlocal
echo foobar > foobar.txt
unset /q *
del /q /e foobar.2.txt
tpipe /input=foobar.txt /output=v:\foobar.2.txt /simple=5
 
I use unset /q * for a clean environment and yes it does work as expected if some specific environments are present. Those specific environments i suspect are; path and comspec although not tested.
Thanks for your reply
 
tpipe /input=yadaya /split=2,0,0,0,0,10 also fails while running in a batch file for some reason.
tried the thread option with no success
 
If APPDATA and LOCALAPPDATA are unset, TPIPE fails. That makes sense. TPIPE does some logging in both those places. And if I recall correctly, that started with TCC v26.
 

Similar threads

Back
Top