Update GitClient to prevent the `push` command from being run in dryMode. PR Close #41387
Create utility functions for adding a dry-run flag and checking the environment for a dry run mode. PR Close #41387