in reply to Getting string value after = operator

I'm not quite sure what you're asking. Example input and output and your script as it is at the moment are generally helpful to clarify the question.

I assume from your title and first part of your question that given a string you want to get any text after an equals sign, and that then you know how to put it in a file, or whatever you want to do with it. If so then this might help:

#!/usr/bin/perl -w use strict; my $string = "name = arrunich"; if ($string =~ m/= \s* (\S+)/x) { print "$1 \n"; }

This uses a regular expression which looks for an = sign followed by zero or more spaces, followed by one or more non-spaces. If it finds it then it puts the non-spaces in $1.

You might find String matching and Regular Expressions useful.

Update: First paragraphs added