To be called with:
git diff --text --word-diff=porcelain | awk -v red="$(tput setaf 1)" -v green="$(tput setaf 2)" -v reset="$(tput sgr0)" -f ~/.dotfiles/scripts/worddiff.awk
// ==UserScript== | |
// @name Github status check sort | |
// @namespace https://github.com/ | |
// @version 1.1.3 | |
// @description Sort the status checks on a PR by status and then by name | |
// @author Skjnldsv | |
// @match https://github.com/*/*/pull/* | |
// @icon https://github.githubassets.com/favicons/favicon.svg | |
// @grant none | |
// @updateURL https://gist.github.com/skjnldsv/eb7b894ae996affde4a7d0e00e0d80a1/raw/github-status-check-sort.user.js |
To be called with:
git diff --text --word-diff=porcelain | awk -v red="$(tput setaf 1)" -v green="$(tput setaf 2)" -v reset="$(tput sgr0)" -f ~/.dotfiles/scripts/worddiff.awk
// ==UserScript== | |
// @name Nextcloud drone status check sort | |
// @namespace http://drone.nextcloud.com/ | |
// @version 0.3 | |
// @description Put Nextcloud drone failed jobs on top of the list | |
// @author MorrisJobke & Skjnldsv | |
// @match https://drone.nextcloud.com/nextcloud/* | |
// @icon https://github.githubassets.com/favicons/favicon.svg | |
// @grant none | |
// @updateURL https://gist.github.com/skjnldsv/d9244cf50d148d4e38319fe497f7b68c/raw/nextcloud-drone-status-sort.user.js |
# The ID of your GitHub App | |
APP_ID= | |
WEBHOOK_SECRET=development | |
# Uncomment this to get verbose logging | |
# LOG_LEVEL=trace # or `info` to show less | |
# Go to https://smee.io/new set this to the URL that you are redirected to. | |
# WEBHOOK_PROXY_URL= |
/* global createImageBitmap */ | |
function loadImageWithImageTag(src) { | |
return new Promise((resolve, reject) => { | |
const img = new Image; | |
img.crossOrigin = ''; | |
img.src = src; | |
img.onload = () => { resolve(img); }; | |
img.onerror = () => { reject(img); }; | |
}); |
# Simple No-ip.com Dynamic DNS Updater | |
# | |
# By Nathan Giesbrecht (http://nathangiesbrecht.com) | |
# | |
# 1) Install binary as described in no-ip.com's source file (assuming results in /usr/local/bin) | |
# 2) Run sudo /usr/local/bin/noip2 -C to generate configuration file | |
# 3) Copy this file noip2.service to /etc/systemd/system/ | |
# 4) Execute `sudo systemctl daemon-reload` | |
# 5) Execute `sudo systemctl enable noip2` | |
# 6) Execute `sudo systemctl start noip2` |
// this is the service worker which intercepts all http requests | |
self.addEventListener('fetch', function fetcher (event) { | |
var request = event.request; | |
// check if request | |
if (request.url.indexOf('assets.contentful.com') > -1) { | |
// contentful asset detected | |
event.respondWith( | |
caches.match(event.request).then(function(response) { | |
// return from cache, otherwise fetch from network | |
return response || fetch(request); |
// go on you labels pages | |
// eg https://github.com/cssnext/cssnext/labels | |
// paste this script in your console | |
// copy the output and now you can import it using https://github.com/popomore/github-labels ! | |
var labels = []; | |
[].slice.call(document.querySelectorAll(".label-link")) | |
.forEach(function(element) { | |
labels.push({ | |
name: element.textContent.trim(), |
# NPM CheatSheet. | |
# Super easy intall: npm comes with node now. | |
# To create your own npm package: https://www.npmjs.org/doc/misc/npm-developers.html | |
# More: https://www.npmjs.org/doc/ | |
# 1. NPM Command Lines. | |
# Local mode is the default. | |
# Use --global or -g on any command to operate in global mode instead. |
/** | |
* | |
* Find the relative file system path between two file system paths | |
* | |
* @param string $frompath Path to start from | |
* @param string $topath Path we want to end up in | |
* | |
* @return string Path leading from $frompath to $topath | |
*/ | |
function find_relative_path ( $frompath, $topath ) { |