Perl

Learning the perl debugger: Lesson 3

pbug-workshop-attendees

This post follows on from lesson 2 in this series of posts.

If you’ve followed the lessons so far you’ll have some basic knowledge around starting the debugger and examining variables.

It’s time to find out how to descend into the depths of some code, stepping into functions.

Continue reading

Command Line

Regular Expression Basics (in a Unix Shell)

Regular expressions are a powerful concept used for searching, filtering, and manipulating text. This article aims to uncover the basics of using regular expressions to extract information from files while working in a Unix shell. To this end, this post covers the basics of working with grep, sed & awk.

Of course, most high-level programming languages have native support for regular expressions too, including Perl, Python, Ruby, Java, JavaScript, PHP etc. Sometimes it can be quicker to do some quick tests on a throw-away file at a shell prompt to test a theory than firing up an environment to create a test, so it might also be useful for developers.

Continue reading

Command Line

Shell Quickstart

This year we are running an IT Graduate program here at Net-a-Porter. The four graduates are doing three-month rotations with various teams, getting experience with many aspects of our business. I volunteered to give them a quick introduction to shell programming and regular expressions. Killing two birds with one stone, I have adapted the shell programming part of that session into this blog post — the regular expressions part of the workshop will be the topic of a future post.

Continue reading