Skip to content

Instantly share code, notes, and snippets.

@Canorus
Canorus / result.log
Created December 19, 2022 14:25
command qmk fails
(.env) Mac-mini-2020:qmk_firmware canor$ python3 -m pip install -r requirements.txt
Collecting appdirs
Using cached appdirs-1.4.4-py2.py3-none-any.whl (9.6 kB)
Collecting argcomplete
Using cached argcomplete-2.0.0-py2.py3-none-any.whl (37 kB)
Collecting colorama
Using cached colorama-0.4.6-py2.py3-none-any.whl (25 kB)
Collecting dotty-dict
Using cached dotty_dict-1.3.1-py3-none-any.whl (7.0 kB)
Collecting hid
@Canorus
Canorus / live\app\javascript\fonts\HBIOS-SYS
Last active February 4, 2023 14:41
Mastodon theme for HBIOS-SYS
https://noonnu.cc/font_page/960 에서 폰트 파일을 다운로드 해주세요.
@Canorus
Canorus / New_Keyboard_Shield_KR.md
Last active May 9, 2022 17:38
ZMK의 새 키보드 쉴드 만들기 문서를 한글화 해보았습니다.

원본 문서

새 키보드 쉴드

개요

이 가이드에서는 (Pro Micro 호환) MCU 보드를 사용하는 키보드에 ZMK 지원을 추가하기 위한 과정을 안내합니다. 큰 틀에서의 단계는:

  • 새 쉴드 디렉터리를 생성
  • 기본 Kconfig 파일들을 추가
@Canorus
Canorus / bot.py
Created October 11, 2021 07:54
Mastodon 인스턴스에서 favourite 한 툿들 중에 키워드를 포함하고 있는 툿을 검색해서 dm으로 보내주는 스크립트
import sys
import requests
import os
import json
from time import sleep
import re
base = os.path.join(os.path.dirname(os.path.abspath(__file__)),'')
with open(os.path.join(base, 'config.txt')) as f:
@Canorus
Canorus / darkreader.js
Created September 4, 2021 02:44 — forked from kfur/darkreader.js
Dark Reader userscript for Safari browser
// ==UserScript==
// @name DarkReader
// @match *://*/*
// @grant none
// @run-at document-start
// ==/UserScript==
// MIT License
// Copyright (c) 2019 Alexander Shutau
@Canorus
Canorus / Synology utf8(NFC) conversion script
Created June 16, 2021 11:22
Convert filenames to NFC so that DSM can correctly handle filenames (and files be seen from other OSes using NFD normalization(macOS/Linux))
#!/bin/sh
encode() {
prefix=$1
ls -a | while read line
do
if [ "." == "$line" ] || [ ".." == "$line" ]; then
continue
fi
@Canorus
Canorus / cleaner.sh
Last active May 4, 2021 05:31
move duplicate .mp3 file into 'trashcan' directory, bash >= 4.0
$(shopt -s globstar)
if ! [ -d trashcan ]; then
mkdir trashcan
fi
for file in */**/*\ 1.mp3;
do
if [ -f "${file/ 1.mp3/.mp3}" ] ; then
echo $file
@Canorus
Canorus / bulk_conversion.scpt
Last active March 11, 2021 15:36
applescript to batch convert hwp files to pdf
on findAndReplaceInText(theText, theSearchString, theReplacementString)
set AppleScript's text item delimiters to theSearchString
set theTextItems to every text item of theText
set AppleScript's text item delimiters to theReplacementString
set theText to theTextItems as string
set AppleScript's text item delimiters to ""
return theText
end findAndReplaceInText
tell application "Finder"
@Canorus
Canorus / bot.py
Created October 26, 2020 16:36
selenium chromedriver sample for beginners
# download chromedriver matching your chrome browser version from here https://chromedriver.chromium.org and place it with this Python file
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.common.by import By
import os
@Canorus
Canorus / keymaps default config.h
Created October 13, 2020 15:58
soflekeyboard LED
#pragma once
/* The way how "handedness" is decided (which half is which),
see https://docs.qmk.fm/#/feature_split_keyboard?id=setting-handedness
for more options.
*/
#define RGB_DI_PIN D3
#define RGBLED_NUM 5
#define RGBLED_SPLIT { 5, 0 }