Skip to content

Instantly share code, notes, and snippets.

View t0mab's full-sized avatar

t0mab t0mab

View GitHub Profile
@t0mab
t0mab / android-backup-apk-and-datas.md
Created August 27, 2025 07:28 — forked from AnatomicJC/android-backup-apk-and-datas.md
Backup android app, data included, no root needed, with adb

Backup android app, data included, no root needed, with adb

Note: This gist may be outdated, thanks to all contributors in comments.

adb is the Android CLI tool with which you can interact with your android device, from your PC

You must enable developer mode (tap 7 times on the build version in parameters) and install adb on your PC.

Don't hesitate to read comments, there is useful tips, thanks guys for this !

# Using these pry gems -- copy to your Gemfile
# group :development, :test do
# gem 'awesome_print' # pretty print ruby objects
# gem 'pry' # Console with powerful introspection capabilities
# gem 'pry-byebug' # Integrates pry with byebug
# gem 'pry-doc' # Provide MRI Core documentation
# gem 'pry-rails' # Causes rails console to open pry. `DISABLE_PRY_RAILS=1 rails c` can still open with IRB
# gem 'pry-rescue' # Start a pry session whenever something goes wrong.
# gem 'pry-theme' # An easy way to customize Pry colors via theme files
# end

Pry Cheat Sheet

Command Line

  • pry -r ./config/app_init_file.rb - load your app into a pry session (look at the file loaded by config.ru)
  • pry -r ./config/environment.rb - load your rails into a pry session

Debugger

@t0mab
t0mab / action_controller_review.md
Created October 23, 2024 10:00 — forked from jamesyang124/action_controller_review.md
Notes for action controller overview from Rails official site. rails 4.2
@t0mab
t0mab / pylance_patcher.rs
Created April 30, 2024 08:04 — forked from pickx/pylance_patcher.rs
Patch Pylance's VSCode check
#!/usr/bin/env -S cargo +nightly -Zscript --quiet
---
[package]
edition = "2021"
[dependencies]
eyre = "0.6.12"
home = "0.5.9"
---
@t0mab
t0mab / jq-cheetsheet.md
Created March 30, 2022 10:19 — forked from olih/jq-cheetsheet.md
jq Cheet Sheet

Processing JSON using jq

jq is useful to slice, filter, map and transform structured json data.

Installing jq

On Mac OS

brew install jq

@t0mab
t0mab / Efficient Encrypted UEFI-Booting Arch Installation
Created April 26, 2019 20:22 — forked from HardenedArray/Efficient Encrypted UEFI-Booting Arch Installation
An effcient method to install Arch Linux with encrypted root and swap filesystems and boot from UEFI. Multi-OS, and VirtualBox, UEFI-booting are also supported.
# OBJECTIVE: Install Arch Linux with encrypted root and swap filesystems and boot from UEFI.
# Note this encrypted installation method, while perfectly correct and highly secure, CANNOT support encrypted /boot and
# also CANNOT be subsequently converted to support an encrypted /boot!!! A CLEAN INSTALL will be required!
# Therefore, if you want to have an encrypted /boot or will want an encrypted /boot system at some point in the future,
# please ONLY follow my encrypted /boot installation guide, which lives here:
@t0mab
t0mab / memoize.py
Created July 3, 2018 09:37 — forked from martync/memoize.py
Memoize Django model's method.
import functools
def memoize_django_model_method(obj):
@functools.wraps(obj)
def memoizer(*args, **kwargs):
# Get the model instance
instance = args[0]
@t0mab
t0mab / rofi-emoji.sh
Created February 24, 2018 00:55 — forked from tadly/rofi-emoji.sh
Rofi emoji picker
#!/usr/bin/env bash
#
# Use rofi to pick emoji because that's what this
# century is about apparently...
#
# Requirements:
# rofi, xsel, curl, xmllint
#
# Usage:
# 1. Download all emoji