- removeNHIICC.sh : 移除健保卡元件與相關設定,須以 root (
sudo
) 權限執行。 - postinstall.sh : 官方「MAC 元件移除安裝檔」的 script 內容(2020)
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
# ripgrep is required | |
codesign -dr - ~/Applications/*.app 2>&1 \ | |
| rg --pcre2 -o '(?<=identifier ")com.jetbrains[^"]+(?=")' \ | |
| xargs -L 1 -I _ defaults read _ ApplePressAndHoldEnabled |
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
package main | |
import "fmt" | |
type ( | |
tF func(int) int | |
tRF func(tF) tF | |
tX func(tX) tF | |
) |
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 bash | |
WEBRTC_REPO=http://webrtc.googlecode.com/svn/trunk | |
WEBRTC_REV=7217 | |
svn checkout ${WEBRTC_REPO}/talk/app/webrtc/java@r${WEBRTC_REV} peer_connection | |
svn checkout ${WEBRTC_REPO}/webrtc/modules/audio_device/android/java@r${WEBRTC_REV} audio_device | |
svn checkout ${WEBRTC_REPO}/webrtc/modules/video_capture/android/java@r${WEBRTC_REV} video_capture | |
svn checkout ${WEBRTC_REPO}/webrtc/modules/video_render/android/java@r${WEBRTC_REV} video_render |
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 | |
# Copied from https://github.com/paulirish/dotfiles/commit/6743b907ff586c28cd36e08d1e1c634e2968893e | |
function strip_diff_leading_symbols(){ | |
color_code_regex=$'(\x1B\\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K])' | |
# simplify the unified patch diff header | |
sed -E "s/^($color_code_regex)diff --git .*$//g" | \ | |
sed -E "s/^($color_code_regex)index .*$/\ | |
\1$(rule)/g" | \ |
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 AWS = require('aws-sdk'); | |
var chain = new AWS.CredentialProviderChain(); | |
var credentials | |
AWS.CredentialProviderChain.defaultProviders = [ | |
function () { return new AWS.EnvironmentCredentials('AWS'); }, | |
function () { return new AWS.EnvironmentCredentials('AMAZON'); }, | |
function () { return new AWS.SharedIniFileCredentials({profile: 'my_profile_name'}); }, | |
function () { return new AWS.EC2MetadataCredentials(); } | |
] |
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 | |
ORIG_BRANCH="$(git rev-parse --abbrev-ref HEAD)" | |
if [[ "$ORIG_BRANCH" == "HEAD" ]] { | |
ORIG_BRANCH="$(git rev-parse --short HEAD)" | |
} | |
for b in $(git branch --track | grep -v 'detached' | sed 's/*//') | |
do | |
git checkout "${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
#!/usr/bin/env zsh | |
if [[ $# != 1 ]]; then | |
cat - << USAGE | |
Usage: `basename $0` <branch> | |
USAGE | |
return 1 | |
fi | |
local old_branch=$(git rev-parse --abbrev-ref HEAD) |
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
""" | |
modified for Python 2.7 and unicode | |
get your goup id at https://lookup-id.com/ | |
get your acess token at https://developers.facebook.com/tools/explorer/ | |
fork from | |
fbfeed2csv: a tool to download all posts from a user/group/page's facebook feed to a csv file | |
yuzawa-san | |
https://github.com/yuzawa-san | |
""" |
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 urllib, urllib2, json | |
''' | |
The ``FacebookTestUserManager`` module | |
====================================== | |
Author: Weizhong Yang <zonble at gmail dot com> | |
A tool which helps to create and delete test account for Facebook. |
NewerOlder