Skip to content

Instantly share code, notes, and snippets.

:octocat:
NullPointerException.

Eana Hufwe blueset

:octocat:
NullPointerException.
Block or report user

Report or block blueset

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@blueset
blueset / pok3r.json
Created Oct 10, 2017
Eana's Karabiner-Element Complex Modifications
View pok3r.json
{
"title": "Eana's POK3R Mods",
"rules": [
{
"description": "[POK3R] Cmd+ESC to Cmd+`",
"manipulators": [
{
"conditions": [{
"type": "device_if",
"identifiers": [{"vendor_id": 1241, "product_id": 321}]
@blueset
blueset / kagami3.py
Created Sep 10, 2017
Utsushidasu Kagami ver 3
View kagami3.py
import telegram
import telegram.ext
import re
# Utsushidasu Kagami Bot v3
# With sticker removal and off-topic transfer.
# License: MIT
"""
Copyright 2017 Eana Hufwe
@blueset
blueset / README.md
Last active May 14, 2017
COMP20007 Assignment 2: 2017 Sem 1 — Auto Test Script
View README.md

Hash table assignment auto test script

This script generates random commands based on the method provided by cmdgen.c, feeds it to the program and verify automatically. All table prints for stage 1, 2, 3 should follow the format provided in the template. For stage 4, the template should follow the merged format of previous stages.

This script tests:

  • Result of insertion
  • Result of query
  • Availablity, preciseness, uniqueness of keys in the printed table
@blueset
blueset / tcdrop.sh
Last active Apr 17, 2017
TC netem Drop packets from 32000 to 60000
View tcdrop.sh
modprobe sch_netem
tc qdisc del dev eth0 root
tc qdisc add dev eth0 root handle 1: prio priomap 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
tc qdisc add dev eth0 parent 1:2 handle 20: netem loss 80% 20%
# tc filter add dev eth0 parent 1:0 protocol ip u32 match ip protocol 17 0xff match ip sport 32768 0xe000 flowid 1:2
tc filter add dev eth0 parent 1:0 protocol ip prio 1 basic match "cmp(u16 at 0 layer transport gt 31999) and cmp(u16 at 0 layer transport lt 60001) and u32(u8 0x11 0xff at 0x9)" flowid 1:2
tc qdisc ls
tc -s qdisc show dev eth0
@blueset
blueset / telegram-zh.scpt
Last active Sep 6, 2018
Telegram Swift Native load language file
View telegram-zh.scpt
-- Telegram Native Swift 汉化脚本
-- 制作:Eana Hufwe
set zh_cn to "简体中文语言文件,来自 @zh_CN 的 GitHub Repo"
set zh_tw to "正體中文化文件(台灣),尚未收录"
set zh_hk to "繁體中文化文件(香港),尚未收录"
set tlocal to "本地语言文件"
set iinput to (choose file with prompt "选择您的 Telegram Native Swift 程序。" of type {"app"} default location "Applications") as string
set tgpath to POSIX path of iinput
@blueset
blueset / README.md
Last active Jun 6, 2019
big_text_bot: Pure text sticker Telegram inline bot.
View README.md
@blueset
blueset / README.md
Last active May 14, 2019
Filter all telegram stickers messages in groups for 60 seconds.
View README.md
  1. Clone https://github.com/vysheng/tg/, and install all necessary dependencies
  2. Apply documents.patch, then ./configure && make
  3. pip3 install pytg
  4. Modify main.py and change tgdir to the correct path.
  5. Log in your tg-cli
  6. nohup ./bin/telegram-cli --json -R -W -P 4458 --permanent-peer-ids --permanent-peer-ids > /dev/null &
  7. nohup python3 kagami.py > /dev/null &
@blueset
blueset / lyricproc.py
Last active Jan 7, 2017
The Making of: Lyricova Screensaver v2
View lyricproc.py
import json
import re
from terminaltables import SingleTable
from collections import Counter
f = open("GY_posts.json").read()
data = json.loads(f)
def lang(s):
if re.match(r".*[ぁ-ヿ].*", s):
@blueset
blueset / Netease_LRC.py
Last active Jan 2, 2019
Netease LRC Downloader
View Netease_LRC.py
import requests
import argparse
import os
import re
import json
import mutagen
import base64
from mutagen import easyid3
import sys
from Crypto.Cipher import AES
You can’t perform that action at this time.