Skip to content
This repository has been archived by the owner on Jun 27, 2020. It is now read-only.

Added instructions for batch installing all snippets #55

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,21 @@ Just a few code snippets I have in my Xcode arsenal. In [dotfiles](http://dotfil

In Xcode 4, open a workspace and toggle the right sidebar to be visible. On the bottom, there is a panel with four icons in the header. Click on the `{ }` icon to open the Code Snippets Library.

Now copy-paste the code from one of these snippets, highlight the code block you just pasted and drag it to the Code Snippet panel. Make sure to match the suggested platform, language, and completion scope. The completion shortcut corresponds to the filename of the code snippet.
Now copy-paste the code from one of these snippets, highlight the code block you just pasted and drag it to the Code Snippet panel. Make sure to match the suggested platform, language, and completion scope. The completion shortcut corresponds to the filename of the code snippet.

## Installing All Snippets

To get started, install the xcodesnippet gem.

```
$ gem install xcodesnippet
```

Once installed, navigate to the directory where the snippets repository has been cloned and run

```
for f in *.m; do xcodesnippet install $f; done
```

This will batch process all of the snippets available in the repository and add them to Xcode.