This repository has been archived on 2025-01-19. You can view files and clone it, but cannot push or open issues or pull requests.
oliverdavies.uk-old-sculpin/source/_posts/2012-11-17-open-sublime-text-2-mac-os-x-command-line.md

20 lines
666 B
Markdown
Raw Normal View History

2015-03-16 21:18:03 +00:00
---
title: Open Sublime Text 2 from the Mac OS X Command Line
2018-12-31 12:13:05 +00:00
excerpt: How to open Sublime Text from the command line.
2015-03-16 21:18:03 +00:00
tags:
2015-06-14 02:27:41 +00:00
- sublime-text
- mac-os-x
- terminal
2015-03-16 21:18:03 +00:00
---
2015-06-18 07:58:56 +00:00
How to open Sublime Text from the command line.
2015-03-16 21:18:03 +00:00
Paste the following code into the Mac OS X Terminal, assuming that you've installed Sublime Text 2 into the /Applications folder.
2017-03-16 08:09:52 +00:00
```language-bash
$ ln -s "/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl" ~/bin/sublime
```
2015-03-16 21:18:03 +00:00
Now you can type `sublime <filename>` open a file or directory in Sublime Text, or `sublime .` to open the current directory.
2015-06-14 02:27:41 +00:00
You can also type `sublime --help` to see a list of the available commands.