fix: change subprocess.Popen calls to work on Linux too (#14689)
fix: change subprocess.Popen calls to work on Linux too (#14689)

* fix: remove 'shell=True' when calling 'git diff'

Calling subprocess.Popen() with a list of args and shell=True causes
the args to be ignored, so ['git', 'diff', '--name-only', '--staged']
was turning into just 'git'. Instead of getting a list of changed
files, we got the --help message.

Two possible fixes: change it from a list to a single string, or remove
'shell=True'. The shell doesn't seem to be needed, so I chose that.

More reading: https://stackoverflow.com/questions/26417658/subprocess-call-arguments-ignored-when-using-shell-true-w-list

* fix: remove 'shell=True' when calling clang-format

Same problem / rationale as previous commit.

* fix: re-add shell=True for win; use different fix

seanchas116/electron,the-ress/electron,electron/electron,the-ress/electron,gerhardberger/electron,bpasero/electron,gerhardberger/electron,electron/electron,gerhardberger/electron,electron/electron,electron/electron,the-ress/electron,electron/electron,the-ress/electron,gerhardberger/electron,gerhardberger/electron,seanchas116/electron,gerhardberger/electron,bpasero/electron,seanchas116/electron,electron/electron,bpasero/electron,the-ress/electron,seanchas116/electron,bpasero/electron,the-ress/electron,seanchas116/electron,gerhardberger/electron,bpasero/electron,electron/electron,bpasero/electron,the-ress/electron,bpasero/electron,seanchas116/electron