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
# ref.) http://www.andrews-corner.org/abcde.html | |
ACTIONS=cddb,playlist,read,encode,tag,move,clean | |
# cddb | |
CDDBURL="http://freedbtest.dyndns.org/~cddb/cddb.cgi" | |
CDDBCOPYLOCAL="y" | |
CDDBLOCALDIR="/data/media/abcde/cddb" | |
CDDBLOCALRECURSIVE="y" | |
CDDBUSELOCAL="y" |
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
{-# LANGUAGE RelaxedPolyRec, FlexibleInstances, TypeSynonymInstances #-} | |
-- RelaxedPolyRec needed for inlinesBetween on GHC < 7 | |
{- | |
Copyright (C) 2012-2015 John MacFarlane <[email protected]> | |
This program is free software; you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by | |
the Free Software Foundation; either version 2 of the License, or | |
(at your option) any later version. |
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
fn get_raw_bytes<T>(p: *const T) -> Vec<u8> { | |
// https://www.reddit.com/r/rust/comments/2ngnmk/viewing_any_object_as_a_raw_memory_array/ | |
let size = std::mem::size_of::<T>(); | |
let mut buf = Vec::with_capacity(size); | |
let view = p as *const _ as *const u8; | |
for i in 0..size { | |
buf.push(unsafe {*view.offset(i as isize)}); | |
} | |
buf | |
} |
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
#!/usr/bin/env python3 | |
#SOLARIZED HEX 16/8 TERMCOL XTERM/HEX L*A*B RGB HSB | |
#--------- ------- ---- ------- ----------- ---------- ----------- ----------- | |
solstr = """ | |
base03 #002b36 8/4 brblack 234 #1c1c1c 15 -12 -12 0 43 54 193 100 21 | |
base02 #073642 0/4 black 235 #262626 20 -12 -12 7 54 66 192 90 26 | |
base01 #586e75 10/7 brgreen 240 #585858 45 -07 -07 88 110 117 194 25 46 | |
base00 #657b83 11/7 bryellow 241 #626262 50 -07 -07 101 123 131 195 23 51 | |
base0 #839496 12/6 brblue 244 #808080 60 -06 -03 131 148 150 186 13 59 |
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
//P. B. C. (Periodic Boundary Condition) by taskie | |
//derived from simple yoke-game sample by MASA | |
//color scheme: http://ethanschoonover.com/solarized | |
float boxW, boxH, boxX, boxY; | |
float bulletX[], bulletY[];//bullet position (x, y) | |
float bulletVx[], bulletVy[];//bullet velocity (x, y) | |
boolean isMyBullet[]; | |
float bulletR = 5;//bullet radius |
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
#!/usr/bin/env fontforge -lang=py -script | |
# -*- coding: utf-8 -*- | |
import fontforge | |
import sys | |
import os | |
def _select_codepoint(codepoint, selection, more=True): | |
more_str = 'more' if more else 'less' | |
if isinstance(codepoint, tuple) and len(codepoint) == 2: |
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
# How to install Arch Linux | |
# ref.) https://wiki.archlinuxjp.org/index.php/%E3%82%A4%E3%83%B3%E3%82%B9%E3%83%88%E3%83%BC%E3%83%AB%E3%82%AC%E3%82%A4%E3%83%89 | |
# ref.) http://qiita.com/macchaberrycream/items/1dfabe8b710dc638e3f9 | |
# (boot from install CD) | |
loadkeys jp106 | |
EDITOR=vi | |
# partition |
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
<?xml version='1.0'?> | |
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'> | |
<fontconfig> | |
<!-- fallback --> | |
<match target="pattern"> | |
<test name="family" compare="not_eq" qual="all"> | |
<string>sans-serif</string> | |
</test> | |
<test name="family" compare="not_eq" qual="all"> | |
<string>serif</string> |
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 | |
status () { | |
cd .vnc | |
local pidfile=$(hostname):1.pid | |
if [[ -f $pidfile ]]; then | |
local pid=$(cat $pidfile) | |
echo PID: $pid | |
if kill -0 $pid; then | |
echo "running" |
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
#!/usr/bin/env ruby | |
devices = `xcrun simctl list devices`.each_line do |line| | |
if line =~ /[^\(]+\(([^\)]+)\)/ | |
puts $1 | |
`xcrun simctl delete #{$1}` | |
end | |
end |