{"id":72,"date":"2011-05-13T16:53:22","date_gmt":"2011-05-13T23:53:22","guid":{"rendered":"http:\/\/www.brightbill.net\/notes\/?p=72"},"modified":"2011-05-13T16:56:06","modified_gmt":"2011-05-13T23:56:06","slug":"windows-batch-processeach-file","status":"publish","type":"post","link":"https:\/\/www.brightbill.net\/notes\/2011\/05\/windows-batch-processeach-file\/","title":{"rendered":"MS Windows Batch Files &#8211; Doing Something to Each File in a Directory"},"content":{"rendered":"<p>Again, a note primarily for my reference&#8230;<\/p>\n<p>To process each file in a directory using a batch file, the syntax would be<\/p>\n<pre>for %%f in (*.txt) do type %%f<\/pre>\n<p>From the command line it would be<\/p>\n<pre>for %f in (*.txt) do type %f<\/pre>\n<p>(and a reminder that<\/p>\n<pre>rename *.pdf B-*.pdf<\/pre>\n<p>really does rename all the PDF files by putting a &#8220;B&#8221; and a dash in front of each file)<\/p>\n<p>Link to the microsoft.com web site:<\/p>\n<p><a href=\"http:\/\/www.microsoft.com\/resources\/documentation\/windows\/xp\/all\/proddocs\/en-us\/batch.mspx?mfr=true\">http:\/\/www.microsoft.com\/resources\/documentation\/windows\/xp\/all\/proddocs\/en-us\/batch.mspx?mfr=true<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Again, a note primarily for my reference&#8230; To process each file in a directory using a batch file, the syntax would be for %%f in (*.txt) do type %%f From the command line it would be for %f in (*.txt) &hellip; <a href=\"https:\/\/www.brightbill.net\/notes\/2011\/05\/windows-batch-processeach-file\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"activitypub_content_warning":"","activitypub_content_visibility":"","footnotes":""},"categories":[4],"tags":[15,14],"class_list":["post-72","post","type-post","status-publish","format-standard","hentry","category-technology","tag-batch-file","tag-ms-windows"],"_links":{"self":[{"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/posts\/72","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/comments?post=72"}],"version-history":[{"count":4,"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/posts\/72\/revisions"}],"predecessor-version":[{"id":76,"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/posts\/72\/revisions\/76"}],"wp:attachment":[{"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/media?parent=72"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/categories?post=72"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.brightbill.net\/notes\/wp-json\/wp\/v2\/tags?post=72"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}