I\'m trying to add a ruby rails file to my repository in gitlab but it somehow wouldn\'t allow me to add the file saying that my file does not have commit checked out.
You don't need to delete the entire file from the directory as the first answer suggests, I just had to delete the .git directory, and then your git add . will work
This happens for the reason @Mario Zigliotto suggested, there is another repo in a subdirectory under that repo.