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
| #include <stdio.h> | |
| enum { | |
| NON = 0x00, | |
| RED = 0x01, | |
| BLUE = 0x02, | |
| GREEN = 0x04, | |
| } flg = NON; | |
| void view(); |
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 perl | |
| use strict; | |
| use warnings; | |
| use Getopt::Long; | |
| my @opt; | |
| GetOptions("opt=s{,}" => \@opt); | |
| foreach my $val ( @opt ){ |
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
| filetype off | |
| " pathogen.vimによってbundle配下のpluginをpathに加える | |
| call pathogen#runtime_append_all_bundles() | |
| call pathogen#helptags() | |
| set helpfile=$VIMRUNTIME/doc/help.txt | |
| " ファイルタイプ判定をon | |
| filetype plugin on |
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
| # ファイル名一括変換コマンド | |
| function formv { | |
| if [ $# -lt 2 ]; then | |
| echo 'usage: formv s/pat1/pat2/ file ..'; | |
| else | |
| s=$1; shift; | |
| for i in "$@"; | |
| do | |
| j=`echo "$i" | sed "$s"`; | |
| echo "$i -> $j"; |
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
| $ diff -c /usr/local/share/perl/5.10.0/XML/Atom/Client.pm /tmp/Client.pm | |
| *** /usr/local/share/perl/5.10.0/XML/Atom/Client.pm 2009-08-03 15:06:36.000000000 +0900 | |
| --- /tmp/Client.pm 2009-04-24 17:34:23.000000000 +0900 | |
| *************** | |
| *** 228,236 **** | |
| sub new { | |
| my($class, $client) = @_; | |
| my $ua = $class->SUPER::new; | |
| - | |
| - $ua->env_proxy; |
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/perl | |
| $max = '30'; | |
| $len = '50'; | |
| @arey = ('|', '/', '-', '\\', ''); | |
| for ($num = 0;$num<=$max;$num++) { | |
| local $| = 1; | |
| $percent = int(($num/$max)*100); | |
| $print = "["."%-"."$len"."s"."] "."%d%%"."\r"; | |
| $bar = '*' x int(($percent/100)*$len); |
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/sh | |
| while getopts ab:c: opt | |
| do | |
| case $opt in | |
| a) | |
| flga=1 | |
| ;; | |
| b) | |
| flgb=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
| if [ -e ~/perl5/perlbrew/etc/bashrc ] ; then | |
| source ~/perl5/perlbrew/etc/bashrc | |
| fi% |
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
| <script type="text/javascript"> | |
| var _gaq = _gaq || []; | |
| _gaq.push(['_setAccount', 'UA-********-*']); | |
| _gaq.push(['_trackPageview']); | |
| (function() { | |
| var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; | |
| ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; | |
| var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); | |
| })(); |
NewerOlder