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 perl | |
use Modern::Perl; | |
use autodie; | |
my $x; | |
open my $f, "<", $ARGV[0]; | |
seek $f, $ARGV[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
/usr/sbin/apachectl -S | |
VirtualHost configuration: | |
wildcard NameVirtualHosts and _default_ servers: | |
*:80 is a NameVirtualHost | |
default server crf.example.com (/etc/httpd/conf.d/vhostcrf.conf:1) | |
port 80 namevhost crf.example.com (/etc/httpd/conf.d/vhostcrf.conf:1) | |
Syntax OK |
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
{{ revealedCharacter }}
package BCV::LDAP::User; | |
use Moose; | |
use namespace::autoclean; | |
has entry => ( | |
is => 'ro', | |
isa => 'Net::LDAP::Entry', | |
); | |
our $AUTOLOAD; |
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
{{ revealedCharacter }}
#!/bin/perl | |
# Before perltidy | |
helper ndb => sub { state $db //= BCV::DB->new('SwitchCLLI') }; | |
helper cdb => sub { state $db //= BCV::DB->new('STARS') }; | |
# After perltidy | |
helper ndb => sub { state $db // = BCV::DB->new('SwitchCLLI') }; | |
helper cdb => sub { state $db // = BCV::DB->new('STARS') }; |
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
{{ revealedCharacter }}
sudo ubic start nice_js | |
Starting nice_js... Can't open '/var/lib/ubic/tmp/1375914532.15896.993049.52270268.new' for writing: Permission denied at /usr/lib/perl5/site_perl/5.8.8/Ubic/AtomicFile.pm line 24. | |
temp file /var/lib/ubic/tmp/1375914532.15896.993049.52270268 not found after fork at /usr/lib/perl5/site_perl/5.8.8/Ubic.pm line 488. | |
cat /etc/ubic/service/nice_js.ini | |
module = Ubic::Service::SimpleDaemon | |
[options] | |
bin = node /opt/node/nICE/nice.js 24.40.52.128 | |
user = bcv |
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
{{ revealedCharacter }}
#!/usr/bin/perl | |
use Modern::Perl; | |
use Math::Complex; | |
my $ul = cplx(-2.1, 1.2); | |
my $lr = cplx( 0.6,-1.2); | |
my $sx = (Re($lr) - Re($ul))/79; | |
my $sy = (Im($lr) - Im($ul))/26; |
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
{{ revealedCharacter }}
package main | |
import ( | |
"fmt" | |
"math/big" | |
) | |
func main() { | |
i := big.NewInt(6) | |
fmt.Println(i.Exp(i, i.Exp(i, i, nil), nil)) |
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
{{ revealedCharacter }}
DB<12> p $r->at('command')->to_xml | |
<command type="Error" xmlns="" xmlns:c="C" xsi:type="c:ErrorResponse"><summary>[Error 4007] Invalid login ID: cfedde001c_as01</summary><summaryEnglish>[Error 4007] Invalid login ID: cfedde001c_as01</summaryEnglish></command> | |
DB<13> x $r->at('command')->attr | |
empty array |
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
{{ revealedCharacter }}
#!/usr/bin/env perl | |
use Modern::Perl; | |
use Mojo::DOM; | |
use Test::More; | |
my $xml = q|<?xml version="1.0" encoding="ISO-8859-1"?> | |
<command type="Error" xmlns="" xmlns:c="C" xsi:type="c:ErrorResponse"><summary>[Error 4007] Invalid login ID: cfedde001c_as01</summary><summaryEnglish>[Error 4007] Invalid login ID: cfedde001c_as01</summaryEnglish></command> | |
|; | |
my $r = Mojo::DOM->new()->xml(1)->parse($xml); |
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
{{ revealedCharacter }}
use Modern::Perl; | |
package A; | |
use Moose; | |
use YAML::XS; | |
has size => ( | |
is => 'ro', | |
default => 4, | |
); |
OlderNewer