This file contains 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 zsh | |
# | |
# Check if array is empty | |
# | |
typeset -A knock_sequences | |
if [ ${#knock_sequences[@]} -eq 0 ]; then | |
echo "No knock sequence found." |
This file contains 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
# https://zaiste.net/zsh_get_filename_extension_path/#!/bin/zsh | |
# Filename | |
fullpath="/etc/nginx/nginx.conf" | |
filename=$fullpath:t | |
echo $filename | |
# result: nginx.conf | |
# Path | |
fullpath="/etc/nginx/nginx.conf" |
This file contains 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
{ | |
"Key Mappings": { | |
"0x2a-0x200000": { | |
"Action": 12, | |
"Text": "*" | |
}, | |
"0x2b-0x200000": { | |
"Action": 12, | |
"Text": "+" | |
}, |
This file contains 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
// ==UserScript== | |
// @name Remove Facebook's external link tracking (updated for the new FB) | |
// @description Removes redirection and "FB click identifier" from external FB links | |
// @namespace https://gist.github.com/k-barton | |
// @include https://*.facebook.com* | |
// @include http://*.facebook.com* | |
// @version 0.3.2 | |
// @grant unsafeWindow | |
// @run-at document-start | |
// ==/UserScript== |
This file contains 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
[automount] | |
enabled = true | |
options = "metadata,umask=027,fmask=117" | |
[interop] | |
appendWindowsPath = false |
This file contains 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 | |
while [[ $# > 0 ]] ; do | |
case "$1" in | |
--not-in-head) | |
NOT_IN_HEAD=true | |
;; | |
esac | |
shift | |
done |
This file contains 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 | |
### BEGIN INIT INFO | |
# Provides: dns-sync | |
# Required-Start: | |
# Required-Stop: | |
# Default-Start: S | |
# Default-Stop: | |
# Short-Description: Synchronizes /etc/resolv.conf in WLS with Windows DNS - Matthias Brooks | |
### END INIT INFO |
This file contains 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 | |
TMP=`mktemp` | |
trap ctrlC INT | |
removeTempFiles() { | |
rm -f $TMP | |
} | |
ctrlC() { |
This file contains 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
export GIT_PS1_SHOWDIRTYSTATE=true | |
export GIT_PS1_SHOWCOLORHINTS=true | |
#PS1='[\u@\h \W$(__git_ps1 " (%s)")]\$ ' | |
#export PROMPT_COMMAND='__git_ps1 "\u@\h:\w" "\\\$ "' | |
export PROMPT_COMMAND='\ | |
__git_ps1 "\[\033]0;\u@\h: \w\007\]\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]" "\\\$ "\ | |
' |
This file contains 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
import static com.fasterxml.jackson.annotation.JsonTypeInfo.As.EXISTING_PROPERTY; | |
import static com.fasterxml.jackson.annotation.JsonTypeInfo.Id.NAME; | |
import static jsinterop.annotations.JsPackage.GLOBAL; | |
import com.fasterxml.jackson.annotation.JsonIgnore; | |
import com.fasterxml.jackson.annotation.JsonSubTypes; | |
import com.fasterxml.jackson.annotation.JsonTypeInfo; | |
import com.fasterxml.jackson.annotation.JsonTypeName; | |
import javax.annotation.Nullable; | |
import jsinterop.annotations.JsOverlay; |
NewerOlder