Skip to content

Instantly share code, notes, and snippets.

View aliumujib's full-sized avatar

Abdul-Mujeeb Aliu aliumujib

  • London, England
View GitHub Profile
@decodeandroid
decodeandroid / SlidingNumberPuzzle.kt
Last active November 6, 2024 20:55
Sliding Numbers Puzzle Game using Jetpack Compose & Canvas
import androidx.compose.foundation.Canvas
import androidx.compose.foundation.gestures.detectDragGestures
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.size
import androidx.compose.runtime.Composable
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateOf
import androidx.compose.runtime.remember
import androidx.compose.runtime.setValue
@nmwsharp
nmwsharp / printarr
Last active October 7, 2025 13:57
Pretty print tables summarizing properties of tensor arrays in numpy, pytorch, jax, etc. --- now on pip: `pip install arrgh`
Pretty print tables summarizing properties of tensor arrays in numpy, pytorch, jax, etc.
Now on pip! `pip install arrgh` https://github.com/nmwsharp/arrgh
@POD666
POD666 / Notion duplicate page script example (python)
Last active December 16, 2025 00:07
Notion page duplication requires recursive blocks population and extra tricks to duplicate images. Hope this example will help someone who also struggle with notion API.
import logging
import os
from io import BytesIO
import boto3
import click
import requests
@emmaguy
emmaguy / AndroidManifest.xml
Created February 1, 2020 14:01
Click the 'Skip Intro' button on the Android notification from the Netflix app
<service
android:name=".NotificationService"
android:label="@string/notification_service_name"
android:permission="android.permission.BIND_NOTIFICATION_LISTENER_SERVICE">
<intent-filter>
<action android:name="android.service.notification.NotificationListenerService" />
</intent-filter>
</service>
@bdivljak91
bdivljak91 / BluetoothStateBroadcastReceiver.txt
Last active April 23, 2021 05:43
Bluetooth state broadcast receiver - Clean Architecture
import android.bluetooth.BluetoothAdapter
import android.content.BroadcastReceiver
import android.content.Intent
import android.content.Context
import dagger.android.AndroidInjection
import io.reactivex.Observable
import io.reactivex.subjects.BehaviorSubject
import javax.inject.Inject
@marnanel
marnanel / gist:87fee222990df53d23a9999d90a4eae2
Created June 27, 2018 18:39
Sub Station Alpha (libass) subtitle format spec
Sub Station Alpha v4.00+ Script Format
1. 1. General information
2. 2. The [sections] of a Sub Station Alpha script
3. 3. The line types in a Sub Station Alpha script
4. 4. Header lines, [Script Info] section
5. 5. Style lines, [v4 Styles] section
6. 6. Dialogue event lines, [Events] section
@BenoitDuffez
BenoitDuffez / mig
Last active October 12, 2023 18:52
Parse migration failed exception (Android Room)
#!/bin/bash
# Clean up on exit
function finish {
rm -f expected found
}
trap finish EXIT
# How to parse JSON
JQ="jq --sort-keys"
@JosiasSena
JosiasSena / DeCryptor.java
Last active September 15, 2025 01:58
Encryptor and Decryptor for data encryption.decryption using the Android KeyStore.
/**
_____ _____ _
| __ \ / ____| | |
| | | | ___| | _ __ _ _ _ __ | |_ ___ _ __
| | | |/ _ \ | | '__| | | | '_ \| __/ _ \| '__|
| |__| | __/ |____| | | |_| | |_) | || (_) | |
|_____/ \___|\_____|_| \__, | .__/ \__\___/|_|
__/ | |
|___/|_|
*/
@chranderson
chranderson / nvmCommands.js
Last active December 20, 2025 10:24
Useful NVM commands
// check version
node -v || node --version
// list locally installed versions of node
nvm ls
// list remove available versions of node
nvm ls-remote
// install specific version of node
@cesarferreira
cesarferreira / RxJava.md
Last active March 30, 2025 00:28
Party tricks with RxJava, RxAndroid & Retrolambda

View Click

Instead of the verbose setOnClickListener:

RxView.clicks(submitButton).subscribe(o -> log("submit button clicked!"));

Filter even numbers

Observable
    .just(1, 2, 3, 4, 5, 6, 7, 8, 9, 10)