Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help translating from bash?

Status
Not open for further replies.

heintze

Programmer
Nov 19, 2005
61
US
I have some bash things I need to translate into either powershell or cmd.exe. Can you tell me how to translate

(1) myProgramThatReadsFromStdIn <<EOF
data read by program
last line of data read by by program from standard input
EOF
anotherCommand.exe

(2) myProgram >"myProgram_`date`.log"

This will give me a unique log file everytime I run myProgram.exe.

(3) export Result="`perl xyz.pl`"
How can I get the results of a program so I can use it in a .bat or .cmd file?

Thanks,
siegfried
 
Try googling Bash on Windows.. there are a few packages out there that can help you run your scripts natively without translating to Powershell or WSH
 
I'm not sure I understand your comment. I'm already running gnu/cygwin bash on windows and it works great (except it does not meet my clients requirements). I need to translate the bash scripts to powershell, cmd.exe or WSH.

My client is microsoft and they are kinda partial to their software, even if cygwin/gnu is free.

Thanks,
Siegfried
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top