Rewriting your git history, removing files permanently
see this great article at https://blog.gitguardian.com/rewriting-git-history-cheatsheet/ Steps: 1) Install newest git version (as git >= 2.22.0 is required) For Ubuntu, this PPA provides the latest stable upstream Git version: add-apt-repository ppa:git-core/ppa apt update; apt install git see: https://git-scm.com/download/linux 2) install git-filter-repo python3 -m pip install –user git-filter-repo 3) Do it – here remove the file git filter-repo –use-base-name –path [FILENAME]...