Skip to content

Instantly share code, notes, and snippets.

View erickogi's full-sized avatar
👨‍💻

Eric kogi erickogi

👨‍💻
View GitHub Profile
@erickogi
erickogi / performance_governor.md
Created December 18, 2024 10:16
Setting Up Performance CPU Governor in Ubuntu

Setting Up Performance CPU Governor in Ubuntu

This guide explains how to permanently set your CPU governor to performance mode in Ubuntu for maximum performance.

Prerequisites

Install the required CPU power management tools:

sudo apt install linux-tools-common linux-tools-generic
@erickogi
erickogi / Apple_mobile_device_types.txt
Created August 14, 2020 12:52 — forked from adamawolf/Apple_mobile_device_types.txt
List of Apple's mobile device codes types a.k.a. machine ids (e.g. `iPhone1,1`, `Watch1,1`, etc.) and their matching product names
i386 : iPhone Simulator
x86_64 : iPhone Simulator
iPhone1,1 : iPhone
iPhone1,2 : iPhone 3G
iPhone2,1 : iPhone 3GS
iPhone3,1 : iPhone 4
iPhone3,2 : iPhone 4 GSM Rev A
iPhone3,3 : iPhone 4 CDMA
iPhone4,1 : iPhone 4S
iPhone5,1 : iPhone 5 (GSM)
# Project-wide Gradle settings.
# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.
# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
org.gradle.jvmargs=-Xmx1536m
# When configured, Gradle will run in incubating parallel mode.
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlin-kapt'
apply plugin: 'com.google.gms.google-services'
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext.kotlin_version = '1.3.20'
repositories {
google()
jcenter()
maven { url "https://jitpack.io" }
maven { url "https://repository.jboss.org/nexus/content/repositories/thirdparty-releases" }
$_json_data_decoded = json_decode($_callbackData, true);
$_json_data_encoded = json_encode($_json_data_decoded);
$_json_data_encoded_decoded = json_decode($_json_data_encoded, true);
$_merchantRequestID = $_json_data_encoded_decoded["Body"]["stkCallback"]["MerchantRequestID"];
$_checkoutRequestID = $_json_data_encoded_decoded["Body"]["stkCallback"]["CheckoutRequestID"];
$_resultCode = $_json_data_encoded_decoded["Body"]["stkCallback"]["ResultCode"];
package com.kogicodes.sokoni.utils.slider.Transformers;
import android.view.View;
import com.nineoldandroids.view.ViewHelper;
public class AccordionTransformer extends BaseTransformer {
@Override
protected void onTransform(View view, float position) {
package com.kogicodes.sokoni.utils.Badge;
import android.graphics.PointF;
import android.graphics.drawable.Drawable;
import android.view.View;
public interface Badge {
int getBadgeNumber();
SIGN IN
import android.app.Application
import android.content.Context
import androidx.lifecycle.LiveData
import androidx.lifecycle.MutableLiveData
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.GlobalScope
import kotlinx.coroutines.launch
import retrofit2.Call
package com.kogicodes.sokoni.view.ui.auth
import android.app.Application
import androidx.lifecycle.AndroidViewModel
import androidx.lifecycle.LiveData
import androidx.lifecycle.MediatorLiveData
class AuthViewModel(application: Application) : AndroidViewModel(application) {
internal var signInRepository: SignInRepository
internal var signUpRepository: SignUpRepository