Skip to content

Instantly share code, notes, and snippets.

View xwsg's full-sized avatar
🎯
Focusing

xwsg xwsg

🎯
Focusing
  • Shandong, China
View GitHub Profile
@xwsg
xwsg / proxychains.md
Last active November 2, 2017 03:29
proxychains安装配置

1. 安装proxychains

sudo apt-get update
sudo apt-get install proxychains

2. 修改配置

@xwsg
xwsg / ubuntu-Q&A.md
Last active October 15, 2018 12:26
Q&A

1. 无法打开文件浏览器

执行 killall nautilus 后,重新打开

2. apt-get和apt区别在哪?

apt是友好版的apt-get,最大特性就是有进度条了。

3. snap 软件包管理

@xwsg
xwsg / socks5_to_http.md
Last active December 5, 2019 02:18
socks5转换为 http 代理(使用privoxy)

目前只测试了Mac和Ubuntu

1.安装 privoxy

Mac

brew install privoxy

ubuntu

@xwsg
xwsg / vscode-Q&A.md
Last active October 31, 2017 05:42
vscode常见问题

1.格式化JSON

安装 Beautify 插件后,按键 F1 调出命令面板然后输入beautify,选择 Beautify selection 或者 Beautify file. Beautify 可以格式化 javascript, JSON, CSS, Sass, 和 HTML

@xwsg
xwsg / Shell.md
Last active December 10, 2017 02:36

查看文件的中间几行

# 查看文件的第100-200行
sed -n '100,200p' filename 

nohup使用,后台运行

@xwsg
xwsg / Generate-Markdown.groovy
Created January 14, 2020 03:21
Datagrip groovy scripts
import com.intellij.database.model.ObjectKind
import com.intellij.database.util.DasUtil
FILES.chooseDirectoryAndSave("Choose directory", "Choose where to store generated files") { dir ->
def schemaMap = new LinkedHashMap<String, Map<String, String>>();
SELECTION.filter { (it.getKind() == ObjectKind.TABLE || it.getKind() == ObjectKind.SCHEMA) }.each {
def schemaName = DasUtil.getSchema(it);
if (!schemaMap.containsKey(schemaName)) {
schemaMap.put(schemaName as String, new LinkedHashMap<String, String>());