Skip to content

Commit

Permalink
Merge pull request carlhuda#402 from chrislerum/patch-1
Browse files Browse the repository at this point in the history
clean up the readme
  • Loading branch information
kalbasit committed Feb 13, 2012
2 parents fc1b228 + b666a47 commit cb8f832
Showing 1 changed file with 70 additions and 70 deletions.
140 changes: 70 additions & 70 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@ popular plug-ins and the most common mappings.
The distribution is completely customisable using a `~/.vimrc.before`
and `~/.vimrc.after` Vim RC files.

# UPGRADING FROM BEFORE JANUARY 10th 2012 and after JANUARY 1st 2012
# UPGRADING FROM JANUARY 1st 2012 THROUGH JANUARY 10th

Please run `rake` twice before running macvim, make sure `command-t` is
gone
Please run `rake` twice before running macvim; make sure `command-t` is
gone.

# UPGRADING FROM BEFORE JANUARY 2012
# UPGRADING FROM BEFORE JANUARY 1st 2012

If you were using Janus before January 2012, note that Janus has gone
through a rewrite to make it more stable and customizable. Most notably,
Expand All @@ -30,6 +30,15 @@ To upgrade to the latest version:
3. Do the same with `/.gvimrc.local`.
4. Run the installer: `curl -Lo- http://bit.ly/janus-bootstrap | bash`

## Updating to the latest version (from any time after January 10th, 2012)

To update to the latest version of the distribution, just run `rake`
inside your `~/.vim` directory.

NOTE: If you ever have an error updating Janus relating to a
missing commit in a submodule, please try running `rake` again before
submitting an issue.

## Mailing list

The mailing list is hosted at [Google
Expand All @@ -40,10 +49,10 @@ discussion and announcements.

The distribution is designed to work with Vim >= 7.3.

The distribution also require `ack`, `pep8`, `ctags`, `ruby` and `rake`,
for the most comfortable experience, use the GUI version of Vim. Linux
The distribution also requires `ack`, `pep8`, `ctags`, `ruby` and `rake`.
For the most comfortable experience, use the GUI version of Vim. Linux
users should install `gvim`, OSX users should install
[MacVim](http://code.google.com/p/macvim/), the recommended way of
[MacVim](http://code.google.com/p/macvim/). The recommended way of
installing MacVim is using
[Homebrew](http://mxcl.github.com/homebrew/), but before installing
MacVim you need to use system-wide Python (If you are using python that
Expand All @@ -55,7 +64,7 @@ is):
$ brew install macvim
```

If you don't use Homebrew, you can still download it
If you don't use Homebrew, you can still download MacVim
[here](https://github.com/b4winckler/macvim/downloads).

Take a look at the [Pre-requisites wiki
Expand All @@ -67,7 +76,7 @@ information.

To install Janus, please use our [automatic
installer](https://github.com/carlhuda/janus/blob/master/bootstrap.sh)
, which backups up any Vim files found in your home folder and installs
, which backs up any Vim files found in your home folder and installs
Janus.

```bash
Expand All @@ -76,10 +85,10 @@ $ curl -Lo- http://bit.ly/janus-bootstrap | bash

## Customization

You can use `~/.gvimrc.before` and `~/.vimrc.before` for settings Janus,
like the __leader__ setting, you may also use `~/.gvimrc.after` and
You can use `~/.gvimrc.before` and `~/.vimrc.before` for settings Janus itself uses,
such as the __leader__ setting. You may also use `~/.gvimrc.after` and
`~/.vimrc.after` for any additional settings; it is also a good place for
overriding Janus settings as both files will be loaded at the end of
overriding Janus settings, as both files will be loaded at the end of
Janus.

For example, to override the default color schemes:
Expand Down Expand Up @@ -108,29 +117,29 @@ $ git submodule add https://github.com/vim-scripts/Rename2.git rename2

If you would like to disable an included plug-in, you can do that with
the `janus#disable_plugin()` function from inside your
`~/.vimrc.before`, this function takes a plug-in name as an argument
without the group, for example, if you would like to disable the
`~/.vimrc.before`. This function takes a plug-in name as an argument
without the group. For example, if you would like to disable the
NERDCommenter plug-in, you can do that with the command:

```bash
$ echo "call janus#disable_plugin('nerdcommenter')" >> ~/.vimrc.before
```

**WARNING**: We've noticed over and over, that people fork Janus just to
customize it, this is bad practice for several reasons and you should
not do that, here's why:
customize it. This is bad practice for several reasons and you should
not do that, and here's why:

- Janus is fully customisable and there's no need to change the core for
using a different plugin fork or using a different mapping.
- Forking means maintenance, maintenance means burden, do not burden
yourself with maintaining a fork, that's what the `~/.janus` folder
- Forking means maintenance; maintenance means burden. Do not burden
yourself with maintaining a fork; that's what the `~/.janus` folder
is for.

if you find yourself needing a customisation that is not possible with
the current setup, then please open an issue or submit a pull request to
make it possible to do so without having a fork.
If you find yourself needing a customisation that is not possible with
the current setup, then please open an issue or consider submitting a
pull request to make it possible to continue using/improving the official repo.

**WARNING**: Any **uncommited** file inside the **janus** folder will be
**WARNING**: Any **uncommited** files inside the **janus** folder will be
removed the next time you run `rake` so make sure to either put them in
the custom folder (`~/.janus`), or commit them. We clean the janus
folder in case we replace a manually installed plugin (using rake tasks)
Expand All @@ -140,25 +149,16 @@ For more information on how to customize Janus, you might want to take
a look at the [Customization wiki
page](https://github.com/carlhuda/janus/wiki/Customization).

## Updating to the latest version

To update to the latest version of the distribution, just run `rake`
again inside your `~/.vim` directory.

NOTE: If you even had an error updating Janus, problem related to a
missing commit in a submodule, please try running `rake` again before
submitting an issue.

# Intro to VIM

Here's some tips if you've never used VIM before:
Here're some tips in case you've never used VIM before:

## Tutorials

* Type `vimtutor` into a shell to go through a brief interactive
tutorial inside VIM.
* Read the slides at [VIM: Walking Without Crutches](http://walking-without-crutches.heroku.com/#1).
* Watch the screen-casts at [vimcasts.org](http://vimcasts.org/)
* Watch the screencasts at [vimcasts.org](http://vimcasts.org/)
* Watch Derek Wyatt's energetic tutorial videos at [his site](http://www.derekwyatt.org/vim/vim-tutorial-videos/)
* Read wycats' perspective on learning Vim at
[Everyone who tried to convince me to use vim was wrong](http://yehudakatz.com/2010/07/29/everyone-who-tried-to-convince-me-to-use-vim-was-wrong/)
Expand All @@ -177,9 +177,9 @@ Here's some tips if you've never used VIM before:

* Use `:q` to exit vim
* Certain commands are prefixed with a `<Leader>` key, which maps to `\`
by default. Use `let mapleader = ","` to change this. If you want this
to be in effect for uses of <Leader> in your .vimrc, make sure to define
this in the `~/.vimrc.before`
by default. You can, for example, use `let mapleader = ","` to change this to a comma. If you want this
to be in effect for uses of `<Leader>` in the .vimrc file, make sure to define
this in `~/.vimrc.before`
* Keyboard [cheat sheet](http://walking-without-crutches.heroku.com/image/images/vi-vim-cheat-sheet.png).

# Features
Expand All @@ -192,7 +192,7 @@ Janus ships with a number of basic customizations for vim:

* Line numbers
* Ruler (line and column numbers)
* No wrap (turn off per-buffer via set :wrap)
* No wrap (turn off per-buffer via :set wrap)
* Soft 2-space tabs, and default hard tabs to 2 spaces
* Show tailing whitespace as `.`
* Make searching highlighted, incremental, and case insensitive unless a
Expand All @@ -204,49 +204,49 @@ Janus ships with a number of basic customizations for vim:
* Automatically resize splits when resizing the Vim window (GUI only)
* `<leader>ew` expands to `:e (directory of current file)/` (open in the
current buffer)
* `<leader>es` expands to `:sp (directory of current file)/` (open in an
* `<leader>es` expands to `:sp (directory of current file)/` (open in a
horizontal split)
* `<leader>ev` expands to `:vsp (directory of current file)/` (open in
an vertical split)
a vertical split)
* `<leader>et` expands to `:tabe (directory of current file)/` (open in
an new tab)
* `:w!!` expands to `%!sudo tee > /dev/null %` Write to the current file
a new tab)
* `:w!!` expands to `%!sudo tee > /dev/null %`. Write to the current file
using sudo (if you forgot to run it with sudo), it will prompt for
sudo password when writing.
* `<F4>` Toggles paste mode
* `<leader>fef` format the entire file
* `,.` (comma followed by a dot) opens the next buffer.
* `,m` (comma followed by m) opens the previous buffer.
* `;'` (semicolon followed by a single quote) switch to next tab.
* `;l` (semicolon followed by l) switch to previous tab.
* `<leader>u` Convert the entire word to uppercace.
* `<leader>l` Convert the entire word to lowercase.
* `<leader>U` Convert the first char of a word to uppercase.
* `<leader>L` Convert the first char of a word to lowercase.
* `<leader>cd` Change the path to the currently active buffer's file.
* `<leader>md` Make the directory of the currently active buffer's file
(for example when editing a new file for which the path does not
sudo password when writing
* `<F4>` toggles paste mode
* `<leader>fef` formats the entire file
* `,.` (comma followed by a dot) opens the next buffer
* `,m` (comma followed by m) opens the previous buffer
* `;'` (semicolon followed by a single quote) switches to next tab
* `;l` (semicolon followed by l) switches to previous tab
* `<leader>u` converts the entire word to uppercace
* `<leader>l` converts the entire word to lowercase
* `<leader>U` converts the first char of a word to uppercase
* `<leader>L` converts the first char of a word to lowercase
* `<leader>cd` changes the path to the active buffer's file
* `<leader>md` creates the directory of the active buffer's file
(For example, when editing a new file for which the path does not
exist.)
* `gw` Swap the current word with the one next to it.
* `<leader>ul` Underline the current line with `=`
* `<leader>tw` Toggle wrap
* `<leader>fc` Finds the next conflict marker (Tested with Git
conflicted files).
* `gw` swaps the current word with the following word
* `<leader>ul` underlines the current line with `=`
* `<leader>tw` toggles wrap
* `<leader>fc` finds the next conflict marker (tested with Git
conflicted files)
* Remap `<Down>` and `<Up>` to `gj` and `gk` (Wrapped text is not
considered a one-long-line of text.
* `<leader>hs` Toggle highlight search.
* `<leader>=` Adjust viewports to the same size (`<C-w>=`)
* `<A-[` (`<D-[` on MacVim) Shift current line or selected lines
rightwards.
* `<A-]` (`<D-]` on MacVim) Shift current line or selected lines
leftwards.
* `<C-W>!` Invokes kwbd plugin, it closes all open buffers in the open
windows but keeps the windows open.
considered a single long line of text.)
* `<leader>hs` toggles highlight search
* `<leader>=` adjusts viewports to the same size (`<C-w>=`)
* `<A-[` (`<D-[` on MacVim) shifts current line or selected lines
rightwards
* `<A-]` (`<D-]` on MacVim) shifts current line or selected lines
leftwards
* `<C-W>!` invokes kwbd plugin; it closes all open buffers in the open
windows but keeps the windows open

## [Ack.vim](http://github.com/mileszs/ack.vim)

Ack.vim uses ack to search inside the current directory for a pattern.
You can learn more about it with :help Ack
You can learn more about it with :help Ack.

**Customizations**: Janus rebinds command-shift-f (`<D-F>`) to bring up
`:Ack `.
Expand Down

0 comments on commit cb8f832

Please sign in to comment.