Created
July 30, 2019 17:11
-
-
Save isaacrlevin/f54b76232bd22dd8f09e83fe92fb59e4 to your computer and use it in GitHub Desktop.
Running CMD with Azure Function
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
System.Diagnostics.Process process = new System.Diagnostics.Process(); | |
string WorkingDirectoryInfo = @"D:\home\site\wwwroot\"; | |
string ExeLocation = @"D:\home\site\wwwroot\gitWork.cmd"; | |
Process proc = new Process(); | |
ProcessStartInfo info = new ProcessStartInfo(); | |
try | |
{ | |
info.WorkingDirectory = WorkingDirectoryInfo; | |
info.FileName = ExeLocation; | |
info.Arguments = ""; | |
info.WindowStyle = ProcessWindowStyle.Minimized; | |
info.UseShellExecute = false; | |
info.CreateNoWindow = true; | |
proc.StartInfo = info; | |
proc.Refresh(); | |
proc.Start(); | |
proc.WaitForInputIdle(); | |
proc.WaitForExit(); | |
} | |
catch { } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git config --global user.name 'Name' | |
git config --global user.email 'Email' | |
git clone url | |
cd folder | |
git add . | |
git commit -m 'updates' | |
git push |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment