Example #1
0
 /// <inheritdoc/>
 public string CloneRemoteRepository(string org, string repository)
 {
     try
     {
         return(_decoratedService.CloneRemoteRepository(org, repository));
     }
     catch (Exception ex)
     {
         LogError(ex, "CloneRemoteRepository", org, repository);
         throw;
     }
 }
Example #2
0
        /// <summary>
        /// clone a repository.
        /// </summary>
        /// <param name="org">Unique identifier of the organisation responsible for the app.</param>
        /// <param name="app">Application identifier which is unique within an organisation.</param>
        /// <returns>The home app token page or the clone page.</returns>
        public IActionResult Clone(string org, string app)
        {
            AltinnStudioViewModel model = new AltinnStudioViewModel();
            string token = _sourceControl.GetAppToken();

            if (!string.IsNullOrEmpty(token))
            {
                _sourceControl.CloneRemoteRepository(org, app);
            }
            else
            {
                return(Redirect("/Home/AppToken"));
            }

            return(RedirectToAction("Index", new { org, app }));
        }
Example #3
0
 public string CloneRemoteRepository(string owner, string repository)
 {
     return(_sourceControl.CloneRemoteRepository(owner, repository));
 }
Example #4
0
 public IActionResult CloneRemoteRepo(string org, string repo)
 {
     _sourceControl.CloneRemoteRepository(org, repo);
     return(View());
 }