public async Task<CommitDetails> GetNewCommitMessage(CommitDetails details)
		{
			var settings = LoadSettings();

			var authenticated = await AuthController.LogIn(settings);

			if (!authenticated)
			{
				await MessageBoxService.ShowMessage("Failed to authenticate. Please check your API key.");
				return details;
			}

			SaveSettings(settings);

			var story = await StoryListController.SelectStory(settings);

			if (story == null)
			{
				return details;
			}

			return new CommitDetails
				{
					Message = string.Format("[#{0}] {1}", story.Id, details.Message)
				};
		}
Beispiel #2
0
        public string GetCommitMessage2(IntPtr hParentWnd, string parameters, string commonUrl, string commonRoot, string[] pathList, string originalMessage, string bugId, out string bugIdOut, out string[] revPropNames, out string[] revPropValues)
        {
            var commitDetails = new CommitDetails
                {
                    Message = originalMessage
                };

            var newCommitDetails = BugTrackProvider.GetNewCommitMessage(commitDetails).Result;

            bugIdOut = null;
            revPropNames = new string[0];
            revPropValues = new string[0];
            return newCommitDetails.Message;
        }