{"id":657,"date":"2021-11-15T15:32:36","date_gmt":"2021-11-15T20:32:36","guid":{"rendered":"https:\/\/molecularsciences.org\/content\/?p=657"},"modified":"2024-02-08T08:40:57","modified_gmt":"2024-02-08T13:40:57","slug":"mac-terminal-shows-wrong-host-name","status":"publish","type":"post","link":"https:\/\/molecularsciences.org\/content\/mac-terminal-shows-wrong-host-name\/","title":{"rendered":"Mac terminal shows wrong host name"},"content":{"rendered":"\n<h3 class=\"wp-block-heading\">Problem<\/h3>\n\n\n\n<p>Mac terminal shows the wrong hostname on prompt.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Solution<\/h3>\n\n\n\n<p>Find out if a hostname is already specified.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$ sudo scutil --get HostName\nHostName: not set\n<\/code><\/pre>\n\n\n\n<p>To set your Hostname<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$ sudo scutil --set HostName 'myname'\n<\/code><\/pre>\n\n\n\n<p>Exit out of your terminal and start a new terminal. You should see your chosen hostname.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Problem Mac terminal shows the wrong hostname on prompt. Solution Find out if a hostname is already specified. To set your Hostname Exit out of your terminal and start a new terminal. You should see your chosen hostname.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[32],"tags":[],"class_list":["post-657","post","type-post","status-publish","format-standard","hentry","category-mac-os"],"_links":{"self":[{"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/posts\/657","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/comments?post=657"}],"version-history":[{"count":1,"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/posts\/657\/revisions"}],"predecessor-version":[{"id":658,"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/posts\/657\/revisions\/658"}],"wp:attachment":[{"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/media?parent=657"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/categories?post=657"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/molecularsciences.org\/content\/wp-json\/wp\/v2\/tags?post=657"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}