autoreply 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b10664ddf4e1e2a762b3c7d8e196954ace9cee32
4
- data.tar.gz: f8d0f36c3eac43af8d8cefbcb7222e734a6a1b03
3
+ metadata.gz: 7f4917525d02255f51f6043a4f6acbcf1d2a1deb
4
+ data.tar.gz: 20292760e5fcc0478b1b307a3fecdace370f2179
5
5
  SHA512:
6
- metadata.gz: fcf8cc47805ada0a4bc8c1eb1c9c3ba0f1b14aaf13dee2c716b0137be607d44df514eb28dc8c2e45797b6549a9b380a6048615bc299b299e2960818fb0f3138c
7
- data.tar.gz: cf12079fc5681687c355c6094f587bf7c8bef91d3f96f24b292861c697d46f2059bde190a8dceb11ac8268bd04b4994d3ffb7a25fcd3a0431abb071b9eac57c0
6
+ metadata.gz: bf826f01fbbe0e95ec2714e8babbfdfe1c412c37c0f4e4bcfa2a50f5411b09ccb740df6b5998dd516fb5f0d812b713f9d3b51b5c95e45f9526ffd2566f26c890
7
+ data.tar.gz: 20de3a2f7e3ee564c1d0de85f8cbc67835b8dfc92751b1efc41c3dabf0cc2603ebded14a29214df633870808930bec97fc90969ca9c4a18c7a9e1be5df319023
data/.travis.yml CHANGED
@@ -3,3 +3,6 @@ rvm:
3
3
  - 2.1.3
4
4
  - 2.2.2
5
5
  before_install: gem install bundler -v 1.10.5
6
+ addons:
7
+ code_climate:
8
+ repo_token: bb203d8a7d6115657017e747ff3b00ab7ef1bb99916d08f3aab831c7d160c6d9
data/Gemfile CHANGED
@@ -1,4 +1,6 @@
1
- source 'https://rubygems.org'
1
+ source "https://rubygems.org"
2
+
3
+ gem "codeclimate-test-reporter", group: :test, require: nil
2
4
 
3
5
  # Specify your gem's dependencies in autoreply.gemspec
4
6
  gemspec
data/README.md CHANGED
@@ -1,6 +1,12 @@
1
1
  # autoreply
2
2
  Detect if email is autoresponder or "out-of-office" email
3
3
 
4
+ [![Gem Version](https://badge.fury.io/rb/autoreply.svg)](http://badge.fury.io/rb/autoreply)
5
+ [![Build Status](https://travis-ci.org/edufii/autoreply.svg?branch=master)](https://travis-ci.org/edufii/autoreply)
6
+ [![Code Climate](https://codeclimate.com/github/edufii/autoreply/badges/gpa.svg)](https://codeclimate.com/github/edufii/autoreply)
7
+ [![Test Coverage](https://codeclimate.com/github/edufii/autoreply/badges/coverage.svg)](https://codeclimate.com/github/edufii/autoreply/coverage)
8
+ [![Dependency Status](https://gemnasium.com/edufii/autoreply.svg)](https://gemnasium.com/edufii/autoreply)
9
+
4
10
  # Usage
5
11
 
6
12
  `Autoreply.autoreply?(mail)`
@@ -19,7 +19,13 @@ module Autoreply
19
19
  )
20
20
 
21
21
  def autoreply?
22
- !(KNOWN_HEADERS & header_fields.map(&:name).map(&:downcase)).blank?
22
+ !(KNOWN_HEADERS & detected_headers).blank?
23
23
  end
24
+
25
+ private
26
+
27
+ def detected_headers
28
+ header_fields.map(&:name).map(&:downcase)
29
+ end
24
30
  end
25
31
  end
@@ -4,8 +4,8 @@ module Autoreply
4
4
  "x-spam-flag" => /yes/,
5
5
  "x-spam-status" => /yes/,
6
6
  "x-spam-flag2" => /yes/,
7
- "precedence" => /(bulk|list|junk)/,
8
- "x-precedence" => /(bulk|list|junk)/,
7
+ "precedence" => /(bulk|list|junk|auto_reply)/,
8
+ "x-precedence" => /(bulk|list|junk|auto_reply)/,
9
9
  "x-barracuda-spam-status" => /yes/,
10
10
  "x-dspam-result" => /(spam|bl[ao]cklisted)/,
11
11
  "x-mailer" => /^[mM]ail$/,
@@ -1,3 +1,3 @@
1
1
  module Autoreply
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: autoreply
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sergey Kishenin
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2015-08-20 00:00:00.000000000 Z
12
+ date: 2015-09-08 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler