Skip to content

Instantly share code, notes, and snippets.

@JuniorJPDJ
JuniorJPDJ / rotate180
Created Dec 3, 2016
x220T / other tablet thinkpad rotation scripts
View rotate180
#!/bin/bash
case $(xrandr -q --verbose | grep LVDS1 | awk '{split($0, a); print a[5]}') in
"normal")
rotate="inverted"
wacom="half"
;;
*)
rotate="normal"
View ferrari-local_manifest.xml
<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<project name="faizauthar12/android_device_xiaomi_ferrari" path="device/xiaomi/ferrari" remote="github" revision="cm-14.1" />
<project name="faizauthar12/android_kernel_xiaomi_ferrari-1" path="kernel/xiaomi/ferrari" remote="github" revision="cm-14.1" />
<project name="faizauthar12/proprietary_vendor_xiaomi" path="vendor/xiaomi" remote="github" revision="vulkan" />
<project name="LineageOS/android_external_stlport" path="external/stlport" remote="github" revision="cm-14.1" />
<project name="LineageOS/android_device_cyanogen_msm8916-common" path="device/cyanogen/msm8916-common" remote="github" revision="cm-14.1" />
<project name="LineageOS/android_packages_resources_devicesettings" path="packages/resources/devicesettings" remote="github" revision="cm-14.1" />
<project name="LineageOS/android_device_qcom_common" path="device/qcom/common" remote="github" revision="cm-14.1" />
@JuniorJPDJ
JuniorJPDJ / android_kernel_patches_list.txt
Last active Jan 25, 2018
Useful android kernel patches
View android_kernel_patches_list.txt
wireguard (VPN, kernel 3.10+): https://git.zx2c4.com/android_kernel_wireguard/about/
USB Gadget HID (Android as USB Keyboard): https://github.com/pelya/android-keyboard-gadget
USB Gadget CD-ROM (Android as USB CD-ROM): https://github.com/CyanogenMod/android_kernel_lge_hammerhead/commit/46bd47757a9f34c1d95dd2620414893212fb0526
@JuniorJPDJ
JuniorJPDJ / wifi.sh
Last active Apr 10, 2020
Nexmon firmware replacing on-demand
View wifi.sh
#!/system/bin/sh
# place me in this folder:
export HOME="/sdcard/wifi"
# place patched firmware with this name
patched_path="$HOME/bcmdhd_sta.bin.patched"
backup_path="$HOME/bcmdhd_sta.bin.backup"
fw_path="/system/etc/wifi/bcmdhd_sta.bin"
View foss-android-pl.txt
Baza systemu:
LineageOS
Kontynuacja (fork) porzuconego projektu CyanogenMod, bardzo dobrego i szanowanego w gronach moderskich systemu operacyjnego opartego na czystym Androidzie
Jeden ze stabilniejszych "custom romów" na smartfony, wspiera sporą liczbę urządzen oficialnie i praktycznie każde dostępne na rynku nieoficialnie (ludzie budują go jako bazę deweloperską)
Oficialna strona: https://lineageos.org/
Źródła: https://github.com/LineageOS
@JuniorJPDJ
JuniorJPDJ / openpgp.txt
Created Mar 27, 2018
OpenKeychain Linked Identity
View openpgp.txt
This Gist confirms the Linked Identity in my OpenPGP key, and links it to this GitHub account.
Token for proof:
[Verifying my OpenPGP key: openpgp4fpr:493c18dc93c8dc3ef7c49fdad43bd84d42e7fa13]
View gist:8d93bc521229017787b02696c12d9de5
-----BEGIN PGP PUBLIC KEY BLOCK-----
mQINBFpfx7ABEADFNFr9kM1k57tSUKRUNpj/LbWtL/GkuXCT2xhMG9o5qIeV/q0/
ZGaEJaxUjZx1xfggH7Kip9/CxL89aLw1uawvfSlGXcu42j0Im4IGyFTw6vluq97m
5AiAOf0v9xEtX8k5jqu/ho6OOYbnxAagJmxWnhdv5khLA9YwVjicKnpk8o7JBdW/
wGegIxFwNvISDSeHuc/Up/TjIyj9xDwn+bTgyFeH8Thx5kZ+BpPcEd5EGBx8qWn4
6kIyh652/qZyg77js7ke8uiBZVRXrasYcretZHDJ9TFpqiBOuIUv7LHidTX1PXYx
ZWKrko7wjtaSw4XT3YpGn5jWM4+nmEhAM23sOgn0ETdp4zdyesqwPdgoGockf3mD
/VGljFNTwKzOYDkl1gYiwcrV6lkSzXMLND3OWcUh/GLYx9WuYoX3plWFU+hYtMPw
XWWlw/Jqea6qTt/jBT/vLsVARHSYCF7ZNyCunuT7B+xXpKtTgYEO/+63rzbGHghF
S1Xzb3wJWJElRA60eyyhZY3wqBoo9575F+ox1TEj7GHPY3RWbIQmURp6Me34xTHN
@JuniorJPDJ
JuniorJPDJ / prestigio-per5574bc_defconfig
Last active Nov 16, 2018
Prestigio Multireader Stream PER5574BC
View prestigio-per5574bc_defconfig
CONFIG_ARM=y
CONFIG_ARCH_SUNXI=y
CONFIG_SPL=y
CONFIG_MACH_SUN5I=y
CONFIG_DRAM_CLK=408
CONFIG_DRAM_EMR1=0
CONFIG_MMC0_CD_PIN="PG0"
CONFIG_USB0_VBUS_DET="PG1"
CONFIG_USB0_VBUS_PIN="PG12"
CONFIG_USB0_ID_DET="PG2"
View goclever_gcta741l_defconfig
CONFIG_ARM=y
CONFIG_ARCH_SUNXI=y
CONFIG_SPL=y
CONFIG_MACH_SUN6I=y
CONFIG_DRAM_CLK=360
CONFIG_DRAM_ZQ=251
CONFIG_MMC0_CD_PIN="PA8"
CONFIG_USB0_VBUS_PIN="AXP0-VBUS-ENABLE"
CONFIG_USB0_VBUS_DET="AXP0-VBUS-DETECT"
CONFIG_USB0_ID_DET="PA15"
@JuniorJPDJ
JuniorJPDJ / git-filter-repo.sh
Last active Apr 15, 2020
git filter-repo and amend commit date editing
View git-filter-repo.sh
// last commit
export GIT_COMMITTER_DATE="$(date -R --date="13 days ago")"; git commit --amend --date="$GIT_COMMITTER_DATE"
// selected dates
git filter-repo -f --commit-callback '
from datetime import datetime  46.175.47.49   96%  ─╯
d = commit.author_date.split()
date = datetime.fromtimestamp(int(d[0]))
if date.day == 2:
d[0]=str(int(d[0])+12*60*60).encode("ascii")