{"id":940,"date":"2007-10-04T13:49:59","date_gmt":"2007-10-04T08:19:59","guid":{"rendered":"http:\/\/www.chiragmehta.info\/chirag\/2007\/10\/04\/print-a-list-of-directory-contents\/"},"modified":"2007-10-04T13:49:59","modified_gmt":"2007-10-04T08:19:59","slug":"print-a-list-of-directory-contents","status":"publish","type":"post","link":"https:\/\/www.chiragmehta.info\/chirag\/2007\/10\/04\/print-a-list-of-directory-contents\/","title":{"rendered":"Print a list of directory contents"},"content":{"rendered":"<p>The DIR command gives you the information you want, but it isn\u00e2\u20ac\u2122t yet in a form you can use in a Windows document\u00e2\u20ac\u201dyou can\u00e2\u20ac\u2122t copy and paste the contents of the DOS window. Instead, you\u00e2\u20ac\u2122ll use another native DOS technique: output redirection. Rather than allow the DIR command\u00e2\u20ac\u2122s output to appear onscreen as it does by default, you\u00e2\u20ac\u2122ll send it to a text file. To do so, you\u00e2\u20ac\u2122ll use the > redirection operator, like this:<br \/>\ndir\/b \/s > dirlist.txt<\/p>\n<p>Of course, you can use any file name you like and you can precede it with a file path. When you press [Enter], you\u00e2\u20ac\u2122ll simply see the command line reappear. However, if you close the DOS session by typing exit and you return to Windows, you\u00e2\u20ac\u2122ll find a new text file that contains the file names<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The DIR command gives you the information you want, but it isn\u00e2\u20ac\u2122t yet in a form you can use in a Windows document\u00e2\u20ac\u201dyou can\u00e2\u20ac\u2122t copy and paste the contents of the DOS window. Instead, you\u00e2\u20ac\u2122ll use another native DOS technique: output redirection. Rather than allow the DIR command\u00e2\u20ac\u2122s output to appear onscreen as it does [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[7],"class_list":["post-940","post","type-post","status-publish","format-standard","hentry","tag-others","post-preview"],"_links":{"self":[{"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/posts\/940","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/comments?post=940"}],"version-history":[{"count":0,"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/posts\/940\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/media?parent=940"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/categories?post=940"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.chiragmehta.info\/chirag\/wp-json\/wp\/v2\/tags?post=940"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}