I want to make some simple scripts work in NT cmd.exe and in bash. Looks like I can do it if I will make bash understand %1 %2 %* etc as valid $1 $2 $*. May be,there is some easy way to do it?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
It is generally a very bad idea to run the same script on compilers targeting different coding languages, what you’re doing is like running javascript code on flash actionscript, sure, the syntax is similar but they’re not the same…
What you could however do is install bash in windows :
http://win-bash.sourceforge.net/
Or installing wine in linux (generally a worse idea)…
The best practice is probably coding it in something that is designed to work cross platform like python