Exemple #1
0
        public static void PackageManager(ITentacleManagerService tentacleManagerService, ICoreConfig config, IList <string> commands, bool useCatch = false, bool force = false, string defaultGitBranch = "")
        {
            if (defaultGitBranch == "")
            {
                defaultGitBranch = TentaclesManagerVars.TENTACLES_DEFAULT_BRANCH;
            }

            try
            {
                if (commands.Contains(ConfigVars.TENTACLES_FORCE_CONFIRM_PARAM) == true)
                {
                    force = true;
                    commands.Remove(ConfigVars.TENTACLES_FORCE_CONFIRM_PARAM);
                }

                var tentacleManager = tentacleManagerService.CreateTentacleManager(config);
                tentacleManager.ParseCommands(commands, force, defaultGitBranch);
            }
            catch (Exception exc)
            {
                if (useCatch == false)
                {
                    throw new Exception(exc.Message);
                }
            }
        }
Exemple #2
0
        public CoreService(ILoggingService loggingService, ITentacleManagerService tentacleManagerService)
        {
            this.loggingService         = loggingService;
            this.tentacleManagerService = tentacleManagerService;

            // Set decimal separator to a dot for all cultures
            var cultureInfo = new CultureInfo(CultureInfo.CurrentCulture.Name);

            cultureInfo.NumberFormat.NumberDecimalSeparator = ".";
            CultureInfo.DefaultThreadCurrentCulture         = cultureInfo;
            CultureInfo.DefaultThreadCurrentUICulture       = cultureInfo;
        }