Go Back   FlashFXP Forums > > > >

ioFTPD General New releases, comments, questions regarding the latest version of ioFTPD.

Reply
 
Thread Tools Rate Thread Display Modes
Old 08-13-2010, 04:49 PM   #1
BoNeZz
Member
ioFTPD Foundation User
 
Join Date: Feb 2004
Posts: 39
Default It's possible execute a .bat ?

Hi

i need to execute this makerls.bat
Code:
E:\VirtualDub-1.9.9\virtualdub.exe /s G:\2.vcf /p"original.avi","saved.avi" /r /c /x
ioftpd.ini i set up:
Code:
makerls = EXEC C:\ioFTPD\scripts\makerls.bat MAKERLS

but when i execute it, it can't find original.avi, so needed a command that execute a bat into a folder where i put it

so if i put in my ftp:
Code:
 /TV/episode1/original.avi
audio.mp3 and makerls.bat
if i execute makerls.bat, works, because it find original.avi, but if i try to execute this bat via raw in ftp, can't find original.avi, because execute this bat in C:\ioFTPD\scripts\makerls.bat
BoNeZz is offline   Reply With Quote
Old 08-13-2010, 04:53 PM   #2
o_dog
Senior Member
 
Join Date: May 2007
Posts: 692
Default

anyone know the legal status of the scripts that was hosted on the site before? Is it ok to put them up or will people start *****ing about copyright?
__________________
ioNiNJA
o_dog is offline   Reply With Quote
Old 08-13-2010, 05:48 PM   #3
BoNeZz
Member
ioFTPD Foundation User
 
Join Date: Feb 2004
Posts: 39
Default

Quote:
Originally Posted by o_dog View Post
anyone know the legal status of the scripts that was hosted on the site before? Is it ok to put them up or will people start *****ing about copyright?
i don't understand your reply, anyway is a ripbox, so owner know that running these script to make rls very fast.

i hope your help
BoNeZz is offline   Reply With Quote
Old 08-13-2010, 08:22 PM   #4
Yil
Too much time...
FlashFXP Beta Tester
ioFTPD Administrator
 
Join Date: May 2005
Posts: 1,194
Default

o_dog: I think 95% of the scripts were free/public domain with ioB 2.x being the big exception. Can always check the LICENSE file if there is one.

BoNeZz: I think the problem you are having is the script, by default, runs with the current working directory set to the directory containing ioFTPD.exe. If you check out the doc/Cookies.txt file you'll find a list of all the available cookies, where they are valid, etc. In the etc/ioftpd.env file you'll find the environmental variables set up for EXEC scripts using those cookies. You can make use of those environmental variables in your .bat file which should solve your problem of determining the current real directory. This should handle any simple site commands you want to use with a .bat file like your makelrs, but probably isn't a good idea for OnEvent style stuff (see below).

Events are tricky because it's possible to do things like STOR /xvid/rel/file.r00 from a directory somewhere other than /xvid/rel. For this reason you may prefer to use a small TCL script where you can use the iTCL resolving functions to figure out the real path to the file and then have TCL call the external application...
Yil is offline   Reply With Quote
Old 08-14-2010, 07:33 AM   #5
BoNeZz
Member
ioFTPD Foundation User
 
Join Date: Feb 2004
Posts: 39
Default

Quote:
Originally Posted by Yil View Post
o_dog: I think 95% of the scripts were free/public domain with ioB 2.x being the big exception. Can always check the LICENSE file if there is one.

BoNeZz: I think the problem you are having is the script, by default, runs with the current working directory set to the directory containing ioFTPD.exe. If you check out the doc/Cookies.txt file you'll find a list of all the available cookies, where they are valid, etc. In the etc/ioftpd.env file you'll find the environmental variables set up for EXEC scripts using those cookies. You can make use of those environmental variables in your .bat file which should solve your problem of determining the current real directory. This should handle any simple site commands you want to use with a .bat file like your makelrs, but probably isn't a good idea for OnEvent style stuff (see below).

Events are tricky because it's possible to do things like STOR /xvid/rel/file.r00 from a directory somewhere other than /xvid/rel. For this reason you may prefer to use a small TCL script where you can use the iTCL resolving functions to figure out the real path to the file and then have TCL call the external application...
thanks for the reply yil.

i tried to see cookies and env file, but i don't understand how to insert in .bat a (variable?) to catch realpath, also because should be batch code, env and cookies works in ioftpd, but if i launch my .bat, execute bath code, and not ioftpd code, (maybe i wrong)

itcl for me is a little bit hard, because i don't have necessary skills to make it, anyway stor question don't scare me eheh

at the moment i tried this:
Code:
E:\VirtualDub-1.9.9\virtualdub.exe /s G:\2.vcf /p"%2","%3" /r /c /x

rename C:%3 Renamed.avi
and i launched in ftprush ( i know i don't use flashfxp, but i prefer rush ), this raw:

Code:
site makerls %p%f %pmuxato.avi
%f filename selectioned
%p current path

with it i can execute with full path and i can mux audio and video, but, there is alwaya a but, when i try to rename, not works, because rename in dos\batch, want backslash \ and not forwardslash / ( forwardslash that is a path, catched from ftprush ). then isn't good this solution that i found, also because after rename, script delete mp3 and old avi, make a rar from this renamed avi, make sfv, and sample. but without realpath of course, isn't possible.

i tried also:
Quote:
@echo off
set y=%2
set y=%y:/=\%
echo ren %y% renamed.avi
with this code, execute the right command! ( because convert / with \ ) finally... no really.... because not renamed... but if i paste it and i execute in dos prompt.... works.... how it's possible if execute the same command

ftplog from this test:
Quote:
(15:42:15) [1] site makerls C:/MYFTP/My.TV.S01E01/original.avi
(15:42:15) [1] 200-ren C:\MYFTP\My.TV.S01E01\original.avi renamed.avi
(15:42:15) [1] 200 Command successful.
i hope in you, you are the only that helped me always

Quote:
Originally Posted by o_dog View Post
anyone know the legal status of the scripts that was hosted on the site before? Is it ok to put them up or will people start *****ing about copyright?
i understand you point of view when i read yil reply.
anyway, i see in your site that you have inserted donations.

im foundation member, some years ago i supported ioftpd cause, so it isn't a problem support you now, ( i hope maybe you implemented makerls in new ioninja eheheh, joke, but would be great )

Last edited by BoNeZz; 08-14-2010 at 08:46 AM.
BoNeZz is offline   Reply With Quote
Reply

Tags
bat, execute, find, ftp, makerls.bat

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 11:35 AM.

Parts of this site powered by vBulletin Mods & Addons from DragonByte Technologies Ltd. (Details)