device_detector 0.4.0 → 0.5.0

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: f73cba454031ad8e9b62806a487cf3fe52bc50a2
4
- data.tar.gz: 677525ac1133c59eb2a7900faf31077546787e45
3
+ metadata.gz: 5cebfa5ab895685c658cb212632694961983b77a
4
+ data.tar.gz: 96f37aaa81a00446b3f74ce13dbc2983469c47a3
5
5
  SHA512:
6
- metadata.gz: a196b3ad6f3da4dcf8eb447fb721fc1671870fb1fcd3fc7cf2326917896079777f4188b19ae2fe84433a050567bab5ff8917418112329021822f6490482b0f0d
7
- data.tar.gz: 4f823b5ab1ce904da8202d12225c09db755d82876c06baaffb2371d838e9779440bedb67e98e03bb76be9f544942490463c95adeb04eb0210003e755165bf652
6
+ metadata.gz: 375d2e3f948dc4d94b03bf0a8222770da2c501af96eeebf772b59019d0f24398eca51656e7e7d47b7abb2beaf6186d96f403a273c62207a8204e4973bf758997
7
+ data.tar.gz: 1b9ac09cf40a683eaf5f15c7a50098b88747f3208c0efbb0a550783bd634c25b6e85a3e4513ddef98d12cc0e6ced63bb446f7fdcbff0fdd805d93f0f67c1b123
data/.travis.yml ADDED
@@ -0,0 +1,11 @@
1
+ language: ruby
2
+ rvm:
3
+ - 1.9.3
4
+ - 2.0.0-p598
5
+ - 2.1.0
6
+ - 2.2.0
7
+ - ruby-head
8
+ - jruby-head
9
+ - rbx-2
10
+ script:
11
+ bundle exec rspec
data/README.md CHANGED
@@ -1,20 +1,21 @@
1
1
  # DeviceDetector
2
2
 
3
- This is a Ruby port of the Universal Device Detection library.
4
- You can find the original code here: [https://github.com/piwik/device-detector].
3
+ ![Podigee DeviceDetector Travisci Badge](https://travis-ci.org/podigee/device_detector.svg)
5
4
 
6
- The Universal Device Detection library will parse any User Agent and detect
7
- the browser, operating system, device used (desktop, tablet, mobile, tv, cars,
8
- console, etc.), brand and model.
5
+ User agent parser and device detector backed by the largest, most precise and up-to-date agent and device database.
6
+
7
+ DeviceDetector will parse any user agent and detect the browser, operating system, device used (desktop, tablet, mobile, tv, cars, console, etc.), brand and model.
8
+
9
+ The DeviceDetector is optimized for speed of detection, by providing optimized code and in-memory caching.
10
+
11
+ This project originated as a Ruby port of the Universal Device Detection library.
12
+ You can find the original code here: https://github.com/piwik/device-detector.
9
13
 
10
14
  ## Disclaimer
11
15
 
12
- This port does not aspire to be a one-to-one copy from the original code, but
13
- rather an adaptation for the Ruby language.
16
+ This port does not aspire to be a one-to-one copy from the original code, but rather an adaptation for the Ruby language.
14
17
 
15
- Still, our goal is to use the original, unchanged regex yaml files, in order to
16
- mutually benefit from updates and pull request to both the original and the
17
- ported versions.
18
+ Still, our goal is to use the original, unchanged regex yaml files, in order to mutually benefit from updates and pull request to both the original and the ported versions.
18
19
 
19
20
  ## Installation
20
21
 
@@ -35,19 +36,19 @@ Or install it yourself as:
35
36
  ## Usage
36
37
 
37
38
  ```ruby
38
- user_agent = 'foo'
39
+ user_agent = 'Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.17 Safari/537.36'
39
40
  client = DeviceDetector.new(user_agent)
40
41
 
41
42
  client.name # => 'Chrome'
42
43
  client.full_version # => '30.0.1599.69'
43
44
 
44
- client.os_name # => 'Mac'
45
- client.os_full_version # => '10_8_5'
45
+ client.os_name # => 'Windows'
46
+ client.os_full_version # => '8'
46
47
 
47
48
  # For many devices, you can also query the device name (usually the model name)
48
49
  # Look into regexes/devices/mobiles.yml to see what devices can be detected
49
50
  client.device_name # => 'iPhone 5'
50
- client.device_type # => 'smartphone'
51
+ client.device_type # => 'smartphone' # device types can be one of `smartphone`, `tablet`, `console`, `portable media player`, `tv`, `car browser` or `camera`
51
52
  ```
52
53
 
53
54
  `DeviceDetector` will return `nil` on all attributes, if the `user_agent` is unknown.
@@ -65,10 +66,26 @@ You can tune the amount of keys that will get saved in the cache:
65
66
  ```ruby
66
67
  # You have to call this code **before** you initialize the Detector
67
68
  DeviceDetector.configure do |config|
68
- config.max_cache_keys = 20_000 # if you have enough RAM, proceed with care
69
+ config.max_cache_keys = 20_000 # increment this if you have enough RAM, proceed with care
69
70
  end
70
71
  ```
71
72
 
73
+ ## Detectable clients, bots and devices
74
+
75
+ Updated on 2015-03-17
76
+
77
+ ### Bots
78
+
79
+ 360Spider, Aboundexbot, Acoon, AddThis.com, aHrefs Bot, Alexa Crawler, Amorank Spider, Analytics SEO Crawler, archive.org bot, Ask Jeeves, Backlink-Ceck.de, BacklinkCrawler, Baidu Spider, BingBot, Blekkobot, BLEXBot Crawler, Bloglovin, Bountii Bot, Browsershots, Butterfly Robot, CareerBot, ccBot crawler, Cliqzbot, CloudFlare Always Online, CommaFeed, Dazoobot, Discobot, DotBot, Easou Spider, EMail Exractor, ExaBot, ExactSeek Crawler, Ezooms, Facebook External Hit, Feedbin, FeedBurner, Feedly, Feedspot, Fever, Genieo Web filter, Goo, Google PageSpeed Insights, Googlebot, Heritrix, HTTPMon, IIS Site Analysis, Kouio, Linkdex Bot, LinkedIn Bot, Mail.Ru Bot, Magpie-Crawler, MagpieRSS, Meanpath Bot, Mixrank Bot, MJ12 Bot, MojeekBot, NalezenCzBot, Netcraft Survey Bot, Netvibes, NewsBlur, NewsGator, NLCrawler, Omgili bot, Openindex Spider, OpenLinkProfiler, OpenWebSpider, PaperLiBot, Picsearch bot, Pingdom Bot, QuerySeekerSpider, Reddit Bot, Rogerbot, Screaming Frog SEO Spider, ScreenerBot, Semrush Bot, Sensika Bot, SEOENGBot, Seznam Bot, ShopWiki, SilverReader, SimplePie, SISTRIX Crawler, Sogou Spider, Soso Spider, Superfeedr Bot, Spinn3r, Sputnik Bot, Survey Bot, TinEye Crawler, Tiny Tiny RSS, TurnitinBot, TweetedTimes Bot, Tweetmeme Bot, Twitterbot, Uptime Robot, URLAppendBot, Visual Site Mapper Crawler, Voila Bot, W3C CSS Validator, W3C I18N Checker, W3C Link Checker, W3C Markup Validation Service, W3C MobileOK Checker, W3C Unified Validator, WeSEE:Search, WebbCrawler, Wotbox, YaCy, Yahoo! Slurp, Yandex Bot, Yeti/Naverbot, Youdao Bot, Yunyun Bot, Zookabot, ZumBot, Yottaa Site Monitor, Lycos, Inktomi Slurp, Speedy, ScoutJet, NetResearchServer, Scooter, Gigabot, Charlotte, Pompos, ichiro, PagePeeker, WebThumbnail, Willow Internet Crawler, EmailWolf, NetLyzer FastProbe, Bot, Nutch-based Bot, Generic Bot
80
+
81
+ ### Clients
82
+
83
+ Internet Explorer, Sailfish Browser, Camino, Fennec, MicroB, Avant Browser, Amigo, Bunjalloo, Iceweasel, WebPositive, Pale Moon, CometBird, IceDragon, Flock, Kapiko, Swiftfox, Firefox, ANTGalio, Espial TV Browser, RockMelt, Fireweb Navigator, Netscape, Opera Mobile, Opera Mini, Opera Next, Opera, Rekonq, CoolNovo, Comodo Dragon, ChromePlus, Conkeror, Konqueror, Baidu Browser, Baidu Spark, Yandex Browser, Vivaldi, Midori, Mercury, Maxthon, Puffin, Iron, Epiphany, Liebao, Sogou Explorer, QQ Browser, Chrome Mobile, Chrome Mobile iOS, Chrome Frame, Chromium, Chrome, UC Browser, Tizen Browser, Palm Blazer, Palm Pre, wOSBrowser, Palm WebPro, Jasmine, Lynx, NCSA Mosaic, ABrowse, Amaya, Amiga Voyager, Amiga Aweb, Arora, Beonex, BlackBerry Browser, BrowseX, Charon, Cheshire, Dillo, Dolphin, Elinks, Firebird, Fluid, Galeon, Google Earth, HotJava, IBrowse, iCab, Sleipnir, Lunascape, IE Mobile, Kazehakase, Kindle Browser, K-meleon, Links, Openwave Mobile Browser, OmniWeb, Phoenix, Mobile Silk, MIUI Browser, Nokia Browser, Nokia OSS Browser, Nokia Ovi Browser, NetFront Life, NetFront, NetPositive, Obigo, Off By One, Oregano, Polaris, SEMC-Browser, Shiira, Snowshoe, Sunrise, WeTab Browser, Xiino, Android Browser, Mobile Safari, Safari, Akregator, Apple PubSub, FeedDemon, Feeddler RSS Reader, JetBrains Omea Reader, Liferea, NetNewsWire, NewsBlur Mobile App, NewsBlur, Newsbeuter, Pulp, ReadKit, Reeder, RSS Bandit, RSS Junkie, RSSOwl, Wget, curl, Python Requests, Python urllib, Java, Perl, Banshee, Clementine, iTunes, FlyCast, MediaMonkey, Miro, NexPlayer, Nightingale, QuickTime, Songbird, SubStream, VLC, Winamp, Windows Media Player, XBMC, Stagefright, AndroidDownloadManager, FeedR, WeChat, Sina Weibo, Outlook Express, Microsoft Outlook, Thunderbird, Airmail, Lotus Notes, Barca, Postbox, The Bat!
84
+
85
+ ### Devices
86
+
87
+ 3Q, Acer, Airness, Alcatel, Amoi, Apple, Archos, Arnova, Asus, Audiovox, Avvio, Axxion, BBK, BangOlufsen, Barnes & Noble, Becker, Beetel, BenQ, BenQ-Siemens, Bird, Blu, Bmobile, Capitel, Cat, Celkon, Cherry Mobile, CnM, Coby Kyros, Compal, ConCorde, Coolpad, Cowon, CreNova, Cricket, Crius Mea, Cube, DMM, Danew, Dbtel, Dell, Denver, Dicam, DoCoMo, Doogee, Dopod, E-Boda, Easypix, Ericsson, Ericy, Evertek, Ezio, Ezze, Fly, Gemini, Gigabyte, Gigaset, Gionee, Google, Gradiente, Grundig, HP, HTC, Haier, Hisense, Huawei, Humax, INQ, Ikea, Infinix, Inkti, Innostream, Intek, Intex, Inverto, Jiayu, Jolla, K-Touch, KDDI, KT-Tech, Karbonn, Kazam, Kindle, Konka, Kyocera, LCT, LG, Lanix, Lava, Lenco, Lenovo, Lexibook, Loewe, Logicom, MEU, Manta Multimedia, MediaTek, Medion, Memup, Metz, MicroMax, Microsoft, Mio, Mitsubishi, Mobistel, Motorola, Mpman, MyPhone, NEC, NGM, Newgen, Nexian, Nikon, Nintendo, Nokia, O2, OPPO, OUYA, Onda, Opsson, Orange, Oysters, PEAQ, Palm, Panasonic, Pantech, Philips, Polaroid, PolyPad, Positivo, Prestigio, Qilive, Qtek, Quechua, RIM, Ramos, Rikomagic, Rover, SFR, Sagem, Samsung, Sanyo, Sega, Selevision, Sendo, Sharp, Siemens, Smart, Smartfren, Softbank, Sony, Spice, Storex, Sumvision, SuperSonic, Symphony, T-Mobile, TCL, TIANYU, TVC, TechniSat, TechnoTrend, Tecno Mobile, Telefunken, Telit, Tesla, Thomson, TiPhone, Tolino, Toplux, Toshiba, Tunisie Telecom, UTStarcom, VK Mobile, Vertu, Vestel, Videocon, Videoweb, ViewSonic, Vitelcom, Voxtel, Web TV, WellcoM, Wiko, Wolder, Wonu, Woxter, Xiaomi, Yuandao, ZTE, Zonda, Zopo, bq, eTouch, i-mate, i-mobile, iBall, iBerry, iKoMo, iTel, phoneOne, teXet
88
+
72
89
  ## Maintainers
73
90
 
74
91
  - Mati Sojka: https://github.com/yagooar
@@ -82,8 +99,10 @@ Thanks a lot to the following contributors:
82
99
 
83
100
  ## Contributing
84
101
 
85
- 1. Fork it ( https://github.com/podigee/device_detector/fork )
86
- 2. Create your feature branch (`git checkout -b my-new-feature`)
87
- 3. Commit your changes (`git commit -am 'Add some feature'`)
88
- 4. Push to the branch (`git push origin my-new-feature`)
89
- 5. Create a new Pull Request (compare with develop)
102
+ 1. Open an issue and explain your feature request or bug before writing any code (this can save a lot of time, both the contributor and the maintainers!)
103
+ 2. Fork the project (https://github.com/podigee/device_detector/fork)
104
+ 3. Create your feature branch (`git checkout -b my-new-feature`)
105
+ 4. Commit your changes (`git commit -am 'Add some feature'`)
106
+ 5. Push to the branch (`git push origin my-new-feature`)
107
+ 6. Create a new Pull Request (compare with develop)
108
+ 7. When adding new data to the yaml files, please make sure to open a PR in the original project, as well (https://github.com/piwik/device-detector)
data/Rakefile CHANGED
@@ -9,3 +9,33 @@ end
9
9
 
10
10
  task default: :spec
11
11
 
12
+ task :detectable_names do
13
+ require 'device_detector'
14
+ bot_names = DeviceDetector::Bot.new.send(:regexes).map { |r| r['name'] }.uniq
15
+ bot_names.delete('$1')
16
+ client_names = DeviceDetector::Client.new.send(:regexes).map { |r| r['name'] }.uniq
17
+ client_names.delete('$1')
18
+ device_filepaths = DeviceDetector::Device.new.send(:filepaths)
19
+ device_regexes = DeviceDetector::Device.load_regexes(device_filepaths)
20
+ device_names = device_regexes.flat_map { |dn| dn.keys }.sort.uniq
21
+
22
+ today = Date.today.strftime
23
+
24
+ puts '## Detectable clients, bots and devices'
25
+ puts
26
+ puts "Updated on #{today}"
27
+ puts
28
+ puts '### Bots'
29
+ puts
30
+ puts bot_names.join(', ')
31
+ puts
32
+ puts '### Clients'
33
+ puts
34
+ puts client_names.join(', ')
35
+ puts
36
+ puts '### Devices'
37
+ puts
38
+ puts device_names.join(', ')
39
+ puts
40
+ end
41
+
@@ -8,8 +8,8 @@ Gem::Specification.new do |spec|
8
8
  spec.version = DeviceDetector::VERSION
9
9
  spec.authors = ['Mati Sójka', 'Ben Zimmer']
10
10
  spec.email = ['yagooar@gmail.com']
11
- spec.summary = %q{Universal Device Detection}
12
- spec.description = %q{The Universal Device Detection library will parse any User Agent and detect the browser, operating system, device, brand and model.}
11
+ spec.summary = %q{Precise and fast user agent parser and device detector}
12
+ spec.description = %q{Precise and fast user agent parser and device detector, backed by the largest and most up-to-date agent and device database}
13
13
  spec.homepage = 'https://github.com/podigee/device_detector'
14
14
  spec.license = 'LGPLv3'
15
15
 
@@ -15,28 +15,42 @@ class DeviceDetector
15
15
 
16
16
  private
17
17
 
18
+ # The order of files is relevant.
19
+ # portable_media_players has to come before mobiles because of devices like the iPod
20
+ # which would otherwise be detected as iPhones
21
+ # televisions.yml works best at the end
18
22
  def filenames
19
23
  [
20
- 'devices/mobiles.yml'
24
+ 'devices/cameras.yml',
25
+ 'devices/car_browsers.yml',
26
+ 'devices/consoles.yml',
27
+ 'devices/portable_media_players.yml',
28
+ 'devices/mobiles.yml',
29
+ 'devices/televisions.yml',
21
30
  ]
22
31
  end
23
32
 
24
- def self.parse_regexes(regexes)
33
+ def self.parse_regexes(regexes, device = nil)
25
34
  regexes.map { |base, nest|
26
35
 
27
36
  if !nest.nil? && nest.key?('models')
28
- parse_regexes nest['models']
37
+ default_device = nest['device']
38
+ parse_regexes(nest['models'], default_device)
29
39
  else
30
- case base
31
- when Hash
32
- base['regex'] = Regexp.new base['regex']
33
- base
34
- when String
35
- nest['regex'] = Regexp.new nest['regex']
36
- nest
37
- else
38
- fail "#{filenames.join(', ')} regexes are either malformed or format has changes."
39
- end
40
+ regex =
41
+ case base
42
+ when Hash
43
+ base
44
+ when String
45
+ nest
46
+ else
47
+ fail "#{filenames.join(', ')} regexes are either malformed or format has changes."
48
+ end
49
+
50
+ regex['device'] ||= device
51
+ regex['regex'] = Regexp.new(regex['regex'])
52
+
53
+ regex
40
54
  end
41
55
 
42
56
  }.flatten
@@ -37,23 +37,34 @@ class DeviceDetector
37
37
  end
38
38
  end
39
39
 
40
- # This is a performance optimization.
41
- # We cache the regexes on the class for better performance
42
- # Thread-safety shouldn't be an issue, as we do only perform reads
43
- def self.regexes_for(filepaths)
44
- @regexes ||=
45
- begin
46
- raw_files = filepaths.map { |filepath| File.read(filepath) }.join
47
- regexes = YAML.load(raw_files)
48
- parse_regexes(regexes)
49
- end
50
- end
40
+ class << self
41
+
42
+ # This is a performance optimization.
43
+ # We cache the regexes on the class for better performance
44
+ # Thread-safety shouldn't be an issue, as we do only perform reads
45
+ def regexes_for(filepaths)
46
+ @regexes ||=
47
+ begin
48
+ regexes = load_regexes(filepaths)
49
+ parsed_regexes = regexes.map { |r| parse_regexes(r) }
50
+
51
+ parsed_regexes.flatten
52
+ end
53
+ end
51
54
 
52
- def self.parse_regexes(regexes)
53
- regexes.map do |meta|
54
- meta['regex'] = Regexp.new(meta['regex'])
55
- meta
55
+ def load_regexes(filepaths)
56
+ raw_files = filepaths.map { |path| File.read(path) }
57
+
58
+ raw_files.map { |f| YAML.load(f) }
56
59
  end
60
+
61
+ def parse_regexes(regexes)
62
+ regexes.map do |meta|
63
+ meta['regex'] = Regexp.new(meta['regex'])
64
+ meta
65
+ end
66
+ end
67
+
57
68
  end
58
69
 
59
70
  end
@@ -1,3 +1,3 @@
1
1
  class DeviceDetector
2
- VERSION = '0.4.0'
2
+ VERSION = '0.5.0'
3
3
  end
data/regexes/bots.yml CHANGED
@@ -977,10 +977,14 @@
977
977
  - regex: 'EmailWolf'
978
978
  name: 'EmailWolf'
979
979
 
980
+ - regex: 'NetLyzer FastProbe'
981
+ name: 'NetLyzer FastProbe'
982
+
980
983
 
981
984
  - regex: '(nuhk|TsolCrawler|Yammybot|Openbot|Gulper Web Bot|grub-client|Download Demon|SearchExpress|Microsoft URL Control|borg|altavista|teoma|blitzbot|oegp|furlbot|http%20client|polybot|htdig|mogimogi|larbin|scrubby|searchsight|seekbot|semanticdiscovery|snappy|vortex|zao|zeal|fast-webcrawler|converacrawler|dataparksearch|findlinks|BrowserMob|HttpMonitor|ThumbShotsBot|URL2PNG|ZooShot|GomezA|Catchpoint bot|Google SketchUp|Read%20Later|Minimo|RackspaceBot)'
982
985
  name: 'Bot'
983
986
 
987
+
984
988
  # Generic detections
985
989
 
986
990
  - regex: 'Nutch'
@@ -991,12 +995,5 @@
991
995
  name: 'The Apache Software Foundation'
992
996
  url: 'http://www.apache.org/foundation/'
993
997
 
994
- # Original:
995
- # - regex: '[a-z0-9-_]*(bot|crawler|archiver|transcoder|spider)'
996
- # name: 'Generic Bot'
997
- #
998
- # Adapted for Ruby:
999
- # Note the backslash added in [a-z0-9\-_], it is necessary to avoid
1000
- # warnings from the interpreter
1001
998
  - regex: '[a-z0-9\-_]*(bot|crawler|archiver|transcoder|spider)'
1002
999
  name: 'Generic Bot'
data/regexes/browsers.yml CHANGED
@@ -55,6 +55,15 @@
55
55
  engine:
56
56
  default: '' # multiple
57
57
 
58
+ #Amigo
59
+ - regex: 'Chrome/(\d+[\.\d]+).*MRCHROME'
60
+ name: 'Amigo'
61
+ version: '$1'
62
+ engine:
63
+ default: 'WebKit'
64
+ versions:
65
+ 28: 'Blink'
66
+
58
67
  #Bunjalloo
59
68
  - regex: 'Bunjalloo(?:/(\d+[\.\d]+))?'
60
69
  name: 'Bunjalloo'
@@ -258,6 +267,13 @@
258
267
  engine:
259
268
  default: 'Blink'
260
269
 
270
+ #Vivaldi
271
+ - regex: 'Vivaldi(?:/(\d+[\.\d]+))?'
272
+ name: 'Vivaldi'
273
+ version: '$1'
274
+ engine:
275
+ default: 'Blink'
276
+
261
277
  #Midori
262
278
  - regex: 'Midori(?:/(\d+[\.\d]+))?'
263
279
  name: 'Midori'
@@ -319,6 +335,11 @@
319
335
  name: 'Sogou Explorer'
320
336
  version: '$1'
321
337
 
338
+ # QQ Browser
339
+ - regex: 'QQBrowser/([\.\d]+)'
340
+ name: 'QQ Browser'
341
+ version: '$1'
342
+
322
343
  #Chrome
323
344
  - regex: 'CrMo(?:/(\d+[\.\d]+))?'
324
345
  name: 'Chrome Mobile'
@@ -685,6 +706,11 @@
685
706
  name: 'Obigo'
686
707
  version: ''
687
708
 
709
+ #Off By One
710
+ - regex: 'OffByOne'
711
+ name: 'Off By One'
712
+ version: ''
713
+
688
714
  #Oregano
689
715
  - regex: 'Oregano(?:[ /](\d+[\.\d]+))?'
690
716
  name: 'Oregano'
@@ -719,6 +745,11 @@
719
745
  name: 'Sunrise'
720
746
  version: '$1'
721
747
 
748
+ # WeTab Browser
749
+ - regex: 'WeTab-Browser'
750
+ name: 'WeTab Browser'
751
+ version: ''
752
+
722
753
  #Xiino
723
754
  - regex: 'Xiino(?:/(\d+[\.\d]+))?'
724
755
  name: 'Xiino'
@@ -752,3 +783,4 @@
752
783
  version: '$1'
753
784
  engine:
754
785
  default: 'WebKit'
786
+
@@ -0,0 +1,26 @@
1
+ ###############
2
+ # Device Detector - The Universal Device Detection library for parsing User Agents
3
+ #
4
+ # @link http://piwik.org
5
+ # @license http://www.gnu.org/licenses/lgpl.html LGPL v3 or later
6
+ ###############
7
+
8
+ #Nikon
9
+ Nikon:
10
+ regex: 'Coolpix S800c'
11
+ device: 'camera'
12
+ model: 'Coolpix S800c'
13
+
14
+ # Samsung
15
+ Samsung:
16
+ regex: 'EK-GC[0-9]{3}'
17
+ device: 'camera'
18
+ models:
19
+ - regex: 'EK-GC100'
20
+ model: 'GALAXY Camera'
21
+ - regex: 'EK-GC110'
22
+ model: 'GALAXY Camera WiFi only'
23
+ - regex: 'EK-GC200'
24
+ model: 'GALAXY Camera 2'
25
+ - regex: 'EK-GC([0-9]{3})'
26
+ model: 'GALAXY Camera $1'
@@ -0,0 +1,13 @@
1
+ ###############
2
+ # Device Detector - The Universal Device Detection library for parsing User Agents
3
+ #
4
+ # @link http://piwik.org
5
+ # @license http://www.gnu.org/licenses/lgpl.html LGPL v3 or later
6
+ ###############
7
+
8
+ # Tesla Model S
9
+ Tesla:
10
+ regex: 'QtCarBrowser'
11
+ device: 'car browser'
12
+ model: 'Model S'
13
+
@@ -0,0 +1,41 @@
1
+ ###############
2
+ # Device Detector - The Universal Device Detection library for parsing User Agents
3
+ #
4
+ # @link http://piwik.org
5
+ # @license http://www.gnu.org/licenses/lgpl.html LGPL v3 or later
6
+ ###############
7
+
8
+ Archos:
9
+ regex: 'Archos.*GAMEPAD([2]?)'
10
+ device: 'console'
11
+ model: 'Gamepad $1'
12
+
13
+ Microsoft:
14
+ regex: 'Xbox'
15
+ device: 'console'
16
+ models:
17
+ - regex: 'Xbox One'
18
+ model: 'Xbox One'
19
+ - regex: 'Xbox'
20
+ model: 'Xbox 360'
21
+
22
+ Nintendo:
23
+ regex: 'Nintendo (([3]?DS[i]?)|Wii[U]?)'
24
+ device: 'console'
25
+ model: '$1'
26
+
27
+ OUYA:
28
+ regex: 'OUYA'
29
+ device: 'console'
30
+ model: 'OUYA'
31
+
32
+ Sega:
33
+ regex: 'Dreamcast'
34
+ device: 'console'
35
+ model: 'Dreamcast'
36
+
37
+ Sony:
38
+ regex: 'PlayStation (3|4|Portable|Vita)'
39
+ device: 'console'
40
+ model: 'PlayStation $1'
41
+