Skip to content

Instantly share code, notes, and snippets.

Normal Operations Checklist

Aircraft

Physical State
  • Free of physical damage, no cracks in motorarms
  • Gimbal protector removed

Preflight

@sand3r
sand3r / git_cheat_sheet.md
Last active November 22, 2018 09:16
GIT Cheat Sheet

Git Cheat Sheet

File Operations

Reset a File

git checkout -- {file}

Reset a File To Origin

git checkout origin/{branch} -- file

@sand3r
sand3r / har_export.js
Last active January 7, 2016 15:41
From HAR to a list of copyable files
// If your browser supports window.performance (at least Chrome does) use this:
window.performance.getEntries().forEach(function(resource) { console.log(resource.name); });
// Other way:
// First 'Copy all as HAR' from Network panel.
// Expose result as 'window.HAR'
console.clear();
@sand3r
sand3r / gist:38531631752a40ab2bd1
Last active August 29, 2015 14:27
Detect images in page without (valid) alt and title
var imagecount = 0;
var titleMissing = 0;
var altMissing = 0;
var $image = null;
jQuery('img').each(function(i, el) {
imagecount++;
$image = jQuery(el);
if(typeof $image.attr('title') !== 'undefined' && $image.attr('title') !== '') {
@sand3r
sand3r / gist:e372b15b300c3c606e59
Last active August 29, 2015 14:08
webdriverio example
# First Terminal
mkdir webdriverio-test && cd webdriverio-test
curl -O http://selenium-release.storage.googleapis.com/2.43/selenium-server-standalone-2.43.1.jar
java -jar selenium-server-standalone-2.43.1.jar
# Second Terminal (start from webdriverio-test directory)
npm install webdriverio
curl https://gist.githubusercontent.com/sand3r/29a431366d89442c5dfb/raw/c9d900abd30104e7d876bc2ee02dbee9b3a3c7c1/gistfile1.txt > test.js
node test.js
@sand3r
sand3r / gist:29a431366d89442c5dfb
Created November 4, 2014 15:52
webdriverio example test
var webdriverio = require('webdriverio');
var options = {
desiredCapabilities: {
browserName: 'firefox'
}
};
webdriverio
.remote(options)
.init()
.url('http://www.google.com')
@sand3r
sand3r / gist:f49d934fbf35355f43b9
Created August 13, 2014 19:18
Strip file/directory type and time when running Windows 8 ls
(\S{5}) *([0-9]*-[0-9]*-20[0-9]* ([0-9]*:([0-9]*)))