git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git
cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git
cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
package com.emil.android.util; | |
import android.content.Context; | |
import android.net.ConnectivityManager; | |
import android.net.NetworkInfo; | |
import android.telephony.TelephonyManager; | |
/** | |
* Check device's network connectivity and speed | |
* @author emil http://stackoverflow.com/users/220710/emil |
package com.mu.tools; | |
import android.annotation.TargetApi; | |
import android.content.Context; | |
import android.content.ContextWrapper; | |
import android.content.res.Configuration; | |
import android.os.Build; | |
import java.util.Locale; |
import Alamofire | |
func makeGetCallWithAlamofire() { | |
let todoEndpoint: String = "https://jsonplaceholder.typicode.com/todos/1" | |
Alamofire.request(todoEndpoint) | |
.responseJSON { response in | |
// check for errors | |
guard response.result.error == nil else { | |
// got an error in getting the data, need to handle it | |
print("error calling GET on /todos/1") |