Skip to content

Instantly share code, notes, and snippets.

View KevinMX's full-sized avatar
🏠
Working from home

Kevin.MX KevinMX

🏠
Working from home
View GitHub Profile
// ==UserScript==
// @name U2 Show Peer location
// @namespace https://u2.dmhy.org
// @version 1.2.1
// @description Show Peer location
// @author Husky
// @match https://u2.dmhy.org/details.php?id=*
// @match https://u2.dmhy.org/userdetails.php?id=*
// @grant none
// @require https://unpkg.com/xhook@latest/dist/xhook.min.js
@ssz66666
ssz66666 / notes.md
Last active January 4, 2021 09:49
Building Anbox Android image on Arch Linux

Build Anbox Android image on Arch Linux

Introduction

This is a note for building the anbox Android image on my Arch Linux laptop.

This closely follows the official guide.

Install build dependencies

# -*- encoding: utf-8 -*-
# Author: Epix
#
# Ban Xunlei IP for deluge
# This script will check deluge connected peers per 30 seconds.
# When an IP with UA in `BAN_PATTERNS` is found, the IP will be added to `BLOCK_LIST_FILE`.
# However if the IP is uploading or reporting 100% progress, it will say "WTF?"
import logging
@lilydjwg
lilydjwg / gh-check
Last active March 20, 2025 01:02
gh-check: speed test to known GitHub IPs
#!/usr/bin/python3
import asyncio
import time
import socket
import argparse
import aiohttp
class MyConnector(aiohttp.TCPConnector):
@cjyar
cjyar / mbr-to-gpt-uefi.md
Last active May 3, 2026 09:23
Convert a disk from MBR to GPT+UEFI, in Linux.

Before starting, make sure you have a backup, and make sure to have a linux live boot ready to rescue your system. It's easy to mess this up!

  1. Use gdisk to convert the partition table to GPT.

    gdisk /dev/sda

  2. Create the "BIOS boot" partition that GRUB needs.

    n to create a new partition. Needs to be about 1MB. You can probably squeeze this in from sectors 34-2047. Use L or l to look up the code for "BIOS boot" (ef02).

  3. Write the new partition table.

    w

  4. Reload the partition table. > partprobe /dev/sda
@Brottweiler
Brottweiler / syyu.md
Created February 22, 2019 21:58
pacman -Syyu vs. pacman -Syu

pacman -Syu

  • User: Hey server do you have any new packages or updates or changes at all
  • Server: no
  • User: Ok bye

pacman -Syyu

  • User: hey server do you have any new packages or updates at all
  • Server: no
@KyonLi
KyonLi / S22v2ray
Created February 10, 2019 07:52
entware v2ray
#!/bin/sh
ENABLED=yes
PROCS=v2ray
ARGS="-config /opt/etc/v2ray/config.pb -format=pb"
PREARGS=""
DESC=$PROCS
PATH=/opt/sbin:/opt/bin:/opt/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
SRC_BYPASS_IP_FILE=/opt/etc/v2ray/src_bypass_ip.txt
@AveYo
AveYo / .. MediaCreationTool.bat ..md
Last active July 19, 2026 02:05
Universal MediaCreationTool wrapper for all MCT Windows 10 versions - MOVED TO github.com/AveYo/MediaCreationTool.bat
// ==UserScript==
// @name U2 大量派發紅包腳本
// @version 0.0.5
//
// @description 在 U2 大量派發紅包的好工具
// @author a0000778
//
// @downloadURL https://share.a0000778.name/userscript/U2/gift.user.js
// @updateURL https://share.a0000778.name/userscript/U2/gift.meta.js
//
# -*- coding:utf-8 -*-
# !/usr/bin/env python3
'''
Author: ayasakinagi
Email: xyz.wang@outlook.com
环境: Python3
依赖: deluge_client
使用: 修改host, port, username, password, limitSize, dataPath变量