Git Autofetch

Git Autofetch is a simple software for fetching new changes from a repo to local repositories after a set time interval.

This program is responsible for checking the remote repo for changes and updating the local copy of the repo after a set delay (can be set in configs file later)


  1. Clone this repo.


  1. cd into the repo


  1. Run the This is important to create important files, and create paths dynamically.

    run python3

    This will create 3 files which are :

    S. No File Name Purpose
    1 Basic Configuration (Delay)
    2 To store the list of projects to update (local folder path)
    3 autofetch.service Service file to tell systemd to run our program in background


  1. Register Projects in the newly created

    For registering projects, you are required to add a _Project object1 in the PROJECT_LIST2, which will be available in file. You can give name, url and local path of the project as parameters to object.

    1. To create objects the syntax is as follows :


    2. Do remember to add a comma after previous _Project object, or else it will give errors. [see below image line:7]


  1. Move the newly created autofetcher.service to systemd's folders.

    run sudo mv autofetch.service /lib/systemd/system/


  1. Reload the systemd daemon.

    run sudo systemctl daemon-reload


  1. Start the service autofetcher.service

    run sudo systemctl start autofetcher


  1. Check the status of autofetcher service

    run sudo systemctl status autofetcher


  1. (optional) Enable the service autofetcher

    run sudo systemctl enable autofetcher

And you will have your autofetcher running.