<commit_before># lita-slack

**lita-slack** is an adapter for [Lita](https://github.com/jimmycuadra/lita) that allows you to use the robot with [Slack](https://slack.com/). As **lita-slack** is one way, robot messages to Slack, it depends on [lita-slack-handler](https://github.com/kenjij/lita-slack-handler) gem to receive messages from Slack.

## Installation

Add **lita-slack** and **lita-slack-handler** to your Lita instance's Gemfile:

``` ruby
gem "lita-slack"
gem "lita-slack-handler"
```

## Configuration

**First, you need to make sure your Slack team has [Incoming WebHooks](https://my.slack.com/services/new/incoming-webhook) integration setup. For configuration regarding lita-slack-handler, see its [README](https://github.com/kenjij/lita-slack-handler).**

Then, define the following attributes:

### Required attributes

* `incoming_token` (String) – Slack integration token.
* `team_domain` (String) – Slack team domain; subdomain of slack.com.

### Optional attributes

* `incoming_url` (String) – Default: https://<team_domain>.slack.com/services/hooks/incoming-webhook
* `username` (String) – Display name of the robot; default: whatever is set in Slack integration
* `add_mention` (Bool) – Always prefix message with mention of the user which it's directed to; this triggers a notification.

### Example lita_config.rb

``` ruby
Lita.configure do |config|
  config.robot.name = "Lita"
  config.robot.mention_name = "@lita"
  # Select the Slack adapter
  config.robot.adapter = :slack
  # lita-slack adapter config
  config.adapter.incoming_token = "aN1NvAlIdDuMmYt0k3n"
  config.adapter.team_domain = "example"
  config.adapter.username = "lita"
  # Some more handlers and other config
  # .....
end
```

## License

[MIT](http://opensource.org/licenses/MIT)<commit_msg>Use new config format in README example.<commit_after># lita-slack

**lita-slack** is an adapter for [Lita](https://github.com/jimmycuadra/lita) that allows you to use the robot with [Slack](https://slack.com/). As **lita-slack** is one way, robot messages to Slack, it depends on [lita-slack-handler](https://github.com/kenjij/lita-slack-handler) gem to receive messages from Slack.

## Installation

Add **lita-slack** and **lita-slack-handler** to your Lita instance's Gemfile:

``` ruby
gem "lita-slack"
gem "lita-slack-handler"
```

## Configuration

**First, you need to make sure your Slack team has [Incoming WebHooks](https://my.slack.com/services/new/incoming-webhook) integration setup. For configuration regarding lita-slack-handler, see its [README](https://github.com/kenjij/lita-slack-handler).**

Then, define the following attributes:

### Required attributes

* `incoming_token` (String) – Slack integration token.
* `team_domain` (String) – Slack team domain; subdomain of slack.com.

### Optional attributes

* `incoming_url` (String) – Default: https://<team_domain>.slack.com/services/hooks/incoming-webhook
* `username` (String) – Display name of the robot; default: whatever is set in Slack integration
* `add_mention` (Bool) – Always prefix message with mention of the user which it's directed to; this triggers a notification.

### Example lita_config.rb

``` ruby
Lita.configure do |config|
  config.robot.name = "Lita"
  config.robot.mention_name = "@lita"
  # Select the Slack adapter
  config.robot.adapter = :slack
  # lita-slack adapter config
  config.adapters.slack.incoming_token = "aN1NvAlIdDuMmYt<PASSWORD>"
  config.adapters.slack.team_domain = "example"
  config.adapters.slack.username = "lita"
  # Some more handlers and other config
  # .....
end
```

## License

[MIT](http://opensource.org/licenses/MIT)
{'fraction_non_alphanumeric': 0.13406593406593406, 'fraction_numerical': 0.001098901098901099, 'mean_word_length': 4.6801872074882995, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 12, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3447508', 'n_tokens_mistral': 1228, 'n_tokens_neox': 1201, 'n_words': 345}