May 29, 2016 - インストール. $ brew install lua $ brew install vim --with-lua. 通常はこれで入るはず。 brew は別途インストールする必要があります。. Getting a new Mac (for me invariably a MBP) is bittersweet. It’s nice to have something shiny and powerful, but setup can be tedious—especially if you don’t remember the steps. Every time I go through the process I vow to capture the steps next time. • • • • • • • • • First I change my shell to zsh, for: chsh -s $(which zsh) Then I install and get my zsh configs from. [ NOTE: I actually don’t need to install it because I just copy over my existing repo, which. ] Right after the shell is in order I like to fix. The reason is simple: Vim is used to edit most of the files in later steps, and I can’t stand using vim without my configs in place. Really all I do here is copy over my.vim directory and.vimrc file, which is also in my project. Now I have my shell and vim working. By default, both Bash and Zsh use emacs mode when editing the command line, meaning you use your cursor to move around inside the command you’re typing. I like Vim, so I use its everywhere I can. That includes editing commands I’m typing! ![]() Bindkey -v Map escape to work the same way on the command line: bindkey -M viins ‘jk’ vi-cmd-mode Now you can move around in your history, edit commands, etc. All using vim language. [ NOTE: Once again, if you do everything in the Pristine project above, this will already be done for you. ] Homebrew is a package manager for OS X, and I think it’s the best one. You can install it like this: [ NOTE: Remember what I said about running commands from the internet? ] ruby -e '$(curl -fsSL [ NOTE: You need to know what you’re doing before you pipe the internet into your shell. ] Run doctor to make sure you’re in good shape: brew doctor One thing I like to do is get OS X using GNU versions of common tools instead of the default BSD versions. We’ll do this using Homebrew. The Basics RELATED: Homebrew is a package manager designed for installing UNIX tools and other open-source applications on Mac OS X. It will quickly download and install them, compiling them from source. Homebrew Cask extends Homebrew with support for installing binary apps — the kind you normally drag to your Applications folder from DMG files. Install Homebrew and Homebrew Cask First, you’ll need the command-line tools for Xcode installed. On a modern Mac OS X system, you can install these just by running the following command in a Terminal window. You could also install the full application from Apple, if you prefer — but that takes up more space on your Mac and isn’t necessary. Xcode-select --install Next, install. You can just open a Terminal window, copy-paste the following command, and press Enter: ruby -e '$(curl -fsSL This script informs you what it will do. Press Enter and then provide your password to install it. By default, it installs Homebrew so you can use the brew command without typing the sudo command and providing your password. Run the following command once you’re done to ensure Homebrew is installed and working properly: brew doctor UPDATE: The below command is no longer necessary. Homebrew Cask is now automatically installed as part of Homebrew itself. Once you’re done, run the following command to install. It uses Homebrew to install Cask: brew install caskroom/cask/brew-cask. Install Graphical Apps With Homebrew Cask Now you can get started installing those graphical apps you want. This involves some very simple commands. To search for one, use the following command: brew cask search name To install an app, run the following command. Homebrew Cask will automatically download it, extract the app, and install it to your Applications folder. Brew cask install name To uninstall an app with Homebrew Cask, run the following command: brew cask uninstall name Install Open-source Utilities With Homebrew The Homebrew command is the underlying package manager that installs all those UNIX and open-source utilities you might want. It’s the easiest way to install them on Mac OS X, just as it is on Linux. Like Homebrew Cask, it uses simple commands. To search for a utility: brew search name To download and install that package: brew install name To remove that package from your system later: brew remove name For more details on using these commands, read the or the on their official websites. Not every graphical application or Unix utility you’re looking for will be available, but most of them probably will be.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
March 2019
Categories |