Exemplo n.º 1
0
        protected override int Execute()
        {
            var cwd = Directory.GetCurrentDirectory();

            configuration = string.IsNullOrEmpty(configuration) ? "full-build" : configuration;

            Log.Info("Updating packages");
            PackageUpdater.UpdatePackages();
            var modules = Helper.GetModules();

            var moduleName = Path.GetFileName(cwd);

            var curRepo = new GitRepository(moduleName, Helper.CurrentWorkspace, Log);

            if (curRepo.IsGitRepo)
            {
                curRepo.TryUpdateUrl(modules.FirstOrDefault(m => m.Name.Equals(moduleName)));
            }
            HooksHelper.InstallHooks(moduleName);

            var getter = new ModuleGetter(
                Helper.GetModules(),
                new Dep(moduleName, null, configuration),
                policy,
                mergedBranch,
                verbose,
                localBranchForce);

            getter.GetDeps();


            Log.Info("SUCCESS UPDATE DEPS");
            return(0);
        }
Exemplo n.º 2
0
        public void Get(string module, string treeish = null, LocalChangesPolicy localChangesPolicy = LocalChangesPolicy.FailOnLocalChanges)
        {
            var getter = new ModuleGetter(
                GetModules().ToList(),
                new Dep(module, treeish),
                localChangesPolicy,
                null);

            getter.GetModule();
            getter.GetDeps();
        }
Exemplo n.º 3
0
        private void GetModule()
        {
            var getter = new ModuleGetter(
                Helper.GetModules(),
                new Dep(module, treeish, configuration),
                policy,
                mergedBranch,
                verbose);

            getter.GetModule();

            ConsoleWriter.WriteInfo("Getting deps for " + module);
            Log.Info("Getting deps list for " + module);

            getter.GetDeps();
        }