LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-01-2013, 10:01 PM   #1
iamtinski
LQ Newbie
 
Registered: Dec 2013
Posts: 1

Rep: Reputation: Disabled
Wink What is the difference between perl and shell scripting


Hi Experts,

Can someone explain what is the difference between perl and shell scripting?

Thank you.
 
Old 12-01-2013, 10:23 PM   #2
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 6,914

Rep: Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999Reputation: 1999
One is scripting using Perl the other is scripting using one of the many built-in scripting languages in the shell.
https://en.wikipedia.org/wiki/Perl
https://en.wikipedia.org/wiki/Bash_%28Unix_shell%29
https://en.wikipedia.org/wiki/C_shell
...
 
Old 12-01-2013, 11:32 PM   #3
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,714

Rep: Reputation: 1280Reputation: 1280Reputation: 1280Reputation: 1280Reputation: 1280Reputation: 1280Reputation: 1280Reputation: 1280Reputation: 1280
Quote:
Originally Posted by iamtinski View Post
Hi Experts,

Can someone explain what is the difference between perl and shell scripting?

Thank you.
The difference is the target use.

The shell is primarily an interactive command function. It is only secondarily a programming interface for stored commands.

Perl CAN access commands... but it is awkward at doing so, and is not that flexible. And if you think the "system" library (or the back tics) are uses--- they are implemented using the shell, not perl. Both spawn off a /bin/sh (or bash) to actually process the command.

Perl is primarily a programming language. As such it has much more complete I/O (direct implementation of hash tables and files, hashes of arrays, arrays of hashes, hashes of hashes, arrays of arrays..., network access (both through the normal system calls and through modules), file access, even an object programming model. In addition, it has the possibility of directly accessing external libraries (given the proper interface definitions of course).

The perl interpreter can even be embedded within other applications.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Python, Perl or Shell scripting? hotspur919 Linux - General 12 06-17-2011 12:39 AM
what is the difference between shell and tcl scripting?? sanpraja Linux - Newbie 1 05-22-2010 11:20 AM
Perl or Shell Scripting latinmusic74 Linux - General 7 10-24-2009 04:01 PM
difference between shell scripting and c language gadekishore Linux - Software 5 10-17-2005 07:33 AM
shell scripting and perl irubin Programming 1 01-01-2004 09:27 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:33 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration