swh.loader.git.from_disk module#
- class swh.loader.git.from_disk.GitLoaderFromDisk(*args, **kwargs)[source]#
- Bases: - BaseGitLoader- Load a git repository from a directory. - prepare()[source]#
- Second step executed by the loader to prepare some state needed by
- the loader. 
- Raises
- NotFound exception if the origin to ingest is not found. 
 
 
- class swh.loader.git.from_disk.GitLoaderFromArchive(*args, **kwargs)[source]#
- Bases: - GitLoaderFromDisk- Load a git repository from an archive. - This loader ingests a git repository compressed into an archive. The supported archive formats are - .zipand- .tar.gz.- From an input tarball named - my-git-repo.zip, the following layout is expected in it:- my-git-repo/ ├── .git │ ├── branches │ ├── COMMIT_EDITMSG │ ├── config │ ├── description │ ├── HEAD ... - Nevertheless, the loader is able to ingest tarballs with the following layouts too: - . ├── .git │ ├── branches │ ├── COMMIT_EDITMSG │ ├── config │ ├── description │ ├── HEAD ... - or: - other-repo-name/ ├── .git │ ├── branches │ ├── COMMIT_EDITMSG │ ├── config │ ├── description │ ├── HEAD ...