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
#! /bin/sh | |
pod2man --utf8 $1 | iconv -t iso8859-5 | nroff -Tlatin1 -c -man - | iconv -f iso8859-5 | less |
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/perl | |
# | |
# cpan-repository-hosts | |
# | |
# Generate list of the different hosts that appear in the CPAN repository field | |
# Get a list of all the repository strings from MetaCPAN, then chop them around | |
# to get the host part | |
# | |
use strict; | |
use warnings; |
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
git log --shortstat | awk '/Author|changed/' | perl -lne'if ( /^Author: (.+)/ ) { $author = $1 } else { while ( /(?:(\d+) (?:insertions|deletions))/g ) { $changes{ $author } += $1 } } END { print "$changes{$_} $_" for keys %changes }' | |
# 2674 Doug Bell <doug.bell@baml.com> | |
# 18332 Doug Bell <madcityzen@gmail.com> |
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
#From http://www.xav.com/perl/faq/Windows/ActivePerl-Winfaq12.html | |
#How do I extract a series of cells from Microsoft Excel? | |
#If you have a sheet object you can extract the values of a series of cells through $Sheet->Range-> #{'Value'}, for example: | |
my $array = $Sheet->Range("A8:B9")->{'Value'}; | |
#Now $array[0][0] contains the value of cell A8, $array[0][1] the value of cell B8, $array[1][0] the value #of cell A9 and $array[1][1] the value of cell B9. |
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 v5.14; | |
# cpanm utf8::all Data::Dumper::Perltidy Data::Dumper | |
use utf8::all; | |
#=========== | |
# TODO: move to standalone module | |
use Data::Dumper::Perltidy; |
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
#!/bin/bash | |
set -e | |
# Usage: | |
# rsync_parallel.sh [--parallel=N] [rsync args...] | |
# | |
# Options: | |
# --parallel=N Use N parallel processes for transfer. Defaults to 10. | |
# | |
# Notes: |
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
#!/opt/bin/perl -w | |
package IRC::Bot2; | |
use strict; | |
use warnings; | |
use Moose; | |
extends 'IRC::Bot'; | |
use IRC::Bot::Log::Extended; |
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 Modern::Perl; | |
use Git::Repository; | |
use File::Slurp qw( :edit ); | |
my $url = 'https://github.com/mishin/perldoc-ru.git'; | |
my $dir = '/home/mishin/github/test_repo'; | |
#Git::Repository->run( clone => $url => $dir ); | |
my $r = Git::Repository->new( work_tree => $dir ); | |
use DateTime; |
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
#This is my perl tips collection: | |
http://grep.cpan.me/?q=author%3A%28MIYAGAWA%7CDCONWAY%7CBDFOY%7CSZABGAB%29+shift | |
author:(MIYAGAWA|DCONWAY|BDFOY|SZABGAB) shift | |
http://eax.me/perl5-oop/ | |
http://grep.cpan.me/?q=author%3A%28MIYAGAWA%7CDCONWAY%7CBDFOY%29+__DATA__ | |
author:(MIYAGAWA|DCONWAY|BDFOY) __DATA__ | |
→ milla-tutorial$ sp_ch () {(cat $1|aspell --lang=ru-yo list|aspell --lang=en list); };sp_ch lib/POD2/RU/perlretut.pod |