My ci jobs leave unwanted files that cause a later git checkout in the same runner to fail.
Trying to remove those files in the before_script is not helping, because before_script is executing after git checkout.
Is it possible to run a command before the git checkout?
Alternatively, how do I cleanup after a job is executed, regardless of its success or failure?
right now I have to manually go into the runner file system and remove leftover files.
On runner side you can use the commands pre_clone_script for executing scripts before cloning.
Cleanup jobs I usually run in my CI Jobs with after_script.