深度学习进阶,自然语言处理
容器中设置host代理
docker run -it \
-e http_proxy="http://host.docker.internal:6152" \
-e https_proxy="http://host.docker.internal:6152" \
-e all_proxy="socks5://host.docker.internal:6153" \
ubuntu /bin/bash
完成项会可能继续完善更新,以下不一定为最新。 详细todo会具体在文件中使用TODO标出。个人使用folke/todo-comments.nvim查询todu项。
个人习惯在实体书,或者使用 知之阅读 做一些读书笔记。markdown版笔记主要针对一些工具书
docker 宿主机 与 容器 进程对应关系
so $VIMRUNTIME/syntax/hitest.vim
TMUX
环境变量: TMUX="tmux" nvim
python debug config snippet
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Python: Current File",
"type": "python",
"request": "launch",
"program": "${file}",
"console": "integratedTerminal",
"justMyCode": true
},
{
"name": "Python: Celery worker",
"type": "python",
"request": "launch",
"module": "celery",
"console": "integratedTerminal",
"args": [
"-A",
"superset.tasks.celery_app",
"worker",
"-l",
"info",
"-P",
"solo",
],
"justMyCode": false
// 生产任务: celery --app=superset.tasks.celery_app beat
// 或者和beat的debug交替执行
},
{
"name": "Python: Celery beat",
"type": "python",
"request": "launch",
"module": "celery",
"console": "integratedTerminal",
"args": [
"-A",
"superset.tasks.celery_app",
"beat",
"-s",
"./superset/app/"
],
"justMyCode": false
},
{
"name": "Python: Flask",
"type": "python",
"request": "launch",
"module": "flask",
"env": {
"FLASK_APP": "superset/app.py",
"FLASK_ENV": "development",
"FLASK_DEBUG": "0"
},
"args": [
"run",
"-p",
"8066",
"--with-threads",
"--debugger",
"--host=0.0.0.0",
],
"jinja": true,
"justMyCode": false,
"console": "integratedTerminal"
},
]
}
while [ $# -gt 0 ]
do
case $1 in
-h|--help) print_usage; exit;;
# For options with required arguments, an additional shift is needed.
-i|--ip) IP="$2" ; shift;;
-p|--port) PORT="$2" ; shift;;
-f|--file) FILE="$2" ; shift;;
-t|--type) TYPE="$2" ; shift;;
(--) shift; break;;
(-*) echo "$0: invalid option $1" 1>&2; exit 1;;
(*) break;;
esac
shift
done
# 解压后,会得到output/${APP}/....,这种方式会保留文件夹层级
tar -czf output/${APP}.tar.gz output/${APP}
# -C 相当于cd到指定目录再压缩,后面跟着一个".",表示压缩 "output/${APP}" 目录
tar -czf output/${APP}.tar.gz -C output/${APP} .
What is the difference between the Bash operators [[ vs [ vs ( vs ((?
==
and =
in conditional expressions?ranger, q quit, Q quit and cd to last dir
function ranger {
local IFS=$'\t\n'
local tempfile="$(mktemp -t tmp.XXXXXX)"
local ranger_cmd=(
command
ranger
--cmd="map Q chain shell echo %d > \"$tempfile\"; quitall"
)
${ranger_cmd[@]} "$@"
if [[ -f "$tempfile" ]] && [[ "$(cat -- "$tempfile")" != "$PWD" ]]; then
cd -- "$(cat -- "$tempfile")" || return
fi
command rm -f -- "$tempfile" 2>/dev/null
}
\e[4:3m
set -g default-terminal "tmux-256color"
vim support
if $TERM =~# '\v(tmux.*)|(screen.*)'
" set any of t_so, t_se, t_ZH, t_ZR that are necessary
endif
maven 源码和doc:
mvn dependency:sources
mvn dependency:resolve -Dclassifier=javadoc
__hash__
method-adopt
会pull/usr/local/stow/ruby/bin/ruby
,stow -S ruby
后/usr/local/bin/ruby
,也就是把stow dir + package
替换为了target dir
stow -t ../stow_target_dir -S package_names -n -v
: 展示之后要做什么cd && git init --bare $HOME/.dotfiles
alias config='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'
yadm 使用教程 中提到 /etc配置,不过看起来是两个repo
# 使用.yadm作为yadm的系统文件管理目录
alias sysyadm="sudo yadm -Y $HOME/.yadm"