After searching a lot I did this to move a dir to git ignore which was included in git:
step1: Adding folder in .gitignore: test/ step2: running: git rm --cached -r -- test/ step3: add and commit & Push
Now when I am creating a MR it is showing delete changes for test folder contents. So this means it will delete my changes in git but I dont want to delete it. I want to just add it in gitignore.
Please let me know how to do this so that I it can be gitignore in my remote as well.
PS: I do want to add this in gitignore. I am just wondering that if I create a MR for my live site and then pull the above commit so will it remove the test folder or only make this gitignore while the folder will present there
Also please let me know when we want to make any folder git ignore then should we need to do the steps both local and server separately?
My main question is this how can I safely gitignore this without deleting it on server and local both.
Thanks