Skip to content

Instantly share code, notes, and snippets.

@Pankra
Pankra / Android Screenshot.bat
Last active February 5, 2017 16:26 — forked from leighmcculloch/Android Screenshot.bat
This batch script will take a screenshot on an Android device using ADB, download the screenshot to the directory this script to the current directory and then remove the screenshot file from the device. /*Screenshots are saved with filename: screenshot-YYYYMMDD-HHMMSS.png.*/ ADB must be connected to a device already.
@echo off
rem configurable parameters
set SCREENCAP_FILE_PREFIX=screenshot
rem the dir on the device where the screenshot will be stored temporarily
set SCREENCAP_WORKING_DIR=/sdcard/
set SCREENCAP_OUT_DIR=D:\ProjectStuff\
rem adb path, leave blank if adb is already on the user or system path
@Pankra
Pankra / git.migrate
Created April 18, 2017 09:00 — forked from niksumeiko/git.migrate
Moving git repository and all its branches, tags to a new remote repository keeping commits history
#!/bin/bash
# Sometimes you need to move your existing git repository
# to a new remote repository (/new remote origin).
# Here are a simple and quick steps that does exactly this.
#
# Let's assume we call "old repo" the repository you wish
# to move, and "new repo" the one you wish to move to.
#
### Step 1. Make sure you have a local copy of all "old repo"
### branches and tags.