Skip to content

Commit

Permalink
Readme updated. Added animation and git ignore
Browse files Browse the repository at this point in the history
  • Loading branch information
durgaswaroop committed Jul 26, 2016
1 parent 0dc6d6c commit af8f85e
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 6 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
README.html
Binary file added Animation.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
34 changes: 28 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,36 @@
Vim Plugin for MPC Player

[MPC](https://www.musicpd.org/clients/mpc/) is an Open source media player that works with [MPD Daemon](https://www.musicpd.org/). This plugin allows you to easily interact with that daemon.
Vim and music is a great combination. Listening to your favorite MJ song while coding makes you a *Bad* ass programmer. But to change a song, Pause/Play it, you have to leave Vim and open the media player. Being able to control your media player from Vim makes you a *Badder* ass.

This is how it looks when you open the Playlist Window
Let Vim-mpc take care of that while you code listening to Thriller.

This is how the Playlist window looks like.

![vim-mpc playlist image](https://github.com/durgaswaroop/vim-mpc/blob/master/PlaylistWindow.PNG)

Let's see a Demo. Shall We ?

![vim-mpc demo image](https://github.com/durgaswaroop/vim-mpc/blob/master/Animation.gif)

Now that's smooth. Smooth like a Criminal!

## Installing
Install it using any Plugin manager of your choice. If you don't have a preference, I recommend [Pathogen](https://github.com/tpope/vim-pathogen) by Tim Pope.

To install using Pathogen,

```bash
cd ~/.vim/bundle # For linux

# vimfiles/bundle in Windows

git clone https://github.com/durgaswaroop/vim-mpc.git
```

## Built-in commands for various actions.
Once installed, you can use the following commands

* `:MpcBrowser` - Opens the playlist in a split window with Colors for Artist and Title

* `:TogglePlayback` - Play/Stop the track
Expand All @@ -17,7 +41,6 @@ This is how it looks when you open the Playlist Window
* `:ToggleRepeat` - Repeat On or Off

## Default Keymaps

* `<Leader>p` - Mapped to `:MpcBrowse`. So, you can use that.

* `Ctrl + x` - Plays the selected song in the Playlist window
Expand All @@ -27,14 +50,13 @@ This is how it looks when you open the Playlist Window
* `Ctrl + e` - Repeat On or Off in the Playlist Window

## Customizing

You can map your own key to get the playlist window as follows

To map it to `Ctrl + p`, add this to your vimrc file

`nnoremap <C-p> <plug>MpcBrowse`
```
nnoremap <C-p> <plug>MpcBrowse
```

## Attribution

This plugin is possible because of the book [VimL Primer](https://pragprog.com/book/bkviml/the-viml-primer) from **The Pragmatic Bookshelf**. Its a must read for anyone looking to learn Vim scripting.

0 comments on commit af8f85e

Please sign in to comment.