Skip to content

Instantly share code, notes, and snippets.

View Ran-Xing's full-sized avatar
💭
I may be slow to respond.

星冉 Ran-Xing

💭
I may be slow to respond.
View GitHub Profile
@Ran-Xing
Ran-Xing / A-English Documentation.md
Last active February 14, 2025 01:28
删除多余的网络适配器,解决强迫症的烦恼,(WLAN 2 WLAN 3 本地连接 2 本地连接 3)

Purpose

The purpose of this script is to help users remove redundant network adapter entries, particularly the frequently appearing duplicates like "WLAN 2," "WLAN 3," "Local Area Connection 2," "Local Area Connection 3," etc. These unnecessary network adapter entries often affect system network management and stability, especially when devices are frequently connected and disconnected. This script allows users to easily remove these entries and resolve the frustration of OCD (Obsessive-Compulsive Disorder) when it comes to network configurations.

Features Overview

  1. Registry Backup: Before performing any changes, the script automatically backs up the registry to ensure that the system can be restored if something goes wrong.
@Ran-Xing
Ran-Xing / 7-README.md
Last active January 25, 2025 13:31
openwrt、usb network、gateway update、custom domain host、wifi adb、wifi ap

Do it:

usb in:

  1. Check PCI Status
  2. Start ADB Service(-a)
  3. Check ADB Auth
  4. Start WiFi-ADB
  5. ADB Forward TO OpenWrt
@Ran-Xing
Ran-Xing / A. Disable Device Enrollment Program (DEP) notification on macOS Sonoma.md
Last active June 4, 2024 07:11
Disable Device Enrollment Program (DEP) notification on macOS Sonoma.md
@Ran-Xing
Ran-Xing / pre-commit.yaml
Created January 6, 2024 05:56
Github Action Commit to PR
name: PR 预处理
on:
push:
branches:
- 'feature/**'
permissions:
pull-requests: write
jobs:
@Ran-Xing
Ran-Xing / cli.yaml
Created January 6, 2024 05:55
Github CICD
name: 编译测试
# 该脚本仅在 PR MERGE 的时候进行测试,不建议 将测试结果上传到 github
# 可以通过变量来判断,比如 PR close 的时候 发布 github release & tag
on:
pull_request:
branches:
- master # 正式版本
types:
- synchronize
@Ran-Xing
Ran-Xing / testNetWork.sh
Last active August 2, 2023 13:36
testNetWork.sh
if curl -s -m 5 -o /dev/null -w "%{http_code}" www.google.com | grep -q "200"; then
echo "true"
else
echo "false"
fi
@Ran-Xing
Ran-Xing / Dockerfile
Created March 22, 2023 12:40
openwrt builder docker lede
FROM ubuntu:20.04
WORKDIR /app
RUN apt-get -qq update \
&& apt-get -qq upgrade \
&& ln -sf "/usr/share/zoneinfo/${TZ}" /etc/localtime \
&& echo "${TZ}" > /etc/timezone \
&& ln -sf "$(which bash)" "$(which sh)" \
&& apt-get -qq full-upgrade \
@Ran-Xing
Ran-Xing / main.go
Created October 15, 2022 02:17
Full platform network test
module testnetwork
go 1.18
require github.com/fatih/color v1.13.0
require (
github.com/mattn/go-colorable v0.1.9 // indirect
github.com/mattn/go-isatty v0.0.14 // indirect
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8 // indirect
@Ran-Xing
Ran-Xing / curl.sh
Created August 14, 2022 16:14
Batch modify github code
TOKEN="ghp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
USER_NAME="Ran-Xing"
jq '.[].ssh_url' <(curl \
-s \
-H "Accept: application/vnd.github+json" \
-H "Authorization: token $TOKEN" \
"https://api.github.com/users/$USER_NAME/repos?type=all&sort=&direction=&per_page=100&page=") \
| grep $USER_NAME