{"id":3171,"date":"2016-02-18T13:42:40","date_gmt":"2016-02-18T13:42:40","guid":{"rendered":"http:\/\/www.garysieling.com\/blog\/?p=3171"},"modified":"2016-02-18T13:42:40","modified_gmt":"2016-02-18T13:42:40","slug":"fixing-error-bash-browserify-command-not-found","status":"publish","type":"post","link":"https:\/\/www.garysieling.com\/blog\/fixing-error-bash-browserify-command-not-found\/","title":{"rendered":"Fixing error &#8220;bash: browserify: command not found&#8221;"},"content":{"rendered":"<p>If you follow the steps on the browserify site, you may find that it does not work afterwards:<\/p>\n<pre lang=\"bash\">\nnpm install -g browserify\n<\/pre>\n<p>When I tried to run browserify, I got this error:<\/p>\n<pre>\nbash: browserify: command not found\n<\/pre>\n<p>In the log output, you will see something like this, which indicates that NPM makes a symlink in the NPM folder (not that my NPM folder is in %AppData% rather than say ~, like most of the internet assumes):<\/p>\n<pre>\nC:\\Users\\gary\\AppData\\Roaming\\npm\\browserify -> C:\\Users\\gary\\AppData\\Roaming\\npm\\node_modules\\browserify\\bin\\cmd.js\nbrowserify@13.0.0 C:\\Users\\gary\\AppData\\Roaming\\npm\\node_modules\\browserify\n\u251c\u2500\u2500 https-browserify@0.0.1\n\u251c\u2500\u2500 tty-browserify@0.0.0\n\u251c\u2500\u2500 path-browserify@0.0.0\n\u251c\u2500\u2500 htmlescape@1.1.0\n...\n<\/pre>\n<p>On Windows, you can get the AppData location by doing this:<\/p>\n<pre lang=\"bash\">\necho %AppData%\n<\/pre>\n<p>Which gives you this value, which you should add to your path:<\/p>\n<pre>\nC:\\Users\\gary\\AppData\\Roaming\\npm\n<\/pre>\n<p>The &#8220;correct&#8221; path entry to add would be &#8220;%AppData%\\npm&#8221;, however you shouldn&#8217;t do this &#8211; I found that git bash could not correctly translate this into the folder, so it isn&#8217;t able to resolve the location of NPM.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you follow the steps on the browserify site, you may find that it does not work afterwards: npm install -g browserify When I tried to run browserify, I got this error: bash: browserify: command not found In the log output, you will see something like this, which indicates that NPM makes a symlink in &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.garysieling.com\/blog\/fixing-error-bash-browserify-command-not-found\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Fixing error &#8220;bash: browserify: command not found&#8221;&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[9],"tags":[79,93,198,302,387,393,597],"aioseo_notices":[],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/3171"}],"collection":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/comments?post=3171"}],"version-history":[{"count":0,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/3171\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/media?parent=3171"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/categories?post=3171"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/tags?post=3171"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}