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
RED="\[\033[0;31m\]" | |
YELLOW="\[\033[0;33m\]" | |
GREEN="\[\033[0;32m\]" | |
BLUE="\[\033[0;34m\]" | |
LIGHT_RED="\[\033[1;31m\]" | |
LIGHT_GREEN="\[\033[1;32m\]" | |
WHITE="\[\033[1;37m\]" | |
LIGHT_GRAY="\[\033[0;37m\]" | |
COLOR_NONE="\[\e[0m\]" |
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
var editor = document.querySelector('.kix-appview-editor'); | |
var observer = new MutationObserver(function (mutations) { | |
mutations.forEach(function (mutation) { | |
var entry = { | |
mutation: mutation, | |
el: mutation.target, | |
value: mutation.target.textContent, | |
oldValue: mutation.oldValue | |
}; |
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://bugzilla.mozilla.org/show_bug.cgi?id=1206649#c11 | |
1) Install HAR Export Trigger extension | |
https://addons.mozilla.org/en-US/firefox/addon/har-export-trigger/ | |
(you need Firefox 42+) | |
2) Set the following prefs in your Firefox profile: | |
devtools.netmonitor.har.enableAutoExportToFile;true // auto export when page load finishes | |
extensions.netmonitor.har.autoConnect;true // This one allows exporting without the Toolbox |
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
PerfTiming Chart: http://askeing.github.io/D3_performance_chart/ | |
200+ pages Data: https://docs.google.com/document/d/1EpYUniwtLvBbZ4ECgT_vwGUfTHKnqSWi7vgNJQBemFk/edit?pref=2&pli=1 | |
empty pages Date: https://docs.google.com/document/d/1YNxUZPc7xB4OtnxnRLMIKlagMzSOh3_uggp2WCz3aww/edit |
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
alias ll='ls -lah' | |
if [ -f `brew --prefix`/etc/bash_completion ]; then | |
. `brew --prefix`/etc/bash_completion | |
fi | |
export NVM_DIR=~/.nvm | |
source $(brew --prefix nvm)/nvm.sh | |
if [ -f ~/.bashrc ]; then |
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
Ran 4669 tests finished in 2872.0 seconds. | |
• 4650 ran as expected. 1361 tests skipped. | |
• 2 tests crashed unexpectedly | |
• 17 tests timed out unexpectedly | |
Error running mach: | |
['test'] | |
The error occurred in code that was called by the mach command. This is either |
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
git branch -r --merged master | sed 's/ *origin\///' | grep -v 'master$' | xargs git push origin --delete |
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 numpy | |
def corr_percentage(a, b): | |
# Ref: | |
# - https://en.wikipedia.org/wiki/Pearson_product-moment_correlation_coefficient | |
# - http://docs.scipy.org/doc/numpy/reference/generated/numpy.corrcoef.html | |
#return 0.5 * numpy.corrcoef(a,b)[0][1] + 0.5 | |
return numpy.abs(numpy.corrcoef(a,b)[0][1]) | |
def cosine_similarity(a, b): |
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 | |
# Author: askeing | |
# Version: 0.0.1 | |
func_log () { | |
echo "$@" | tee -a bootstrap-linux.log | |
} | |
################ |
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
# Create new Firefox profile | |
## Mac, Windows | |
firefox --profile <PROFILE_DIR> -silent | |
## Ubuntu | |
firefox -createprofile "<PROFILE_NAME> <PROFILE_DIR>" -silent | |
# disable Flash | |
user_pref("plugin.state.flash", 0); |
OlderNewer