public VersionControlSystemInfo CreateRepositoryForProject(CreateProjectRequest request) { var project = new ProjectCreate { IssuesEnabled = false, Description = request.Info, MergeRequestsEnabled = false, Name = request.Name, VisibilityLevel = request.AccessLevel == AccessLevel.Public ? VisibilityLevel.Public : VisibilityLevel.Private }; var createdProject = _gitLabClient.Projects.Create(project); return new VersionControlSystemInfo(createdProject.Id, new Uri(createdProject.WebUrl)); }
private ProjectCreate CreateProject(out Project created, string name) { var p = new ProjectCreate { Description = "desc", ImportUrl = null, IssuesEnabled = true, MergeRequestsEnabled = true, Name = name, NamespaceId = null, SnippetsEnabled = true, VisibilityLevel = VisibilityLevel.Public, WallEnabled = true, WikiEnabled = true }; created = _projects.Create(p); return p; }
public Project Create(ProjectCreate project) { return _api.Post().With(project).To<Project>(Project.Url); }