Hi!
Just to add my 5 cents.
Theoretically speaking, it is still possible. For example, I've been
contacted once about such position recently.
Practically speaking, if you're good developer there is a lot of
language agnostic positions.
For the last 12 month I passed the interviews and succ
You can easily use any perl version you want with plenv (my favourite),
perlbrew or docker.
Check this guides to find details about how to install and use them
https://stackoverflow.com/questions/21980853/install-another-perl-in-linux
https://christopher.rasch-olsen.no/perl-dependency-manageme
For example, this regex
/(?[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})\s+(?\/.*)/
On 25.10.2019 13:23, Maggie Q Roth wrote:
Hello
There are two primary types of lines in the log:
60.191.38.xx /
42.120.161.xx /archives/1005
I know how to write regex to match each line, but do
Hi!
Have you looked on https://metacpan.org/pod/Net::Google::Spreadsheets::V4?
It's newer, so probably It can give you a bit more data from modern
Google API
On 16/08/2019 14:18, James Kerwin wrote:
Thanks Dave and Mike,
I am using Net::Google::Spreadsheets and all the associated modules
a
There is two main tools to install different versions of perl - perlbrew
https://perlbrew.pl/ and plenv https://github.com/tokuhirom/plenv.
If you want different project environments, you can use tools like cpanm
https://metacpan.org/pod/cpanm
For example:
cpanm -L local DBI@1.01 will instal
Hi!
Yes, they are
Try this snippet
perl -E 'use feature 'signatures'; use warnings; my $a = sub ($b,$c) {
return $b + $c; }'
You can find current status for your perl with `perldoc feature` command
and then find signatures section.
I expected attempts to make them stable from 5.30 version
use Time::Piece;
my $t1 = Time::Piece->strptime('Feb 23 01:10:28 2018', '%b %d %H:%M:%S %Y');
my $t2 = Time::Piece->strptime('02/23/18 01:10:33', '%m/%d/%y %H:%M:%S');
if ($t1 > $t2) { ... }
On 23/10/2018 09:17, Asad wrote:
Hi All ,
first hurdle is how do I extract this Feb 23 01:10:
Hi!
You can set up javascript handler for the form and submit it
automatically if all fields are filled.
On 02/10/2018 16:18, James Kerwin wrote:
Hi All,
I have a Perl script that pulls in some information, generates an
email, sends the email to a person and provides a URL to a WuFoo form.
Hi!
See encpass from Passwd::Unix
https://metacpan.org/pod/Passwd::Unix
On 8/23/18 10:54 AM, Olivier wrote:
Hello,
I am not sure if my question is really of beginer level.
On a system, I have set my password to "t410" and it has ben hashed to:
$2b$10$OQBll77HJqnOR.zqK2jx8ukE6m68Azc7nrsgRdcT6
Hi!
Look at https://metacpan.org/pod/Tie::File::AsHash
On 8/1/18 2:16 PM, Lauren C. wrote:
Do you know how to tie a hash to a disk file thus read by another process?
Currently my solution is writing the data to a JSON file and read it
from the other program.
Thank you.
--
To unsubscribe,
Hi!
You can resize image with Perl. For example, Imager library can do the
thing. See
https://metacpan.org/pod/distribution/Imager/lib/Imager/Transformations.pod#scale()
On 7/25/18 4:56 AM, Lauren C. wrote:
Thanks for all kind answers.
I have another question that, though this is maybe hard
I Found it on github
https://github.com/eprints/eprints/blob/392474eec1b8125a66ed2d3e12b02aeb67dc07c4/lib/defaultcfg/cfg.d/security.pl
On 7/20/18 6:24 PM, Chas. Owens wrote:
All of this is supposition since I can't see anything you haven't
shown us.
It sounds like this code is part of a larg
Hi!
$c is hash reference with key "can_request_view_document";
The value for that key is anonymous sub.
You can call this sub like this
$c->{can_request_view_document}->($doc, $r);
On 7/20/18 6:04 PM, James Kerwin wrote:
Afternoon all,
I have been asked to take a look at a .pl file which
Hi!
I think, m{path/(\w+)?/?$} regex can solve your problem.
In general, to parse URL, you can use official regex from rfc3986 (see
Appendix B for rfc3986)
regex is
^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?
$2 is protocol
$4 is host
$5 is path
$7 is query
$9 is fragment.
Ano
Hi!
"m{ pattern }" is regular expression to parse log string.
It's equal to just "/ pattern /". Using different delimiter is
convenient here because usually symbol "/" must be escaped with
backslash "\", but if we use another delimiter - we can left "/" symbol
unescaped and reges is more read
Hi!
According to FAQ
https://metacpan.org/pod/distribution/Archive-Zip/lib/Archive/Zip/FAQ.pod
Archive::Zip can do it as long as any compressed members are compressed
using Deflate compression.
If your archive compressed with another compression algorithm, you can
use external programm an
Try to look at Net::SSH::Any https://metacpan.org/pod/Net::SSH::Any
On 2/14/18 5:32 AM, Lancelot Mak wrote:
do u have any recommendation on module to use? what i wanted is to
login ssh using username,password but in script
no key, no non-interactive
thanks
On 13 February 2018 at 23:38, Chas.
Why can't you use 'signatures' feature at the first place?
Usually, it means that you tight yourself to system perl, which is not a
good decision at all.
Don't trust me on this, trust brian d foy
https://www.effectiveperlprogramming.com/2015/11/apple-recommends-installing-your-own-perl/
Ins
Hi!
I see no reason to squash these lines of code into one. It works, it
shows your idea clearly.
All technics you can use to reduce this code will make this code less readable.
If you need it for production, I don't recommend it.
27.11.2017 12:54, Luca Ferrari пишет:
Hi all,
I cannot fig
Hi!
It's strange design decision.
If FOOR is ancestor for BAR, why can't you just place methods into FOO?
03.08.17 21:44, hw пишет:
Hi,
suppose I have a class FOO and a class BAR. The parent of BAR is FOO.
I would like FOO to /use/ BAR because BAR has some methods needed by FOO.
BAR is /
Perl5 plugin for intelij IDEA has support for built-in Perl debugger. So
you may consider it as a gui interface to debugger.
18.07.17 5:48, David Mertens пишет:
If you really want a GUI debugger you might consider Padre. I've used
it as a debugger once or twice, but recall running into issues.
Hi!
You don't need logical string negotiation and logical number
negotiation. You just need logical negotioation.
Using `!` operator to convert non-empty string to empty string is wrong,
so as using `!` operator to convert not zero number to zero.
`!` operator is for logical operations only
Quote from amazing ModernPerl book http://modernperlbooks.com/
"Perl's default object system is minimal but flexible. Its syntax is a
little clunky, and it exposes /how/ an object system works. You can
build great things on top of it, but it doesn't give you what many other
languages do by def
Hi!
It looks like the password issue, maybe password is incorrect or not set
properly?
This value (16) can be stored on the device.
Did you try to reboot host.example.com and see the value of
usmStatsWrongDigest counter?
23.04.17 6:30, lee пишет:
Hi,
Net::SNMP only gives a useless error
en we start to splice elements from
array indices will be change. If we delete first element, third element
became second, fourth became third and so on.
12.04.17 23:19, Uri Guttman пишет:
On 04/12/2017 04:08 PM, Илья Рассадин wrote:
Hi!
You can use splice to delete elements from array.
To d
Hi!
You can use splice to delete elements from array.
To delete multiple elements you need to do splice in a loop
my @indices = qw/2 4 5 7/;
my @array;
for my $index (reverse sort @indices) {
splice @array, $index, 0;
}
12.04.17 22:19, Uri Guttman пишет:
On 04/12/2017 03:00 PM, David
Hi!
First of all, using unless with complex logic inside the condition,
especially using negatives (unless not...) is much harder to read and
understand than using if.
See http://stackoverflow.com/a/3048787 and of course see original adwise
from Conway's perl best practices
http://shop.orei
See docs https://metacpan.org/pod/JSON::PP#simple-scalars
You do print Dumper on hash, it stringifies all hash values, so you see
such an obscure result for encode_json.
If don't dump $hash before encode json you get what you want -
work_hours_to_float_try2 is json valid number
{"work_hours
Hi!
You forgot arrow operator
$args->{'FN'}, not $args{'FN'}
15.01.17 23:45, al...@myfastmail.com пишет:
Hi
On Sun, Jan 15, 2017, at 12:23 PM, Илья Рассадин wrote:
I think, you can use this aproach
If I use either of those
sub modrec {
-
Hi!
I think, you can use this aproach
sub modrec {
my ($args) = @_; # or my $args = shift @_; use what you like more
my $fn = $args->{'FN'};
}
15.01.17 23:09, al...@myfastmail.com пишет:
Hi,
I have a simple script with a subroutine that I pass scalar & array arguments
Hi, claus!
Actually, I can't understand the question.
You can (and should) define type constraint for attribute via Moose
predefined types, Types::Standart module or your own type system.
use Types::Standard -all;
use Moose;
has 'attr_name' => (
'is' => 'ro',
'isa' => InstanceOf['
Hi!
For introduction to Modern Perl practicies, read Modern Perl by chromatic
http://modernperlbooks.com/books/modern_perl_2016/index.html
01.09.16 19:52, Walker, Michael E пишет:
Hi, even though _Beginning Perl_ dates back to 2000, is it still
relevant for learning today? I wondered, becau
Hi!
According to Net::RawIP docs, checksum will be calculated automatically
unless your provide it manually via "check" parameter during object
construction.
So my guess is you incorrectly construct Net::RawIP objects. But it's a
sort of guesswork, so it'll be much easier to help if You send
w/net/;
|$port_re = "[.:]|||[1-9][0-9]{1,4}|";
|
my $re = qr|/^(||$RE||{net}{IPv4}|$RE||{net}{IPv6})(?:$port_re)?|$/;
if ($string =~ $re) {
say "$string is valid ip";
}
14.07.16 23:46, Chris Knipe пишет:
Hi,
On Thu, Jul 14, 2016 at 10:28 PM, Илья Рассадин <mailto
Hi!
It's really simple regexp that can handle this, I wrote simple example
to illustrate the idea.
Of course, this $port_re can match invalid port (all port numbers which
higher than 65536). If it's critical to your case, you can adjust strip
port function.
|use Regexp::Common qw/net/; ||m
gt; Shlomi Fish
>
> Please reply to list if it's a mailing list post
>
>
> --
> To unsubscribe, e-mail: beginners-unsubscr...@perl.org
> For additional commands, e-mail: beginners-h...@perl.org
> http://learn.perl.org/
>
>
> --
С уважением, Илья Рассадин
telegram.me/elcamlost
+7 920 652-19-37
skype elcamlost
Hi, Martin!
First, specify UTF-8 binmode for STDOUT, it's good practice if you printing
unicode characters.
Second and main, problem here is that your umlaut character has not ord
195. More over, the way you construct umlaut character give you not a
single character but unicode grapheme.
You can
Why you don't want rebuild you hash into another hash with ip address as a
key?
Yes, it will cost you additional memory and runtime but it will be more
convenient and easy to understand, support and modificate. If memory is not
a problem, i think it's best choice in your case.
See https://gist.gi
Hi everybody!
I think, problem code is
```
if($buf eq chr hex $xhtmlbegin[$j + 1]) {
$doread = 1;
$j = $j + 1;
} else {
if($j == 0) {
$doread = 1;
} else {
#this line is very suspicious
$j = $
Hi Nathalie.
Please, next time create gist with updated code, and send link to it. Now
your code is messy and its really hard to tell anything about it.
One more comment - you mix variable with computerish names and with names
from subject area. It's bad, you must always name your variables with
Hi!
Look at Config::Any https://metacpan.org/pod/Config::Any
пн, 22 июня 2015 г. в 18:23, Unknown User :
> I am using Conf::Libconfig to read a libconfig config file.
> - are there any better modules to read it?
> - If not, is it possible with Conf::Libconfig to print out all the
> entries
I think, even better if initialize magic numbers and symbols
use constant NEWLINE_SYMBOL => chr(10);
use constant SOME_MEANINGFULL_NAME => ;
чт, 18 июня 2015 г. в 16:54, Shlomi Fish :
> Hi Marco,
>
> see below for my response.
> On Thu, 18 Jun 2015 15:17:27 +0200
> Marco wrote:
>
> > Hello
Hi, Tiago!
I can't reproduce such behaviour
use Modern::Perl '2014';
my $string = 'Crosses misses=50 ';
my (@matches) = ($string =~ /(Crosses)(.*)(misses=)(\d+)/s);
use Data::Dumper;
print Dumper \@matches;
result:
$VAR1 = [
'Crosses',
' ',
'mis
Hi!
You can use say instead of print (with use v5.10 as minimum) to avoid this
strange behaviour.
use v5.10;
say %hash;
but output still be ugly - all keys and values concatenates withoud
delimeter.
if you want to dump your hash for debugging purpose, module Data::Dumper is
a great choice.
use
Hi
You can find suitable solutions at CPAN.
For example, https://metacpan.org/pod/Format::Human::Bytes
This module seems to be exactly what you looking for.
пн, 25 мая 2015 г. в 15:37, Sunita Pradhan :
> Hi
>
> Is there any perl module for byte , KB, MB conversion ?
>
> Thanks
> Sunita
>
rustful an original source, do you need maintain your code
or it's one time job. And maybe some of this questions are beyond this
mailing list topic ))
Thank for your reply and thank for your code review
ср, 6 мая 2015 г. в 12:02, Shlomi Fish :
Hi Илья,
>
> some comments on your
HI, Anirban.
Regexp and hash of arrays can help you.
my @a =
('1900-0','1900-1','NULL','NULL','1900-2','1900-4','1902-5','1902-6','1902-7','1902-8');
my %result;
foreach (@a) {
next if $_ eq 'NULL';
my ($earfcn, $pcid) = /^(\d+)-(.+)$/;
push @{$result{$earfcn}}, $pcid;
47 matches
Mail list logo