简体   繁体   中英

How do I restore my project to an older version in Android Studio?

I'm not using subversion or something like this, only Android Studio. I messed up some features and I need to get back to an older version of the project

How do I do it?

Right click on a class file, and select "Local History". This will also work on directories.

在应用程序模块目录上显示本地历史记录

Switch view to Android in the left part of the Android Studio, right-click the app node, Local History , Show History . Then find the revision you want back, right click it and choose Revert . Your whole project will be reverted to this state.

Switch to Project in the left part of Android Studio, right-click the application name on top, click Local History , click Show History .

Then find the revision you want back, right click it and choose Revert . Your whole project will be reverted to this state.

Another solution here suggested Switch to Android in the left menu before reverting but that will not revert the entire project . I failed using that solution.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM