This repository has been archived on 2024-10-22. You can view files and clone it, but cannot push or open issues or pull requests.
spacemacs/layers/+chat/slack
syl20bnr 703f78c2b8 Cleanup pass on file spacemacs-base/funcs.el
- Apply `/` and `//` rules (double / is for private functions)
- Add missing `spacemacs/` prefixes
- Move functions used outside of spacemacs-base layer to
  core/core-funcs.el
- Remove unused functions

Commit originally intented to only rename linum-update-window-scale-fix
to spacemacs/linum-update-window-scale-fix :-)
2016-10-09 13:14:41 -04:00
..
img
packages.el Cleanup pass on file spacemacs-base/funcs.el 2016-10-09 13:14:41 -04:00
README.org

Slack layer

/TakeV/spacemacs/media/commit/e1f128b269d623df1c43e4e9d30b4a5c3bb31943/layers/+chat/slack/img/slack.png

Description

This layer provides an interface to the Slack chat service via the emacs-slack package. Where possible, this layer aims to reuse keybindings from the IRC packages in Spacemacs.

Install

To use this configuration layer, add it to your ~/.spacemacs. You will need to add slack to the existing dotspacemacs-configuration-layers list in this file.

Configuration

Follow the instructions in the emacs-slack package for obtaining your client ID, client secret, and token.

To test that eveyrthing is alright put the following snippet in your dotspacemacs/user-config() replacing client-id, client-secret and token with your info.

Important Do not keep private data in your dotfile. You can put your private stuff elsewhere (like Dropbox for instance) and load the file in your dotfile.

(slack-register-team
  :name "emacs-slack"
  :default t
  :client-id "my@email.address"
  :client-secret "mypassword"
  :token "token"
  :subscribed-channels '(general slackbot))

Key bindings

Key Binding Description
SPC a C s (Re)connects to Slack
SPC a C j Join a channel
SPC a C d Direct message someone
SPC a C q Close connection
SPC m j Join a channel
SPC m d Direct message someone
SPC m p Load previous messages
SPC m e Edit message at point
SPC m q Quit Slack
SPC m m Embed mention of user
SPC m c Embed mention of channel

The following bindings are provided to mimic bindings in the official Slack client.

Key Binding Description
<SPC> m k Join a channel
<SPC> m @ Embed mention of user
<SPC> m # Embed mention of channel

In insert state, one can also use @ and # directly without the leader key prefix.