I have housekeeping script which is running on Redhat operating system.
I have a requirement where i want to run the same script in the Windows environment.
So i have 3 options
- Write a new script for windows
- Convert Linux script in to windows script using some tool.
- Use Cygwin and run the script without making any change to the linux script.
So i want to know what would be the best option to select.
Thanks in advance for any help
It depends on how complex the scripts are, whether you want to make changes to them and what utilities the existing ones use.
If the scripts are very complex, you will be better off keeping the original and use Cygwin.
If you want to maintain the scripts and port changes back and forth, you will want to use the original (and use Cygwin)
If the script uses some Unix utilities that have not been ported to Cygwin, you either need to do the porting yourself (to be able to keep the original scripts) or convert the scripts to use Windows equivalent (or similar) programs
So I’d recommend you using Cygwin in most cases, unless the scripts are very easy to translate to Windows batch format