[ansible-project] Run exe file with spaces in the filename using Win Command

2021-08-20 Thread david.burt...@bmt.ky
I'm trying to run an exe with a space in the filename using the Win Command module. For example 'filenames with spaces.exe' I have other playbooks that use win command to run exe files, but those files don't have spaces in the filename, but this isn't an option for this particular scenario u

Re: [ansible-project] Run exe file with spaces in the filename using Win Command

2021-08-20 Thread vinoth kumar
Hi, You can try escaping or store the file names in register and pass register through loop to run your executable files. //Vinoth On Fri 20. Aug 2021 at 17:30, david.burt...@bmt.ky wrote: > I'm trying to run an exe with a space in the filename using the Win > Command module. > > For example 'f

Re: [ansible-project] Run exe file with spaces in the filename using Win Command

2021-08-22 Thread jbor...@gmail.com
If the path to the executable has a space you need to quote it, unfortunately yaml makes that a bit more difficult as whatever quote you start the value on you also need to end with that quote. There are 2 solutions I recommend to you: * Wrap the whole value in a single quote and use an inner d

Re: [ansible-project] Run exe file with spaces in the filename using Win Command

2021-08-23 Thread david.burt...@bmt.ky
Thanks! I ended up just quoting those names in the shell ==> win_command: '"file name with spaces.exe"' On Sunday, August 22, 2021 at 2:19:08 PM UTC-5 jbor...@gmail.com wrote: > If the path to the executable has a space you need to quote it, > unfortunately yaml makes that a bit more difficult