install
url --url=http://ftp.jaist.ac.jp/pub/Linux/Fedora/releases/18/Fedora/x86_64/os/
# Yum Repos
repo --name=fedora \
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
function toIsbn13(isbn10) { | |
var digits = '978' + isbn10.substr(0, 9); | |
var tmp = digits.split('').map(function (e) { | |
return parseInt(e); | |
}).map(function (e, i) { | |
return (i % 2 == 0) ? e : e * 3; | |
}).reduce(function (a, b) { | |
return a + b; | |
}) % 10; | |
var checksum = tmp == 0 ? 0 : 10 - tmp; |
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/sh | |
if [ $# -lt 2 ]; then | |
echo "usage: $0 [DOCUMENT_ROOT] [PORT]" | |
exit 1 | |
fi | |
DOCUMENT_ROOT=$1 | |
PORT=$2 |
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/sh | |
if [ $# -lt 1 ]; then | |
echo "usage: $0 [PAGE]" | |
exit 1 | |
fi | |
OUTFILE=`mktemp` | |
BROWSER=firefox | |
PAGE=$1 |
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/sh | |
COMMAND=`cat <<JS | |
const Gio = imports.gi.Gio; | |
let settings = new Gio.Settings({ schema: 'org.gnome.desktop.input-sources' }); | |
let current = settings.get_uint('current'); | |
let sources = settings.get_value('sources').get_child_value(current); | |
let type = sources.get_child_value(0).unpack(); | |
if (type === 'xkb') { | |
let layout = sources.get_child_value(1).unpack(); |
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/env python | |
import sys | |
import fontforge | |
if __name__ == '__main__': | |
if len(sys.argv) != 5: | |
print 'usage: %s <input-font> <output-font> <hhead-ascent> <hhead-descent>' % sys.argv[0] | |
else: | |
font = fontforge.open(sys.argv[1]) |
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
(function() { | |
let completer = function (context, args) { | |
let feeds = buffer.pageInfo.f[0]; | |
let completions = []; | |
for (let [title, template] in feeds(true)) { | |
let dom = util.xmlToDom(template, document); | |
let url = dom.firstChild.href; | |
completions.push([url, title]); | |
} |
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 | |
set -e | |
if [ $# -ne 2 ]; then | |
echo "usage: $0 <base_uri> <target_dir_path>" | |
exit 1; | |
fi | |
BASE_URI=$1 |
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
(function () { | |
function contains(clazz) { | |
return 'contains(concat(" ", normalize-space(@class), " "), " ' + clazz + ' ")'; | |
} | |
mappings.addUserMap( | |
[modes.NORMAL], | |
['v'], | |
'Open links contained in a selected tweat', |
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 | |
set -e | |
DBUS_WATCH_EXPR="\ | |
type='signal',\ | |
sender='org.fedoraproject.Setroubleshootd',\ | |
interface='org.fedoraproject.SetroubleshootdIface',\ | |
member='alert'\ | |
" |