News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

i need script advice

Started by daydreamer, December 02, 2022, 09:52:25 AM

Previous topic - Next topic

daydreamer

I want add things to make.bat or separate .bat
Usual is commands to assemble .asm file
Seen delete commands if previous .obj and .exe exists
I dont know to make copy of .asm file and rename it to .txt file in .bat file ?
Is possible?

Is it possible do this also with
Sourcecode\ folder together with all subfolders ,each an asm project folder ,type something in console ?

my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

zedd151

easy peasy, use the 'copy' command

copy filename.asm filename.txt


Can be added to the makeit.bat (or whatever batch file name) file, and will make the copy when assembling. I tested it on the 'minimum' example from Masm32 SDK before posting this. It copied 'minimum.asm to minimum.txt' without any problem.

zedd151

Quote
Is it possible do this also with
Sourcecode\ folder together with all subfolders ,each an asm project folder ,type something in console ?


Do you mean a recursive copy of all .asm files to .txt files, included in sub folders as well? Would probably be better to investigate using 'xcopy' as that is a bit more involved than the simple 'copy' example I gave above.

It's been a long time since I have used those commands.

daydreamer

Thanks zedd :thumbsup:
I added copy "x.asm x.txt"to makeit.bat after all ifs that check for assembly error and link error
Going to create revert.bat in same folder
Copy "x.txt x2.asm"
Now i can edit code in any text editor on any device i have
Found out my Samsung tablet also had simple text editor "db text editor"

my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

Vortex

Hi daydreamer,

A very good tool for advanced scripting :

https://frippery.org/busybox/

QuoteBusyBox is a single binary that contains many common Unix tools. It's often found in embedded Linux systems like routers, in Android smartphones, in Linux containers and anywhere else it would be handy to have a compact set of Unix command line tools.

busybox-w32 is a port of BusyBox to the Microsoft Windows WIN32 API. It brings a subset of the functionality of BusyBox to Windows in a single self-contained native executable.