Added to gitignore

!/rootfolder/js /rootfolder/js/* !/rootfolder/js/some.sale /rootfolder/js/some.sale/* !/rootfolder/js/some.sale/some_sale.js 

and pushed on master

Now go to the old branch created from the wizard before this commit (git checkout oldbranch) then if you go through ftp, you will see that this file /rootfolder/js/some.sale/some_sale.js is missing. If you create a new branch from this wizard, then in ftp will show this file. How to fix it I can not understand. I understand that the old gitignore branches do not contain these changes, and this file was added to the repo, but since in the old gitignore branches there is such a record above /rootfolder/* then it turns out that it ignores this file from the repo and does not show it on ftp. I recently started using git. I would be happy to help. I cannot update the branch from the wizard.

  • Sorry if I'm wrong, I just can't. I simply explain the fact of the error. The situation is this. There is a main repository and my local repository. I made these changes in the gigignor in the local branch and started it. Further, this commit merged with the master repo master branch and further such problem as in the description in all branches of the local repo. - Viktor
  • Made changes to files in the local test branch. git add files git commit git push Next from the master wizard of the main git merge origin / test --squash git commit - Viktor
  • if you have lost local files, then: // git stores a lot of "extra information" until you make git gc (clean up your turnips from garbage) // most likely you will be helped by git-fsck (maybe with the - unreachable key), find make the necessary commit and make a new branch of it or copy the necessary data. - strangeqargo
  • In addition, you can do git checkout репа/имя_ветки -- путь_к_файлу most likely, git checkout коммитХэш -- путь_к_файлу will work the same way - if you need to tear out a file from another git object - strangeqargo
  • Thanks, I will try - Viktor

0