Skip to content

Instantly share code, notes, and snippets.

View goxofy's full-sized avatar
💭
stay for u.

TinK goxofy

💭
stay for u.
View GitHub Profile
@eklex
eklex / 80-mount-usb-to-media-by-label.rules
Last active April 16, 2024 18:49
udev rule for Home Assistant OS (hassio) to mount USB drives into the Supervisor Media directory
#
# udev rule
# Mount USB drive to the media directory using the partition name as mount point
#
# Description:
# Created for Home Assistant OS, this rule mounts any USB drives
# into the Hassio media directory (/mnt/data/supervisor/media).
# When a USB drive is connected to the board, the rule creates one directory
# per partition under the media directory. The newly created partition is named
# as the partition name. If the partition does not have a name, then the following
@sdhzdmzzl
sdhzdmzzl / bj-unicom-iptv.m3u
Last active April 23, 2024 07:10
北京联通iptv列表
#EXTM3U name="bj-unicom-iptv"
#EXTINF:-1,CCTV1
rtp://239.3.1.1:8000
#EXTINF:-1,CCTV2
rtp://239.3.1.2:8004
#EXTINF:-1,CCTV4
rtp://239.3.1.4:8216
#EXTINF:-1,CCTV7
rtp://239.3.1.7:8024
#EXTINF:-1,CCTV9
var CryptoJS = require('crypto-js')
var request = require('request-promise')
/*
* npm install crypto-js request-promise request
* node wx_t1t_hack.js
*/
// export function testEncription(msg, fullKey) {
// var fullKey = fullKey.slice(0, 16)
@fxkraus
fxkraus / debian-install-megacli.md
Last active April 30, 2024 04:09
Install LSI MegaCli .deb package on Debian/Ubuntu

download

wget https://docs.broadcom.com/docs-and-downloads/raid-controllers/raid-controllers-common-files/8-07-14_MegaCLI.zip

unzip

unzip 8-07-14_MegaCLI.zip
@jannson
jannson / nvpproxy.go
Created June 9, 2016 01:55
proxy for open.v.p.n
package main
import (
"bufio"
"flag"
"io"
"log"
"net"
"net/http"
"os"
@ryerh
ryerh / tmux-cheatsheet.markdown
Last active April 18, 2024 18:06 — forked from MohamedAlaa/tmux-cheatsheet.markdown
Tmux 快捷键 & 速查表 & 简明教程

注意:本文内容适用于 Tmux 2.3 及以上的版本,但是绝大部分的特性低版本也都适用,鼠标支持、VI 模式、插件管理在低版本可能会与本文不兼容。

Tmux 快捷键 & 速查表 & 简明教程

启动新会话:

tmux [new -s 会话名 -n 窗口名]

恢复会话:

OS X 屏幕录制视频转 GIF 动画

本篇文章告诉你如何在 Mac OS X 上用免费的工具来将屏幕录制视频转成 GIF 动画, 这些免费的工具是: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

步骤

首先, 使用系统自带的 "QuickTime Player" 程序来录制屏幕:

@cattyhouse
cattyhouse / Backup Archlinux and Restore to another machine
Last active November 3, 2017 01:46
Backup Archlinux and Restore to another machine
## Backup the current vps 备份当前vps
1. Clean Arch system 清理系统
pacman -Scc
2. Create an excluded file to exclude certain dirs 建立一个需要排除的目录的文件,这些文件不必要备份,新系统会自动生成
cat /root/backup/exclude.txt
/tmp/*
/root/backup/*
/proc
/dev
@acgotaku
acgotaku / baidupan
Last active April 26, 2023 04:00
新版百度云盘aria2c导出下载 ,目前只实现了核心功能.
// ==UserScript==
// @name 百度网盘aria2导出工具
// @author acgotaku311
// @description 一个方便吧百度网盘的Aria2rpc导出的脚本。
// @encoding utf-8
// @include http://*n.baidu.com/s/*
// @include http://*n.baidu.com/disk/home*
// @include http://*n.baidu.com/share/link*
// @include https://*n.baidu.com/s/*
// @include https://*n.baidu.com/disk/home*
@wen-long
wen-long / ss-redir 透明代理.md
Last active March 18, 2024 12:13
ss-redir 透明代理.md

##ss-redir 的 iptables 配置(透明代理)

透明代理指对客户端透明,客户端不需要进行任何设置就使用了网管设置的代理规则

创建 /etc/ss-redir.json 本地监听 7777 运行ss-redir -v -c /etc/ss-redir.json

iptables -t nat -N SHADOWSOCKS
# 在 nat 表中创建新链
iptables -t nat -A SHADOWSOCKS -p tcp --dport 23596 -j RETURN
# 23596 是 ss 代理服务器的端口,即远程 shadowsocks 服务器提供服务的端口,如果你有多个 ip 可用,但端口一致,就设置这个