I can't find the debug.keystore file
Asked Answered
P

4

52

I'm having an error with Eclipse and Android's SDK. apparently, it comes from the fact that my certificate expired. So I googled the error and I found that I have to remove the ~/.android/debug.keystore file. The thing is I can't find this file. It's not in my SDK.

Can someone help me with this ?

Edit: I work on Mac.

Prowel answered 22/2, 2012 at 15:43 Comment(3)
Which OS are you running? ~/.android/debug.keystore will only work on unix like operating systemsAgglomerate
and %USERPROFILE%\.android\debug.keystore will work on windowsRivulet
OSX 10.6 If I remember correctly.Prowel
F
121

Open Eclipse Preferences, then navigate to Android > Build. There you'll see a field that tells the location of your debug keystore.

Footboard answered 22/2, 2012 at 16:16 Comment(1)
Where is it in android studioEducator
K
25

On Linux / OSX use your favorite terminal and type rm ~/.android/debug.keystore to remove the debug keystore.

You can create a new keystore after that by following these steps.

Karsten answered 22/2, 2012 at 15:45 Comment(1)
the thing is with the cd command, I manage to go to smthg like ~/Documents/Work/Workspace/SDK Android(which is where i put my android sdk)/.DS_Store and there, when i push tab there is the .android/debug.keystore file. But it makes no sense, it seems to be in a file.Prowel
W
3

I believe it is in the .android/avd/ directory in OSX, but it could also be just in /.android/ as you suggest.

Remember that ~ means your home directory, so you do not need to look for it in your SDK!

(disclaimer) It's been a while since I've battled with this, and I didn't do it on a mac.

Wilda answered 22/2, 2012 at 15:49 Comment(0)
W
2

Expiry of the Debug Certificate

The self-signed certificate used to sign your application in debug mode (the default on Eclipse/ADT and Ant builds) will have an expiration date of 365 days from its creation date.

When the certificate expires, you will get a build error. On Ant builds, the error looks like this:

debug: [echo] Packaging bin/samples-debug.apk, and signing it with a debug key... [exec] Debug Certificate expired on 8/4/08 3:43 PM In Eclipse/ADT, you will see a similar error in the Android console.

To fix this problem, simply delete the debug.keystore file. The default storage location for AVDs is in ~/.android/ on OS X and Linux, in C:\Documents and Settings\.android\ on Windows XP, and in C:\Users\.android\ on Windows Vista and Windows 7.

Source: Android Publishing Guide: http://developer.android.com/guide/publishing/app-signing.html

Wonky answered 22/2, 2012 at 15:52 Comment(1)
Yeah I know all this. The thing is, there is no debug.keystore file in mine. And that's my problem btw...Prowel

© 2022 - 2024 — McMap. All rights reserved.