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
| import SwiftUI | |
| struct SpreadShadow: ViewModifier { | |
| let color: Color | |
| let x: CGFloat | |
| let y: CGFloat | |
| let blur: CGFloat | |
| let spread: CGFloat | |
| init(color: Color, x: CGFloat = 0, y: CGFloat = 0, blur: CGFloat = 0, spread: CGFloat = 0) { |
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
| import type { IncomingMessage } from 'http' | |
| import http from 'http' | |
| import httpProxy from 'http-proxy' | |
| import chalk from 'chalk' | |
| type Target = { host: string; port: number } | |
| type PathMapping = { '*': Target } & { [key: `/${string}`]: Target } | |
| const MAPPING = { | |
| // http://localhost:8080/api/hello -> http://localhost:8787/api/hello |
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
| #!/bin/bash | |
| for sysdevpath in $(find /sys/bus/usb/devices/usb*/ -name dev); do | |
| ( | |
| syspath="${sysdevpath%/dev}" | |
| devname="$(udevadm info -q name -p $syspath)" | |
| [[ "$devname" == "bus/"* ]] && exit | |
| eval "$(udevadm info -q property --export -p $syspath)" | |
| [[ -z "$ID_SERIAL" ]] && exit | |
| echo "/dev/$devname - $ID_SERIAL" |
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
| { | |
| "title": "For HHKB US", | |
| "rules": [ | |
| { | |
| "description": "左コマンドキーを単体で押したときに、英数キーを送信する", | |
| "manipulators": [ | |
| { | |
| "type": "basic", | |
| "from": { | |
| "key_code": "left_command", |
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
| #Space:: | |
| Send, {vkF3sc029} | |
| return | |
| ^j:: | |
| Send, {Esc} | |
| return |
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
| eval$s=%w' | |
| b="BAhsKwIFAQAAAAAAAA | |
| AAAAAAAADwPwAAAAAAAAAAAAD//x8AAAAA | |
| AAAAAPD///8/AAAAAAAAAP7/////fwAAAAAAwP//////// | |
| 8AAAAA/A8A8P//////AQCA/wEAAMD/////BwDwHwAAAADA////AwD/AwAA | |
| AAAA4P9/AO D/AQAAAAAAAP4PAPz/HwAAAAAAgP8BwP///x8AAAAA8D8 | |
| A+P////8/A AAA/gMA////////BwDAfwDw//////8fAAD8Dw | |
| D+/////z8 AAOD/AMD/////BwAAgP8fAPz///9 | |
| /AAAA//8Dg AcA//8HAID//z8A8AA |
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
| eval$s=%w'b="BAhsKwHg//////////////////////////////////////////////////////////////// | |
| ////////////////////////////A///////////DwCA/////////x8AAACA////////AAAAAMD//////wcAA | |
| AAAwP////8/AIAHfACA/////wE4/PwHAMD///8fwOf/fwAA8P///wD8/////wD+//8P4P////8PgP//fwD/// | |
| ///wDA//8D8P//////A+D/DwD///////8D+B8A+P//////fwD/AMAH/v////8B8A8Af8D/////HwD+Af4P+P/ | |
| ///8fgD/A/wH//////w/gD/h/4P//////AfwB/////////weAP8D/////////APgPAPj//////z/A/wEAAP// | |
| ////Afz/AADAHwDgDwCA//8HAPABAPgAAPD///8APgAAHwCA////f4ADAMAB+P////8fAMAPAMD//////wMA+ | |
| AEA/P//////AIB/AMD////////////////////////// /////////////////////////////////// | |
| //////////////////////////8DAA==" ;n=Marshal.load(b.unpack("m")[0]) | |
| ;e="eval$s=%w"<<39<<($s*5);o= "";j=-1;0.upto(42*85-1 | |
| ){|i|o<<((n[i]==1)?e[j+=1]: 32);o<<((i%85==84)?1 |
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
| eval$s=%w'b="BAhsKwIAAf////////////////////////////////////////////////////////////////8B/P | |
| ///////////w8A+D8A8P///////wMA/wAA+P//////PwDgPwDA////////BwD/HwD+//////9/APj/APj///////8Hg | |
| P8B/////////38AvAP//////////wdAAPj/////////fwAAAP7/////////AAAA8P///////x8AAACA///////wAQAA | |
| APz//////wMAAACA////////HwAAwAP8////////AAD4HwDg//////8H8P//AADg/////z+A/z8AAAD8/////wH8HwA | |
| AAsD/////B+APAA8AAP////8/AAcA /gAA/P////8BAAD+DwDg/////w8AAPz/AMD/////fwAA+P8PAP/// | |
| ///AQDw/x8A/P////8PwOH/PwDg// z//38A//9/A AD+w////wH4/38AAMA//P/ | |
| /D8D/HwDAAfzB//8/AP7/AOAfgA/8//8 A+P///f8 BcMD//wfA/////z8AA | |
| vz/fwD+/////wMA4P//A/D/////PwAA/v 8/gP///// /AwDw//8D/v////9/A | |
| ID//3/4//////8PAPz///////////8A4P// /////////z/A/ ////////////////// | |
| ///////////9/";n=Marshal.load(b.unpa ck("m")[0]);e ="eval$s=%w"<<39<<( |
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
| import Control.Monad.Trans.State | |
| data Auto = Auto { | |
| getNode :: Int, | |
| getValue :: [Int] | |
| } deriving Show | |
| type AutoOp = State Auto () | |
| f :: Char -> AutoOp |
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
| module.exports = function promisify(f) { | |
| return (...args) => { | |
| return new Promise((resolve, reject) => { | |
| f(...[...args, (err, data) => { | |
| if (err) { | |
| reject(err); | |
| } else { | |
| resolve(data); | |
| } | |
| }]); |
NewerOlder