{"id":1148,"date":"2022-10-18T15:41:16","date_gmt":"2022-10-18T07:41:16","guid":{"rendered":"https:\/\/benson.ml\/?p=1148"},"modified":"2022-10-18T15:52:48","modified_gmt":"2022-10-18T07:52:48","slug":"%e5%a6%82%e4%bd%95%e5%9c%a8-windows-%e4%b8%ad%e6%9f%a5%e7%9c%8b-powershell-%e7%89%88%e6%9c%ac%e5%8f%b7","status":"publish","type":"post","link":"https:\/\/benson80.eu.org\/?p=1148","title":{"rendered":"\u5982\u4f55\u5728 Windows \u4e2d\u67e5\u770b PowerShell \u7248\u672c\u53f7"},"content":{"rendered":"\n<p>Windows PowerShell \u662f Windows \u7528\u6237\u300c\u4efb\u52a1\u81ea\u52a8\u5316\u300d\u548c\u300c\u7cfb\u7edf\u7ba1\u7406\u300d\u7684\u4e13\u4e1a\u5de5\u5177\uff0c\u5b83\u7684\u5de5\u4f5c\u65b9\u5f0f\u4e0e\u300c\u547d\u4ee4\u63d0\u793a\u7b26\u300d\u7c7b\u4f3c\uff0c\u53ef\u4ee5\u901a\u8fc7\u547d\u4ee4\u884c Shell \u6765\u7ba1\u7406\u7edd\u5927\u591a\u6570 Windows \u548c\u5fae\u8f6f\u4ea7\u54c1\u7684\u8bbe\u7f6e\u3002<\/p>\n\n\n\n<p>\u5982\u679c\u4f60\u662f\u666e\u901a\u7528\u6237\uff0c\u67e5\u770b\u5e76\u786e\u4fdd Windows \u4e2d\u5b89\u88c5\u4e86\u6700\u65b0\u7248\u672c\u7684 PowerShell \u662f\u5f88\u6709\u5fc5\u8981\u7684\u3002\u4e0b\u9762\u7cfb\u7edf\u6781\u5ba2\u5c31\u4e3a\u5927\u5bb6\u4ecb\u7ecd\uff0c\u5728 Windows \u4e2d\u67e5\u770b PowerShell \u7248\u672c\u4e24\u79cd\u65b9\u5f0f\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u5728 Windows \u4e2d\u67e5\u770b PowerShell \u7248\u672c<\/h2>\n\n\n\n<p>\u901a\u8fc7 PowerShell \u81ea\u8eab\u7684\u547d\u4ee4\u6765\u67e5\u770b\u5f53\u524d\u7248\u672c\u662f\u6700\u7b80\u5355\u7684\u64cd\u4f5c\u65b9\u5f0f\uff0c\u6b65\u9aa4\u5982\u4e0b\uff1a<\/p>\n\n\n\n<p>1. \u5728\u300c\u5f00\u59cb\u300d\u83dc\u5355\u4e2d\u641c\u7d22PowerShell\u5e76\u6253\u5f00\u300cWindows PowerShell\u300d\u754c\u9762<\/p>\n\n\n\n<p>2. \u5728\u6253\u5f00\u7684\u754c\u9762\u4e2d\u6267\u884c\u5982\u4e0b\u547d\u4ee4\uff1a<\/p>\n\n\n\n<p>$PSVersionTable<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"433\" height=\"309\" src=\"https:\/\/benson.ml\/wp-content\/uploads\/2022\/10\/image-17.png\" alt=\"\" class=\"wp-image-1156\" srcset=\"https:\/\/benson80.eu.org\/wp-content\/uploads\/2022\/10\/image-17.png 433w, https:\/\/benson80.eu.org\/wp-content\/uploads\/2022\/10\/image-17-300x214.png 300w, https:\/\/benson80.eu.org\/wp-content\/uploads\/2022\/10\/image-17-421x300.png 421w\" sizes=\"auto, (max-width: 433px) 100vw, 433px\" \/><\/figure>\n\n\n\n<p>\u547d\u4ee4\u6267\u884c\u540e\u4f1a\u8f93\u51fa\u6709\u5173 PowerShell \u7684\u5b8c\u6574\u4fe1\u606f\u5217\u8868\uff0c\u901a\u8fc7PSVersion\u503c\u53ef\u77e5\u5f53\u524d PowerShell \u7248\u672c\u4e3a 5.1.19041.1682\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u901a\u8fc7\u6ce8\u518c\u8868\u67e5\u770b PowerShell \u7248\u672c<\/h2>\n\n\n\n<p>Windows \u6ce8\u518c\u8868\u662f\u4e00\u4e2a\u96c6\u4e2d\u7684\u5206\u5c42\u6570\u636e\u5e93\uff0c\u4e13\u95e8\u7528\u4e8e\u5b58\u50a8\u548c\u4fdd\u5b58 PC \u7684\u4f4e\u7ea7\u914d\u7f6e\u4fe1\u606f\u3002 \u5982\u679c\u4f60\u4e0d\u60f3\u542f\u52a8 PowerShell\uff0c\u53ef\u4ee5\u67e5\u770b\u6ce8\u518c\u8868\u6765\u786e\u5b9a\u5f53\u524d PowerShell \u7248\u672c\uff1a<\/p>\n\n\n\n<p>1. \u4f7f\u7528Windows + R\u5feb\u6377\u952e\u6253\u5f00\u300c\u8fd0\u884c\u300d\u2014\u2014\u6267\u884cregedit\u6253\u5f00\u300c\u6ce8\u518c\u8868\u7f16\u8f91\u5668\u300d<\/p>\n\n\n\n<p>2. \u5bfc\u822a\u5230\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"659\" height=\"417\" src=\"https:\/\/benson.ml\/wp-content\/uploads\/2022\/10\/image-18.png\" alt=\"\" class=\"wp-image-1159\" srcset=\"https:\/\/benson80.eu.org\/wp-content\/uploads\/2022\/10\/image-18.png 659w, https:\/\/benson80.eu.org\/wp-content\/uploads\/2022\/10\/image-18-300x190.png 300w, https:\/\/benson80.eu.org\/wp-content\/uploads\/2022\/10\/image-18-421x266.png 421w\" sizes=\"auto, (max-width: 659px) 100vw, 659px\" \/><\/figure>\n\n\n\n<p>\u8ba1\u7b97\u673a\\HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\PowerShell\\3\\PowerShellEngine<\/p>\n\n\n\n<p>3. \u901a\u8fc7\u67e5\u770bPowerShellVersion\u6ce8\u518c\u8868\u503c\u6765\u786e\u8ba4 PowerShell \u7248\u672c\u3002<\/p>\n\n\n\n<p>\u901a\u5e38\uff0cPowerShell \u4f1a\u901a\u8fc7\u81ea\u52a8\u66f4\u65b0\u81ea\u884c\u66f4\u65b0\uff0c\u4e5f\u53ef\u4ee5\u4ece<a rel=\"noreferrer noopener\" href=\"https:\/\/docs.microsoft.com\/zh-cn\/powershell\/\" target=\"_blank\">\u5fae\u8f6f PowerShell \u5b98\u7f51<\/a>\u83b7\u53d6\u6700\u6700\u65b0\u66f4\u65b0\u3001\u6587\u6863\u548c\u53c2\u8003\u793a\u4f8b\u3002<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Windows PowerShell \u662f Wind &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-1148","post","type-post","status-publish","format-standard","hentry","category-windows"],"_links":{"self":[{"href":"https:\/\/benson80.eu.org\/index.php?rest_route=\/wp\/v2\/posts\/1148","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/benson80.eu.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/benson80.eu.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/benson80.eu.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/benson80.eu.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1148"}],"version-history":[{"count":6,"href":"https:\/\/benson80.eu.org\/index.php?rest_route=\/wp\/v2\/posts\/1148\/revisions"}],"predecessor-version":[{"id":1160,"href":"https:\/\/benson80.eu.org\/index.php?rest_route=\/wp\/v2\/posts\/1148\/revisions\/1160"}],"wp:attachment":[{"href":"https:\/\/benson80.eu.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1148"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/benson80.eu.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1148"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/benson80.eu.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1148"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}