Skip to content

Instantly share code, notes, and snippets.

@Isanderthul
Isanderthul / sms.sh
Last active January 22, 2018 15:04 — forked from TotemaT/sms.sh
Send an sms from a computer through an Android device using ADB
#!/bin/zsh
# Send text through adb by Madura A.
# https://market.android.com/details?id=org.jraf.android.nolock
# Please use the above app(or similar) to keep it from locking while
# using this script
# If screen is off, turn it on and unlock it (Only works with slide to unlock)
if adb shell dumpsys input_method | grep -q mScreenOn=false; then
$ADB shell input keyevent 26
$ADB shell input swipe 250 650 1000 650
@Isanderthul
Isanderthul / CursorRecyclerAdapter.java
Created December 17, 2016 07:03 — forked from Shywim/CursorRecyclerAdapter.java
A custom Adapter for the new RecyclerView, behaving like the CursorAdapter class from previous ListView and alike. Now with Filters and updated doc.
/*
* The MIT License (MIT)
*
* Copyright (c) 2014 Matthieu Harlé
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@Isanderthul
Isanderthul / screenrecord.sh
Last active December 14, 2016 15:09 — forked from tasomaniac/screenrecord.sh
Screen Record for Android
#!/bin/sh
set -e
if [ -z "$1" ]; then
shot_path=$(date +%Y-%m-%d-%H-%M-%S).mp4
else
shot_path="$*"
fi
pm list packages -f
require 'rubygems'
require 'mechanize'
FIRST_NAME = 'FIRST_NAME'
LAST_NAME = 'LAST_NAME'
PHONE = 'PHONE'
EMAIL = 'EMAIL@provider.com'
PARTY_SIZE = 2
SCHEDULE_RANGE = { :start_time => '19:00', :end_time => '20:30' }