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
" Vim syntax file | |
" Language: NSL | |
" Maintainer: KISHIMOTO, Makoto <ksmakoto@dd.iij4u.or.jp> | |
" Last Change: 2012 Jan 8 | |
" URL: https://gist.github.com/1489582 | |
" Filenames: *.nsl | |
" Version: 0.2 | |
if version < 600 | |
syntax clear |
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
RE match, based chap. 1 of "Beautiful Code" | |
> import Data.List (tails) | |
> match ('^' : re_rest) | |
> = matchhere re_rest | |
> match regexp | |
> = or . map (matchhere regexp) . tails | |
> matchhere [] _ |
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
#include <stdio.h> | |
int | |
main(void) | |
{ | |
for (;;) { | |
int c = getc(stdin); | |
printf("%d\n", c); | |
if (c == EOF) { | |
break; |
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
左カラム: パッケージ名 | |
右カラム: 「rpm -qR パッケージ名」では出てくるのに、 | |
「rpm -q --whatrequires ケーパビリティ名」に、その | |
パッケージが出てこないケーパビリティ | |
+--------------------------------------------------+ | |
| NetworkManager | systemd-sysv | | |
|----------------+---------------------------------| | |
| audit | chkconfig | | |
| | systemd-sysv | |
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/local/bin/ruby19 | |
=begin | |
Usage | |
1. Concatenate this script and some tar.gz file. | |
$ cat some.tar.gz >> this.rb |
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
module Kernel | |
def and | |
if self then yield else self end | |
end | |
def or | |
if self then self else yield end | |
end |
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/local/bin/ruby19 | |
class Acc | |
BITS = 36 | |
MASK = ("1" * BITS).to_i 2 | |
def to_s | |
s = @val.to_s 2 | |
s = s.rjust BITS, "0" | |
s[1, 0] = "." |
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
func match(regexp string, text string) bool { | |
if regexp[0] == '^' { | |
return matchhere(regexp[1:], text) | |
} | |
for { | |
if matchhere(regexp, text) { | |
return true | |
} | |
if len(text) == 0 { | |
break |
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
1) Failure: | |
test_segv_test(TestRubyOptions) [/home/ksmakoto/ruby-working/ruby-trunk/ruby-git/test/ruby/test_rubyoptions.rb:457]: | |
Expected /\A | |
-e:(?:1:)?\s\[BUG\]\sSegmentation\sfault\n | |
ruby\ 2\.0\.0dev\ \(2012\-09\-25\ trunk\ 37032\)\ \[x86_64\-freebsd8\.3\]\n\n | |
--\sControl\sframe\sinformation\s-+\n | |
(?:c:.*\n)* | |
(?: | |
--\sRuby\slevel\sbacktrace\sinformation\s----------------------------------------\n | |
-e:1:in\s\`<main>\'\n |
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
CC libmonoruntimesgen_static_la-sgen-fin-weak-hash.lo | |
CCLD libmonoruntimesgen-static.la | |
CC pedump.o | |
CCLD pedump | |
./.libs/libmonoruntime.a(libmonoruntime_la-filewatcher.o)(.text+0x7a): In function `ves_icall_System_IO_InotifyWatcher_AddWatch': | |
../../../mono/mono/metadata/filewatcher.c:161: undefined reference to `inotify_add_watch' | |
./.libs/libmonoruntime.a(libmonoruntime_la-filewatcher.o)(.text+0x11): In function `ves_icall_System_IO_InotifyWatcher_RemoveWatch': | |
../../../mono/mono/metadata/filewatcher.c:197: undefined reference to `inotify_rm_watch' | |
./.libs/libmonoruntime.a(libmonoruntime_la-filewatcher.o)(.text+0x151): In function `ves_icall_System_IO_InotifyWatcher_GetInotifyInstance': | |
../../../mono/mono/metadata/filewatcher.c:142: undefined reference to `inotify_init' |
OlderNewer