mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-12-22 08:19:47 +01:00
Cleanup order of class components
This commit is contained in:
@@ -50,7 +50,13 @@ public class GitContext implements Closeable, RepositoryProvider
|
||||
private static final Logger logger =
|
||||
LoggerFactory.getLogger(GitContext.class);
|
||||
|
||||
private final GitConfig config;
|
||||
public GitContext(File directory, Repository repository, GitRepositoryConfigStoreProvider storeProvider, GitConfig config)
|
||||
{
|
||||
this.directory = directory;
|
||||
this.repository = repository;
|
||||
this.storeProvider = storeProvider;
|
||||
this.config = config;
|
||||
}
|
||||
|
||||
//~--- methods --------------------------------------------------------------
|
||||
|
||||
@@ -109,28 +115,21 @@ public class GitContext implements Closeable, RepositoryProvider
|
||||
}
|
||||
}
|
||||
|
||||
public GitContext(File directory, Repository repository, GitRepositoryConfigStoreProvider storeProvider, GitConfig config)
|
||||
{
|
||||
this.directory = directory;
|
||||
this.repository = repository;
|
||||
this.storeProvider = storeProvider;
|
||||
this.config = config;
|
||||
}
|
||||
|
||||
void setConfig(GitRepositoryConfig newConfig) {
|
||||
storeProvider.get(repository).set(newConfig);
|
||||
}
|
||||
|
||||
GitConfig getGlobalConfig() {
|
||||
return config;
|
||||
}
|
||||
|
||||
//~--- fields ---------------------------------------------------------------
|
||||
|
||||
/** Field description */
|
||||
private final File directory;
|
||||
private final Repository repository;
|
||||
private final GitRepositoryConfigStoreProvider storeProvider;
|
||||
|
||||
GitConfig getGlobalConfig() {
|
||||
return config;
|
||||
}
|
||||
private final GitConfig config;
|
||||
|
||||
/** Field description */
|
||||
private org.eclipse.jgit.lib.Repository gitRepository;
|
||||
|
||||
Reference in New Issue
Block a user