Skip to content

Instantly share code, notes, and snippets.

View wynemo's full-sized avatar
:octocat:
找工作中

Nemo.Zhang wynemo

:octocat:
找工作中
View GitHub Profile
@wynemo
wynemo / merge.py
Last active December 16, 2024 00:07
sing-box 例子
import json
import sys
# 用法
# nodes.json 可以用Sub-Store生成 sing-box 格式的
# python3 merge.py sing-box-basic.json nodes.json
# 文件已成功更新并保存为 sing-box-basic-updated.json
# 节点
with open(sys.argv[2], "r", encoding="utf-8") as nodes_file:
@wynemo
wynemo / simple_clash.yaml
Last active November 22, 2024 14:37
clash 配置
# Profile Enhancement Merge Template for Clash Verge
profile:
store-selected: true
geodata-mode: false
geox-url:
geosite: "https://cdn.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@release/geosite-lite.dat"
geoip: "https://cdn.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@release/geoip-lite.dat"
mmdb: "https://cdn.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@release/country-lite.mmdb"
@wynemo
wynemo / Youtube Advanced Speed Controller.user.js
Last active June 16, 2023 17:12
Youtube Advanced Speed Controller
// ==UserScript==
// @name Youtube Advanced Speed Controller
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Allows you to play youtube videos from 0 to 16 times normal speed
// @author Ehren Julien-Neitzert
// @match https://www.youtube.com/*
// @grant none
// ==/UserScript==
@wynemo
wynemo / z-lib-douban.user.js
Last active December 5, 2022 16:56
在豆瓣查找Z-lib资源
// ==UserScript==
// @name 在豆瓣查找Z-lib资源
// @description 直接查找在Z-lib网站上的书籍资源
// @namespace http://tampermonkey.net/
// @version 0.5
// @author Tim
// @match https://book.douban.com/*
// @grant GM_xmlhttpRequest
// @license MIT
// ==/UserScript==
@wynemo
wynemo / main.py
Created August 30, 2022 16:00
sqlalchemy sqlite in memory static pool
from sqlalchemy import create_engine
from sqlalchemy.orm import sessionmaker
from sqlalchemy.pool import StaticPool
import sqlite3
# According to SQLite documentation, both strings below should create in-memory databases:
#url_mode_memory = "sqlite:///file:foo.db?mode=memory&uri=true"
url_mode_memory = "file:foo.db?mode=memory&cache=shared"
sql_url = f'sqlite:///{url_mode_memory}'
@wynemo
wynemo / psycopg2 python2.6.md
Last active December 21, 2020 01:40
psycopg2 python2.6.md

gcc

yum install gcc

install pg 10

sudo yum install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-6-x86_64/pgdg-redhat-repo-latest.noarch.rpm
sudo yum install -y postgresql10-server
sudo service postgresql-10 initdb
sudo chkconfig postgresql-10 on
@wynemo
wynemo / .bashrc
Created October 14, 2019 15:57
haha.bashrc
#~/.bashrc
cat << EOF
........;,',,...
....,lxkOK0K0XXXXXXKK0koc:,.
.c,.cOKXXXXXXXXXXXXXXXXXXXXXXKOkd:.
.;,:o0KK00KXXXXKKKK00OOO0K0KKKXXXXXXKx,
;;...,::;lk0d,...... ...':xKXXXXKl
d0do, .c,. .xXXXXXl

use aptitude to install redsocks:

pi@raspberrypi:~ $ sudo aptitude show redsocks Package: redsocks
Version: 0.5-1 State: installed

@wynemo
wynemo / 519888.py
Last active August 19, 2022 05:31
同花顺买519888
import pyautogui
import time
pyautogui.moveTo(134, 1)
pyautogui.click()
pyautogui.hotkey('f1')
pyautogui.moveTo(260, 112)
pyautogui.click()
pyautogui.typewrite('519888')
time.sleep(0.5)
pyautogui.moveTo(278, 201)