Before hearing of git I was doing a manual version control. Basiclly I would copy a full directory with my code files in it and give it a new name like “Project 1.2 version with that new feature”. Then I installed git and created a local repository with Atom. There were 190 unstaged changes and I was like “What no I don’t want to change my files” so I clicked “discard all” and this deleted all my files. So I used undo last discard and it restored them. Except that it restored ALL the files with the same name from one identical file, of course, an old one. So now ALL my files are the same inside all the 1.x versions. This is catastrophic my research was erased, I don’t know what to do. I though it could only change your files when using commit, which I never did since I never even logged in. I was trying to secure my work and instead it brought me back months ago !
EDIT: Clearer explanation
My project directory looked like this:
> My Project
> Module 1.1
> Module 1.2
I would accumulate versions by duplicating the “Module” directory. So exactly what I did was (in Atom):
I selected the “My Project file”, went to the git tab and clicked _create repository. _This added a .git directory in My Project.
190 Unstaged changes appeared in the git tab. I clicked discard all changes(i.e. the stupid thing to do). This deleted all the .jl files in all my Module directories.
I clicked on undo last discard and this restored them.
But this did not restore them as they used to be. All the files “morecode.jl” (e.g.) are now identical and it somehow selected a random one among all the existing ones in the project.
I’m on windows, I only used atom to do the git operations (not bash).
Please I’m desperate for a solution.