This file contains 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
#!/usr/bin/env bash | |
# Add spaces between Chinese and English, number or symbols. | |
# | |
# Dependency: This script requires the `https://www.npmjs.com/package/pangu` package. | |
# Install it via `pip install pangu` or `pnpm install -g pangu` or `npm install -g pangu`. | |
# | |
# Required parameters: | |
# @raycast.schemaVersion 1 | |
# @raycast.title Fix Chinese |
This file contains 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 os | |
import subprocess | |
import tarfile | |
import json | |
SING_BOX_DIR = "/root/sing-box" | |
CERTS_DIR = "/root/certs" | |
DOMAIN = "sjc.realtong.cn" | |
HYSTERIA2_PORT = 18090 | |
TROJAN_PORT = 18082 |
This file contains 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 requests | |
import psutil | |
import datetime | |
import pytz | |
# Discord Webhook URL | |
WEBHOOK_URL = 'https://discord.com/api/webhooks/' | |
# Your timezone | |
YOUR_TIMEZONE = 'Asia/Shanghai' |
This file contains 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
#!/usr/bin/env python3 | |
# Copy the verification code from Mail. | |
# | |
# Dependency: This script requires the `emlx` package. | |
# Install it via `pip install emlx`. | |
# | |
# Required parameters: | |
# @raycast.schemaVersion 1 | |
# @raycast.title CaptchaFromMail |
This file contains 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 | |
# Required parameters: | |
# @raycast.schemaVersion 1 | |
# @raycast.title SSID Name | |
# @raycast.mode inline | |
# @raycast.refreshTime 1m | |
# Optional parameters: | |
# @raycast.icon 🛜 |
This file contains 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
module.exports = function ({ addComponents, theme }) { | |
const screens = theme('screens') | |
const ignoredScreens = theme('debugScreens.ignore', ['dark']) | |
const selector = theme('debugScreens.selector', '.debug') | |
const components = { | |
[`${selector}::before`]: Object.assign({ | |
position: 'fixed', | |
zIndex: '50', | |
width: 6, | |
height: 6, |
This file contains 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
openssl x509 -noout -fingerprint -sha256 -inform pem -in your.pem |
This file contains 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
检测GPU是否可用 | |
python | |
>>> import torch | |
>>> torch.cuda.is_available() | |
True | |
>>> torch.cuda.current_device() | |
0 | |
>>> torch.cuda.get_device_name(0) | |
'NVIDIA GeForce RTX 3090' | |
>>> |
This file contains 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
sudo update_dyld_shared_cache -force |
This file contains 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 | |
network_interface=ens5 | |
bot_token="" | |
user_id="" | |
traffic=$(vnstat -m $network_interface | grep "estimated" | awk '{print $8}') | |
unit=$(vnstat -m $network_interface | grep "estimated" | awk '{print $9}') | |
curl -s -X POST "https://api.telegram.org/bot$bot_token/sendMessage" \ |
NewerOlder