visevol / GithubVisualisation

PFE028 Été 2024
MIT License
0 stars 1 forks source link

[Backend] Add RepositorySyncService #21

Closed zergov closed 1 week ago

zergov commented 1 week ago

Closes: https://github.com/visevol/GihubVisualisation/issues/10

Add the RepositorySyncService class

This class takes a Repository model, and sync its content in our database:

  1. It clones the repository in a tmp directory
  2. It calls git log on it, and saves the output in a temporary file.
  3. The service read the log files and creates Commit and CommitFileChange records for each of the commits.