@@ -171,24 +171,26 @@ func (p *RepositoryPool) Add(repo repository) error {
171
171
return nil
172
172
}
173
173
174
- // AddGit checks if a git repository can be opened and adds it to the pool. It
175
- // also sets its path as ID.
174
+ // AddGit adds a git repository to the pool. It also sets its path as ID.
176
175
func (p * RepositoryPool ) AddGit (path string ) error {
177
176
return p .AddGitWithID (path , path )
178
177
}
179
178
180
- // AddGitWithID checks if a git repository can be opened and adds it to the
181
- // pool. ID should be specified.
179
+ // AddGitWithID adds a git repository to the pool. ID should be specified.
182
180
func (p * RepositoryPool ) AddGitWithID (id , path string ) error {
183
181
return p .Add (gitRepo (id , path ))
184
182
}
185
183
186
- // AddSivaFile adds to the pool the given file if it's a siva repository,
187
- // that is, has the .siva extension
184
+ // AddSivaFile adds a siva file to the pool. It also sets its path as ID.
188
185
func (p * RepositoryPool ) AddSivaFile (path string ) error {
189
186
return p .Add (sivaRepo (path , path ))
190
187
}
191
188
189
+ // AddSivaFileWithID adds a siva file to the pool. ID should be specified.
190
+ func (p * RepositoryPool ) AddSivaFileWithID (id , path string ) error {
191
+ return p .Add (sivaRepo (id , path ))
192
+ }
193
+
192
194
// GetPos retrieves a repository at a given position. If the position is
193
195
// out of bounds it returns io.EOF.
194
196
func (p * RepositoryPool ) GetPos (pos int ) (* Repository , error ) {
0 commit comments