Skip to content

Instantly share code, notes, and snippets.

@z9gmoon
z9gmoon / AdbCommands
Created February 6, 2021 12:36 — forked from Pulimet/AdbCommands
Adb useful commands list
adb help // List all comands
== Adb Server
adb kill-server
adb start-server
== Adb Reboot
adb reboot
adb reboot recovery
adb reboot-bootloader
#optimize time
import os
import cv2
import time
import sys
import numpy as np
from datetime import datetime
import win32api, win32con
defaultThreshold = 0.55
@z9gmoon
z9gmoon / mysql-docker.sh
Created November 7, 2019 03:42 — forked from spalladino/mysql-docker.sh
Backup and restore a mysql database from a running Docker mysql container
# Backup
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql
# Restore
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE
@z9gmoon
z9gmoon / bashrc
Last active October 3, 2018 10:00
ubuntu config
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
# if [ "$color_prompt" = yes ]; then
# PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[01;31m\] $(parse_git_branch)\[\033[00m\]\$ '
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[01;33m\] $(parse_git_branch)\[\033[00m\]\$ '
# else
# PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w$(parse_git_branch)\$ '
# fi
# end change
@z9gmoon
z9gmoon / bd3d4befe38185704bf0fc875e9deed6|configuration.json
Last active September 20, 2018 02:18
Visual Studio Code Settings Sync Gist
{"contents":{"launch":{"version":"0.2.0","configurations":[{"type":"node","request":"launch","name":"Launch Program","program":"${file}"}]}},"overrides":[],"keys":["launch.version","launch.configurations"]}