Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Firefox OS 1.2 and UA override settings

68 views
Skip to first unread message

Karl Dubost

unread,
Dec 10, 2013, 6:17:19 PM12/10/13
to Jim Chen, compatibility
Jim,

So I updated the device to 1.2 today
It was said in another thread that to cancel the UA override, you could set:

general.useragent.updates.enabled to false


My issue is that both in
/system/b2g/defaults/pref/user.js
/system/b2g/defaults/settings.json

there is NOT such a preference.

1. If not here, means true, do I add it to user.js or to settings.json?
2. If somewhere else, where is it?


--
Karl Dubost, Mozilla
http://www.la-grange.net/karl/moz

Karl Dubost

unread,
Dec 11, 2013, 12:11:00 PM12/11/13
to Jim Chen, compatibility
OK. I have figured it out and tested.


1. Testing a domain with UA override on
Getting mobile site

2. Putting the preference to "false"

→ adb pull /system/b2g/defaults/pref/user.js b2g-user.js
51 KB/s (1859 bytes in 0.035s)
→ grep useragent.updates.enabled b2g-user.js
→ echo 'pref("general.useragent.updates.enabled", false);' >> b2g-user.js
→ adb shell mount -o rw,remount /system
→ adb push b2g-user.js /system/b2g/defaults/pref/user.js
137 KB/s (1909 bytes in 0.013s)
→ adb shell mount -o ro,remount /system
→ adb shell stop b2g && adb shell start b2g

3. Testing the same domain after erasing cookies.
Getting the desktop site.


I will update the script mozua.sh to take into consideration b2g 1.2+
https://github.com/karlcow/webcompat/blob/master/moz/mozua.sh
(be my guest with a pull request :) )

Jim Chen

unread,
Dec 11, 2013, 12:22:23 PM12/11/13
to compat...@lists.mozilla.org
Forgot to include the mailing list.

-------- Original Message --------
Subject: Re: Firefox OS 1.2 and UA override settings
Date: Wed, 11 Dec 2013 02:14:19 -0500
From: Jim Chen <nc...@mozilla.com>
To: Karl Dubost <kdu...@mozilla.com>

Hi Karl,

The default prefs are set in Gecko here,
http://mxr.mozilla.org/mozilla-central/source/b2g/app/b2g.js?rev=b843867654c3#764

To change the default, I think you can add the new pref to either
user.js or settings.js (or try adding to both).

Note that "general.useragent.updates.enabled" only applies to
overrides through *updates*, overrides through old-style prefs are
independent and still controlled by
"general.useragent.site_specific_overrides".

Cheers,
Jim
0 new messages