TrFile_ExecuteShell

2 messages Options
Embed this post
Permalink
FileMaker Lists

TrFile_ExecuteShell

Reply Threaded More More options
Print post
Permalink
Hi folks -

Mac 0S 10.5.8, FMPA 10, Troi File 4.0

I'm using TrFile_ExecuteShell to run two different shell commands from  
FMP.  One of the shell commands (md5 - generate checksum on a file)  
works from FMP, as well as from Terminal.  The other shell command  
(MediaInfo, http://mediainfo.sourceforge.net/) works from Terminal,  
but not from FileMaker.  I've copied the exact text from terminal  
(after having successfully run the command) into the Set Variable  
script step in FM:

TrFile_ExecuteShell( "" ; "mediainfo -f output=XML --LogFile=/volumes/
[dir]/[filename.txt] /volumes/[dir]/[filename.mpg]" )

I've tried both commands on the same file, and have tested several  
files.  In all cases, running either command in Terminal works  
perfectly, running md5 from FMP works perfectly, but running mediainfo  
from FMP does not return a result (including any sort of error code.)

The command should save a .txt file, and when run in Terminal, it  
displays the result in Terminal as well as saving the file.

Any ideas why a shell command will return no results using  
TrFile_ExecuteShell, when it returns good results when run from  
Terminal?  Oh, and I don't think it's timing out, but I tried running  
it with "-DontWaitOnResult" and "-TimeoutSecs=10", with no better luck.

Thanks,

-Katherine
_______________________________________________
The Troi plug-list mailing list
[hidden email]
http://mail.troi.com/mailman/listinfo/plug-list_troi.com
Julio Plasencia

Re: TrFile_ExecuteShell

Reply Threaded More More options
Print post
Permalink
Hello, you may need to put the full path of the media info file in
order to get that to work. I ran into a similar issue when using a
similar tool called exiftool.

Julio

On Thursday, October 1, 2009, FileMaker Lists <[hidden email]> wrote:

> Hi folks -
>
> Mac 0S 10.5.8, FMPA 10, Troi File 4.0
>
> I'm using TrFile_ExecuteShell to run two different shell commands from FMP.  One of the shell commands (md5 - generate checksum on a file) works from FMP, as well as from Terminal.  The other shell command (MediaInfo, http://mediainfo.sourceforge.net/) works from Terminal, but not from FileMaker.  I've copied the exact text from terminal (after having successfully run the command) into the Set Variable script step in FM:
>
> TrFile_ExecuteShell( "" ; "mediainfo -f output=XML --LogFile=/volumes/[dir]/[filename.txt] /volumes/[dir]/[filename.mpg]" )
>
> I've tried both commands on the same file, and have tested several files.  In all cases, running either command in Terminal works perfectly, running md5 from FMP works perfectly, but running mediainfo from FMP does not return a result (including any sort of error code.)
>
> The command should save a .txt file, and when run in Terminal, it displays the result in Terminal as well as saving the file.
>
> Any ideas why a shell command will return no results using TrFile_ExecuteShell, when it returns good results when run from Terminal?  Oh, and I don't think it's timing out, but I tried running it with "-DontWaitOnResult" and "-TimeoutSecs=10", with no better luck.
>
> Thanks,
>
> -Katherine
> _______________________________________________
> The Troi plug-list mailing list
> [hidden email]
> http://mail.troi.com/mailman/listinfo/plug-list_troi.com
>

_______________________________________________
The Troi plug-list mailing list
[hidden email]
http://mail.troi.com/mailman/listinfo/plug-list_troi.com