This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//First you need to activate the Google+ API in Google Cloud Console and create a Project. Submit your SHA1 fingerprint ,package name in the newly formed ClientID . Remember - need to create a public key as well. | |
import java.io.Console; | |
import java.io.InputStream; | |
import org.json.JSONException; | |
import org.json.JSONObject; | |
import android.app.Activity; | |
import android.content.Intent; | |
import android.content.IntentSender.SendIntentException; | |
import android.graphics.Bitmap; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
To check the ssh key already in the system : ls -al ~/.ssh | |
To generate the new SSH key : ssh-keygen -t rsa -C "your_email@example.com" | |
Press enter , enter for the all the prompt. | |
Check connectivity with github : ssh -T git@github.com |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ curl ifconfig.me | |
(ip address) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
To get android key hash code follow these steps | |
Download the openssl for windows | |
now unzip to c drive | |
open cmd prompt | |
type cd C:\Program Files\Java\jdk1.6.0_26\bin | |
then type only | |
keytool -export -alias myAlias -keystore C:\Users\your user name\.android\myKeyStore | C:\openssl-0.9.8k_WIN32 \bin\opens sl sha1 -binary | C:\openssl-0.9.8k_WIN32\bin\openssl enc -a -e |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In the terminal : | |
1> cd /usr/lib/jvm/java-7-openjdk-amd64/bin | |
2> keytool -list -v -keystore ~/.android/debug.keystore -alias androiddebugkey -storepass android -keypass android |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LatLng HAMBURG = new LatLng(53.558, 9.927); | |
LatLng KIEL = new LatLng(53.551, 9.993); | |
GoogleMap map = ((MapFragment) getFragmentManager().findFragmentById(R.id.map)).getMap(); | |
if (map !=null){ | |
Log.d("FUApp", "Map isnt null"); | |
Marker hamburg = map.addMarker(new MarkerOptions().position(HAMBURG).title("Hamburg")); | |
Marker kiel = map.addMarker(new MarkerOptions() | |
.position(KIEL) | |
.title("Kiel") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CameraPosition cameraPosition = new CameraPosition.Builder().target(latlng).zoom(14.0f).build(); | |
CameraUpdate cameraUpdate = CameraUpdateFactory.newCameraPosition(cameraPosition); | |
map.moveCamera(cameraUpdate); |
OlderNewer