{"id":32220,"date":"2023-03-04T18:18:51","date_gmt":"2023-09-15T10:12:39","guid":{"rendered":"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/"},"modified":"2024-01-15T07:10:59","modified_gmt":"2024-01-14T23:10:59","slug":"%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm","status":"publish","type":"post","link":"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/","title":{"rendered":"\u5728Ubuntu\u4e0a\u5b89\u88c5npm"},"content":{"rendered":"<p>\u5c1d\u8bd5\u5728Ubuntu 14.04\u4e0a\u5b89\u88c5npm\u65f6\u82b1\u8d39\u4e86\u4e00\u4e9b\u65f6\u95f4\uff0c\u56e0\u6b64\u6211\u6574\u7406\u4e86\u4e00\u4e9b\u4fe1\u606f\u3002<\/p>\n<p>\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u65f6\u53d1\u751f\u9519\u8bef\u3002<\/p>\n<p>sudo apt-get install nodejs<\/p>\n<p>\u624b\u518c\u300a\u901a\u8fc7\u8f6f\u4ef6\u5305\u7ba1\u7406\u5668\u5b89\u88c5Node.js\u300b\u4e2d\u8be6\u7ec6\u8bf4\u660e\u4e86\u5728Ubuntu\u4e0a\u5b89\u88c5\u7684\u6b65\u9aa4\u3002\u6309\u7167\u8be5\u6b65\u9aa4\u8fdb\u884c\u64cd\u4f5c\u3002<\/p>\n<p>\u9996\u5148\u5220\u9664\u5b89\u88c5\u5931\u8d25\u7684 nodejs\u3002<\/p>\n<p>sudo apt-get remove &#8211;purge nodejs<\/p>\n<p>\u8bf7\u6309\u7167\u4ee5\u4e0b\u6b65\u9aa4\u5728\u624b\u518c\u4e2d\u8fdb\u884c\u64cd\u4f5c\uff1a<\/p>\n<p>sudo apt-get install curl<\/p>\n<p>curl -sL https:\/\/deb.nodesource.com\/setup_6.x | sudo -E bash &#8211;<\/p>\n<p>sudo apt-get install -y nodejs<\/p>\n<p>\u5728\u6b64\u4e4b\u540e\uff0c\u5168\u5c40\u5b89\u88c5\u6700\u65b0\u7684npm\u3002<\/p>\n<p>sudo npm install npm@latest -g\u3002<\/p>\n<p>\u4ee5\u4e0a\u5185\u5bb9\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5c1d\u8bd5\u5728Ubuntu 14.04\u4e0a\u5b89\u88c5npm\u65f6\u82b1\u8d39\u4e86\u4e00\u4e9b\u65f6\u95f4\uff0c\u56e0\u6b64\u6211\u6574\u7406\u4e86\u4e00\u4e9b\u4fe1\u606f\u3002 \u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u65f6\u53d1\u751f\u9519\u8bef\u3002  [&hellip;]<\/p>\n","protected":false},"author":7,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-32220","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.5 (Yoast SEO v21.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u5728Ubuntu\u4e0a\u5b89\u88c5npm - Blog - Silicon Cloud<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.silicloud.com\/zh\/blog\/\u5728ubuntu\u4e0a\u5b89\u88c5npm\/\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u5728Ubuntu\u4e0a\u5b89\u88c5npm\" \/>\n<meta property=\"og:description\" content=\"\u5c1d\u8bd5\u5728Ubuntu 14.04\u4e0a\u5b89\u88c5npm\u65f6\u82b1\u8d39\u4e86\u4e00\u4e9b\u65f6\u95f4\uff0c\u56e0\u6b64\u6211\u6574\u7406\u4e86\u4e00\u4e9b\u4fe1\u606f\u3002 \u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u65f6\u53d1\u751f\u9519\u8bef\u3002 [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.silicloud.com\/zh\/blog\/\u5728ubuntu\u4e0a\u5b89\u88c5npm\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog - Silicon Cloud\" \/>\n<meta property=\"article:published_time\" content=\"2023-09-15T10:12:39+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-01-14T23:10:59+00:00\" \/>\n<meta name=\"author\" content=\"\u79d1, \u9896\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u79d1, \u9896\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/\",\"name\":\"\u5728Ubuntu\u4e0a\u5b89\u88c5npm - Blog - Silicon Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\"},\"datePublished\":\"2023-09-15T10:12:39+00:00\",\"dateModified\":\"2024-01-14T23:10:59+00:00\",\"author\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/8ca01ba7f7362ad4edb7da206a12f29e\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.silicloud.com\/zh\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u5728Ubuntu\u4e0a\u5b89\u88c5npm\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/\",\"name\":\"Blog - Silicon Cloud\",\"description\":\"\",\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/8ca01ba7f7362ad4edb7da206a12f29e\",\"name\":\"\u79d1, \u9896\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/8a6fb3cc7ba2f69d2189ba532aec4633ea7ed75ac0af162ec367cb3abc0fb2af?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/8a6fb3cc7ba2f69d2189ba532aec4633ea7ed75ac0af162ec367cb3abc0fb2af?s=96&d=mm&r=g\",\"caption\":\"\u79d1, \u9896\"},\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/author\/keying\/\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/#local-main-organization-logo\",\"url\":\"\",\"contentUrl\":\"\",\"caption\":\"Blog - Silicon Cloud\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"\u5728Ubuntu\u4e0a\u5b89\u88c5npm - Blog - Silicon Cloud","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.silicloud.com\/zh\/blog\/\u5728ubuntu\u4e0a\u5b89\u88c5npm\/","og_locale":"zh_CN","og_type":"article","og_title":"\u5728Ubuntu\u4e0a\u5b89\u88c5npm","og_description":"\u5c1d\u8bd5\u5728Ubuntu 14.04\u4e0a\u5b89\u88c5npm\u65f6\u82b1\u8d39\u4e86\u4e00\u4e9b\u65f6\u95f4\uff0c\u56e0\u6b64\u6211\u6574\u7406\u4e86\u4e00\u4e9b\u4fe1\u606f\u3002 \u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u65f6\u53d1\u751f\u9519\u8bef\u3002 [&hellip;]","og_url":"https:\/\/www.silicloud.com\/zh\/blog\/\u5728ubuntu\u4e0a\u5b89\u88c5npm\/","og_site_name":"Blog - Silicon Cloud","article_published_time":"2023-09-15T10:12:39+00:00","article_modified_time":"2024-01-14T23:10:59+00:00","author":"\u79d1, \u9896","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"\u79d1, \u9896"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/","url":"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/","name":"\u5728Ubuntu\u4e0a\u5b89\u88c5npm - Blog - Silicon Cloud","isPartOf":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website"},"datePublished":"2023-09-15T10:12:39+00:00","dateModified":"2024-01-14T23:10:59+00:00","author":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/8ca01ba7f7362ad4edb7da206a12f29e"},"breadcrumb":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.silicloud.com\/zh\/blog\/"},{"@type":"ListItem","position":2,"name":"\u5728Ubuntu\u4e0a\u5b89\u88c5npm"}]},{"@type":"WebSite","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website","url":"https:\/\/www.silicloud.com\/zh\/blog\/","name":"Blog - Silicon Cloud","description":"","inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/8ca01ba7f7362ad4edb7da206a12f29e","name":"\u79d1, \u9896","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/8a6fb3cc7ba2f69d2189ba532aec4633ea7ed75ac0af162ec367cb3abc0fb2af?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/8a6fb3cc7ba2f69d2189ba532aec4633ea7ed75ac0af162ec367cb3abc0fb2af?s=96&d=mm&r=g","caption":"\u79d1, \u9896"},"url":"https:\/\/www.silicloud.com\/zh\/blog\/author\/keying\/"},{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/%e5%9c%a8ubuntu%e4%b8%8a%e5%ae%89%e8%a3%85npm\/#local-main-organization-logo","url":"","contentUrl":"","caption":"Blog - Silicon Cloud"}]}},"_links":{"self":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/32220","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/comments?post=32220"}],"version-history":[{"count":2,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/32220\/revisions"}],"predecessor-version":[{"id":57248,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/32220\/revisions\/57248"}],"wp:attachment":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/media?parent=32220"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/categories?post=32220"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/tags?post=32220"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}