Em Andamento

Replace Windows File Date Modified Timestamp With Date In File

I am looking for a Windows script (batch, VB, PowerShell) that scans through a specified directory with sub-directories and replaces the date modified timestamp of each file with a value found within each file:

I need the script to do the following:

1. Check if file contents begins with "MIME-Version" or "Delivered-To".

2.

If file begins with "MIME-Version" perform the following steps:

A. Extract the date timestamp from line 2 (see example below and note that sometimes the day date is one [1] digit else it is two [2] digits):

MIME-Version: 1.0

Received: by [url removed, login to view] with HTTP; Thu, 10 Aug 2017 16:43:01 -0700 (PDT)

B. Tokenize the date timestamp into MM DD YYY hh:mm AM/PM

C. Adjust time such as -0700 (PDT) into Central Time

D. Change date modified timestamp of file to the adjusted time.

-OR-

If file begins with "Delivered-To" perform the following steps

A. Extract the date timestamp from line 3 (see example below and note that sometimes the day date is one [1] digit else it is two [2] digits):

Delivered-To: [url removed, login to view]

Received: by [url removed, login to view] with SMTP id kj3csp1973383qcb;

Fri, 2 Jan 2015 17:13:55 -0800 (PST)

B. Tokenize the date timestamp into MM DD YYY hh:mm AM/PM

C. Adjust time such as -0700 (PDT) into Central Time

D. Change date modified timestamp of file to the adjusted time.

3. The script should process only a specific file type. In this case it is *.eml files.

4. The script should be able to skip files that do not start with either "MIME-Version" or "Delivered-To" AND files that may be missing date timestamps on the specified corresponding lines.

5. The script should recurse the files and sub-directories of a specified directory.

6. The script should produce a log of what files were successfully processed and or skipped.

7. The script should be able to tell which files it has already processed in case the script must be resumed.

8. The script should replace the date modified timestamp of each file with the adjusted date reference as specified in step 2.

Is this something you would be willing to help me with? If so, how much would you charge and when would you expect it to be delivered?

I look forward to working with you.

Kind regards,

Paul Luckett

Habilidades: DOS, Powershell, Visual Basic

Ver mais: vb6 file date modified, delphi file date modified, file date modified, vbnet file date modified, visual file date modified, modified file date, vba file date modified, file date modified vba, file date modified vbnet, net modifed file date

Acerca do Empregador:
( 28 comentários ) Starkville, United States

ID do Projeto: #14907798

Premiar a:

huongth

Hi. I can create auto scripts to scrape websites, auto click, format txt, csv, xls, xlsx, doc, docx, rtf, json, xml, database files as you request. I can start right now Relevant Skills and Experience I am an exper Mais

$50 USD em 1 dia
(6 Avaliações)
2.6

3 freelancers estão ofertando em média $133 para este trabalho

AccuPro

I can do this with perfection.. using C language. best regards, AccuPro.

$249 USD in 5 dias
(2 Comentários)
2.5
$100 USD in 3 dias
(0 Comentários)
0.0