This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use File::Path qw(make_path); | |
my $download_url = "http://sourceforge.net/projects/davmail/files/latest/download?source=files"; | |
my $user_agent = 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/34.0.1847.116 Chrome/34.0.1847.116 Safari/537.36'; | |
my $version_file = "davmail_version"; | |
my $davmail_deb = "davmail_latest.deb"; | |
my $version_path = "$ENV{'HOME'}/.config/davmail_updater"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
BEGIN { $Curses::OldCurses = 1; } | |
use strict; | |
use warnings; | |
use Curses; | |
use perlmenu; | |
my $ARGC = $#ARGV + 1; | |
my $killid = 15; | |
my @all_pids; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function! BddFindFunction() | |
ruby<<E___ | |
line = VIM::Buffer.current.line | |
if /^\s*(?:[Gg]iven|[Ww]hen|[Tt]hen|[Bb]ut|[Aa]nd)\s+"([^"]+)".*$/ =~ line | |
function_name = $1.gsub(/[^A-Za-z0-9\s]/, "").gsub(/\s+/, "_").downcase | |
Vim::command('call searchpos("def ' + function_name + '")') | |
else | |
Vim::message "Not a BDD :^(" | |
end | |
E___ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/usr/libexec/java_home -v 1.8.0_25 --exec javac -version |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let csrfToken = 'lololololol'; | |
let axiosDefaults = require('axios/lib/defaults'); | |
axiosDefaults.headers.common['X-CSRF-Token'] = csrfToken; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
nc -l localhost 12345 | |
curl -H "Content-Type: application/json" -X POST -d '{"lol": "data"}' http://localhost:12345 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git tag -d 12345 | |
git push origin :refs/tags/12345 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Time.new().strftime("%Y%m%d%H%M%S") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Put this in your "setupEnvScriptFile" for Jest. | |
// usage: `jest.genMockFn().mockReturnValue(promisify('whateva'))` | |
promisify = function (returnValue, delay) { | |
delay = !!delay; | |
let delayCount = 0; | |
let recursiveMockPromise = new function () { | |
let self = this; | |
self.returnValue = returnValue; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
git branch -u origin/$(git rev-parse --abbrev-ref HEAD) |