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
// ==UserScript== | |
// @name PKU Auto Click | |
// @namespace https://gist.github.com/AllanChain/c0782061f9e9836e2807a81acfe3b254 | |
// @version 3.5 | |
// @description 自动点击 PKU IAAA,教学网和邮箱的登录键,首次使用需手动点击一次以使插件记录密码。 | |
// @icon https://www.pku.edu.cn/favicon.ico | |
// @author Allan Chain | |
// @copyright 2020 - 2024, Allan Chain | |
// @homepageURL https://gist.github.com/AllanChain/c0782061f9e9836e2807a81acfe3b254 | |
// @supportURL https://gist.github.com/AllanChain/c0782061f9e9836e2807a81acfe3b254 |
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
{ | |
"triggerSettings": null, | |
"dollarTrigger": false, | |
"selectEdit": false, | |
"selectModifier": "Shift", | |
"formatSettings": null, | |
"preferDisplay": false, | |
"preferMultiline": true, | |
"smartFormat": true, | |
"mathliveSettings": null, |
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/python3 | |
import sys | |
import subprocess | |
from PySide6 import QtCore, QtWidgets, QtGui | |
class MyWidget(QtWidgets.QLabel): | |
def __init__(self): | |
super().__init__() |
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
from bs4 import BeautifulSoup | |
from pathlib import Path | |
from dataclasses import dataclass | |
import urllib.request | |
import re | |
from unicodedata import normalize | |
from mutagen.mp3 import EasyMP3 | |
DOWNLOAD_TEMPLATE = "http://music.163.com/song/media/outer/url?id=%s.mp3" |
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
# Learn from https://mrigank11.github.io/2018/03/zsh-auto-completion/ | |
function _scancel { | |
_describe 'command' "($(squeue -h -o '%i:%T-%j' -u $USER))" | |
} | |
compdef _scancel scancel |
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
% | |
% Copyright (c) Tailwind Labs, Inc. | |
% | |
% Permission is hereby granted, free of charge, to any person obtaining a copy | |
% of this software and associated documentation files (the "Software"), to deal | |
% in the Software without restriction, including without limitation the rights | |
% to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
% copies of the Software, and to permit persons to whom the Software is | |
% furnished to do so, subject to the following conditions: | |
% |
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
zrmfast = {} | |
for line in open('./zrmfast.dict.yaml'): | |
if not '\t' in line or not '[' in line: | |
continue | |
char, code, *_ = line.strip().split('\t') | |
zrmfast[char] = code.split('[')[1] | |
lines = [] | |
for line in open('/usr/share/rime-data/luna_pinyin.dict.yaml'): | |
if not '\t' in line: |
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 | |
bat_status=$(cat /sys/class/power_supply/BAT1/status) | |
if [[ $bat_status != "Discharging" ]]; then | |
# More programs before Wayland tray is reday | |
sleep 30 # wait for Wayland tray | |
/usr/bin/safeeyes & | |
# More... | |
fi |
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
# : << EOF | |
# https://github.com/gpakosz/.tmux | |
# (‑●‑●)> dual licensed under the WTFPL v2 license and the MIT license, | |
# without any warranty. | |
# Copyright 2012— Gregory Pakosz (@gpakosz). | |
tmux_conf_24b_colour=auto | |
# default theme | |
tmux_conf_theme_colour_1="#2e3440" # dark gray | |
tmux_conf_theme_colour_2="#3b4252" # gray |
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
tmux_conf_theme_colour_1="#2e3440" # dark gray | |
tmux_conf_theme_colour_2="#3b4252" # gray | |
tmux_conf_theme_colour_3="#4c566a" # light gray | |
tmux_conf_theme_colour_4="#5e81ac" # light blue | |
tmux_conf_theme_colour_5="#ebcb8b" # yellow | |
tmux_conf_theme_colour_6="#2e3440" # dark gray | |
tmux_conf_theme_colour_7="#e5e9f0" # white | |
tmux_conf_theme_colour_8="#2e3440" # dark gray | |
tmux_conf_theme_colour_9="#ebcb8b" # yellow | |
tmux_conf_theme_colour_10="#d08770" # pink |
NewerOlder