Accidentally removed xcassets file from Xcode project
I just did this myself and figured out how to quickly remedy the issue.
Go to the project folder in the Finder. You should find that the
folder Images.xcassets is still there.Move it to a separate location like to the Desktop or something. It
still has all of the images and json files.Jump back to Xcode and create a new asset catalog for images.
File > New > File... > Resource > Asset Catalog
Name it Images.
Quit Xcode and return to the Finder.
Copy the folders from within your old Images.xcassets to the new
Images.xcassets directory in your project.Launch Xcode and you're back in business!
I just deleted my Images.xcassets folder from my Xcode project
What I did in the end because I had all the code and the app wasn't vary large is I made a new project and transferred everything. Then I created a git repository for if it happens again.
I accidentally deleted LaunchImage from Xcassets help? How to restore LaunchImage to xcassets
I looked around for a question that *specifically addressed this issue and couldn't find one.
Here's what you do:
- Right click in the white space under the existing image folders
(OR) click on the "+" at the bottom of the area
Now select "New Launch Image"
This will bring back the original launch image options with all the many, many new image sizes that Xcode 5 and iOS 7 need.
Like this:
Accidentally deleted .xcodeproj file how to recreate it?
If you haven't committed the deletion of the file, do the following:
- Open Terminal
cd /path/to/my/local/repo
git checkout -- myproject.xcodeproj
The folder Images.xcassets doesn't exist
You have probably set your launch images to be extracted from an asset catalog (which is 'images.xcassets' by default). If you don't want to use asset catalogs, go to your application settings and select 'don't use asset catalogs', but, if you do (I recommend you do use asset catalogs for App Icons and Launch Images), click 'create asset catalog'. If that option isn't available, right click on your project, select 'New File', go to 'Resource', and select Asset Catalog.
How to add storyboard back to xcode after accidentally deleted
- drag and drop it to Xcode's project navigator
- uncheck "Copy items if needed"
Asset Catalog Compiler Error In Xcode
If you dont have an assets in any other place even though Trash then need one 1024x1024 icon of your app to generate all assets also need to do following steps.
If you had accidently deleted the app icons folder from image assets then it will be look like this.
please dont be panic now just clean your project using Cmd+Shift+Alt+K
then it will be seems like this
Now Click on use Asset Catalogue it will show the prompt like this.
Just click on Migrate
Now there is the appIcon is present
Just click on right arrow and right click on the appIcons
Now open it in finder and make the appicon assets using the app named "Icon Set Creator" which is Free on appStore.
Once you generated all icons replace the generated folder will existing one.
Your all assets will be regenerated.
Related Topics
How to Do Transforms on a Calayer
Changing the Status Bar Text Color in Splash Screen iOS 7
Ios: Place Uiview on Top of Uitableview in Fixed Position
Editing Screenshots in Itunes Connect After iOS App Was Approved
How to Rotate an Uiimageview by 20 Degrees
Automatic Signing Is Unable to Resolve an Issue with the "Projectname" Target's Entitlements File
Url Scheme "Open Settings" iOS
Remove Uisegmentedcontrol Separators Completely. (Iphone)
How to Create Entitlement.Plist File in Xcode
Facebook Login Issue - Canopenurl: Failed for Url: "Fbauth2:///" - Error: "(Null)"
Left-Align Image and Center Text on Uibutton
Getting Video Snapshot for Thumbnail
How to Delete App Build in New Itunes Connect Site
Get Email and Name Facebook Sdk V4.4.0 Swift
Remembering Scroll Position on Uitableview
"'Cdvplugin.H' File Not Found" in Cordova as Component (Cleaver)