aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: aMuleCMD: dos/windows batch scipt errorlevel.  (Read 2548 times)

woutermense

  • Full Member
  • ***
  • Karma: 18
  • Offline Offline
  • Posts: 154
aMuleCMD: dos/windows batch scipt errorlevel.
« on: January 14, 2010, 01:56:17 PM »

Hey all, I would like to do something like this in a batch script (see last code line):

Code: [Select]
@echo off
set link=%1
for /f "useback tokens=*" %%a in ('%link%') do set link=%%~a
echo Requesting link from server: "%link%"
echo.
"c:\Program Files (x86)\aMule\aMuleCMD.exe" /h Server /P Pass /c "add %link%"
if ERRORLEVEL 1 pause

Normally the batch sript runs and then the window automatically closes, thats okay but I would like it to remain open when something goes wrong. aMuleCMD doesnt set errorlevel so that is my feature request :)
« Last Edit: January 14, 2010, 01:59:16 PM by woutermense »
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: aMuleCMD: dos/windows batch scipt errorlevel.
« Reply #1 on: January 14, 2010, 11:21:53 PM »

Good idea.  :)
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon