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/perl | |
use strict; | |
use warnings; | |
my $foo = "hello\n"; | |
$a = undef; | |
$b = undef; | |
EVIL: | |
$foo = $a if $a; |
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
exodist@Aswan $ setopt PROMPT_SUBST | |
exodist@Aswan $ function foo() { date +%s } | |
exodist@Aswan $ export RPROMPT="%{$(foo)%}" | |
exodist@Aswan $ 1394749035 | |
exodist@Aswan $ 1394749035 | |
exodist@Aswan $ 1394749035 | |
exodist@Aswan $ 1394749035 |
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
BLACK="%{"$'\033[01;30m'"%}" | |
GREEN="%{"$'\033[01;32m'"%}" | |
RED="%{"$'\033[01;31m'"%}" | |
YELLOW="%{"$'\033[01;33m'"%}" | |
BLUE="%{"$'\033[01;34m'"%}" | |
BOLD="%{"$'\033[01;39m'"%}" | |
NORM="%{"$'\033[00m'"%}" | |
function gstat() { | |
branchinfo=`git branch 2>/dev/null` |
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
package Test::Calculate; | |
use strict; | |
use warnings; | |
use Data::Dumper; | |
use base 'Exporter'; | |
use Carp qw/croak/; | |
our @EXPORT = ('CALCULATE'); |
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
use strict; | |
use warnings; | |
{ | |
package Foo; | |
sub finish { | |
$_[0] = undef; | |
} |
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
sub use_fork { | |
require Storable; | |
my ($r, $w); | |
pipe($r, $w) || confess "Could not open pipe! $!"; | |
$_[0]->[_USE_FORK] ||= [$r, $w]; | |
return 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
use strict; | |
use warnings; | |
BEGIN { | |
if( $ENV{PERL_CORE} ) { | |
chdir 't'; | |
@INC = '../lib'; | |
} | |
} |
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
package Test::SkipWithout; | |
use strict; | |
use warnings; | |
require Test::More; | |
sub import { | |
my $class = shift; | |
my ($module, $version) = @_; |
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
:map <F9> :w<cr>:! PERL5LIB="" /usr/bin/prove -v -Ilib -I/home/cgranum/ndn/perl %<CR> | |
:imap <F9> <ESC>:w<cr>:! PERL5LIB="" /usr/bin/prove -v -Ilib -I/home/cgranum/ndn/perl %<CR> | |
:map <F10> :w<cr>:! PERL5LIB="" /opt/plack/perl/bin/prove -v -Ilib -I/home/cgranum/ndn/perl %<CR> | |
:imap <F10> <ESC>:w<cr>:! PERL5LIB="" /opt/plack/perl/bin/prove -v -Ilib -I/home/cgranum/ndn/perl %<CR> | |
function! RunFennecLine() | |
let cur_line = line(".") | |
exe "!FENNEC_TEST='" . cur_line . "' prove -v -Ilib -I. -I/home/cgranum/ndn/perl %" | |
endfunction |
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
<VirtualHost *:443> | |
ServerName uebernet-plack.testdomain.com | |
ServerAlias * | |
ServerAdmin webmaster@uebernet-plack.testdomain.com | |
DocumentRoot /ndn/web/uebernet | |
ErrorLog /var/log/apache2/uebernet.https/error.log | |
CustomLog /var/log/apache2/uebernet.https/access.log combined |
OlderNewer