Open slack, like a file
- vim-plug
Plug 'yaasita/edit-slack.vim'
- NeoBundle
NeoBundle 'yaasita/edit-slack.vim'
- Vundle
Plugin 'yaasita/edit-slack.vim'
- Vim packages (since Vim 7.4.1528)
git clone https://github.com/yaasita/edit-slack.vim ~/.vim/pack/plugins/start/edit-slack.vim
2. download edit-slack binary
- Linux
- FreeBSD
- Windows
- macOS
Save binary under edit-slack.vim directory.
Rename the file name to edit-slack (windows user is edit-slack.exe)
example. Linux(64bit) User
cd /path/to/install/directory/edit-slack.vim
curl -L -O https://github.com/yaasita/edit-slack/releases/download/v0.8.2/linux-amd64-edit-slack
mv linux-amd64-edit-slack edit-slack # windows user is edit-slack.exe
chmod +x edit-slack
Get token from slack API page.
Add the token to vimrc.
let g:yaasita_slack_token = "xoxp-xxxxxxxxxx-xxxxxxxxxx-xxxxxxxxxx-xxxxxx"
When displaying Unicode characters
set fileencodings+=utf-8
set encoding=utf-8
# open channels/private group/users list
vim slack://ch
vim slack://pg
vim slack://dm
# gf command opens a chat under the cursor
# open general channel
vim slack://ch/general
# in the vim
:e slack://ch
:tabe slack://dm/hogeuser
# reload
:e
# post
# write it under the "=== Message ===" mark
:w
# search word
vim slack://sw/hoge
vim slack://sw/from:@yamasita_on:today # replace space with _
(c) gopher stickers