Dosbox-x: Running-automounting programs directly from console command "dosbox-x.exe" "%1"

Created on 16 Dec 2017  路  8Comments  路  Source: joncampbell123/dosbox-x

Hi, i'm missing very important and basic feature - running (with directory automounting to C:) programs directly from console command
for example: we have "Dosbox-x" folder and "Game" folder. I do

cd Dosbox-x
dosbox-x.exe "..\GAME\start.bat"

so it will

  1. mount GAME folder as C:
  2. run (call) start.bat
    If i want to associate dosbox-x or run it from a batch (as i always do)...
    Instead of creating new copy of .conf file every time just to change some "autoexec" strings - i prefer there will be clean "autoexec" section and i could just select bat file dosbox will be running.
    Currently it does nothing
enhancement

Most helpful comment

@WarlockSVG Good workaround. But long-term, if that is what DOSBox does, then DOSBox-X will do it too.

All 8 comments

Is this what the main DOSBox project does?

Yes, dosbox main project does it (even version 0.72), dosbox-daum too
http://picsee.net/upload/2017-12-16/07cfca0b91ae.png

Hey Corak.
You can use 2 config files to start dosbox-x
dosbox-x.exe -conf "default.conf" -conf "game??.conf"

The first will be loaded first... use it with your default settings.
The 2nde will load 2nde, it will override whatever is defined is the first config. Use it to fine tune for the specific game?? no need to have al the default.conf settings in the 2nde config. Only define in the 2nde config what is game?? specific and what needs to be different from you default setting.

This way you can use the 2nde config file to act as your start.bat using the [autoexec] section.
so you can add there

game??.conf
[autoexec]
mount C: "game?? -freesize 1024 -label RetroBOX
call play.bat
exit

@WarlockSVG Good workaround. But long-term, if that is what DOSBox does, then DOSBox-X will do it too.

@WarlockSVG thanks for advice! Good, but still i prefer .bat, because if i want to run my game on real DOS (or another virtual machine) then, i dont need to copy this strings from .conf, i will have working already gamepack with preset batches

Using the config to start your bat file will give you the same result.

dosbox-x.exe "..\GAME\start.bat"

or

dosbox-x.exe ( no %1 parrameter )
dosbox.conf
[autoexec]
mount C: "..\GAME" -freesize 1024 -label RetroBOX
C:
call "start.bat"

It just comes down to what you prefer... or what your setup layout already is ;-)

@WarlockSVG I understand, but this are not useful enough. Because:

  1. If i use want to use associated run (with quick-shortcut (using lst2str.exe) or keys in Total Commander)
    http://picsee.net/upload/2017-12-18/85f24faf3d19.png
    dosbox on ANY .bat file - i will have to auto-create .conf file for EVERY DOS .bat/exe file i'm trying to run. And if i'm trying to run it on totally write-protected drive - it will be a problem.
  2. I don't want to mess with thousands .conf files to direct them to another bat/exe files, i better just use some bat file as preset to quickstart selected exe/bat

Done.

If a .BAT file is given on the command line, it auto inserts into AUTOEXEC.BAT commands to mount the current working directory as C: and then call each BAT file one by one, then unmount drive C: and continue on to the [autoexec] section of dosbox.conf normally.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jadasse picture jadasse  路  19Comments

rangerxusa picture rangerxusa  路  13Comments

sduensin picture sduensin  路  10Comments

maximus105 picture maximus105  路  18Comments

joncampbell123 picture joncampbell123  路  14Comments