<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by David Brookton on Medium]]></title>
        <description><![CDATA[Stories by David Brookton on Medium]]></description>
        <link>https://medium.com/@davidbrookton?source=rss-3780750efcdf------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*2heXbE_U1V3IQGvbp3jepA.jpeg</url>
            <title>Stories by David Brookton on Medium</title>
            <link>https://medium.com/@davidbrookton?source=rss-3780750efcdf------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 03:02:51 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@davidbrookton/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Setting Up a Mac OS Development Environment]]></title>
            <link>https://davidbrookton.medium.com/setting-up-a-mac-os-development-environment-834f81a4ea88?source=rss-3780750efcdf------2</link>
            <guid isPermaLink="false">https://medium.com/p/834f81a4ea88</guid>
            <category><![CDATA[terminal]]></category>
            <category><![CDATA[development-tips]]></category>
            <category><![CDATA[development-tools]]></category>
            <category><![CDATA[macos]]></category>
            <category><![CDATA[development]]></category>
            <dc:creator><![CDATA[David Brookton]]></dc:creator>
            <pubDate>Wed, 31 Jul 2019 19:21:21 GMT</pubDate>
            <atom:updated>2021-02-10T19:27:47.506Z</atom:updated>
            <cc:license>http://creativecommons.org/publicdomain/zero/1.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="Know the Pain Harold ready to setup his development enviornment" src="https://cdn-images-1.medium.com/max/1000/1*i4B0Dx_TIIJXS9_x3lkNYA.jpeg" /></figure><p>Whether you’re new to a Mac, new to development or you just got a new computer and want to start fresh… Here are the steps I go through to setup my development enviornment.</p><h4>If you just bought or received a new Mac for work</h4><p>Congrats! I recommend setting it up <em>without restoring from a backup</em> (if you haven’t already). You can read more on why below, but feel free to skip to the installation instructions to get started.</p><h3>Benefits of starting fresh on Mac OS</h3><p>I’ve spent six and a half years working for Apple doing external customer support, as a Senior Advisor, and also spent some time on the internal support side. I’m bringing it up because unequivocally the <strong>best possible </strong>Mac OS cure-all is <a href="https://support.apple.com/en-us/HT204904">Erasing and Reinstalling a fresh copy of your Mac’s operating system</a>.</p><h4><strong>If you’re a recent CS or dev bootcamp grad and already using a Mac</strong></h4><p>I’d like to briefly explain why it’s worth considering backing up, erasing, and reinstalling a fresh copy of your computer, <strong>manually migrating your files, </strong>and manually re-configuring your dev environment with the steps I use below.</p><h4>A fresh Mac OS installation ensures security, stability &amp; speed.</h4><p>Over time, who knows how many global npm packages, sql database configurations and or other dependencies you may have installed. Obviously, it’s possible to monitor and update your dev dependencies, but especially if you’re interested in security and performance, I recommend starting fresh every once and a while.</p><p>To erase and reinstall a fresh copy of the OS on your Mac, first backup to Time Machine so that you can manually restore from these and recover system configurations later if needed. Then, when you’re ready, <a href="https://support.apple.com/en-us/HT204904">click this link</a> and follow Apple’s offical support documentation on erasing and reinstalling from Recovery. These are the same steps you take when you’re ready to sell or give away your mac. If you’re setting it up again, don’t restore from the backup, manually migrate your files, and follow these steps to get your basic development dependencies up and running.</p><h3><strong>Lets get started</strong></h3><p>Note: I’m going to be listing setup instructions based on popular development dependencies, feel free to skip dependencies that you don’t plan on using or needing. I’ll continue to update so feel free to check back as your languages or dependencies change.</p><h3>Install Homebrew</h3><p>This step on your mac is essential to other dev dependency installations. It’s worth noting that this installation <em>automatically installs</em> <strong>XCode</strong> command line tools. Run this line of code, <a href="https://brew.sh/">here’s where you can verify if it’s the latest</a>, and you’re set:</p><pre>/bin/bash -c &quot;$(curl -fsSL <a href="https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh">https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh</a>)&quot;</pre><h3>Install Git</h3><pre>brew install git</pre><p>Note that you’ll also need an ssh key tied to your github account for secure data transfering. To do this first run</p><pre>ssh-keygen</pre><p>Then you can view your ssh key by running</p><pre>~/.ssh/id_rsa.pub</pre><pre><br>Copy &amp; paste to GitHub profile &gt; settings &gt; SSH &amp; GPG Keys, ‘New SSH Key’. Add to profile</pre><p>After that, login to Github, click on your profie, open Settings then click “SSH &amp; GPG Keys” on the left. Select ‘New SSH Key” and copy paste this key to that field. You can name the key after your computer type or the name of your machine. Next, configure the Git CLI with:</p><pre>git config --global user.email “<a href="/service/mailto:you@example.com">you@example.com</a>” <br>git config --global user.name “Your Name”</pre><p>(Optional) <a href="https://desktop.github.com/"><strong>Github Desktop</strong></a><strong> </strong>is great incase you ever need to undo a push to your project’s branches.</p><h3>Encryption &amp; Security Support</h3><pre>brew install gnupg</pre><h3>Download Code Editors</h3><p>Feel free to install your preferred editor, these are the two I prefer…</p><h3>VSCode</h3><ul><li><a href="https://code.visualstudio.com/download">Current download link</a></li><li>Open it, select “View” &gt; “Command Pallet” and type “Command Pallet: Add code to terminal”. Now you’ll be able to use the <em>code</em> command in terminal to open directories.</li><li>Optional: Sync / Import your previous settings (article coming soon)</li></ul><h4>Atom</h4><ul><li><a href="https://atom.io/">https://atom.io</a></li></ul><h3>Thoughts on Terminal</h3><p>Your mac comes standard with Zsh as your default command line shell in the Terminal application. If you want to give your terminal a bit of a facelift, you can consider iTerm 2 and Oh-My-Zsh styles. If you’re a bash fanatic, there’s a few steps you can follow below to set it as your default I’ll throw out there just incase as well.</p><h4>iTerm2</h4><p>A super-powered terminal alternative: <a href="https://iterm2.com/">https://iterm2.com</a></p><h4>Bash</h4><p>How to change the default shell to Bash on Mac OS Catilina: <a href="https://www.howtogeek.com/444596/how-to-change-the-default-shell-to-bash-in-macos-catalina/">https://www.howtogeek.com/444596/how-to-change-the-default-shell-to-bash-in-macos-catalina/</a></p><p>How to update your version of Bash on a Mac: <a href="https://itnext.io/upgrading-bash-on-macos-7138bd1066ba">https://itnext.io/upgrading-bash-on-macos-7138bd1066ba</a></p><h4>Oh-My-Zsh</h4><p>order to enable a theme, set ZSH_THEME to the name of the theme in your ~/.zshrc, before sourcing Oh My Zsh; for example: ZSH_THEME=xiong-chiamiov-plusis a good one. If you do not want any theme enabled, just set ZSH_THEME to bl: ZSH_THEME=&quot;&quot;. Themes are listed below on GitHub.</p><p><a href="https://github.com/ohmyzsh/ohmyzsh/wiki/Themes">Themes</a></p><p>As Node updates more than I update my blog posts,<a href="https://github.com/nvm-sh/nvm#installing-and-updating"> please be sure to verify the latest install commants here</a>. These are the latest as of Feb 2021:</p><pre>curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.37.2/install.sh | bash</pre><pre># This next command loads nvm into ~/.bash_profile, ~/.zshrc, ~/.profile, or ~/.bashrc </pre><pre>export NVM_DIR=&quot;$([ -z &quot;${XDG_CONFIG_HOME-}&quot; ] &amp;&amp; printf %s &quot;${HOME}/.nvm&quot; || printf %s &quot;${XDG_CONFIG_HOME}/nvm&quot;)&quot;<br>[ -s &quot;$NVM_DIR/nvm.sh&quot; ] &amp;&amp; \. &quot;$NVM_DIR/nvm.sh&quot; </pre><pre>nvm install node</pre><pre>nvm use node</pre><pre>nvm alias default node</pre><h3>Angular</h3><pre>npm install -g <a href="http://twitter.com/angular/cli">@angular/cli</a></pre><h3>Vue</h3><pre>npm install -g <a href="http://twitter.com/vue/cli">@vue/cli</a><br># OR<br>yarn global add <a href="http://twitter.com/vue/cli">@vue/cli</a></pre><h3>React / React-Native</h3><p>Personally, I don’t install these globally. Creating a package I run them through nvm instead. A note on react-native, to develop apps simpler you may want to install <a href="https://developer.apple.com/xcode/">Xcode</a> (<a href="https://apps.apple.com/us/app/xcode/id497799835?mt=12">available free on the Mac App Store</a>) and <a href="https://developer.android.com/studio">Android Studio</a></p><pre>nvm create-react-app</pre><pre>#or</pre><pre>nvm create-react-native-app</pre><h3>Yarn</h3><pre>brew install yarn</pre><h3>.NET</h3><p>Please verify the download instructions <a href="https://dotnet.microsoft.com/download">here</a>. If you want to give <a href="https://visualstudio.microsoft.com/vs/mac/">Visual Studio for Mac</a> a try, it can help sometimes for .NET development, but imo is almost useless on Mac. If you’re a serious C# fanatic, <a href="https://www.jetbrains.com/rider/">Rider</a> is probably the one you want.</p><h3>Ruby Version Manager (RVM)</h3><p>I’ll update this article frequently, but be sure to check that you’re installing the latest stable release of ruby by <a href="https://www.ruby-lang.org/en/downloads/">checking it here</a>. If you want to see the list of versions that rvm has installed on your old development environment, you can run <em>rvm list.</em></p><pre>curl -sSL <a href="https://get.rvm.io/">https://get.rvm.io</a> | bash</pre><pre>source ~/.bash_profile (reloads your terminal configuration file)</pre><pre>rvm get stable</pre><pre>rvm install 2.6.3</pre><pre>rvm use 2.6.3 — default</pre><pre>ruby -v to verify</pre><h3>Gems</h3><p>The bundler gem is going to more or less be required by almost every project, so I’d definitely install that. Nokogiri is a gem to help parse HTML and is useful for scraping websites. I’d recommend that too as a basic system gem.</p><pre>gem install bundler</pre><pre>gem install nokogiri</pre><h3>Fuck</h3><p>Congratulations, you’ve just unlocked: An actual, essential commandline utility fuck (Requires RVM and Gems). fuck typed into the terminal will correct spelling mistakes and auto-type suggested corrections upstream. Cons: way too fun to type.</p><p><a href="https://github.com/nvbn/thefuck">GitHub - nvbn/thefuck: Magnificent app which corrects your previous console command.</a></p><h3>Rails</h3><pre>gem install rails</pre><h3>Composer</h3><p>The easiest way to install Composer is to directly download to your downloads folder from getcomposer.org by clicking the link below, then enter the following commands in the terminal.</p><p><a href="https://getcomposer.org/composer.phar?source=post_page---------------------------">https://getcomposer.org/composer.phar?source=post_page---------------------------</a></p><pre>php ~/Downloads/composer.phar — version   (shows the version)</pre><pre>cp ~/Downloads/composer.phar /usr/local/bin/composer   (copies it)</pre><pre>sudo chmod +x /usr/local/bin/composer     (installs it)</pre><pre>composer — version       (verifies installed version)</pre><h3>Laravel</h3><pre>composer global require laravel/installer</pre><h3>MySQL</h3><pre>brew install mysql</pre><pre>brew tap homebrew/services</pre><pre>brew services start mysql</pre><pre>(Next step is not required if you only run it locally using mysql.server start / mysql.server stop, but generally still recommended)</pre><pre>mysqladmin -u root password ‘yourpassword’</pre><h3>SQLite</h3><pre>brew install sqlite</pre><h3>Postgres</h3><pre>brew cask install postgres</pre><h3>MongoDB</h3><pre>brew install mongodb</pre><h3>Redis</h3><pre>brew install redis</pre><h3>Firebase</h3><pre>npm install -g firebase-tools</pre><pre>firebase login</pre><pre>firebase list   (verify it&#39;s installed)</pre><h3>Heroku</h3><pre>brew tap heroku/brew &amp;&amp; brew install heroku</pre><pre>npm install -g heroku</pre><pre>heroku — version to confirm</pre><pre>heroku login</pre><h3>Netlify</h3><pre>npm install netlify-cli -g</pre><h3>Final Thoughts</h3><p>That’s about it! This obviously isn’t including every framework and language. These are the ones I’ve been coding in the most lately.</p><p>Do you have development packages, languages or apps that you prefer which aren’t listed? Leave me a comment below. I’d love to hear your feedback!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=834f81a4ea88" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>