This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*! | |
| powerfullz 的 Substore 订阅转换脚本 | |
| https://github.com/powerfullz/override-rules | |
| 支持的传入参数: | |
| - loadbalance: 启用负载均衡(url-test/load-balance,默认 false) | |
| - landing: 启用落地节点功能(如机场家宽/星链/落地分组,默认 false) | |
| - ipv6: 启用 IPv6 支持(默认 false) | |
| - full: 输出完整配置(适合纯内核启动,默认 false) | |
| - keepalive: 启用 tcp-keep-alive(默认 false) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #define da_append(xs, x) \ | |
| do { \ | |
| if ((xs)->count >= (xs)->capacity) { \ | |
| if ((xs)->capacity == 0) (xs)->capacity = 256; \ | |
| else (xs)->capacity *= 2; \ | |
| (xs)->items = realloc((xs)->items, (xs)->capacity*sizeof(*(xs)->items)); \ | |
| } \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Forked from https://gist.github.com/pganssle/0e3a5f828b4d07d79447f6ced8e7e4db | |
| # Licensed under MIT License which the author permits to release with. | |
| # Copyright 2024 Takumi Sueda | |
| # Copyright 2019 Paul Ganssle | |
| # A clang-format style that approximates Python's PEP 7 | |
| # Useful for IDE integration | |
| BasedOnStyle: Google | |
| AlwaysBreakAfterReturnType: AllDefinitions | |
| AllowShortIfStatementsOnASingleLine: false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import pandas as pd | |
| import numpy as np | |
| from scipy.optimize import curve_fit | |
| import matplotlib.pyplot as plt | |
| import sympy as sp | |
| from pandas.plotting import table | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # 变量 | |
| YUBIKEY5CNFC_PUBLIC_KEY="sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIDjFtyHmKX9UovGeZvQhyy7tSKcKVyMMWsZqgcO6QpXcAAAABHNzaDo= Realtong's Yubikey 5C NFC" | |
| YUBIKEY5NFC_PUBLIC_KEY="sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIHGPu9ys/hNYveYQeJYtYIGfoedzWPPKsswMTc8prhxSAAAABHNzaDo= Realtong's Yubikey 5 NFC" | |
| echo -e "\n🔍 检测依赖...\n" | |
| # Check if curl is installed | |
| if ! command -v curl &> /dev/null |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # This script will add the directory where it is located to the PATH | |
| # if it's not already included. | |
| # Get the directory of the current script, regardless of where it's called from | |
| DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" | |
| # Check if the directory is already in PATH | |
| if [[ ":$PATH:" != *":$DIR:"* ]]; then | |
| # Add the script directory to PATH for the duration of this session or |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import numpy as np | |
| import pybullet as pyb | |
| import pybullet_data | |
| def make_box( | |
| position, half_extents, orientation=(0, 0, 0, 1), mass=1.0, color=(1, 0, 0, 1) | |
| ): | |
| collision_uid = pyb.createCollisionShape( | |
| shapeType=pyb.GEOM_BOX, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # install nerd fonts: | |
| declare -a fonts=( | |
| # BitstreamVeraSansMono | |
| # CodeNewRoman | |
| # DroidSansMono | |
| FiraCode | |
| FiraMono | |
| # Go-Mono | |
| # Hack | |
| # Hermit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import pybullet as p | |
| import numpy as np | |
| def draw_frame(T: np.ndarray) -> None: | |
| """ Draw a frame represented by the 4-by-4 homogenous transformation matrix T.""" | |
| for i in range(3): | |
| color = [0, 0, 0] | |
| color[i] = 1 | |
| p.addUserDebugLine( | |
| lineFromXYZ=T[:3, 3], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
| { | |
| "log": { | |
| "level": "info", | |
| "output": "sing-box.log", | |
| "timestamp": true | |
| }, | |
| "dns": { | |
| "servers": [ | |
| { | |
| "tag": "cloudflare", |
NewerOlder