Skip to content

Instantly share code, notes, and snippets.

@mokurin000
mokurin000 / win32-drive-devices.py
Created June 4, 2026 03:36
Windows Drive Information query using Administator
from ctypes import (
POINTER,
WinDLL,
Structure,
WinError,
addressof,
c_wchar,
cast,
create_string_buffer,
get_last_error,
$url = "https://fitgirl-repacks.site"
try {
$response = Invoke-WebRequest -Uri $url -Method Head -ErrorAction Stop -TimeoutSec 10
Write-Host "Accessed successfully. Status Code: $($response.StatusCode)" -ForegroundColor Green
}
catch [System.Net.WebException] {
if ($_.Exception.Response.StatusCode -eq 403) {
Write-Host "403 Forbidden detected when accessing $url" -ForegroundColor Red
}
else {
#!/bin/bash
set -e
URL="https://objects.githubusercontent.com/github-production-release-asset-2e65be/941824078/a1366113-ad92-493b-a1ca-e024ace96143?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=releaseassetproduction%2F20250305%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20250305T092505Z&X-Amz-Expires=300&X-Amz-Signature=756f0389dc3c27f2246c879ee43f2b0b46a6bfbd94fe74b24955f3aa2bac1f50&X-Amz-SignedHeaders=host&response-content-disposition=attachment%3B%20filename%3DIncuboot-0.9.3-macos-arm64.dmg&response-content-type=application%2Foctet-stream"
DMG_FILE="Incuboot-0.9.3-macos-arm64.dmg"
MOUNT_POINT="/Volumes/Incuboot"
@mokurin000
mokurin000 / ocr.py
Last active March 12, 2023 01:14
使用ffmpeg + PaddleOCR 自动生成月月妈视频第n个兰那多对应的时间戳
from paddleocr import PaddleOCR, draw_ocr
import os
ocr = PaddleOCR(lang='ch')
png_files = (f for f in os.listdir('.') if f.endswith('.png'))
last_result = -1
count = 0
ITEM_PER_LINE=4
@mokurin000
mokurin000 / naifu_launcher.py
Last active December 4, 2022 07:17
naifu_launcher.py
#!/usr/bin/python3
from os import environ, path, listdir, system
# default model
environ["MODEL_PATH"] = "models/animefull-final-pruned"
map = {
"Novel AI": "models/animefull-final-pruned",
}
models = listdir('models/custom')
function transport_query() {
transport_id="$1"
if [ x != x$transport_id ]
then xdg-open "https://m.kuaidi100.com/result.jsp?nu=$transport_id" &> /dev/null
fi
}
[19:06:50] [main/INFO]: [STDOUT]: No global eula found at /home/poly/eula.txt
[19:06:50] [main/INFO]: Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', servicesHost='https://api.minecraftservices.com', name='PROD'
[19:06:50] [main/INFO]: Reloading ResourceManager: Default, bukkit
[19:06:51] [Worker-Main-2/INFO]: Loaded 7 recipes
[19:06:52] [Server thread/INFO]: Starting minecraft server version 1.16.5
[19:06:52] [Server thread/INFO]: Loading properties
[19:06:52] [Server thread/INFO]: This server is running Yatopia version git-Yatopia-ver/1.16.5-26 (MC: 1.16.5) (Implementing API version 1.16.5-R0.1-SNAPSHOT)
[19:06:52] [Server thread/INFO]: Debug logging is disabled
[19:06:52] [Server thread/INFO]: Server Ping Player Sample Count: 12
[19:06:52] [Server thread/INFO]: Using 4 threads for Netty based IO
@mokurin000
mokurin000 / convert.sh
Created December 31, 2020 01:49
安全教育平台 TeacherMessage到教师ID 用于批量重置教师密码
grep target=\"dbl 0.txt|cat |sed 's/ <tr target="dbl" rel="//g;s!/.*!!g'