Skip to content

Instantly share code, notes, and snippets.

@WoHal
WoHal / docker_compose.yml
Last active March 27, 2025 06:40
yapi docker_compose file
services:
yapi:
image: wohal/yapi:latest
container_name: yapi
environment:
- VERSION=1.12.0
- HOME=/home
- PORT=3000
- [email protected] # CHANGE ME
- DB_SERVER=mongo
类别 药品通用名 原研品牌
抗生素类 头孢克洛 希刻劳
头孢呋辛 西力欣
左氧氟沙星 可乐必妥
莫西沙星 拜复乐
阿奇霉素 希舒美
头孢妥仑匹酯 美爱克
抗真菌类 盐酸特比萘芬 兰美抒
奥美拉唑 洛赛克
@WoHal
WoHal / ForceEnablingXcodeLLM.md
Created June 18, 2024 02:50 — forked from unixzii/ForceEnablingXcodeLLM.md
A guide to force enabling Xcode LLM feature on China-SKU Macs.

Introduction

Apple restricted the access to Xcode LLM (Predictive code completion) feature on China models of Mac. This guide provides a way to bypass that restriction. It's verified on macOS 15.0 Beta (24A5264n), but there is no guarentee that it will always work on later macOS versions.

Prerequisites

  • Xcode is installed and run at least once.
  • SIP debugging restrictions are disabled (via csrutil enable --without debug command in recovery mode).

Disclaimer

@WoHal
WoHal / gist:77f3372870289d0958b5c365f230d6ad
Created May 25, 2024 07:02
Windows 7 All Online/Offline [Retail-MAK] Activation Keys
Windows 7 All Online/Offline [Retail-MAK] Activation Keys
=================================================================================
. Run "Command Prompt" as Administrator
. slmgr.vbs -ipk Product Key
. slui4
=================================================================================
Windows 7 Ultimate Retail Phone Activation Keys
RHTBY-VWY6D-QJRJ9-JGQ3X-Q2289
V77DJ-CT8WB-Y3GXT-X3FBP-6F987
JC7BV-94FD2-D86PH-XRMHR-BXKDG
@WoHal
WoHal / xcode-keybindings-as-vscode.md
Created April 16, 2024 14:16 — forked from tranquan/xcode-keybindings-as-vscode.md
Xcode KeyBindings as VSCode
@WoHal
WoHal / webdav_curl.md
Created April 16, 2024 13:51 — forked from stokito/webdav_curl.md
WebDAV with curl for scripts and command line

Assuming the following:

  • Webdav share URL: http://example.com/dav/
  • Username: user
  • Password: pass

curl options:

  • -u username:password use HTTP Basic authorization with the folowing username and password
  • -X GET send a request with GET method. You can use any other methods here.

Oh my zsh.

Oh My Zsh

Install ZSH.

sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh

Install Oh my ZSH.

@WoHal
WoHal / subsetfont
Created May 26, 2020 07:34
get sub font from ttf file
const fs = require('fs');
const util = require("util");
const fontKit = require("font-toolkit");
const readFile = util.promisify(fs.readFile);
const writeFile = util.promisify(fs.writeFile);
async function save() {
// read font
const buf = await readFile("20th_bold.ttf");
function mapLimit(arr, limit, iterator) {
let count = limit;
const next = () => {
if (count > arr.length) {
return;
}
iterator(arr[count], next);
count++;
}
for (let i = 0; i < limit; i++) {