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
| # 在野外如果pixel 8 pro手机意外重启, 则无法注册中国移动/联通运营商, 而adb也无法借助wifi配对,需要: | |
| # android linux terminal与shizuku app是一样的 都无法独立设备启动adbd的tcp模式, | |
| # 要么带另外手机开wifi热点(A方案), 要么带电脑通过usb有线执行adb tcpip启动tcp模式监听5555端口(B方案), | |
| # 或者不想带第二手机或电脑,更geek点让codex往esp32 s3 FH4R2小开发板(淘宝15元)写个wifi ap(对应A方案)或adb client(对应B方案),野外时插手机上 | |
| # 因为android linux terminal子系统每次重启都会更换ip, 需要在/home/droid下写个adb_connect.sh, | |
| # 用adb连接宿主android, 并把子系统的ssh 22端口暴露为127.0.0.1:2222(方便chuchu等terminal app用固定ip连接: ssh -p 2222 droid@127.0.0.1), | |
| # 暴露为手机所在wifi内网的2222(方便内网电脑ssh客户端连接: ssh -p 2222 droid@192.168...) | |
| $ cat adb_connect.sh |
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
| # put your sshdog into a github release or other public url | |
| # tell your muse ai to curl download your sshdog url and run it (listen at 127.0.0.1:2222) | |
| # in your local machine: cloudflared tunnel login, cloudflared tunnel create muse_con_1, cloudflared tunnel route dns muse_con_1 muse_con_1.mydomain.com, cloudflared tunnel list | grep muse_con_1, cat ~/.cloudflared/<tunnel id>.json | |
| # tell your muse ai the <tunnel id>.json content to create json file ~/.cloudflared/<tunnel id>.json | |
| # tell your muse ai create edge_forward.py and run it (listen at 127.0.0.2:7844, target to 198.41.200.233:7844) | |
| # tell your muse ai to run: cloudflared tunnel --protocol http2 --no-autoupdate --edge-ip-version 4 --edge 127.0.0.2:7844 --url ssh://localhost:2222 run <tunnel id> | |
| # tell your muse ai to create ensure.sh and schedule it every 2 minutes | |
| ==============================edge_forward.py======================================== |
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
| //预先填好购票车次和人, 打开预填页面看看是否填正确了并保持在该页面: https://kyfw.12306.cn/otn/view/prefill_order.html | |
| //先同步电脑时间, 因为太早或晚一秒都会在发第2个请求POST的时候失败, debian系统下: sudo ntpdate -u ntp.aliyun.com 然后用https://time.is 可验证误差 | |
| //然后打开浏览器console, 在firefox里是F12 | |
| //在开抢前5分钟仍要自己刷新及登录12306, 因为即使脚本在跑登录仍会过期, 也可以采用在同一浏览器另一个tab页面自动刷新 | |
| //贴入下方脚本并回车开始运行 | |
| (function() { | |
| console.log('12306 预填强票自动点击脚本已启动...'); | |
| let buyClicked = 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
| apply linuxone trial(60 days) with a github project: https://linuxone.cloud.marist.edu/ | |
| activate account from receipt email | |
| login and click "Manage instances", create ubuntu 22.04(CPU 2 core, RAM 4GB, disk 50GB), import pub key | |
| ssh linux1@<ip addr> | |
| sudo apt install docker-ce | |
| sudo apt install -y qemu-user-static binfmt-support | |
| sudo docker run --platform linux/amd64 --volume /run/dbus:/run/dbus --security-opt apparmor=unconfined --cap-add=SYS_PTRACE -it ubuntu:latest /bin/bash | |
| sudo docker attach <container id> |
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
| 2025年出现免费esim美国手机号: | |
| 安装helium mobile应用,用中国护照和假美国地址注册帐号, | |
| 得到形如"LPA:1$t-mobile.idemia.io$..."密钥, | |
| 在android手机设置的已有移动网络旁点击"+"号, | |
| 下载新ESIM, 点击wifi下载,点击扫码页面底下"Need Help",点击"手工输入"即可通过联通/移动激活 | |
| 手机不支持esim的需买9esim等空白手机卡(京东130元), | |
| android手机用9esim的应用或者越狱安装magisk+magisk-module-openeuicc重启后写卡 | |
| 虽可经 联通/中移动 漫游激活手机卡 且含 免费 电话/短信/流量 套餐, | |
| 但只能通过Wi-Fi calling来使用 电话/短信 |
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
| # -*- coding: utf-8 -*- | |
| # Make by x:@BoxMrChen and windsurf ai | |
| import asyncio | |
| import base64 | |
| import json | |
| import io | |
| import os | |
| import sys | |
| import pyaudio |
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
| # Run Docker container with latest Ubuntu and pass DISPLAY | |
| $ xhost +local:root #先允许Docker容器访问host的X服务器 | |
| $ docker run --net=host --env="DISPLAY" --volume="$XAUTHORITY:/root/.Xauthority:rw" -it ubuntu | |
| # Install simple GUI applications for test | |
| $ apt update && apt install -y x11-apps | |
| # Run GUI application 'calculator' | |
| $ xcalc |
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
| llama3-70b-8192的翻译是有问题的, 会导致1024字节缓冲区的后半段数据(下一个udp包的不完整前半部)作为一个udp包发送 | |
| claude-3-opus-20240229的翻译 性能好于 gpt-4-turbo-2024-04-09的翻译 | |
| =================================python gpt4 生成 65行============================================================ | |
| import aiohttp | |
| from aiohttp import web | |
| import socket | |
| import base64 | |
| import asyncio |
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
| ref: https://github.com/sleeyax/cronet-binaries/issues/1 | |
| package main | |
| import ( | |
| "net/http" | |
| "os" | |
| "github.com/sagernet/cronet-go" | |
| ) |
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
| ### Keybase proof | |
| I hereby claim: | |
| * I am diyism on github. | |
| * I am diyism (https://keybase.io/diyism) on keybase. | |
| * I have a public key whose fingerprint is 11A9 8349 5D23 9308 4FF7 772A 098B 48D8 50FB 1759 | |
| To claim this, I am signing this object: |
NewerOlder