Append a string to a file in Perl in one-line fashion

Want to append a string to a file in Perl one-line fashion. DOS Shell, we can do
echo This is a test >> test.txt
In Perl, can it be achived? I know that open a file with option ">>..." in Perl. Appending can be done. How about commad-line fashion?  
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

jl66ConsultantAuthor Commented:
The command-line fshion means that
perl -p -e ..........
perl -e 'print "The new line\n"' >> file.txt

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
jl66ConsultantAuthor Commented:
Thanks for the info. I tried it and found the following:
E:\oracle\perl\5.8.3\bin\MSWin32-x86-multi-thread>perl -e 'print "The new line\n" ' >> file.txt
Can't find string terminator "'" anywhere before EOF at -e line 1.

E:\ora10g\perl\5.8.3\bin\MSWin32-x86-multi-thread>perl -version
This is perl, v5.8.3 built for MSWin32-x86-multi-thread
Copyright 1987-2003, Larry Wall
OWASP Proactive Controls

Learn the most important control and control categories that every architect and developer should include in their projects.

jl66ConsultantAuthor Commented:
ora10g = oracle.
perl -le "print 'The new line' " >> file.txt
why not trying simple way:

echo "new line" >> file
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.