Example #1
0
        static private bool integrateInSourceTree()
        {
            string scriptPath = Path.GetDirectoryName(Process.GetCurrentProcess().MainModule.FileName);

            try
            {
                SourceTreeIntegrationHelper.AddCustomActions(scriptPath);
            }
            catch (SourceTreeIntegrationHelperException ex)
            {
                ExceptionHandlers.Handle("Cannot integrate mrHelper in Source Tree", ex);
                return(false);
            }
            return(true);
        }
Example #2
0
        static private void integrateInGitUI()
        {
            string scriptPath = Path.GetDirectoryName(Process.GetCurrentProcess().MainModule.FileName);

            try
            {
                GitExtensionsIntegrationHelper.AddCustomActions(scriptPath);
                SourceTreeIntegrationHelper.AddCustomActions(scriptPath);
            }
            catch (GitExtensionsIntegrationHelperException ex)
            {
                ExceptionHandlers.Handle("Cannot integrate mrHelper in Git Extensions", ex);
            }
            catch (SourceTreeIntegrationHelperException ex)
            {
                ExceptionHandlers.Handle("Cannot integrate mrHelper in Source Tree", ex);
            }
        }