Skip to content

Make it easier to run the tool locally#565

Closed
RikkiGibson wants to merge 1 commit intodotnet:masterfrom
RikkiGibson:run-locally
Closed

Make it easier to run the tool locally#565
RikkiGibson wants to merge 1 commit intodotnet:masterfrom
RikkiGibson:run-locally

Conversation

@RikkiGibson
Copy link
Member

@RikkiGibson RikkiGibson commented Oct 19, 2019

This PR adds a /local flag to run the tool locally. It prompts you with a nice popup login window. This way you don't have to type your corporate username and password in the command line/save it in VS debug options/other bad stuff like that.

TODO: make pushing the PR branch locally work. I suspect the client credential uses a token but libgit2sharp doesn't expose any way to provide a custom header with the token for a git push. So we would have to either:

  1. send a patch to libgit2sharp to add the option (probably not that hard, since they did do the native bridging in Add CustomHeaders member to GitPushOptions libgit2/libgit2sharp#1233)
  2. just Process.Start("git", ...).WaitForExit()

/cc @JoeRobich @dibarbet @jmarolf

|| environmentStatus.Equals(EnvironmentStatus.Queued)
|| environmentStatus.Equals(EnvironmentStatus.NotStarted)
|| environmentStatus.Equals(EnvironmentStatus.Scheduled)))
if (environmentStatus != EnvironmentStatus.InProgress
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this change keeps the tool from spinning for 10 minutes waiting for a release that isn't actually happening.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need any of this release stuff at all? What is the release for?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comments make it seem like it is supposed to do symbol publishing for the build we're inserting. But it's not clear to me if that is still something that RIT users need to be worried about, or whether it's something that just happens as part of the signed build pipeline. Can you shed any light @brettfo?

}

Console.WriteLine("---PR description---");
Console.WriteLine(prDescription);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Eventually I'd like to have a dry-run flag for local testing so we can have decent experience finally getting to the bottom of #502

Copy link
Member

@dibarbet dibarbet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving so we can at least avoid the 10min delay. Should definitely followup on if we can remove the release all together though.

@RikkiGibson
Copy link
Member Author

closing in lieu of #570

@RikkiGibson RikkiGibson deleted the run-locally branch October 23, 2019 22:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants