Restoring a Deleted File
In this episode, we will explore how to restore a deleted file.
Transcript
With Git as your version control system, you cannot only undo modifications in a file - you can also restore files that you’ve deleted.
In our example scenario, you can see that we’ve deleted "about.html" - and let’s say that we want to have it back.
In Tower’s working copy view, you can simply right-click a deleted file - then select the “discard local changes” option and confirm that.
And that’s it: we just restored a deleted file - and it’s again part of our project’s files.
Course outlineEpisode 2 of 17
- Discarding All Local Changes in a File
- Restoring a Deleted File
- Discarding Chunks / Lines in a File
- Discarding All Local Changes
- Fixing the Last Commit
- Reverting a Commit in the Middle
- Resetting to an Old Revision
- Resetting a File to an Old Revision
- Recovering Deleted Commits
- Recovering a Deleted Branch
- Moving a Commit to a New Branch
- Moving a Commit to a Different Branch
- Editing Old Commit Messages
- Deleting Old Commits
- Squashing Multiple Commits into One
- Adding a Change to an Old Commit
- Splitting / Editing an Old Commit