Skip to content

Instantly share code, notes, and snippets.

View me7's full-sized avatar

Gampol T. me7

  • Thailand
View GitHub Profile
@me7
me7 / .bash_profile
Last active February 4, 2023 20:13
fzf .bash_profile and .bashrc
# System settings before starting X
. $HOME/.bashrc
PATH=$PATH:$HOME/bin
# set up alsa
/usr/bin/amixer sset Master Mono 90% unmute &> /dev/null
/usr/bin/amixer sset Master 90% unmute &> /dev/null
/usr/bin/amixer sset PCM 90% unmute &> /dev/null
let blacklists = ["https://feedly.com/*"]
[
{
"id": "tools",
"children":
[{
"caption": "SublimeREPL",
"mnemonic": "R",
"id": "SublimeREPL",
"children":
[
@me7
me7 / Clojure.sublime-settings
Created March 3, 2016 10:06 — forked from jamesmacaulay/Clojure.sublime-settings
Clojure stuff for Sublime Text 2. Files live in ~/Application Support/Sublime Text 2/Packages/User
// installed Clojure packages:
//
// * BracketHighlighter
// * lispindent
// * SublimeREPL
// * sublime-paredit
{
"word_separators": "/\\()\"',;!@$%^&|+=[]{}`~?",
"paredit_enabled": true,
@me7
me7 / 0_reuse_code.js
Created April 20, 2016 09:43
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@me7
me7 / download.js
Created February 8, 2017 02:23
Inject mithril to webpage
//press F12 to open chrome dev tools
//then add mithril to header
var mt = document.createElement('script');
mt.src = "https://unpkg.com/mithril/mithril.js";
document.getElementsByTagName('head')[0].appendChild(mt);
//test render
m.render(document.body,"Hello");
//let create link and click
@me7
me7 / aes.md
Created March 30, 2017 09:59
python aes
@me7
me7 / script.js
Last active March 31, 2017 09:09
lightning launcher select first item in folder
var item = LL.getEvent().getItem();
if ( item.getType() != 'Folder' )
{
alert('Not a folder');
return;
}
var items = item.getContainer().getItems();
var count = items.getLength();
if ( count == 0 )
{
@me7
me7 / capture.py
Last active March 8, 2023 02:05
use adb to capture image and transfer to PC
# check device present: adb devices -> 5203d550fe3ea3ab
from time import clock, sleep
from subprocess import check_output, call
import re
#call this to capture image
def capture():
clock()
screen_on()
clear_camera_folder()