soulheart 0.0.4 → 0.0.5

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: b170565afcbbfc53d9ab5f0a46713af88803a3a4
4
- data.tar.gz: 58445b7ecdf5713487ba1af3539ad06137a04877
3
+ metadata.gz: cd989a4107aacd141e1ecbcdcab17c4565237768
4
+ data.tar.gz: eadaae2aad79d613be888a6cd39fe130071c8b00
5
5
  SHA512:
6
- metadata.gz: 169f0de49bcd01b4ec5b2182f0075e220ea25b0059f16bffb9347567a1012d2925c6efef9a35b212825ba6989a97e60f18970b47f8d5df2e9bed2ea6dedf7fb6
7
- data.tar.gz: b5b5de55c31b6cd03be318f05c08780302b3e1eee20b124e4eda1b737ffba4eee526b051d6969643ee7709b9f90123c485b21f9efdcdf2c9677c6fe0e66201be
6
+ metadata.gz: 8f476069f2c8ff7491142570abc525ca25d0ad9870ac22398b6ee1fa6c55653b828ae6f3cc2bc427ea32103fbd8cd4a3649483aefebdf31cdf3a0e4fad4714b1
7
+ data.tar.gz: a4a3682db05d5227469b5291399be897cb006ebed4654aae8a305f2c84eb388afce580974fbe4d6578cac17ce0521300921e1f6d76001df0b8c84e645a66fb12
data/README.md CHANGED
@@ -1,21 +1,21 @@
1
1
  # <img src="https://raw.githubusercontent.com/sethherr/soulheart/master/logo.png" alt="Soulheart" width="200"> Soulheart [![Build Status](https://travis-ci.org/sethherr/soulheart.svg)](https://travis-ci.org/sethherr/soulheart) [![Code Climate](https://codeclimate.com/github/sethherr/soulheart/badges/gpa.svg)](https://codeclimate.com/github/sethherr/soulheart) [![Test Coverage](https://codeclimate.com/github/sethherr/soulheart/badges/coverage.svg)](https://codeclimate.com/github/sethherr/soulheart/coverage)
2
2
 
3
-
4
- **Soulheart is a ready to use remote data source for autocomplete**. It supports:
3
+ **Soulheart is a ready-to-use remote data source for autocomplete**. It supports:
5
4
 
6
5
  - pagination
7
6
  - categories
8
7
  - sorting by priority (not just alphabetically)
9
- - arbitrary returns
10
- - loading data via gists
8
+ - arbitrary return values/objects
9
+ - loading data via gists (or any url)
11
10
  - mounting standalone or inside of a rails app
12
11
 
13
12
  ... and is [instantly deployable to heroku](https://heroku.com/deploy) (for free).
14
13
 
15
- To get started, check out examples and documentation at [sethherr.github.io/soulheart](https://sethherr.github.io/soulheart).
14
+ To get started, check out examples and documentation at [sethherr.github.io/soulheart/](https://sethherr.github.io/soulheart/).
16
15
 
16
+ ----
17
17
 
18
- ---
18
+ Soulheart is in Beta. It's probably appropriate to use in production... but maybe wait? There are a few more changes coming, and some documentation improvements to be made.
19
19
 
20
20
  ### Adding data
21
21
 
@@ -66,10 +66,8 @@ module Soulheart
66
66
  unless cleaned
67
67
  item = clean(item)
68
68
  category_base_id ||= category_id(item['category'])
69
- item.keys.select{ |k| k[/data-/i] }.each do |key|
70
- item['data'].merge!({
71
- "#{key.gsub(/data-/i,'')}" => item.delete(key)
72
- })
69
+ item.keys.select{ |k| !%w(category priority term aliases data).include?(k) }.each do |key|
70
+ item['data'].merge!({"#{key}" => item.delete(key)})
73
71
  end
74
72
  unless redis.smembers(categories_id).include?(item['category'])
75
73
  redis.sadd categories_id, item['category']
@@ -1,3 +1,3 @@
1
1
  module Soulheart
2
- VERSION = '0.0.4'
2
+ VERSION = '0.0.5'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: soulheart
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Seth Herr
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-06-23 00:00:00.000000000 Z
11
+ date: 2015-06-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: hiredis