Perl is a powerful, high level programming language. Questions about Perl should be limited to the Perl development environment, running Perl, or using Perl to automate tasks on your computer.

learn more… | top users | synonyms

2
votes
1answer
1k views

Bulk insert bugs into bugzilla from another Bug tracker

I am looking for a script and/or examples of scripts for bulk importing/inserting bugs into a new installation of bugzilla 4. We are moving from an old DevTrack and need all our bugs inserted. Our ...
1
vote
3answers
56 views

Quickly uploading images to an imagehosting site and getting the URL

A Perl or Python script would be perfect, only I've yet to find one. I saw some but they're all work in progress. In short, I need a [thing] for quickly uploading an image to an imagehosting site ...
2
votes
2answers
535 views

How to remove three consecutive line feeds in a Makefile rule?

I need to search for and replace three consecutive newline characters in an input file and filter them out of an output file for a makefile rule on Centos 4. I am using GNU sed v4.1.2 and GNU make ...
0
votes
1answer
129 views

rsync on Lion failing with Perl error

I'm trying to rsync a bunch of photos from one mac to another. rsync -av /Users/billybobob/Pictures/ sarahsansskirt@192.168.1.4:/Volumes/Harddrive/Billybobob_Photos I've got the keys correct ...
2
votes
1answer
108 views

Emacs inserting boilerplate twice

I have an entry that is basically identical to the one found here: (defun perl-boilerplate () (if (not (file-exists-p (buffer-file-name (current-buffer)))) (cond ((string-match ...
0
votes
1answer
272 views

How to use Perl Plugins in Pidgin

I am trying to install a perl plugin to pidgin, by placing the .pl file in the ~/.purple/plugins directory, as described here. The problem is that when I put the .pl file in the directory and open ...
1
vote
2answers
36 views

Find script with early cutting branches on first occurences

It must exists, my problem is how to express my need. When I search for a given filename, Iwant the search stop searching the current branch when it finds a first occurence, BUT continue to search in ...
0
votes
2answers
2k views

Downgrading Module or Downgrading to perl 5.10 on Ubuntu 12.04

I have a requirement to have Storable module version 2.07 instead of latest 2.08 version installed in perl. I tried installing from backpan repository and it seems to install fine, however when script ...
0
votes
1answer
914 views

Macports irssi & perl5 installation issues

Long time reader, first time poster. Big, appreciative thanks for everyone's collective questioning and answering here and at stackoverflow, it's helped me quite a lot over the time I've been learning ...
1
vote
0answers
35 views

lwp-rget changes file format automatically to .bin?

I'm trying to recursively get an html page to get everything that's there and save it to my directory. Lwp-rget from perl allows me to do this but I'm having the problem that its getting all the ...
1
vote
2answers
281 views

Where to obtain logs after Xorg freezes

I have this issue where a perl script will sometimes freeze Xorg. It's an extension for urxvt that detects URLs and allows me to "launch" them in the browser. Sometimes, upon launching, Xorg will ...
1
vote
0answers
570 views

Get sublime text 2 (sublimecodeintel) to parse mason

So Sublime Text 2 seems to getting a lot of love lately. I am using the Sublime Code intel plugin, https://github.com/Kronuz/SublimeCodeIntel for auto completion. The problem is, it does not recognize ...
2
votes
1answer
45 views

Synchronizing perl packages from one install to another

I currently have perl 5.8.8 installed on a production linux system, and there are many, many packages installed. I am planning on installing perl 5.16 under a prefix (from source). Is there any way ...
0
votes
1answer
264 views

Ubuntu: perl: undefined symbol: PL_perl_destruct_level

Recently, I tried to crosscompile Perl on my Ubuntu system but made a mistake. The finished binary was installed on my productive system besides the already present perl version. Ever since I get the ...
3
votes
1answer
1k views

SSL trouble in Perl's LWP after Debian Wheezy upgrade

I just upgraded to Debian Wheezy from Lenny (long story) and a few of my Perl packages didn't make the upgrade for some reason, among them Crypt::SSLeay (libcrypt-ssleay-perl). I was unable to ...
1
vote
1answer
192 views

Searching current directory and 1 subdirectory for files with .txt extension

Using the 'ls -R' command in perl, what is the parameter to find files with a .txt extension under the current and 1 subdirectory? Also I how would I count the number of files and if the number is one ...
2
votes
1answer
993 views

Perl error while compiling Munin transmission plugin

Could you please tell me what this error says?: Can't locate JSON/RPC/Client.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.14.2 /usr/local/share/perl/5.14.2 /usr/lib/perl5 ...
1
vote
2answers
2k views

Perl EPIC Not recognising installed CPAN modules

Eclipse on a mac, was working fine adding new modules until I Installed Text::CSV_XS which Eclips doesn't recognise as added to @INC For instance use strict; use SOAP::Transport::HTTP; ...
0
votes
1answer
250 views

Converting between a vim replace and a perl pie replace

So I have a file test.txt, that contains, home -> range If I edit the file in vim and run the command %s/^\(.*\)->\(.*\)$/\2 ::= \1 ;/g it converts the file to range ::= home ; which is ...
2
votes
1answer
2k views

Notepad++ Perl Multi-line comment syntax highlighting

Is there a way to set notepad++ to highlight a Perl multi-line comment block as comments (currently there is no highlighting - it's black on white). The type of comment I am talking about is of the ...
0
votes
1answer
442 views

Linux replace ^M$ with $ in csv

I'm working on migrating from MDaemon to Google Apps. As part of this process I'm exporting the contacts and calendars for all of our users into CSV files then reading them into a perl script and ...
0
votes
1answer
2k views

how to install libio-socket-ssl-perl on tiny core Linux?

I found this commands on another pages: apt-get install libio-socket-ssl-perl tce-load -wi libio-socket-ssl-perl but doesnt work. Any idea to install libio-socket-ssl-perl on tiny core ...
3
votes
2answers
2k views

perl - translate sed to perl

The following command work fine on Solaris ( delete line only if last character is ":" ) sed -e '/:$/d' < foo > foo.new how to do the same in perl ? ( the reason for that because I not want ...
0
votes
1answer
2k views

'perl' is not recognized as an internal or external command: Even when there is nothing about perl?

Ok, I just installed MinGW on my PC and to used g++ command on cmd and it says, 'perl' is not recognized as an internal or external command, operable program or batch file. I just checked PATH ...
0
votes
0answers
127 views

Mock --init failing on perl command

I have a rather unique situation here that about 2 hours of googling couldn't help me with. I'm building a project using Cmake that will eventually generate rpms for target architectures using mock. ...
4
votes
2answers
7k views

How can I identify non-ASCII characters from the shell?

Is there a simple way to print all non-ASCII characters and the line numbers on which they occur in a file using a command line utility such as grep, awk, perl, etc? I want to change the encoding of ...
1
vote
1answer
4k views

Perl for matching with regular expressions in Terminal?

I'm trying to familiarize myself a little with Perl to use for regular expression searches in Terminal (Mac). Now, I'm not really looking to learn Perl rigourously, just trying to find out how to do ...
1
vote
2answers
141 views

Installing a second version of e.g. git, perl and or python on osx lion

At the moment i am running git 1.7.5.4, perl 5.12.3 as well as python 2.7.1 on osx 10.7.3, which were all included in the basic system setup. Applying the "which" command the locations are: ...
25
votes
7answers
36k views

When to use Bash and when to use Perl/Python/Ruby?

We are doing all our scripting with Bash so far, but I'm starting to feel a bit silly about it. While we can of course do everything we want with Bash (it's quite powerful), I'm starting to wonder if ...
0
votes
1answer
4k views

How to uninstall Perl version 5.10.1 from Ubuntu 10.4 and install a single threaded version of Perl?

I have to uninstall Perl version 5.10.1 from Ubuntu 10.4 and install a single threaded version of Perl. What commands should I run on terminal to do this? Or, is there another way to uninstall the ...
1
vote
1answer
634 views

Apache can't load dbi module in mac os x

I installed dbd:mysql via cpan. I have the following simple script: #!/usr/bin/perl -U use DBI; $ds = 'DBI:mysql:project:localhost'; $user = 'root'; $password = '123456'; $db = DBI->connect($ds, ...
3
votes
1answer
761 views

How can uptime be used to trigger an action?

I want to write shell or perl code which would give me notification after x days. Basically on SUSE Linux server, there is reboot required after 208 days, else the system would freeze. This is known ...
3
votes
2answers
6k views

Need to configure perl

I was going to run a perl program and then I got this error message: Can't locate JSON.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 ...
0
votes
0answers
187 views

How to reinstall Perl on OS X

I accidentally deleted the /System/Library/Perl/ folder. Now I am not be able to run any of my projects. How can I reinstall Perl on OS X?
3
votes
1answer
1k views

Estimating compressed file size using a list parameter

I am currently compressing a list of files from a directory in the following format: tar -cvjf test_1.tar.gz -T test_1.lst --no-recursion The above command will compress only those files ...
2
votes
1answer
290 views

Cygwin wants to downgrade my Perl

I'm using Cygwin 2.769. I used setup.exe to upgrade Perl to version 5.14.1-2, which works fine. But now whenever I open setup.exe to upgrade/install some other package, it by default wants to ...
1
vote
1answer
655 views

Script or program to download all images in a folder

I'm currently using windows 7, and I was wondering if there is perhaps a perl script or a program I can install to download files from a given directory. For example, I want to be able to specify that ...
3
votes
4answers
4k views

Perl Package Manager via NTLM proxy

I've installed ActivePerl and the include PPM at work, but I'm unable to get it connect to the module repository through the proxy. I've set up an environment variable HTTP_PROXY = ...
0
votes
1answer
662 views

Eclipse lost line numbers

My eclipse no longer shows line numbers, its configured to do and it did before (I believe it became like this after I moved its application folder, mac osx) The settings read that it's supposed ...
1
vote
1answer
2k views

Can someone explain why LWP::Simple is satisfied by perl-libwww-perl?

Installing Munin on RHEL 6 from RPM available at, http://pkgs.repoforge.org/ most installs were ok but when installing munin-node got this: rpm -Uvh munin-node-1.2.5-1.el5.rf.noarch.rpm warning: ...
1
vote
2answers
1k views

Building VIM with python support in Cygwin?

I'm trying to build VIM with Python/Perl support under Cygwin. Has anyone done this and can shed some light how this is achieved?
8
votes
6answers
9k views

unix - split a huge .gz file by line

I'm sure someone has had the below need, what is a quick way of splitting a huge .gz file by line? The underlying text file has 120million rows. I don't have enough disk space to gunzip the entire ...
16
votes
6answers
9k views

Removing ANSI color codes from text stream

Examining the output from perl -e 'use Term::ANSIColor; print color "white"; print "ABC\n"; print color "reset";' in a text editor (e.g., vi) shows the following: ^[[37mABC ^[[0m How would one ...
1
vote
4answers
669 views

sed removal of whitespace

I find that sed often fails to pattern-match whitespace. Consider the following examples: echo 'A B C' | sed 's/[ \t]*//g' ABC echo -e 'A\tB\tC' | sed 's/[ \t]*//g' A B C perl ...
0
votes
1answer
306 views

awk + sed + match complex string

I need useful command to match the string "/pci.../pci.../pci..../scsi..../disk..." with awk or sed? ( I need to put this command in my ksh script ) remark 1 [...] can be any string , and “pci pci ...
0
votes
2answers
804 views

egrep: CPU and memory usage

My Linux machine has 16 processors and free memory of 70 GB but when I run an egrep command, the command is using (checked through the top command) 100% of CPU and 0.5 of memory: 22391 aime 25 ...
1
vote
2answers
493 views

How to pass bash variables (passwords) to IRSSI config file?

I'm using IRSSI and I wonder how can I pass my IRC channel's passwords to the IRSSI config file (~/.irssi/config) without writing them directly in the file. In Mutt I've an awk command that queries a ...
0
votes
2answers
54 views

How to do create a thumbnail of many sites?

I've got a list of 2500 websites and need to grab a little screenshot of them - to create a thumbnail How do I do that? Well I could try to parse the sites. Either with Perl or Python
2
votes
3answers
31k views

How to install Perl on Ubuntu Server?

I'm trying to deploy an application which according to the documentation requires the following: 2.2.5. Perl LMS-MGC and the rest of Perl scripts requires also Perl interpreter and some modules: ...
5
votes
2answers
436 views

What is causing git byte order error?

I can no longer git svn rebase (using msysgit on Windows 7). The error starts with: Byte order is not compatible at ../../lib/Storable.pm And ends with: Could not unmemoize function ...