How to check git version when streamlit starts & include on each page

Hi, I want to run a simple bash subprocess that gets my git repo describe info every time (and only when) streamlit detects a refreshed file, then display it somewhere unobtrusively on every page. How could I do that?