forked from mobalean/wurfl
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Examples.txt
27 lines (16 loc) · 1 KB
/
Examples.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
First step to do anything is to merge the patch and the base wurfl
into a pstore database.
1 Get latest wurfl base and unzip it
wget http://jaist.dl.sourceforge.net/sourceforge/wurfl/wurfl-latest.xml.gz
gunzip wurfl-latest.xml.gz
2 Using the wurfltools.rb utility, merge the patch to the base wurfl
and output as a pstore database.
wurfltools.rb loader -f ./wurfl-latest.xml -e wurfl.patch.xml -d handsetpstore.db
Now we can perform various operations, such as output a csv file
containing japanese carrier handset uer agents and the supported flash
lite version.
wurfltools.rb inspector -d handsetpstore.db -s '{|h| puts
h.user_agent+","+h["flash_lite_version"] if ( h.actual_device=="true"
&& h.user_agent =~/^(docomo|kddi|softbank)/i) }' | sort | uniq
Output browser width and height
./bin/wurfltools.rb inspector -d handsetpstore-november.db -s '{|h| puts h["model_name"]+","+h["resolution_width"]+","+h["resolution_height"] if (h.actual_device && h.user_agent=~/^(docomo|kddi|softbank|voda)/i) }' | sort | uniq