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 warnings; | |
use strict; | |
die("Usage: ./build APP_NAME") if !$ARGV[0]; | |
my ($dir,$appname) = ("~/dev/asm/".$ARGV[0],$ARGV[0]); | |
if((-d $dir and chdir($dir)) { # Directory exists. | |
open(SOURCEFILE,"<$dir/$appname.s"); | |
my @lines = <SOURCEFILE>; | |
$b = ($line[0] eq ';32') ? 32 : 64; | |
`nasm -felf$b $appname.s -o $appname.o && ld $appname.o -o $appname`; |
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 warnings; | |
use strict; | |
die("Usage: ./build APP_NAME") if !$ARGV[0]; | |
my ($dir,$appname) = ("~/dev/asm/".$ARGV[0],$ARGV[0]); | |
if((-d $dir and chdir($dir))) { # Directory exists. | |
open(SOURCEFILE,"<$dir/$appname.s"); | |
my @lines = <SOURCEFILE>; | |
$b = ($lines[0] eq ';32') ? 32 : 64; | |
`nasm -felf$b $appname.s -o $appname.o && ld $appname.o -o $appname`; |
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
[/home/ricky]$ ldd /usr/local/bin/weechat-curses | |
/usr/local/bin/weechat-curses: | |
libncursesw.so.6.0 => /usr/local/lib/libncursesw.so.6.0 (0x280ce000) | |
libgnutls.so.40 => /usr/local/lib/libgnutls.so.40 (0x280f9000) | |
libtasn1.so.4 => /usr/local/lib/libtasn1.so.4 (0x2818b000) | |
libz.so.4 => /lib/libz.so.4 (0x2819b000) | |
libgcrypt.so.16 => /usr/local/lib/libgcrypt.so.16 (0x281ad000) | |
libgpg-error.so.0 => /usr/local/lib/libgpg-error.so.0 (0x28223000) | |
libintl.so.8 => /usr/local/lib/libintl.so.8 (0x28227000) | |
libiconv.so.3 => /usr/local/lib/libiconv.so.3 (0x28239000) |
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
[/home/ricky/dev/perl/wikipedia]$ perl TextFuncs.pm perl | |
{{Infobox programming language | |
| name = Perl logo = paradigm = multi-paradigm: functional, imperative, object- | |
| oriented (class-based) year = 1987 designer = Larry Wall | |
| latest_release_version = 5.10.1 latest_release_date = turing-complete = Yes | |
| typing = Dynamic influenced_by = AWK, Smalltalk 80, Lisp, C, C++, sed, Unix | |
| shell, Pascal influenced = Python, PHP, Ruby, ECMAScript, Dao, Windows | |
| PowerShell, JavaScript, Falcon programming_language = C operating_system = Cross- |
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
[/home/ricky]$ gdb pidgin | |
gdb pidgin | pts/6GNU gdb 6.1.1 [FreeBSD] | |
Copyright 2004 Free Software Foundation, Inc. | |
GDB is free software, covered by the GNU General Public License, and you are | |
welcome to change it and/or distribute copies of it under certain conditions. | |
Type "show copying" to see the conditions. | |
There is absolutely no warranty for GDB. Type "show warranty" for details. | |
This GDB was configured as "i386-marcel-freebsd"...(no debugging symbols found)... | |
(gdb) bt full | |
No stack. |
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 -f | |
# Configure wmii | |
# Configuration Variables | |
MODKEY=Mod1 | |
UP=k | |
DOWN=j | |
LEFT=h | |
RIGHT=l |
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
$ ls | grep pk3 | |
q_wootjumps_beta4.pk3 | |
ut4_LiquidNight_test1.pk3 | |
ut4_aerodynamic_a2.pk3 | |
ut4_ajumps.pk3 | |
ut4_brickjumps_beta5.pk3 | |
ut4_core.pk3 | |
ut4_crystalonight_jump_a1.pk3 | |
ut4_deathjumps.pk3 | |
ut4_deathjumps_hell.pk3 |
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
// Fufills ( http://rosettacode.org/wiki/Ackermann_Function ) in Pike. | |
int main(){ | |
write(ackermann(3,4) + "\n"); | |
} | |
int ackermann(int m, int n){ | |
if(m == 0){ | |
return n + 1; | |
} else if(n == 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
// Fufills ( http://rosettacode.org/wiki/Execute_a_System_Command ) in Pike. | |
int main(){ | |
string response = Process.run("ls") | |
// response is now a map containing 3 fields | |
// stderr, stdout, and exitcode. We want stdout. | |
write(response["stdout"] + "\n"); | |
} |
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
// Fufills ( http://rosettacode.org/wiki/Sum_a_series ) in Pike. | |
int main(){ // S(x) = 1/x2, from 1 to 1000 | |
int sum = 0; | |
for(int i = 1; i <= 100; i++){ | |
sum = sum + (1 / pow(i,2)); | |
} | |
} |