Skip to content

Instantly share code, notes, and snippets.

@bennyhuo
bennyhuo / init.gradle.kts
Last active April 29, 2024 15:53
How to config mirrors for repositories in Gradle without changing the source code of your project?
fun RepositoryHandler.enableMirror() {
all {
if (this is MavenArtifactRepository) {
val originalUrl = this.url.toString().removeSuffix("/")
urlMappings[originalUrl]?.let {
logger.lifecycle("Repository[$url] is mirrored to $it")
this.setUrl(it)
}
}
}
@Godsing
Godsing / .tmux.conf
Created May 19, 2021 08:27
Tmux 配置文件(保姆级注释,含部分插件)
# 1. 安装tpm: mkdir -p ~/.tmux/plugins && cd ~/.tmux/plugins && git clone https://github.com/tmux-plugins/tpm
# 2. 按 prefix + I(大写) 来安装插件
# 3. 安装 vim-obsession, 用 vundle 安装或: cd ~/.vim/bundle && git clone git://github.com/tpope/vim-obsession.git --depth 1 && vim -u NONE -c "helptags vim-obsession/doc" -c q
##### 以上需手工执行 #####
## 修改 tmux-prefix 键: ctrl+b --> ctrl+a
set -g prefix C-a
unbind C-b
bind a send-prefix
#set-option -g prefix2 `
@twaddington
twaddington / charles-proxy-android.md
Last active April 20, 2024 17:26
How to set up Charles Proxy for the Android Emulator.

Charles Proxy Android

Note: Consider using mitmproxy instead of Charles. There is better, more recent, documentation for using mitmproxy on Android.

Steps

1. Add the Network Security Configuration to your app

@fworks
fworks / install-zsh-windows-git-bash.md
Last active April 19, 2024 19:52
Zsh / Oh-my-zsh on Windows Git Bash