Class GithubRepositoryServiceImpl
java.lang.Object
com.winchesters.devopsify.service.technologies.github.GithubRepositoryServiceImpl
- All Implemented Interfaces:
GithubRepositoryService
@Service
@Transactional
public class GithubRepositoryServiceImpl
extends Object
implements GithubRepositoryService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionanalyseGithub
(Project project) analyse github repositoryorg.kohsuke.github.GHRepository
createRepository
(GithubRepositoryDto githubRepositoryDto) create a new repository in githubcreateWebHook
(Project project, String token) void
Deprecated.uses the username in github object that may not existvoid
deleteAllRepositories
(String username) void
deleteGithubRepository
(String name) Deprecated.please set the owner's namevoid
deleteGithubRepository
(String owner, String name) deletes a github repositorystatic void
-
Constructor Details
-
GithubRepositoryServiceImpl
public GithubRepositoryServiceImpl()
-
-
Method Details
-
createRepository
public org.kohsuke.github.GHRepository createRepository(GithubRepositoryDto githubRepositoryDto) throws IOException Description copied from interface:GithubRepositoryService
create a new repository in github- Specified by:
createRepository
in interfaceGithubRepositoryService
- Parameters:
githubRepositoryDto
- an object containing name, owner, autoInit, licenseTemplate, gitIgnoreTemplate attributes- Returns:
- the created repository
- Throws:
IOException
- : connection problems
-
analyseGithub
Description copied from interface:GithubRepositoryService
analyse github repository- Specified by:
analyseGithub
in interfaceGithubRepositoryService
- Parameters:
project
- the correspondent project- Returns:
- a githubAnalyseResults that contains readMe/license/gitignore ... analysis
- Throws:
IOException
- if any problem while connecting to the github api
-
test
- Throws:
IOException
-
deleteGithubRepository
deletes a github repository- Parameters:
owner
- the repository owner's namename
- the name of the repository- Throws:
IOException
- when io exceptions
-
deleteGithubRepository
Deprecated.please set the owner's name- Parameters:
name
- the name of the repository- Throws:
IOException
- when io exceptions
-
deleteAllRepositories
- Parameters:
username
- github username- Throws:
IOException
- when io exceptions
-
deleteAllRepositories
Deprecated.uses the username in github object that may not exist- Throws:
IOException
- when io exceptions
-
createWebHook
- Throws:
IOException
-
main
- Throws:
IOException
-