<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Perl move files - does not error out in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040380#M95694</link>
    <description>Ah makes more sense.&lt;BR /&gt;I actually used the open DIR or die, before my move.&lt;BR /&gt;2 ways of skinning cat...</description>
    <pubDate>Mon, 16 Apr 2007 16:27:22 GMT</pubDate>
    <dc:creator>Ratzie</dc:creator>
    <dc:date>2007-04-16T16:27:22Z</dc:date>
    <item>
      <title>Perl move files - does not error out</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040377#M95691</link>
      <description>I need to move files from one directory to another.&lt;BR /&gt;I am using the perl File::Copy module&lt;BR /&gt;&lt;BR /&gt;The script works, but I would like notification if the move fails.&lt;BR /&gt;I am moving to a folder, but if the folder is not there it will create a file with the folder name instead and not error out.&lt;BR /&gt;&lt;BR /&gt;my @files=&amp;lt;$fin_tck_tmp/AC*&amp;gt;;&lt;BR /&gt;foreach (@files) {&lt;BR /&gt;move ($_, "/tmp/fin/") or die "could not move files $!";&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;Everything works if there is a folder called /tmp/fin&lt;BR /&gt;But if I remove the fin folder, it will create the a file call fin.&lt;BR /&gt;I need it to complete error out and keep those tickets in $fin_tck_tmp/&lt;BR /&gt;Other wise, I have files in the bitbucket that I can not get back.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Mon, 16 Apr 2007 12:27:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040377#M95691</guid>
      <dc:creator>Ratzie</dc:creator>
      <dc:date>2007-04-16T12:27:23Z</dc:date>
    </item>
    <item>
      <title>Re: Perl move files - does not error out</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040378#M95692</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Use 'mkdir' and handle any exception!&lt;BR /&gt;&lt;BR /&gt;# perl -le '$path="/zot/nopath"; mkdir($path,755) or die "mkdir failed for $path: $!\n"' &lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Mon, 16 Apr 2007 12:44:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040378#M95692</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-04-16T12:44:23Z</dc:date>
    </item>
    <item>
      <title>Re: Perl move files - does not error out</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040379#M95693</link>
      <description>Hi (again):&lt;BR /&gt;&lt;BR /&gt;Oops; I dropped a part!  Before you attempt to move files, either create the directory you need or verify that a directory exists:&lt;BR /&gt;&lt;BR /&gt;# perl -le '$path="/tmp/fin";unless (-d $path) {mkdir($path,755) or die "mkdir failed for $path: $!\n"}'&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Mon, 16 Apr 2007 16:10:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040379#M95693</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-04-16T16:10:04Z</dc:date>
    </item>
    <item>
      <title>Re: Perl move files - does not error out</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040380#M95694</link>
      <description>Ah makes more sense.&lt;BR /&gt;I actually used the open DIR or die, before my move.&lt;BR /&gt;2 ways of skinning cat...</description>
      <pubDate>Mon, 16 Apr 2007 16:27:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-move-files-does-not-error-out/m-p/5040380#M95694</guid>
      <dc:creator>Ratzie</dc:creator>
      <dc:date>2007-04-16T16:27:22Z</dc:date>
    </item>
  </channel>
</rss>

