mirror of
https://github.com/arkenfox/user.js.git
synced 2025-09-01 09:28:31 +02:00
Compare commits
622 Commits
v62.0-beta
...
83.0
Author | SHA1 | Date | |
---|---|---|---|
94712f59a3 | |||
ef93a754ce | |||
c6ddda1aa3 | |||
ccbca41e2d | |||
5b0d173078 | |||
d6186819f4 | |||
ea0eb85404 | |||
8dc43cfdc2 | |||
f7bee988de | |||
f2fe7f02b0 | |||
accef19af4 | |||
910d7004c6 | |||
07cccd5386 | |||
ac52886ea8 | |||
c45780d79b | |||
e14732aad3 | |||
26d4768447 | |||
9f99885272 | |||
0adfddd1e2 | |||
f591a8adf8 | |||
0e10a820d9 | |||
c90341dded | |||
d5ccf4693b | |||
e89f9a5d89 | |||
a56ba85936 | |||
421f1e361c | |||
2391874e04 | |||
4779ea7850 | |||
c367beabe3 | |||
e1d336a178 | |||
ee3e5f0186 | |||
42b7650d42 | |||
f61d4a0d38 | |||
7fe9784bf8 | |||
ed05c64482 | |||
16c3658040 | |||
515d6ff874 | |||
fc65052286 | |||
6a107d4d2f | |||
eff4b74130 | |||
2532ddcc18 | |||
44e22835c1 | |||
1f545312fd | |||
637e5964db | |||
26bca612d7 | |||
6fdda5fb62 | |||
ed5b158777 | |||
4c4270f1d7 | |||
af51631597 | |||
ae0c980d25 | |||
3e4c56cf27 | |||
18112f9ae8 | |||
c8eee094e0 | |||
78a7c194eb | |||
f606c8b866 | |||
9c98972d14 | |||
75a03df0f7 | |||
76019e6fbe | |||
3c2bd930c3 | |||
ed993d5502 | |||
22d2d702be | |||
8dacf6e91f | |||
fbe1d48fe2 | |||
5fd7f6de7e | |||
592b959c24 | |||
c6f53c8768 | |||
38d772e4c8 | |||
cfce521919 | |||
a5ab3e23d6 | |||
b3eee6c9fd | |||
8d6d17d46b | |||
9a37e1340c | |||
f1e0203ef4 | |||
726d5bde30 | |||
f9f0fffd27 | |||
93840ca181 | |||
99aa5af356 | |||
0358fdac8b | |||
815c3026b5 | |||
5ed3047b7a | |||
e16ede1cdf | |||
6905187b3e | |||
172118e61b | |||
8452edb94b | |||
0f6957bbd4 | |||
8c2bcc0352 | |||
bc832575d8 | |||
c4b7e07691 | |||
58fb1db838 | |||
2809854802 | |||
091a71aade | |||
117ab133b1 | |||
c4a06c4689 | |||
0d27689c64 | |||
771e57480a | |||
f8fd03482d | |||
10cc1224d0 | |||
52926cca7a | |||
be64819ce7 | |||
24c228df92 | |||
892b3d9d69 | |||
df21798b81 | |||
46d03279d3 | |||
fe0af3bb34 | |||
84997386c1 | |||
1a389c0214 | |||
d0060fed3c | |||
3d18af19e3 | |||
b5b04454e0 | |||
618f7bed3f | |||
488a825626 | |||
aaf6cb33d7 | |||
77ecef8be3 | |||
4be0a80720 | |||
f573200aa8 | |||
48f258ff53 | |||
b9100488cb | |||
9d78e050ee | |||
b07cf1f03d | |||
683ef63b37 | |||
05580f5e99 | |||
ecc62554e5 | |||
f6e6de8444 | |||
f69d92e6dd | |||
3edc48da56 | |||
868882ae33 | |||
ff9bf76e52 | |||
4bc5b89cfe | |||
bb1e5bfd54 | |||
27d72eda9e | |||
07117c65c1 | |||
919d4bfe96 | |||
e38e253c25 | |||
14aaec71fb | |||
c0780df24d | |||
0ea1605642 | |||
bd384622db | |||
3366e0aa16 | |||
dff5bb478a | |||
d455c500a6 | |||
b90e72370c | |||
dd162d9f48 | |||
d7c276b3fe | |||
394b691599 | |||
ba83c555cc | |||
b695468c7e | |||
deae6e14f9 | |||
97c5378e52 | |||
d2dd0c2ab4 | |||
8c7149c6a5 | |||
d2da48c215 | |||
7e71b6663c | |||
94c83519f2 | |||
e7d20867cb | |||
55ae994972 | |||
f0945743b7 | |||
ee35d7c70d | |||
fe1b03bd2a | |||
187692af66 | |||
b6e2a3f64f | |||
6f7e09ad43 | |||
4ddf60cf32 | |||
24777c9ac2 | |||
615ebeda2f | |||
4139630635 | |||
a542701ba5 | |||
e67a0c868d | |||
1afd52de6e | |||
64f34f1471 | |||
5f3e3b2691 | |||
1ce1f74494 | |||
03f558b09c | |||
cd9fc110b0 | |||
7619e312de | |||
5d2c5de11c | |||
e1022c2e72 | |||
e431b324c8 | |||
18ad40a5c6 | |||
315de066ec | |||
85273d0f19 | |||
ef293b57a7 | |||
79d316fd22 | |||
ed60588473 | |||
07c128a190 | |||
5b1d56933b | |||
34cfcedc1b | |||
f9146fdf24 | |||
a1cdbc8324 | |||
cd07641a9d | |||
9c02949e04 | |||
1ef62a1036 | |||
5672bc8cc8 | |||
df1732745d | |||
30daf8640c | |||
4074a37e1d | |||
97043b0ce1 | |||
42ea484017 | |||
3f6340b69c | |||
884e84a4cb | |||
560acfc94f | |||
fb263f5624 | |||
19b392b83d | |||
2db76c95c3 | |||
b6fbf77dde | |||
a4ba22e912 | |||
163e18ce6d | |||
a13027905e | |||
8f76d9439f | |||
f0980b5cb8 | |||
450c9a9e0f | |||
6acfdaccbd | |||
a0e0a2a6c9 | |||
f67e729197 | |||
19526b573c | |||
b0221ec838 | |||
a3611b7cf8 | |||
bff1e84afa | |||
1d31da40ec | |||
0d57cfc44a | |||
0cfb2fb06d | |||
d5f297ed42 | |||
c13dbdf40d | |||
6173104a9e | |||
0c79b8b45b | |||
895f8d01d5 | |||
65dfad5c76 | |||
fdaf22780f | |||
16756646bb | |||
e4f80225d8 | |||
67eec9c85c | |||
539750d2f2 | |||
d91226ed55 | |||
301fcd059d | |||
1cc9a08a18 | |||
5d1857ddd8 | |||
226af6f679 | |||
7f2c92f654 | |||
5b82afd5bd | |||
d7b1877a1f | |||
1b6239eab8 | |||
ad0187122d | |||
624e50faac | |||
a9e9392172 | |||
201210111e | |||
53f8578749 | |||
dc4d9e4dae | |||
e1b0eae740 | |||
be0ccf6460 | |||
7c0a327b06 | |||
a35cba3914 | |||
e16425310f | |||
d503d96db0 | |||
335299a0cf | |||
7311cfdf84 | |||
3a9440aeea | |||
3210ab0ca8 | |||
2c734612f6 | |||
a12dd83b1f | |||
44d9ceaf05 | |||
be9d9ac9ca | |||
66cdb72927 | |||
953b96431e | |||
4d72ad90b0 | |||
cccb5b10b4 | |||
810045eb39 | |||
b47982bb9a | |||
0691b8babe | |||
8d1c95c650 | |||
19484e1a56 | |||
755ebf88fb | |||
d26ea4f39e | |||
a0f3da208f | |||
5166811bd5 | |||
86bfdd1470 | |||
90ef9e63eb | |||
f2200fd442 | |||
aff595b6ea | |||
6618bf5f76 | |||
9aa8e27ef4 | |||
9c782fbf57 | |||
931462b30b | |||
217553b367 | |||
469bbc1ab3 | |||
11dcc54b61 | |||
d40d7dbabd | |||
b80c515e88 | |||
ed735f875c | |||
55b720faec | |||
31567c7938 | |||
8f939c91fe | |||
27bd07d496 | |||
42281a9e52 | |||
8f40c97fd1 | |||
9642452c48 | |||
8f1c3018ca | |||
f85eb9d0c2 | |||
408a992893 | |||
23c884a5f8 | |||
51089fbad9 | |||
83b4ada670 | |||
7df6c676be | |||
e338186953 | |||
fa61a7c25b | |||
dafd0894e6 | |||
06cf53d63e | |||
fc545b4d27 | |||
3c5f58b812 | |||
7d7f580bfc | |||
ca5d6b3317 | |||
9e7f9de56f | |||
8a204b5db0 | |||
690a93b71d | |||
0da3835a49 | |||
a92c4086bb | |||
9b7771fe76 | |||
2265b73521 | |||
01aae1b346 | |||
c2dbdcd4ec | |||
f53b996cfa | |||
a633622d11 | |||
caaf76e3fb | |||
8811a28c56 | |||
fdc9db9a08 | |||
c079c3c632 | |||
6f76a9bfd2 | |||
dfab1516ef | |||
57339d09b1 | |||
ed23a88c08 | |||
dae1087082 | |||
7a103b0c23 | |||
5d5a9acaa4 | |||
76c476ee3c | |||
b3c6561ba8 | |||
a4c2bb80aa | |||
a173d30d4e | |||
fc801db06a | |||
61ce537f20 | |||
7a766cd2a7 | |||
842a78692e | |||
540f5ce868 | |||
be7c50c198 | |||
473e88c784 | |||
da4cfce10f | |||
2a30436905 | |||
7f6d7c6a52 | |||
720253eca3 | |||
7394f2f553 | |||
ccec62f66b | |||
329719fe25 | |||
57f4bd46e9 | |||
59a85bcdda | |||
dab27cd143 | |||
1ff14e31c0 | |||
c55ecbd8b2 | |||
99eb835e7a | |||
1e0b3d74f9 | |||
7bb0bfefe1 | |||
f1d28f3878 | |||
57618a31dc | |||
600f9677e9 | |||
0d40613268 | |||
11f40f8a84 | |||
c3a74a7c6e | |||
4dd40bddcc | |||
9da3cf4be8 | |||
50869a734f | |||
bb788682c9 | |||
50afeb1861 | |||
0eb107abf3 | |||
675577fb8d | |||
b28677a594 | |||
48f3dfec84 | |||
59930d4697 | |||
579aa3aa9c | |||
ed687fc7ca | |||
ce3d5a8cbe | |||
8ffbd81813 | |||
4119be3a86 | |||
8d874401fa | |||
b4a4856223 | |||
8a86097997 | |||
7a9763d129 | |||
a39516ff0e | |||
3e5e1bfdd2 | |||
7b667db766 | |||
8f1a489e36 | |||
6f8d0263df | |||
25b8b404fb | |||
528d0de6b4 | |||
c9c1671e4a | |||
8765231de0 | |||
e6017af4bd | |||
053808ba97 | |||
2d0182ce6e | |||
98f65da430 | |||
6a0c44d0a4 | |||
882d25f725 | |||
c3210d1be9 | |||
d4f7590c83 | |||
d6ccf7ba64 | |||
0922215670 | |||
f849e1c602 | |||
986c900193 | |||
b8367959da | |||
b05cfc32de | |||
358ddfdfce | |||
8a68fc48c5 | |||
87959d621c | |||
8b07fd57d0 | |||
4989928c1e | |||
c2775a3441 | |||
50d31a7aa2 | |||
9fbe3080c5 | |||
8a98cd1890 | |||
2d62b9f729 | |||
bb7f8df647 | |||
373602f0f0 | |||
e56665ecd1 | |||
59d056de27 | |||
d41372a7f0 | |||
f62f781645 | |||
408d1d0e26 | |||
d491cf1e89 | |||
ca0f2a5a88 | |||
fd10c35049 | |||
6ed3581cb0 | |||
c2034617f0 | |||
6231d6ebed | |||
411805b05c | |||
8c12f4bb14 | |||
e3349d0f07 | |||
92082621d6 | |||
54f86f4be6 | |||
585415b534 | |||
99586c4a3b | |||
8419b4d71b | |||
79e316a26f | |||
26a70f3cd7 | |||
bee47f33cd | |||
2fcec590b4 | |||
3c4b312cc7 | |||
0354895a2e | |||
462db2062c | |||
d9e24e5095 | |||
b1aa1f5619 | |||
a349662f69 | |||
28a7226235 | |||
97f08ad3cd | |||
68584a3397 | |||
8b4f45774a | |||
f8428dcc0a | |||
6d6cd5f410 | |||
eae8434853 | |||
2cff24f12e | |||
60be8be5ec | |||
981dd83c15 | |||
5c703f0262 | |||
de0ebbed21 | |||
e448015704 | |||
d3b1ed45ad | |||
ed140425ea | |||
3847f97f41 | |||
d81e8ae583 | |||
7a8381d894 | |||
649699ad22 | |||
1d5289dd94 | |||
74c8f294d6 | |||
a0508eccf6 | |||
25acd9f63e | |||
74a08114a8 | |||
71ffc661b2 | |||
e432a22693 | |||
f06c78f897 | |||
847eb80877 | |||
ec0e58099f | |||
e6eb473071 | |||
f1b892bc1c | |||
524b5f79dc | |||
24f2e1d982 | |||
c6060e5645 | |||
d0b8a08a4b | |||
f047fe93c0 | |||
6147fed61c | |||
54f79604da | |||
2f351fa5ce | |||
5dc3ea66cd | |||
d9a87b3ac4 | |||
95b75a065d | |||
8c96432eb8 | |||
1c09ec36e3 | |||
f1e6d164f7 | |||
3b90e6e592 | |||
45bd5ccc02 | |||
7bf5790f2b | |||
075d6fe6e4 | |||
4604cf0d4e | |||
b845f8fe3a | |||
96063027ba | |||
186fb1c9be | |||
ac4e764c37 | |||
5b0952f60a | |||
5bd5f6b28e | |||
55c2cacbce | |||
4badc42879 | |||
6946a01232 | |||
da80e39064 | |||
c1d6d81528 | |||
d5ece0f6f4 | |||
f6ea20a8b0 | |||
645492e82f | |||
15c68dc344 | |||
04b797f1aa | |||
e60abd6c44 | |||
d55b8176ad | |||
31adbba774 | |||
3c247a2c5b | |||
879f0abf28 | |||
d97d0ec0f5 | |||
3916e38681 | |||
51ac69874b | |||
2d956d04f3 | |||
9d6bfb650c | |||
ccdd4decf0 | |||
f0fbfd3086 | |||
88b747ef36 | |||
c6ebe36165 | |||
7684e83aba | |||
4f37975566 | |||
26b874bed7 | |||
61be5ae563 | |||
ef1e61ebcd | |||
205c48d9d3 | |||
0e1b0a4b6e | |||
778dc89bb6 | |||
23733097a9 | |||
71a2d393f3 | |||
74ebacc0dd | |||
45e3b3a0e0 | |||
8172f730d3 | |||
5c85e61bb4 | |||
0a67cdec8b | |||
b85668c2cd | |||
786839ffc1 | |||
8313f2e01a | |||
0a87c99a0e | |||
91fed43fc7 | |||
74f029566e | |||
571be93ae0 | |||
11b16c9c6d | |||
c4ec4dbc77 | |||
67998eb4af | |||
834857b564 | |||
25923f1acd | |||
85eaba2571 | |||
51237f6889 | |||
74e753d0c5 | |||
db56940422 | |||
400d764a93 | |||
f3e2bfa76d | |||
d4907faa8e | |||
62351bfbf5 | |||
b182946ae4 | |||
2ae3a3e4e1 | |||
0ff610c056 | |||
661a314e28 | |||
106f46d053 | |||
643cba63cf | |||
b5c5d8e9d1 | |||
36b90cd5e6 | |||
299a03663f | |||
13550d18a1 | |||
c12eb0fdc6 | |||
acbf881b1f | |||
7351e561c4 | |||
4e42bad6a1 | |||
b85e748b53 | |||
0cc4007eda | |||
3003f2dd85 | |||
ce48306a0d | |||
3423d39fa9 | |||
4834472107 | |||
f214e4bc4e | |||
8fd6061bcc | |||
92acb6b2f7 | |||
b6b9733afa | |||
89bc0bee16 | |||
f8fc465d0a | |||
58fa4e9b6d | |||
afee555045 | |||
5a36b4e016 | |||
7b3e6f5143 | |||
452c717502 | |||
661af196d9 | |||
39a30d710b | |||
8f10300c15 | |||
806d047729 | |||
0efebe3e83 | |||
49d9314b0a | |||
b4b5e3a068 | |||
29d832e350 | |||
68e44285c5 | |||
e8bfa93696 | |||
1abe1fd4df | |||
24f7847f73 | |||
56206f77ba | |||
587194ce84 | |||
7aac6d476a | |||
9e073ea5d5 | |||
732c438148 | |||
58931bc15d | |||
21b18cbe49 | |||
cbcd293e68 | |||
aacf5d4a0b | |||
ec5fb6e3a1 | |||
b2fc9bc266 | |||
ca1cc2001f | |||
f88af1dac6 | |||
1c6c5ea2ff | |||
2d316ceedd | |||
36c791c4bc | |||
ee213f2bab | |||
01a978e33a |
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -13,3 +13,4 @@
|
||||
.gitattributes export-ignore
|
||||
*.yml export-ignore
|
||||
/wikipiki export-ignore
|
||||
/.github export-ignore
|
||||
|
18
.github/ISSUE_TEMPLATE/tools.md
vendored
Normal file
18
.github/ISSUE_TEMPLATE/tools.md
vendored
Normal file
@ -0,0 +1,18 @@
|
||||
---
|
||||
name: Tools
|
||||
about: Report issues with the updaters, the troubleshooter, or any other tools.
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
<!--
|
||||
Please specify:
|
||||
- the name of the file (i.e. updater.bat, updater.sh)
|
||||
- steps to reproduce the issue
|
||||
- actual result
|
||||
- expected result
|
||||
|
||||
Blank out this field before typing, or start typing after the next line.
|
||||
-->
|
28
.github/ISSUE_TEMPLATE/troubleshooting-help.md
vendored
Normal file
28
.github/ISSUE_TEMPLATE/troubleshooting-help.md
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
---
|
||||
name: Troubleshooting help
|
||||
about: Ask for help to solve problems with user.js
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
Before you proceed...
|
||||
- Issues will be closed as invalid if you do not [troubleshoot](https://github.com/arkenfox/user.js/wiki/1.4-Troubleshooting), including
|
||||
- confirming the problem is caused by the `user.js`
|
||||
- searching the `[Setup` tags in the `user.js`
|
||||
- Search the GitHub repository. The information you need is most likely here already.
|
||||
- Note: We do not support forks
|
||||
|
||||
See also:
|
||||
- Extension breakage due to prefs [issue 391](https://github.com/arkenfox/user.js/issues/391)
|
||||
- Prefs vs Recommended Extensions: Co-Existance+Enhancement | Conflicts [issue 350](https://github.com/arkenfox/user.js/issues/350)
|
||||
|
||||
If you still need help, help us help you by providing relevant information:
|
||||
- browser version
|
||||
- Steps to Reproduce (STR)
|
||||
- actual result
|
||||
- expected result
|
||||
- anything else you deem worth mentioning
|
||||
|
||||
Clear all of this when you're ready to type.
|
15
.github/ISSUE_TEMPLATE/user-js.md
vendored
Normal file
15
.github/ISSUE_TEMPLATE/user-js.md
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
---
|
||||
name: user.js
|
||||
about: Suggest changes to user.js
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
We value feedback in general, but we value feedback from informed users more. There is no need for you to be an expert to participate (most of us aren't), but we hope that you at least understand our decisions before questioning them. We discuss all changes openly, and we do not make changes lightly. So, if you don't understand why we decided to add/remove/change a certain pref, search the repo. The answer is most certainly here.
|
||||
|
||||
If some change we made took you by surprise (in the wrong way), remember that keeping track of changes is your responsibility. Watch the repo, read the [changelogs](https://github.com/arkenfox/user.js/issues?utf8=✓&q=is%3Aissue+label%3Achangelog), compare [releases](https://github.com/arkenfox/user.js/releases) as you update your copy of user.js, or use any other method you prefer.
|
||||
|
||||
Clear all of this when you're ready to type.
|
||||
|
@ -1,6 +1,6 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2017 ghacksuserjs
|
||||
Copyright (c) 2020 arkenfox
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
|
34
README.md
34
README.md
@ -1,21 +1,27 @@
|
||||
###  user.js
|
||||
A `user.js` is a configuration file that can control hundreds of Firefox settings. For a more technical breakdown and explanation, you can read more on the [overview](https://github.com/ghacksuserjs/ghacks-user.js/wiki/1.1-Overview) wiki page.
|
||||
### 🟪 user.js
|
||||
A `user.js` is a configuration file that can control hundreds of Firefox settings. For a more technical breakdown and explanation, you can read more on the [overview](https://github.com/arkenfox/user.js/wiki/1.1-Overview) wiki page.
|
||||
|
||||
###  ghacks user.js
|
||||
The `ghacks user.js` is a **template**, which, as provided, aims to provide as much privacy and enhanced security as possible, and to reduce tracking and fingerprinting as much as possible - while minimizing any loss of functionality and breakage (but it will happen).
|
||||
### 🟩 the arkenfox user.js
|
||||
|
||||
Everyone, experts included, should at least read the [implementation](https://github.com/ghacksuserjs/ghacks-user.js/wiki/1.3-Implementation) wiki page, as it contains important information regarding a few `ghacks user.js` settings.
|
||||
[](https://opensource.org/licenses/MIT)
|
||||
|
||||
Sitemap: [Releases](https://github.com/ghacksuserjs/ghacks-user.js/releases), [changelogs](https://github.com/ghacksuserjs/ghacks-user.js/issues?utf8=%E2%9C%93&q=is%3Aissue+label%3Achangelog), [Wiki](https://github.com/ghacksuserjs/ghacks-user.js/wiki), [stickies](https://github.com/ghacksuserjs/ghacks-user.js/issues?q=is%3Aissue+is%3Aopen+label%3A%22sticky+topic%22). [diffs](https://github.com/ghacksuserjs/ghacks-user.js/issues?q=is%3Aissue+label%3Adiffs)
|
||||
The `arkenfox user.js` is a **template** which aims to provide as much privacy and enhanced security as possible, and to reduce tracking and fingerprinting as much as possible - while minimizing any loss of functionality and breakage (but it will happen).
|
||||
|
||||
###  acknowledgments
|
||||
Literally thousands of sources, references and suggestions. That said...
|
||||
Everyone, experts included, should at least read the [implementation](https://github.com/arkenfox/user.js/wiki/1.3-Implementation) wiki page, as it contains important information regarding a few `user.js` settings.
|
||||
|
||||
* Martin Brinkmann at [ghacks](https://www.ghacks.net/) <sup>1</sup>
|
||||
* The ghacks community and commentators
|
||||
* [12bytes](http://12bytes.org/tech/firefox/firefoxgecko-configuration-guide-for-privacy-and-performance-buffs)
|
||||
* The 12bytes article now uses this user.js and supplements it with an additonal JS hosted right [here](https://github.com/atomGit/Firefox-user.js) at github
|
||||
Note that we do *not* recommend connecting over Tor on Firefox. Use the [Tor Browser](https://www.torproject.org/projects/torbrowser.html.en) if your [threat model](https://www.torproject.org/about/torusers.html.en) calls for it, or for accessing hidden services.
|
||||
|
||||
Also be aware that the `arkenfox user.js` is made specifically for desktop Firefox. Using it as-is in other Gecko-based browsers can be counterproductive, especially in the Tor Browser.
|
||||
|
||||
### 🟧 sitemap
|
||||
|
||||
- [Releases](https://github.com/arkenfox/user.js/releases)
|
||||
- [changelogs](https://github.com/arkenfox/user.js/issues?utf8=%E2%9C%93&q=is%3Aissue+label%3Achangelog)
|
||||
- [Wiki](https://github.com/arkenfox/user.js/wiki)
|
||||
- [stickies](https://github.com/arkenfox/user.js/issues?q=is%3Aissue+is%3Aopen+label%3A%22sticky+topic%22)
|
||||
- [diffs](https://github.com/arkenfox/user.js/issues?q=is%3Aissue+label%3Adiffs)
|
||||
|
||||
### 🟥 acknowledgments
|
||||
Literally thousands of sources, references and suggestions. Many thanks, and much appreciated.
|
||||
|
||||
<sup>1</sup> The ghacks user.js was an independent project by [Thorin-Oakenpants](https://github.com/Thorin-Oakenpants) started in early 2015 and was [first published](https://www.ghacks.net/2015/08/18/a-comprehensive-list-of-firefox-privacy-and-security-settings/) at ghacks in August 2015. With Martin Brinkmann's blessing, it will keep the ghacks name.
|
||||
|
||||
###  [](https://opensource.org/licenses/MIT)
|
||||
|
@ -1 +1,3 @@
|
||||
theme: jekyll-theme-midnight
|
||||
title: user.js
|
||||
description: An ongoing comprehensive user.js template for configuring and hardening Firefox privacy, security and anti-fingerprinting
|
||||
|
@ -3,7 +3,7 @@ TITLE prefs.js cleaner
|
||||
|
||||
REM ### prefs.js cleaner for Windows
|
||||
REM ## author: @claustromaniac
|
||||
REM ## version: 2.2
|
||||
REM ## version: 2.3
|
||||
|
||||
CD /D "%~dp0"
|
||||
|
||||
@ -13,7 +13,7 @@ ECHO:
|
||||
ECHO ########################################
|
||||
ECHO #### prefs.js cleaner for Windows ####
|
||||
ECHO #### by claustromaniac ####
|
||||
ECHO #### v2.2 ####
|
||||
ECHO #### v2.3 ####
|
||||
ECHO ########################################
|
||||
ECHO:
|
||||
CALL :message "This script should be run from your Firefox profile directory."
|
||||
@ -101,7 +101,7 @@ ECHO add-ons disabled. Then, restart it again normally, and see if the
|
||||
CALL :message " problems were solved."
|
||||
ECHO:
|
||||
CALL :message "If you are able to identify the cause of your issues, please bring it up"
|
||||
ECHO on ghacks-user.js GitHub repository.
|
||||
ECHO on arkenfox user.js GitHub repository.
|
||||
ECHO:
|
||||
ECHO:
|
||||
PAUSE
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
## prefs.js cleaner for Linux/Mac
|
||||
## author: @claustromaniac
|
||||
## version: 1.1
|
||||
## version: 1.3
|
||||
|
||||
## special thanks to @overdodactyl and @earthlng for a few snippets that I stol..*cough* borrowed from the updater.sh
|
||||
|
||||
@ -27,7 +27,7 @@ fQuit() {
|
||||
fFF_check() {
|
||||
# there are many ways to see if firefox is running or not, some more reliable than others
|
||||
# this isn't elegant and might not be future-proof but should at least be compatible with any environment
|
||||
while [ -e webappsstore.sqlite-shm ]; do
|
||||
while [ -e lock ]; do
|
||||
echo -e "\nThis Firefox profile seems to be in use. Close Firefox and try again.\n"
|
||||
read -p "Press any key to continue."
|
||||
done
|
||||
@ -58,7 +58,7 @@ echo -e "\n\n"
|
||||
echo " ╔══════════════════════════╗"
|
||||
echo " ║ prefs.js cleaner ║"
|
||||
echo " ║ by claustromaniac ║"
|
||||
echo " ║ v1.1 ║"
|
||||
echo " ║ v1.3 ║"
|
||||
echo " ╚══════════════════════════╝"
|
||||
echo -e "\nThis script should be run from your Firefox profile directory.\n"
|
||||
echo "It will remove any entries from prefs.js that also exist in user.js."
|
||||
@ -90,7 +90,7 @@ select option in Start Help Exit; do
|
||||
echo "4. Rename or copy your latest backup to prefs.js."
|
||||
echo "5. Run Firefox and see if you notice anything wrong with it."
|
||||
echo "6. If you do notice something wrong, especially with your extensions, and/or with the UI, go to about:support, and restart Firefox with add-ons disabled. Then, restart it again normally, and see if the problems were solved."
|
||||
echo -e "If you are able to identify the cause of your issues, please bring it up on ghacks-user.js GitHub repository.\n"
|
||||
echo -e "If you are able to identify the cause of your issues, please bring it up on the arkenfox user.js GitHub repository.\n"
|
||||
;;
|
||||
Exit)
|
||||
fQuit 0
|
||||
|
@ -1,10 +1,12 @@
|
||||
/***
|
||||
This will reset the preferences that are under sections 4600 & 4700 in the ghacks user.js
|
||||
up to and including release 60-beta. These are the prefs that are no longer necessary,
|
||||
or they conflict with, privacy.resistFingerprinting if you have that enabled.
|
||||
Version: up to and including FF/ESR78
|
||||
|
||||
This will reset the preferences that are under sections 4600 & 4700 in the
|
||||
arkenfox user.js. These are the prefs that are no longer necessary, or they
|
||||
conflict with, privacy.resistFingerprinting if you have that enabled.
|
||||
|
||||
For instructions see:
|
||||
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
|
||||
https://github.com/arkenfox/user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
|
||||
***/
|
||||
|
||||
(function() {
|
||||
@ -22,6 +24,10 @@
|
||||
'dom.w3c_touch_events.enabled',
|
||||
'media.ondevicechange.enabled',
|
||||
'webgl.enable-debug-renderer-info',
|
||||
'dom.w3c_pointer_events.enabled',
|
||||
'ui.use_standins_for_native_colors',
|
||||
'ui.systemUsesDarkTheme',
|
||||
'ui.prefersReducedMotion',
|
||||
/* section 4700 */
|
||||
'general.useragent.override',
|
||||
'general.buildID.override',
|
@ -1,19 +1,81 @@
|
||||
/***
|
||||
Version: up to and including FF/ESR78
|
||||
|
||||
This will reset the preferences that have been deprecated by Mozilla
|
||||
and used in the ghacks user.js up to and including release 60-beta
|
||||
and used in the arkenfox user.js
|
||||
|
||||
It is in reverse order, so feel free to remove sections that do not apply
|
||||
|
||||
For instructions see:
|
||||
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
|
||||
https://github.com/arkenfox/user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
|
||||
***/
|
||||
|
||||
(function() {
|
||||
let ops = [
|
||||
/* deprecated */
|
||||
|
||||
/* ESR52.x users can remove sections 53-60 but it is not
|
||||
crucial as your user.js will reinstate them */
|
||||
/* 78 */
|
||||
'media.autoplay.enabled.user-gestures-needed',
|
||||
'toolkit.cosmeticAnimations.enabled',
|
||||
/* 77 */
|
||||
'browser.urlbar.oneOffSearches',
|
||||
'browser.tabs.remote.allowLinkedWebInFileUriProcess',
|
||||
/* 76 */
|
||||
'extensions.blocklist.url',
|
||||
/* 74 */
|
||||
'geo.wifi.uri',
|
||||
'geo.wifi.logging.enabled',
|
||||
'privacy.userContext.longPressBehavior',
|
||||
'webgl.disable-extensions',
|
||||
/* 72 */
|
||||
'browser.newtabpage.activity-stream.telemetry.ping.endpoint',
|
||||
'toolkit.telemetry.hybridContent.enabled',
|
||||
'dom.indexedDB.enabled',
|
||||
/* 71 */
|
||||
'devtools.webide.enabled',
|
||||
'devtools.webide.autoinstallADBExtension',
|
||||
'offline-apps.allow_by_default',
|
||||
/* 69 */
|
||||
'gfx.downloadable_fonts.woff2.enabled',
|
||||
'plugins.click_to_play',
|
||||
'media.autoplay.allow-muted',
|
||||
/* 68 */
|
||||
'browser.newtabpage.activity-stream.disableSnippets',
|
||||
'browser.aboutHomeSnippets.updateUrl',
|
||||
'lightweightThemes.update.enabled',
|
||||
'security.csp.experimentalEnabled',
|
||||
/* F67 */
|
||||
'dom.event.highrestimestamp.enabled',
|
||||
'browser.newtabpage.activity-stream.asrouter.userprefs.cfr',
|
||||
/* 66 */
|
||||
'browser.chrome.errorReporter.enabled',
|
||||
'browser.chrome.errorReporter.submitUrl',
|
||||
'network.allow-experiments',
|
||||
/* 65 */
|
||||
'browser.urlbar.autocomplete.enabled',
|
||||
'browser.fixup.hide_user_pass',
|
||||
/* 64 */
|
||||
'browser.onboarding.enabled',
|
||||
'devtools.webide.autoinstallADBHelper',
|
||||
'devtools.webide.adbAddonURL',
|
||||
'security.csp.enable_violation_events',
|
||||
/* 63 */
|
||||
'browser.search.countryCode',
|
||||
'app.update.enabled',
|
||||
'shield.savant.enabled',
|
||||
'browser.chrome.favicons',
|
||||
'media.autoplay.enabled',
|
||||
'network.cookie.lifetime.days',
|
||||
'browser.ctrlTab.previews',
|
||||
/* 62 */
|
||||
'plugin.state.java',
|
||||
/* 61 */
|
||||
'experiments.enabled',
|
||||
'experiments.manifest.uri',
|
||||
'experiments.supported',
|
||||
'experiments.activeExperiment',
|
||||
'network.jar.block-remote-files',
|
||||
'network.jar.open-unsafe-types',
|
||||
/* 60 */
|
||||
'browser.newtabpage.directory.source',
|
||||
'browser.newtabpage.enhanced',
|
||||
@ -22,7 +84,6 @@
|
||||
'extensions.shield-recipe-client.api_url',
|
||||
'browser.newtabpage.activity-stream.enabled',
|
||||
'dom.workers.enabled',
|
||||
'view_source.tab',
|
||||
/* 59 */
|
||||
'intl.locale.matchOS',
|
||||
'general.useragent.locale',
|
||||
@ -36,7 +97,8 @@
|
||||
'camera.control.face_detection.enabled',
|
||||
'dom.disable_window_status_change',
|
||||
'dom.idle-observers-api.enabled',
|
||||
/* 58 : nothing */
|
||||
/* 58 */
|
||||
'browser.crashReports.unsubmittedCheck.autoSubmit',
|
||||
/* 57 */
|
||||
'social.whitelist',
|
||||
'social.toast-notifications.enabled',
|
||||
@ -75,8 +137,6 @@
|
||||
'plugin.scan.WindowsMediaPlayer',
|
||||
'media.getusermedia.screensharing.allow_on_old_platforms',
|
||||
'dom.beforeAfterKeyboardEvent.enabled',
|
||||
/* End of ESR52.x section */
|
||||
|
||||
/* 52 */
|
||||
'network.http.sendSecureXSiteReferrer',
|
||||
'media.gmp-eme-adobe.enabled',
|
259
scratchpad-scripts/arkenfox-clear-removed.js
Normal file
259
scratchpad-scripts/arkenfox-clear-removed.js
Normal file
@ -0,0 +1,259 @@
|
||||
/***
|
||||
This will reset the preferences that have been removed completely from the arkenfox user.js.
|
||||
|
||||
Last updated: 02-Nov-2020
|
||||
|
||||
For instructions see:
|
||||
https://github.com/arkenfox/user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
|
||||
***/
|
||||
|
||||
(function() {
|
||||
let ops = [
|
||||
/* removed in arkenfox user.js v52-57 */
|
||||
/* 52-alpha */
|
||||
'browser.search.reset.enabled',
|
||||
'browser.search.reset.whitelist',
|
||||
/* 54-alpha */
|
||||
'browser.migrate.automigrate.enabled',
|
||||
'services.sync.enabled',
|
||||
'webextensions.storage.sync.enabled',
|
||||
'webextensions.storage.sync.serverURL',
|
||||
/* 55-alpha */
|
||||
'dom.keyboardevent.dispatch_during_composition', // default is false anyway
|
||||
'dom.vr.oculus.enabled', // covered by dom.vr.enabled
|
||||
'dom.vr.openvr.enabled', // ditto
|
||||
'dom.vr.osvr.enabled', // ditto
|
||||
'extensions.pocket.api', // covered by extensions.pocket.enabled
|
||||
'extensions.pocket.oAuthConsumerKey', // ditto
|
||||
'extensions.pocket.site', // ditto
|
||||
/* 56-alpha: none */
|
||||
/* 57-alpha */
|
||||
'geo.wifi.xhr.timeout', // covered by geo.enabled
|
||||
'browser.search.geoip.timeout', // ditto
|
||||
'media.webspeech.recognition.enable', // default is false anyway
|
||||
'gfx.layerscope.enabled', // default is false anyway
|
||||
/* 58-alpha */
|
||||
// excluding these e10 settings
|
||||
// 'browser.tabs.remote.autostart',
|
||||
// 'browser.tabs.remote.autostart.2',
|
||||
// 'browser.tabs.remote.force-enable',
|
||||
// 'browser.tabs.remote.separateFileUriProcess',
|
||||
// 'extensions.e10sBlocksEnabling',
|
||||
// 'extensions.webextensions.remote',
|
||||
// 'dom.ipc.processCount',
|
||||
// 'dom.ipc.shims.enabledWarnings',
|
||||
// 'dom.ipc.processCount.extension',
|
||||
// 'dom.ipc.processCount.file',
|
||||
// 'security.sandbox.content.level',
|
||||
// 'dom.ipc.plugins.sandbox-level.default',
|
||||
// 'dom.ipc.plugins.sandbox-level.flash',
|
||||
// 'security.sandbox.logging.enabled',
|
||||
'dom.presentation.controller.enabled',
|
||||
'dom.presentation.discoverable',
|
||||
'dom.presentation.discovery.enabled',
|
||||
'dom.presentation.enabled',
|
||||
'dom.presentation.receiver.enabled',
|
||||
'dom.presentation.session_transport.data_channel.enable',
|
||||
/* 59-alpha */
|
||||
'browser.stopReloadAnimation.enabled',
|
||||
'browser.tabs.insertRelatedAfterCurrent',
|
||||
'browser.tabs.loadDivertedInBackground',
|
||||
'browser.tabs.loadInBackground',
|
||||
'browser.tabs.selectOwnerOnClose',
|
||||
'browser.urlbar.clickSelectsAll',
|
||||
'browser.urlbar.doubleClickSelectsAll',
|
||||
'media.flac.enabled',
|
||||
'media.mediasource.enabled',
|
||||
'media.mediasource.mp4.enabled',
|
||||
'media.mediasource.webm.audio.enabled',
|
||||
'media.mediasource.webm.enabled',
|
||||
'media.mp4.enabled',
|
||||
'media.ogg.enabled',
|
||||
'media.ogg.flac.enabled',
|
||||
'media.opus.enabled',
|
||||
'media.raw.enabled',
|
||||
'media.wave.enabled',
|
||||
'media.webm.enabled',
|
||||
'media.wmf.amd.vp9.enabled',
|
||||
'media.wmf.enabled',
|
||||
'media.wmf.vp9.enabled',
|
||||
'ui.submenuDelay',
|
||||
/* 60-beta - these were all at default anyway */
|
||||
'device.storage.enabled',
|
||||
'general.useragent.compatMode.firefox',
|
||||
'network.dns.blockDotOnion',
|
||||
'network.stricttransportsecurity.preloadlist',
|
||||
'security.block_script_with_wrong_mime',
|
||||
'security.fileuri.strict_origin_policy',
|
||||
'security.sri.enable',
|
||||
/* 61-beta */
|
||||
'browser.laterrun.enabled',
|
||||
'browser.offline-apps.notify',
|
||||
'browser.rights.3.shown',
|
||||
'browser.slowStartup.maxSamples',
|
||||
'browser.slowStartup.notificationDisabled',
|
||||
'browser.slowStartup.samples',
|
||||
'browser.storageManager.enabled',
|
||||
'dom.allow_scripts_to_close_windows',
|
||||
'dom.disable_window_flip',
|
||||
'network.http.fast-fallback-to-IPv4',
|
||||
'offline-apps.quota.warn',
|
||||
'services.blocklist.signing.enforced',
|
||||
/* 62-beta */
|
||||
'browser.urlbar.autoFill.typed',
|
||||
'security.tls.version.fallback-limit',
|
||||
/* 63-beta */
|
||||
'extensions.webextensions.keepStorageOnUninstall',
|
||||
'extensions.webextensions.keepUuidOnUninstall',
|
||||
'privacy.trackingprotection.ui.enabled',
|
||||
/* 64-beta */
|
||||
'browser.eme.ui.enabled',
|
||||
'browser.sessionstore.max_windows_undo',
|
||||
'network.auth.subresource-img-cross-origin-http-auth-allow',
|
||||
'media.peerconnection.ice.tcp',
|
||||
'media.peerconnection.identity.enabled',
|
||||
'media.peerconnection.identity.timeout',
|
||||
'media.peerconnection.turn.disable',
|
||||
'media.peerconnection.use_document_iceservers',
|
||||
'media.peerconnection.video.enabled',
|
||||
'media.navigator.video.enabled',
|
||||
/* 65-beta */
|
||||
'browser.contentblocking.enabled',
|
||||
'browser.urlbar.maxHistoricalSearchSuggestions',
|
||||
/* 67-beta */
|
||||
'app.update.service.enabled',
|
||||
'app.update.silent',
|
||||
'app.update.staging.enabled',
|
||||
'browser.cache.disk.capacity',
|
||||
'browser.cache.disk.smart_size.enabled',
|
||||
'browser.cache.disk.smart_size.first_run',
|
||||
'browser.cache.offline.insecure.enable',
|
||||
'browser.safebrowsing.downloads.remote.url',
|
||||
'browser.safebrowsing.provider.google.reportMalwareMistakeURL',
|
||||
'browser.safebrowsing.provider.google.reportPhishMistakeURL',
|
||||
'browser.safebrowsing.provider.google.reportURL',
|
||||
'browser.safebrowsing.provider.google4.dataSharing.enabled',
|
||||
'browser.safebrowsing.provider.google4.dataSharingURL',
|
||||
'browser.safebrowsing.provider.google4.reportMalwareMistakeURL',
|
||||
'browser.safebrowsing.provider.google4.reportPhishMistakeURL',
|
||||
'browser.safebrowsing.provider.google4.reportURL',
|
||||
'browser.safebrowsing.reportPhishURL',
|
||||
'browser.sessionhistory.max_total_viewers',
|
||||
'browser.urlbar.filter.javascript',
|
||||
'canvas.capturestream.enabled',
|
||||
'dom.imagecapture.enabled',
|
||||
'dom.popup_maximum',
|
||||
'gfx.offscreencanvas.enabled',
|
||||
'javascript.options.shared_memory',
|
||||
'media.gmp-gmpopenh264.autoupdate',
|
||||
'media.gmp-gmpopenh264.enabled',
|
||||
'media.gmp-manager.updateEnabled',
|
||||
'media.gmp-manager.url',
|
||||
'media.gmp-manager.url.override',
|
||||
'media.gmp.trial-create.enabled',
|
||||
'media.gmp-widevinecdm.autoupdate',
|
||||
'network.cookie.leave-secure-alone',
|
||||
'network.cookie.same-site.enabled',
|
||||
'network.dnsCacheEntries',
|
||||
'network.dnsCacheExpiration',
|
||||
'network.proxy.autoconfig_url.include_path',
|
||||
'pdfjs.enableWebGL',
|
||||
'plugin.default.state',
|
||||
'plugin.defaultXpi.state',
|
||||
'plugin.scan.plid.all',
|
||||
'security.data_uri.block_toplevel_data_uri_navigations',
|
||||
'security.insecure_field_warning.contextual.enabled',
|
||||
'security.insecure_password.ui.enabled',
|
||||
'signon.autofillForms.http',
|
||||
'signon.storeWhenAutocompleteOff',
|
||||
'xpinstall.whitelist.required',
|
||||
/* 67-beta: Blocklist, SB & TP cleanup: these were all inactive */
|
||||
'browser.safebrowsing.downloads.remote.block_dangerous',
|
||||
'browser.safebrowsing.downloads.remote.block_dangerous_host',
|
||||
'browser.safebrowsing.blockedURIs.enabled',
|
||||
'browser.safebrowsing.provider.google.gethashURL',
|
||||
'browser.safebrowsing.provider.google.updateURL',
|
||||
'browser.safebrowsing.provider.google4.gethashURL',
|
||||
'browser.safebrowsing.provider.google4.updateURL',
|
||||
'browser.safebrowsing.provider.mozilla.gethashURL',
|
||||
'browser.safebrowsing.provider.mozilla.updateURL',
|
||||
'browser.urlbar.userMadeSearchSuggestionsChoice',
|
||||
'privacy.trackingprotection.annotate_channels',
|
||||
'privacy.trackingprotection.enabled',
|
||||
'privacy.trackingprotection.lower_network_priority',
|
||||
'privacy.trackingprotection.pbmode.enabled',
|
||||
'services.blocklist.addons.collection',
|
||||
'services.blocklist.gfx.collection',
|
||||
'services.blocklist.onecrl.collection',
|
||||
'services.blocklist.plugins.collection',
|
||||
'services.blocklist.update_enabled',
|
||||
'urlclassifier.trackingTable',
|
||||
/* 68-beta */
|
||||
'dom.forms.datetime',
|
||||
'font.blacklist.underline_offset',
|
||||
'font.name.monospace.x-unicode',
|
||||
'font.name.monospace.x-western',
|
||||
'font.name.sans-serif.x-unicode',
|
||||
'font.name.sans-serif.x-western',
|
||||
'font.name.serif.x-unicode',
|
||||
'font.name.serif.x-western',
|
||||
'layout.css.font-loading-api.enabled',
|
||||
'toolkit.telemetry.cachedClientID',
|
||||
/* 69-beta */
|
||||
'plugin.sessionPermissionNow.intervalInMinutes',
|
||||
/* 70-beta */
|
||||
'browser.cache.disk_cache_ssl',
|
||||
'browser.sessionhistory.max_entries',
|
||||
'dom.push.connection.enabled',
|
||||
'dom.push.serverURL',
|
||||
'extensions.getAddons.discovery.api_url',
|
||||
'extensions.htmlaboutaddons.discover.enabled',
|
||||
'extensions.webservice.discoverURL',
|
||||
'intl.locale.requested',
|
||||
'intl.regional_prefs.use_os_locales',
|
||||
'privacy.usercontext.about_newtab_segregation.enabled',
|
||||
'security.insecure_connection_icon.pbmode.enabled',
|
||||
'security.insecure_connection_text.pbmode.enabled',
|
||||
'webgl.dxgl.enabled',
|
||||
/* 71-beta */
|
||||
'media.block-autoplay-until-in-foreground',
|
||||
'middlemouse.paste',
|
||||
/* 75-beta */
|
||||
'browser.search.geoip.url',
|
||||
'browser.search.region',
|
||||
/* 79-beta */
|
||||
'browser.urlbar.usepreloadedtopurls.enabled',
|
||||
/* 82-beta */
|
||||
'dom.IntersectionObserver.enabled',
|
||||
'extensions.screenshots.upload-disabled',
|
||||
'privacy.partition.network_state',
|
||||
'security.ssl3.dhe_rsa_aes_128_sha',
|
||||
'security.ssl3.dhe_rsa_aes_256_sha',
|
||||
/* reset parrot: check your open about:config after running the script */
|
||||
'_user.js.parrot'
|
||||
]
|
||||
|
||||
if("undefined" === typeof(Services)) {
|
||||
alert("about:config needs to be the active tab!");
|
||||
return;
|
||||
}
|
||||
|
||||
let c = 0;
|
||||
for (let i = 0, len = ops.length; i < len; i++) {
|
||||
if (Services.prefs.prefHasUserValue(ops[i])) {
|
||||
Services.prefs.clearUserPref(ops[i]);
|
||||
if (!Services.prefs.prefHasUserValue(ops[i])) {
|
||||
console.log("reset", ops[i]);
|
||||
c++;
|
||||
} else { console.log("failed to reset", ops[i]); }
|
||||
}
|
||||
}
|
||||
|
||||
focus();
|
||||
|
||||
let d = (c==1) ? " pref" : " prefs";
|
||||
if (c > 0) {
|
||||
alert("successfully reset " + c + d + "\n\nfor details check the Browser Console (Ctrl+Shift+J)");
|
||||
} else { alert("nothing to reset"); }
|
||||
|
||||
})();
|
@ -1,132 +0,0 @@
|
||||
/***
|
||||
This will reset the preferences that have been removed completely from the ghacks user.js.
|
||||
|
||||
Last updated: 08-Sept-2018
|
||||
|
||||
For instructions see:
|
||||
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
|
||||
***/
|
||||
|
||||
(function() {
|
||||
let ops = [
|
||||
/* removed in ghacks user.js v52-57 */
|
||||
/* 52-alpha */
|
||||
'browser.search.reset.enabled',
|
||||
'browser.search.reset.whitelist',
|
||||
/* 54-alpha */
|
||||
'browser.migrate.automigrate.enabled',
|
||||
'services.sync.enabled',
|
||||
'webextensions.storage.sync.enabled',
|
||||
'webextensions.storage.sync.serverURL',
|
||||
/* 55-alpha */
|
||||
'dom.keyboardevent.dispatch_during_composition', // default is false anyway
|
||||
'dom.vr.oculus.enabled', // covered by dom.vr.enabled
|
||||
'dom.vr.openvr.enabled', // ditto
|
||||
'dom.vr.osvr.enabled', // ditto
|
||||
'extensions.pocket.api', // covered by extensions.pocket.enabled
|
||||
'extensions.pocket.oAuthConsumerKey', // ditto
|
||||
'extensions.pocket.site', // ditto
|
||||
/* 56-alpha: none */
|
||||
/* 57-alpha */
|
||||
'geo.wifi.xhr.timeout', // covered by geo.enabled
|
||||
'browser.search.geoip.timeout', // ditto
|
||||
'media.webspeech.recognition.enable', // default is false anyway
|
||||
'gfx.layerscope.enabled', // default is false anyway
|
||||
/* 58-alpha */
|
||||
// excluding these e10 settings
|
||||
// 'browser.tabs.remote.autostart',
|
||||
// 'browser.tabs.remote.autostart.2',
|
||||
// 'browser.tabs.remote.force-enable',
|
||||
// 'browser.tabs.remote.separateFileUriProcess',
|
||||
// 'extensions.e10sBlocksEnabling',
|
||||
// 'extensions.webextensions.remote',
|
||||
// 'dom.ipc.processCount',
|
||||
// 'dom.ipc.shims.enabledWarnings',
|
||||
// 'dom.ipc.processCount.extension',
|
||||
// 'dom.ipc.processCount.file',
|
||||
// 'security.sandbox.content.level',
|
||||
// 'dom.ipc.plugins.sandbox-level.default',
|
||||
// 'dom.ipc.plugins.sandbox-level.flash',
|
||||
// 'security.sandbox.logging.enabled',
|
||||
'dom.presentation.controller.enabled',
|
||||
'dom.presentation.discoverable',
|
||||
'dom.presentation.discovery.enabled',
|
||||
'dom.presentation.enabled',
|
||||
'dom.presentation.receiver.enabled',
|
||||
'dom.presentation.session_transport.data_channel.enable',
|
||||
/* 59-alpha */
|
||||
'browser.stopReloadAnimation.enabled',
|
||||
'browser.tabs.insertRelatedAfterCurrent',
|
||||
'browser.tabs.loadDivertedInBackground',
|
||||
'browser.tabs.loadInBackground',
|
||||
'browser.tabs.selectOwnerOnClose',
|
||||
'browser.urlbar.clickSelectsAll',
|
||||
'browser.urlbar.doubleClickSelectsAll',
|
||||
'media.flac.enabled',
|
||||
'media.mediasource.enabled',
|
||||
'media.mediasource.mp4.enabled',
|
||||
'media.mediasource.webm.audio.enabled',
|
||||
'media.mediasource.webm.enabled',
|
||||
'media.mp4.enabled',
|
||||
'media.ogg.enabled',
|
||||
'media.ogg.flac.enabled',
|
||||
'media.opus.enabled',
|
||||
'media.raw.enabled',
|
||||
'media.wave.enabled',
|
||||
'media.webm.enabled',
|
||||
'media.wmf.amd.vp9.enabled',
|
||||
'media.wmf.enabled',
|
||||
'media.wmf.vp9.enabled',
|
||||
'ui.submenuDelay',
|
||||
/* 60-beta - these were all at default anyway */
|
||||
'device.storage.enabled',
|
||||
'general.useragent.compatMode.firefox',
|
||||
'network.dns.blockDotOnion',
|
||||
'network.stricttransportsecurity.preloadlist',
|
||||
'security.block_script_with_wrong_mime',
|
||||
'security.fileuri.strict_origin_policy',
|
||||
'security.sri.enable',
|
||||
/* 61-beta */
|
||||
'browser.laterrun.enabled',
|
||||
'browser.offline-apps.notify',
|
||||
'browser.rights.3.shown',
|
||||
'browser.slowStartup.maxSamples',
|
||||
'browser.slowStartup.notificationDisabled',
|
||||
'browser.slowStartup.samples',
|
||||
'browser.storageManager.enabled',
|
||||
'dom.allow_scripts_to_close_windows',
|
||||
'dom.disable_window_flip',
|
||||
'network.http.fast-fallback-to-IPv4',
|
||||
'offline-apps.quota.warn',
|
||||
'services.blocklist.signing.enforced',
|
||||
/* 62-beta */
|
||||
'browser.urlbar.autoFill.typed',
|
||||
'security.tls.version.fallback-limit',
|
||||
/* reset parrot: check your open about:config after running the script */
|
||||
'_user.js.parrot'
|
||||
]
|
||||
|
||||
if("undefined" === typeof(Services)) {
|
||||
alert("about:config needs to be the active tab!");
|
||||
return;
|
||||
}
|
||||
|
||||
let c = 0;
|
||||
for (let i = 0, len = ops.length; i < len; i++) {
|
||||
if (Services.prefs.prefHasUserValue(ops[i])) {
|
||||
Services.prefs.clearUserPref(ops[i]);
|
||||
if (!Services.prefs.prefHasUserValue(ops[i])) {
|
||||
console.log("reset", ops[i]);
|
||||
c++;
|
||||
} else { console.log("failed to reset", ops[i]); }
|
||||
}
|
||||
}
|
||||
|
||||
focus();
|
||||
|
||||
let d = (c==1) ? " pref" : " prefs";
|
||||
if (c > 0) {
|
||||
alert("successfully reset " + c + d + "\n\nfor details check the Browser Console (Ctrl+Shift+J)");
|
||||
} else { alert("nothing to reset"); }
|
||||
|
||||
})();
|
@ -1,65 +1,11 @@
|
||||
|
||||
/*** ghacks-user.js troubleshooter.js v1.5 ***/
|
||||
/*** arkenfox user.js troubleshooter.js v1.6.2 ***/
|
||||
|
||||
(function() {
|
||||
|
||||
if("undefined" === typeof(Services)) {
|
||||
alert("about:config needs to be the active tab!");
|
||||
return;
|
||||
}
|
||||
if ("undefined" === typeof(Services)) return alert('about:config needs to be the active tab!');
|
||||
|
||||
function getMyList(arr) {
|
||||
let aRet = [];
|
||||
let dummy = 0;
|
||||
for (let i = 0, len = arr.length; i < len; i++) {
|
||||
if (Services.prefs.prefHasUserValue(arr[i])) {
|
||||
dummy = Services.prefs.getPrefType(arr[i]);
|
||||
switch (dummy) {
|
||||
case 32: // string (see https://dxr.mozilla.org/mozilla-central/source/modules/libpref/nsIPrefBranch.idl#31)
|
||||
dummy = Services.prefs.getCharPref(arr[i]);
|
||||
aRet.push({'name':arr[i],'value': dummy,'type':32});
|
||||
break;
|
||||
case 64: // int
|
||||
dummy = Services.prefs.getIntPref(arr[i]);
|
||||
aRet.push({'name':arr[i],'value': dummy,'type':64});
|
||||
break;
|
||||
case 128: // boolean
|
||||
dummy = Services.prefs.getBoolPref(arr[i]);
|
||||
aRet.push({'name':arr[i],'value': dummy,'type':128});
|
||||
break;
|
||||
default:
|
||||
console.log("error detecting pref-type for '"+arr[i]+"' !");
|
||||
}
|
||||
}
|
||||
}
|
||||
return aRet;
|
||||
}
|
||||
|
||||
function reapply(arr) {
|
||||
for (let i = 0, len = arr.length; i < len; i++) {
|
||||
switch (arr[i].type) {
|
||||
case 32: // string
|
||||
Services.prefs.setCharPref(arr[i].name, arr[i].value);
|
||||
break;
|
||||
case 64: // int
|
||||
Services.prefs.setIntPref(arr[i].name, arr[i].value);
|
||||
break;
|
||||
case 128: // boolean
|
||||
Services.prefs.setBoolPref(arr[i].name, arr[i].value);
|
||||
break;
|
||||
default:
|
||||
console.log("error re-appyling value for '"+arr[i].name+"' !"); // should never happen
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function myreset(arr) {
|
||||
for (let i = 0, len = arr.length; i < len; i++) {
|
||||
Services.prefs.clearUserPref(arr[i].name);
|
||||
}
|
||||
}
|
||||
|
||||
let ops = [
|
||||
const aPREFS = [
|
||||
|
||||
/* known culprits */
|
||||
'network.cookie.cookieBehavior',
|
||||
@ -71,7 +17,6 @@
|
||||
|
||||
/* Storage + Cache */
|
||||
'browser.cache.offline.enable',
|
||||
'dom.indexedDB.enabled',
|
||||
'dom.storage.enabled',
|
||||
'browser.storageManager.enabled',
|
||||
'dom.storageManager.enabled',
|
||||
@ -82,7 +27,6 @@
|
||||
'dom.push.enabled',
|
||||
'dom.push.serverURL',
|
||||
'dom.serviceWorkers.enabled',
|
||||
'dom.workers.enabled',
|
||||
'dom.webnotifications.enabled',
|
||||
'dom.webnotifications.serviceworker.enabled',
|
||||
|
||||
@ -115,7 +59,8 @@
|
||||
|
||||
/* Audio + Video */
|
||||
'dom.webaudio.enabled',
|
||||
'media.autoplay.enabled',
|
||||
'media.autoplay.default', // FF63+
|
||||
'media.autoplay.blocking_policy', // FF78+
|
||||
|
||||
/* Forms */
|
||||
'browser.formfill.enable',
|
||||
@ -125,7 +70,6 @@
|
||||
/* HTTPS */
|
||||
'security.cert_pinning.enforcement_level',
|
||||
'security.family_safety.mode',
|
||||
'security.mixed_content.use_hsts',
|
||||
'security.OCSP.require',
|
||||
'security.pki.sha1_enforcement_level',
|
||||
'security.ssl.require_safe_negotiation',
|
||||
@ -152,65 +96,118 @@
|
||||
'dom.popup_maximum',
|
||||
'layout.css.visited_links_enabled',
|
||||
'mathml.disabled',
|
||||
'network.auth.subresource-img-cross-origin-http-auth-allow',
|
||||
'network.auth.subresource-http-auth-allow',
|
||||
'network.http.redirection-limit',
|
||||
'network.protocol-handler.external.ms-windows-store',
|
||||
'privacy.trackingprotection.enabled',
|
||||
'security.data_uri.block_toplevel_data_uri_navigations',
|
||||
'privacy.window.name.update.enabled', // FF82+
|
||||
|
||||
'last.one.without.comma'
|
||||
]
|
||||
|
||||
// any runtime-set pref that everyone will have and that can be safely reset
|
||||
const oFILLER = { type: 64, name: 'app.update.lastUpdateTime.browser-cleanup-thumbnails', value: 1580000000 };
|
||||
|
||||
// reset prefs that set the same value as FFs default value
|
||||
let aTEMP = getMyList(ops);
|
||||
myreset(aTEMP);
|
||||
reapply(aTEMP);
|
||||
function getMyList(arr) {
|
||||
const aRet = [];
|
||||
for (const sPname of arr) {
|
||||
if (Services.prefs.prefHasUserValue(sPname)) {
|
||||
const ptype = Services.prefs.getPrefType(sPname);
|
||||
switch (ptype) {
|
||||
case 32: // string (see https://dxr.mozilla.org/mozilla-central/source/modules/libpref/nsIPrefBranch.idl#31)
|
||||
aRet.push({'type':ptype,'name':sPname,'value':Services.prefs.getCharPref(sPname)});
|
||||
break;
|
||||
case 64: // int
|
||||
aRet.push({'type':ptype,'name':sPname,'value':Services.prefs.getIntPref(sPname)});
|
||||
break;
|
||||
case 128: // boolean
|
||||
aRet.push({'type':ptype,'name':sPname,'value':Services.prefs.getBoolPref(sPname)});
|
||||
break;
|
||||
default:
|
||||
console.log("error detecting pref-type for '"+sPname+"' !");
|
||||
}
|
||||
}
|
||||
}
|
||||
return aRet;
|
||||
}
|
||||
|
||||
const aBACKUP = getMyList(ops);
|
||||
//console.log(aBACKUP.length, "user-set prefs from our list detected and their values stored.");
|
||||
function reapply(arr) {
|
||||
for (const oPref of arr) {
|
||||
switch (oPref.type) {
|
||||
case 32: // string
|
||||
Services.prefs.setCharPref(oPref.name, oPref.value);
|
||||
break;
|
||||
case 64: // int
|
||||
Services.prefs.setIntPref(oPref.name, oPref.value);
|
||||
break;
|
||||
case 128: // boolean
|
||||
Services.prefs.setBoolPref(oPref.name, oPref.value);
|
||||
break;
|
||||
default:
|
||||
console.log("error re-appyling value for '"+oPref.name+"' !"); // should never happen
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
let myArr = aBACKUP;
|
||||
let found = false;
|
||||
let aDbg = [];
|
||||
focus();
|
||||
myreset(aBACKUP); // reset all detected prefs
|
||||
if (confirm("all detected prefs reset.\n\n!! KEEP THIS PROMPT OPEN AND TEST THE SITE IN ANOTHER TAB !!\n\nIF the problem still exists, this script can't help you - click cancel to re-apply your values and exit.\n\nClick OK if your problem is fixed.")) {
|
||||
aDbg = myArr;
|
||||
reapply(aBACKUP);
|
||||
myreset(myArr.slice(0, parseInt(myArr.length/2)));
|
||||
while (myArr.length >= 2) {
|
||||
function myreset(arr) {
|
||||
for (const oPref of arr) Services.prefs.clearUserPref(oPref.name);
|
||||
}
|
||||
|
||||
function resetAllMatchingDefault(arr) {
|
||||
const aTmp = getMyList(arr);
|
||||
myreset(aTmp);
|
||||
reapply(aTmp);
|
||||
}
|
||||
|
||||
function _main(aALL) {
|
||||
const _h = (arr) => Math.ceil(arr.length/2);
|
||||
|
||||
let aTmp = aALL, aDbg = aALL;
|
||||
reapply(aALL);
|
||||
myreset(aTmp.slice(0, _h(aTmp)));
|
||||
while (aTmp.length) {
|
||||
alert("NOW TEST AGAIN !");
|
||||
if (confirm("if the problem still exists click OK, otherwise click cancel.")) {
|
||||
myArr = myArr.slice(parseInt(myArr.length/2));
|
||||
if (myArr.length == 1) {
|
||||
alert("The problem is caused by more than 1 pref !\n\nNarrowed it down to "+ aDbg.length.toString() +" prefs, check the console ...");
|
||||
break;
|
||||
}
|
||||
aTmp = aTmp.slice(_h(aTmp));
|
||||
} else {
|
||||
myArr = myArr.slice(0, parseInt(myArr.length/2));
|
||||
aDbg = myArr;
|
||||
if (myArr.length == 1) { found = true; break; }
|
||||
aTmp = aTmp.slice(0, _h(aTmp));
|
||||
aDbg = aTmp; // update narrowed down list
|
||||
if (aDbg.length == 1) break;
|
||||
}
|
||||
reapply(aBACKUP);
|
||||
myreset(myArr.slice(0, parseInt(myArr.length/2))); // reset half of the remaining prefs
|
||||
reapply(aALL);
|
||||
myreset(aTmp.slice(0, _h(aTmp))); // reset half of the remaining prefs
|
||||
}
|
||||
reapply(aBACKUP);
|
||||
reapply(aALL);
|
||||
|
||||
if (aDbg.length == 1) return alert("narrowed it down to:\n\n"+aDbg[0].name+"\n");
|
||||
if (aDbg.length == aALL.length) {
|
||||
let msg = "Failed to narrow it down beyond the initial "+aALL.length+" prefs. The problem is most likely caused by at least 2 prefs!\n\n";
|
||||
msg += "Either those prefs are too far apart in the list or there are exactly 2 culprits and they just happen to be at the wrong place.\n\n";
|
||||
msg += "In case it's the latter, the script can add a dummy pref and you can try again - Try again?";
|
||||
if (confirm(msg)) return _main([...aALL, oFILLER]);
|
||||
} else if (aDbg.length > 10 && confirm("Narrowed it down to "+aDbg.length+" prefs. Try narrowing it down further?")) {
|
||||
return _main(aDbg.reverse());
|
||||
}
|
||||
else {
|
||||
reapply(aBACKUP);
|
||||
|
||||
alert("Narrowed it down to "+ aDbg.length.toString() +" prefs, check the console ...");
|
||||
console.log("The problem is caused by 2 or more of these prefs:");
|
||||
for (const oPref of aDbg) console.log(oPref.name);
|
||||
}
|
||||
|
||||
|
||||
resetAllMatchingDefault(aPREFS); // reset user-set prefs matching FFs default value
|
||||
|
||||
const aBAK = getMyList(aPREFS);
|
||||
//console.log(aBAK.length, "user-set prefs from our list detected and their values stored.");
|
||||
|
||||
focus();
|
||||
myreset(aBAK);
|
||||
if (!confirm("all detected prefs reset.\n\n!! KEEP THIS PROMPT OPEN AND TEST THE SITE IN ANOTHER TAB !!\n\nIF the problem still exists, this script can't help you - click cancel to re-apply your values and exit.\n\nClick OK if your problem is fixed.")) {
|
||||
reapply(aBAK);
|
||||
return;
|
||||
}
|
||||
|
||||
if (found) {
|
||||
alert("narrowed it down to:\n\n"+myArr[0].name+"\n");
|
||||
myreset(myArr); // reset the culprit
|
||||
}
|
||||
else {
|
||||
console.log("the problem is caused by a combination of the following prefs:");
|
||||
for (let i = 0, len = aDbg.length; i < len; i++) {
|
||||
console.log(aDbg[i].name);
|
||||
}
|
||||
}
|
||||
_main(aBAK);
|
||||
|
||||
})();
|
||||
|
66
updater.bat
66
updater.bat
@ -1,12 +1,12 @@
|
||||
@ECHO OFF & SETLOCAL EnableDelayedExpansion
|
||||
TITLE ghacks user.js updater
|
||||
TITLE arkenfox user.js updater
|
||||
|
||||
REM ## ghacks-user.js updater for Windows
|
||||
REM ## arkenfox user.js updater for Windows
|
||||
REM ## author: @claustromaniac
|
||||
REM ## version: 4.6
|
||||
REM ## instructions: https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.3-Updater-Scripts
|
||||
REM ## version: 4.12
|
||||
REM ## instructions: https://github.com/arkenfox/user.js/wiki/3.3-Updater-Scripts
|
||||
|
||||
SET v=4.7
|
||||
SET v=4.12
|
||||
|
||||
VERIFY ON
|
||||
CD /D "%~dp0"
|
||||
@ -22,6 +22,8 @@ IF /I "%~1"=="-multioverrides" (SET _multi=1)
|
||||
IF /I "%~1"=="-merge" (SET _merge=1)
|
||||
IF /I "%~1"=="-updatebatch" (SET _updateb=1)
|
||||
IF /I "%~1"=="-singlebackup" (SET _singlebackup=1)
|
||||
IF /I "%~1"=="-esr" (SET _esr=1)
|
||||
IF /I "%~1"=="-rfpalts" (SET _rfpalts=1)
|
||||
SHIFT
|
||||
GOTO parse
|
||||
:endparse
|
||||
@ -50,7 +52,7 @@ IF DEFINED _updateb (
|
||||
REM Uncomment the next line and comment out the PowerShell call for testing.
|
||||
REM COPY /B /Y "!_myname!.bat" "[updated]!_myname!.bat" >nul
|
||||
(
|
||||
PowerShell -Command "(New-Object Net.WebClient).DownloadFile('https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/updater.bat', '[updated]!_myname!.bat')"
|
||||
PowerShell -Command "(New-Object Net.WebClient).DownloadFile('https://raw.githubusercontent.com/arkenfox/user.js/master/updater.bat', '[updated]!_myname!.bat')"
|
||||
) >nul 2>&1
|
||||
IF EXIST "[updated]!_myname!.bat" (
|
||||
START /min CMD /C "[updated]!_myname!.bat" !_myparams!
|
||||
@ -98,7 +100,10 @@ IF NOT EXIST user.js (
|
||||
)
|
||||
:exitloop
|
||||
IF NOT "!_name!"=="" (
|
||||
IF /I NOT "!_name!"=="!_name:ghacks=!" (
|
||||
SET "_tempvar="
|
||||
IF /I NOT "!_name!"=="!_name:ghacks=!" SET _tempvar=1
|
||||
IF /I NOT "!_name!"=="!_name:arkenfox=!" SET _tempvar=1
|
||||
IF !_tempvar! EQU 1 (
|
||||
CALL :message "!_name! !_version:~2!,!_date!"
|
||||
) ELSE (CALL :message "Current user.js version not recognised.")
|
||||
) ELSE (CALL :message "Current user.js version not recognised.")
|
||||
@ -106,7 +111,7 @@ IF NOT EXIST user.js (
|
||||
ECHO:
|
||||
IF NOT DEFINED _ua (
|
||||
CALL :message "This batch should be run from your Firefox profile directory."
|
||||
ECHO: It will download the latest version of ghacks user.js from github and then
|
||||
ECHO: It will download the latest version of arkenfox user.js from github and then
|
||||
CALL :message "append any of your own changes from user-overrides.js to it."
|
||||
CALL :message "Visit the wiki for more detailed information."
|
||||
ECHO:
|
||||
@ -128,9 +133,17 @@ IF DEFINED _log (
|
||||
IF EXIST user.js.new (DEL /F "user.js.new")
|
||||
CALL :message "Retrieving latest user.js file from github repository..."
|
||||
(
|
||||
PowerShell -Command "(New-Object Net.WebClient).DownloadFile('https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/user.js', 'user.js.new')"
|
||||
PowerShell -Command "(New-Object Net.WebClient).DownloadFile('https://raw.githubusercontent.com/arkenfox/user.js/master/user.js', 'user.js.new')"
|
||||
) >nul 2>&1
|
||||
IF EXIST user.js.new (
|
||||
IF DEFINED _rfpalts (
|
||||
CALL :message "Activating RFP Alternatives section..."
|
||||
CALL :activate user.js.new "[SETUP-non-RFP]"
|
||||
)
|
||||
IF DEFINED _esr (
|
||||
CALL :message "Activating ESR section..."
|
||||
CALL :activate user.js.new ".x still uses all the following prefs"
|
||||
)
|
||||
IF DEFINED _multi (
|
||||
FORFILES /P user.js-overrides /M *.js >nul 2>&1
|
||||
IF NOT ERRORLEVEL 1 (
|
||||
@ -196,7 +209,7 @@ IF NOT DEFINED _log (
|
||||
)
|
||||
EXIT /B
|
||||
|
||||
REM ########### Message Function ###########
|
||||
::::::::::::::: Message :::::::::::::::
|
||||
:message
|
||||
SETLOCAL DisableDelayedExpansion
|
||||
IF NOT "2"=="%_log%" (ECHO:)
|
||||
@ -205,7 +218,28 @@ IF NOT "2"=="%_log%" (ECHO:)
|
||||
ENDLOCAL
|
||||
GOTO :EOF
|
||||
|
||||
REM ############ Merge function ############
|
||||
::::::::::::::: Activate Section :::::::::::::::
|
||||
:activate
|
||||
:: arg1 = file
|
||||
:: arg2 = line substring
|
||||
SETLOCAL DisableDelayedExpansion
|
||||
(
|
||||
FOR /F "tokens=1,* delims=:" %%G IN ('FINDSTR /N "^" "%~1"') DO (
|
||||
SET "_temp=%%H"
|
||||
SETLOCAL EnableDelayedExpansion
|
||||
IF "!_temp:%~2=!"=="!_temp!" (
|
||||
ENDLOCAL & ECHO:%%H
|
||||
) ELSE (
|
||||
ECHO://!_temp:~2!
|
||||
ENDLOCAL
|
||||
)
|
||||
)
|
||||
)>updatertempfile
|
||||
MOVE /Y updatertempfile "%~1" >nul
|
||||
ENDLOCAL
|
||||
GOTO :EOF
|
||||
|
||||
::::::::::::::: Merge :::::::::::::::
|
||||
:merge
|
||||
SETLOCAL DisableDelayedExpansion
|
||||
FOR /F tokens^=2^,^*^ delims^=^'^" %%G IN ('FINDSTR /R /C:"^user_pref[ ]*\([ ]*[\"'].*[\"'][ ]*,.*\)[ ]*;" "%~1"') DO (SET "[%%G]=%%H")
|
||||
@ -244,11 +278,13 @@ MOVE /Y updatertempfile "%~1" >nul
|
||||
ENDLOCAL
|
||||
GOTO :EOF
|
||||
|
||||
REM ############### Help ##################
|
||||
::::::::::::::: Help :::::::::::::::
|
||||
:showhelp
|
||||
MODE 80,46
|
||||
MODE 80,54
|
||||
CLS
|
||||
CALL :message "Available arguments (case-insensitive):"
|
||||
CALL :message " -esr"
|
||||
ECHO: Activate ESR related preferences
|
||||
CALL :message " -log"
|
||||
ECHO: Write the console output to a logfile (user.js-update-log.txt)
|
||||
CALL :message " -logP"
|
||||
@ -272,7 +308,9 @@ ECHO: Run without user input.
|
||||
CALL :message " -singleBackup"
|
||||
ECHO: Use a single backup file and overwrite it on new updates, instead of
|
||||
ECHO: cumulative backups. This was the default behaviour before v4.3.
|
||||
CALL :message " -updatebatch"
|
||||
CALL :message " -rfpAlts"
|
||||
ECHO: Activate RFP Alternatives section
|
||||
CALL :message " -updateBatch"
|
||||
ECHO: Update the script itself on execution, before the normal routine.
|
||||
CALL :message ""
|
||||
PAUSE
|
||||
|
456
updater.sh
456
updater.sh
@ -1,129 +1,399 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
### ghacks-user.js updater for Mac/Linux
|
||||
## author: @overdodactyl, @ema-pe
|
||||
## version: 1.4
|
||||
## arkenfox user.js updater for macOS and Linux
|
||||
|
||||
## DON'T GO HIGHER THAN VERSION x.9 !! ( because of ASCII comparison in check_for_update() )
|
||||
## version: 2.8
|
||||
## Author: Pat Johnson (@overdodactyl)
|
||||
## Additional contributors: @earthlng, @ema-pe, @claustromaniac
|
||||
|
||||
ghacksjs="https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/user.js"
|
||||
updater="https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/updater.sh"
|
||||
update_pref=${1:--ask}
|
||||
## DON'T GO HIGHER THAN VERSION x.9 !! ( because of ASCII comparison in update_updater() )
|
||||
|
||||
currdir=$(pwd)
|
||||
readonly CURRDIR=$(pwd)
|
||||
|
||||
DOWNLOAD_TO_STDOUT="curl -s"
|
||||
DOWNLOAD_TO_FILE="curl -O"
|
||||
|
||||
# Use wget if curl is not available.
|
||||
if [[ -z $(command -v "curl") ]]; then
|
||||
DOWNLOAD_TO_STDOUT="wget --quiet --output-document=-"
|
||||
DOWNLOAD_TO_FILE="wget"
|
||||
fi
|
||||
|
||||
## get the full path of this script (readlink for Linux, greadlink for Mac with coreutils installed)
|
||||
sfp=$(readlink -f "${BASH_SOURCE[0]}" 2>/dev/null || greadlink -f "${BASH_SOURCE[0]}" 2>/dev/null)
|
||||
[ -z "$sfp" ] && sfp=${BASH_SOURCE[0]}
|
||||
readonly SCRIPT_DIR=$(dirname "${sfp}")
|
||||
|
||||
## fallback for Macs without coreutils
|
||||
if [ -z "$sfp" ]; then sfp=${BASH_SOURCE[0]}; fi
|
||||
|
||||
## change directory to the Firefox profile directory
|
||||
cd "$(dirname "${sfp}")"
|
||||
#########################
|
||||
# Base variables #
|
||||
#########################
|
||||
|
||||
## Used to check if a new version of updater.sh is available
|
||||
update_available="no"
|
||||
check_for_update () {
|
||||
online_version="$($DOWNLOAD_TO_STDOUT ${updater} | sed -n '5 s/.*[[:blank:]]\([[:digit:]]*\.[[:digit:]]*\)/\1/p')"
|
||||
path_to_script="$(dirname "${sfp}")/updater.sh"
|
||||
current_version="$(sed -n '5 s/.*[[:blank:]]\([[:digit:]]*\.[[:digit:]]*\)/\1/p' "$path_to_script")"
|
||||
if [[ "$current_version" < "$online_version" ]]; then
|
||||
update_available="yes"
|
||||
# Colors used for printing
|
||||
RED='\033[0;31m'
|
||||
BLUE='\033[0;34m'
|
||||
BBLUE='\033[1;34m'
|
||||
GREEN='\033[0;32m'
|
||||
ORANGE='\033[0;33m'
|
||||
CYAN='\033[0;36m'
|
||||
NC='\033[0m' # No Color
|
||||
|
||||
# Argument defaults
|
||||
UPDATE='check'
|
||||
CONFIRM='yes'
|
||||
OVERRIDE='user-overrides.js'
|
||||
BACKUP='multiple'
|
||||
COMPARE=false
|
||||
SKIPOVERRIDE=false
|
||||
VIEW=false
|
||||
PROFILE_PATH=false
|
||||
ESR=false
|
||||
|
||||
# Download method priority: curl -> wget
|
||||
DOWNLOAD_METHOD=''
|
||||
if [[ $(command -v 'curl') ]]; then
|
||||
DOWNLOAD_METHOD='curl --max-redirs 3 -so'
|
||||
elif [[ $(command -v 'wget') ]]; then
|
||||
DOWNLOAD_METHOD='wget --max-redirect 3 --quiet -O'
|
||||
else
|
||||
echo -e "${RED}This script requires curl or wget.\nProcess aborted${NC}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
show_banner () {
|
||||
echo -e "${BBLUE}
|
||||
############################################################################
|
||||
#### ####
|
||||
#### arkenfox user.js ####
|
||||
#### Hardening the Privacy and Security Settings of Firefox ####
|
||||
#### Maintained by @Thorin-Oakenpants and @earthlng ####
|
||||
#### Updater for macOS and Linux by @overdodactyl ####
|
||||
#### ####
|
||||
############################################################################"
|
||||
echo -e "${NC}\n"
|
||||
echo -e "Documentation for this script is available here: ${CYAN}https://github.com/arkenfox/user.js/wiki/3.3-Updater-Scripts${NC}\n"
|
||||
}
|
||||
|
||||
## Used to backup the current script, and download and execute the latest version of updater.sh
|
||||
update_script () {
|
||||
echo -e "This script will be backed up and the latest version of updater.sh will be executed.\n"
|
||||
mv updater.sh "updater.sh.backup.$(date +"%Y-%m-%d_%H%M")"
|
||||
$DOWNLOAD_TO_FILE ${updater} && echo -e "\nThe latest updater script has been downloaded\n"
|
||||
#########################
|
||||
# Arguments #
|
||||
#########################
|
||||
|
||||
# make new file executable
|
||||
chmod +x updater.sh
|
||||
|
||||
# execute new updater script
|
||||
./updater.sh -donotupdate
|
||||
|
||||
# exit script
|
||||
usage() {
|
||||
echo
|
||||
echo -e "${BLUE}Usage: $0 [-bcdehlnrsuv] [-p PROFILE] [-o OVERRIDE]${NC}" 1>&2 # Echo usage string to standard error
|
||||
echo -e "
|
||||
Optional Arguments:
|
||||
-h Show this help message and exit.
|
||||
-p PROFILE Path to your Firefox profile (if different than the dir of this script)
|
||||
IMPORTANT: If the path contains spaces, wrap the entire argument in quotes.
|
||||
-l Choose your Firefox profile from a list
|
||||
-u Update updater.sh and execute silently. Do not seek confirmation.
|
||||
-d Do not look for updates to updater.sh.
|
||||
-s Silently update user.js. Do not seek confirmation.
|
||||
-b Only keep one backup of each file.
|
||||
-c Create a diff file comparing old and new user.js within userjs_diffs.
|
||||
-o OVERRIDE Filename or path to overrides file (if different than user-overrides.js).
|
||||
If used with -p, paths should be relative to PROFILE or absolute paths
|
||||
If given a directory, all files inside will be appended recursively.
|
||||
You can pass multiple files or directories by passing a comma separated list.
|
||||
Note: If a directory is given, only files inside ending in the extension .js are appended
|
||||
IMPORTANT: Do not add spaces between files/paths. Ex: -o file1.js,file2.js,dir1
|
||||
IMPORTANT: If any file/path contains spaces, wrap the entire argument in quotes.
|
||||
Ex: -o \"override folder\"
|
||||
-n Do not append any overrides, even if user-overrides.js exists.
|
||||
-v Open the resulting user.js file.
|
||||
-r Only download user.js to a temporary file and open it.
|
||||
-e Activate ESR related preferences."
|
||||
echo
|
||||
exit 1
|
||||
}
|
||||
|
||||
#########################
|
||||
# File Handling #
|
||||
#########################
|
||||
|
||||
main () {
|
||||
## create backup folder if it doesn't exist
|
||||
mkdir -p userjs_backups;
|
||||
# Download files
|
||||
download_file () { # expects URL as argument ($1)
|
||||
declare -r tf=$(mktemp)
|
||||
|
||||
echo -e "\nThis script should be run from your Firefox profile directory.\n"
|
||||
$DOWNLOAD_METHOD "${tf}" "$1" && echo "$tf" || echo '' # return the temp-filename or empty string on error
|
||||
}
|
||||
|
||||
echo -e "Updating the user.js for Firefox profile:\n$(pwd)\n"
|
||||
|
||||
if [ -e user.js ]; then
|
||||
echo "Your current user.js file for this profile will be backed up and the latest ghacks version from github will take its place."
|
||||
echo -e "\nIf currently using the ghacks user.js, please compare versions:"
|
||||
echo " Available online: $($DOWNLOAD_TO_STDOUT ${ghacksjs} | sed -n '4p')"
|
||||
echo " Currently using: $(sed -n '4p' user.js)"
|
||||
open_file () { # expects one argument: file_path
|
||||
if [ "$(uname)" == 'Darwin' ]; then
|
||||
open "$1"
|
||||
elif [ "$(uname -s | cut -c -5)" == "Linux" ]; then
|
||||
xdg-open "$1"
|
||||
else
|
||||
echo "A user.js file does not exist in this profile. If you continue, the latest ghacks version from github will be downloaded."
|
||||
echo -e "${RED}Error: Sorry, opening files is not supported for your OS.${NC}"
|
||||
fi
|
||||
}
|
||||
|
||||
readIniFile () { # expects one argument: absolute path of profiles.ini
|
||||
declare -r inifile="$1"
|
||||
declare -r tfile=$(mktemp)
|
||||
|
||||
if [ $(grep '^\[Profile' "$inifile" | wc -l) == "1" ]; then ### only 1 profile found
|
||||
grep '^\[Profile' -A 4 "$inifile" | grep -v '^\[Profile' > $tfile
|
||||
else
|
||||
grep -E -v '^\[General\]|^StartWithLastProfile=|^IsRelative=' "$inifile"
|
||||
echo ''
|
||||
read -p 'Select the profile number ( 0 for Profile0, 1 for Profile1, etc ) : ' -r
|
||||
echo -e "\n"
|
||||
if [[ $REPLY =~ ^(0|[1-9][0-9]*)$ ]]; then
|
||||
grep '^\[Profile'${REPLY} -A 4 "$inifile" | grep -v '^\[Profile'${REPLY} > $tfile
|
||||
if [[ "$?" != "0" ]]; then
|
||||
echo "Profile${REPLY} does not exist!" && exit 1
|
||||
fi
|
||||
else
|
||||
echo "Invalid selection!" && exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
echo -e "\nIf a user-overrides.js file exists in this profile, it will be appended to the user.js.\n"
|
||||
declare -r profpath=$(grep '^Path=' $tfile)
|
||||
declare -r pathisrel=$(grep '^IsRelative=' $tfile)
|
||||
|
||||
read -p "Continue Y/N? " -n 1 -r
|
||||
rm "$tfile"
|
||||
|
||||
# update global variable
|
||||
if [[ ${pathisrel#*=} == "1" ]]; then
|
||||
PROFILE_PATH="$(dirname "$inifile")/${profpath#*=}"
|
||||
else
|
||||
PROFILE_PATH="${profpath#*=}"
|
||||
fi
|
||||
}
|
||||
|
||||
getProfilePath () {
|
||||
declare -r f1=~/Library/Application\ Support/Firefox/profiles.ini
|
||||
declare -r f2=~/.mozilla/firefox/profiles.ini
|
||||
|
||||
if [ "$PROFILE_PATH" = false ]; then
|
||||
PROFILE_PATH="$SCRIPT_DIR"
|
||||
elif [ "$PROFILE_PATH" = 'list' ]; then
|
||||
local ini=''
|
||||
if [[ -f "$f1" ]]; then
|
||||
ini="$f1"
|
||||
elif [[ -f "$f2" ]]; then
|
||||
ini="$f2"
|
||||
else
|
||||
echo -e "${RED}Error: Sorry, -l is not supported for your OS${NC}"
|
||||
exit 1
|
||||
fi
|
||||
readIniFile "$ini" # updates PROFILE_PATH or exits on error
|
||||
#else
|
||||
# PROFILE_PATH already set by user with -p
|
||||
fi
|
||||
}
|
||||
|
||||
#########################
|
||||
# Update updater.sh #
|
||||
#########################
|
||||
|
||||
# Returns the version number of a updater.sh file
|
||||
get_updater_version () {
|
||||
echo $(sed -n '5 s/.*[[:blank:]]\([[:digit:]]*\.[[:digit:]]*\)/\1/p' "$1")
|
||||
}
|
||||
|
||||
# Update updater.sh
|
||||
# Default: Check for update, if available, ask user if they want to execute it
|
||||
# Args:
|
||||
# -d: New version will not be looked for and update will not occur
|
||||
# -u: Check for update, if available, execute without asking
|
||||
update_updater () {
|
||||
if [ $UPDATE = 'no' ]; then
|
||||
return 0 # User signified not to check for updates
|
||||
fi
|
||||
|
||||
declare -r tmpfile="$(download_file 'https://raw.githubusercontent.com/arkenfox/user.js/master/updater.sh')"
|
||||
[ -z "${tmpfile}" ] && echo -e "${RED}Error! Could not download updater.sh${NC}" && return 1 # check if download failed
|
||||
|
||||
if [[ $(get_updater_version "${SCRIPT_DIR}/updater.sh") < $(get_updater_version "${tmpfile}") ]]; then
|
||||
if [ $UPDATE = 'check' ]; then
|
||||
echo -e "There is a newer version of updater.sh available. ${RED}Update and execute Y/N?${NC}"
|
||||
read -p "" -n 1 -r
|
||||
echo -e "\n\n"
|
||||
|
||||
if [[ $REPLY =~ ^[Yy]$ ]]; then
|
||||
if [ -e user.js ]; then
|
||||
# backup current user.js
|
||||
bakfile="userjs_backups/user.js.backup.$(date +"%Y-%m-%d_%H%M")"
|
||||
mv user.js "${bakfile}" && echo "Your previous user.js file was backed up: ${bakfile}"
|
||||
fi
|
||||
|
||||
# download latest ghacks user.js
|
||||
echo "downloading latest ghacks user.js file"
|
||||
$DOWNLOAD_TO_FILE ${ghacksjs} && echo "ghacks user.js has been downloaded"
|
||||
|
||||
if [ -e user-overrides.js ]; then
|
||||
echo "user-overrides.js file found"
|
||||
cat user-overrides.js >> user.js && echo "user-overrides.js has been appended to user.js"
|
||||
[[ $REPLY =~ ^[Nn]$ ]] && return 0 # Update available, but user chooses not to update
|
||||
fi
|
||||
else
|
||||
echo "Process aborted"
|
||||
return 0 # No update available
|
||||
fi
|
||||
|
||||
## change directory back to the original working directory
|
||||
cd "${currdir}"
|
||||
mv "${tmpfile}" "${SCRIPT_DIR}/updater.sh"
|
||||
chmod u+x "${SCRIPT_DIR}/updater.sh"
|
||||
"${SCRIPT_DIR}/updater.sh" "$@" -d
|
||||
exit 0
|
||||
}
|
||||
|
||||
|
||||
update_pref="$(echo $update_pref | tr '[A-Z]' '[a-z]')"
|
||||
if [ $update_pref = "-donotupdate" ]; then
|
||||
main
|
||||
#########################
|
||||
# Update user.js #
|
||||
#########################
|
||||
|
||||
# Returns version number of a user.js file
|
||||
get_userjs_version () {
|
||||
[ -e $1 ] && echo "$(sed -n '4p' "$1")" || echo "Not detected."
|
||||
}
|
||||
|
||||
add_override () {
|
||||
input=$1
|
||||
if [ -f "$input" ]; then
|
||||
echo "" >> user.js
|
||||
cat "$input" >> user.js
|
||||
echo -e "Status: ${GREEN}Override file appended:${NC} ${input}"
|
||||
elif [ -d "$input" ]; then
|
||||
SAVEIFS=$IFS
|
||||
IFS=$'\n\b' # Set IFS
|
||||
FILES="${input}"/*.js
|
||||
for f in $FILES
|
||||
do
|
||||
add_override "$f"
|
||||
done
|
||||
IFS=$SAVEIFS # restore $IFS
|
||||
else
|
||||
check_for_update
|
||||
if [ $update_available = "no" ]; then
|
||||
main
|
||||
else
|
||||
## there is an update available
|
||||
if [ $update_pref = "-update" ]; then
|
||||
## update without asking
|
||||
update_script
|
||||
else
|
||||
read -p "There is a newer version of updater.sh available. Download and execute? Y/N? " -n 1 -r
|
||||
echo -e "\n\n"
|
||||
if [[ $REPLY =~ ^[Yy]$ ]]; then
|
||||
update_script
|
||||
else
|
||||
main
|
||||
echo -e "${ORANGE}Warning: Could not find override file:${NC} ${input}"
|
||||
fi
|
||||
}
|
||||
|
||||
remove_comments () { # expects 2 arguments: from-file and to-file
|
||||
sed -e 's/^[[:space:]]*\/\/.*$//' -e '/^\/\*/,/\*\//d' -e '/^[[:space:]]*$/d' -e 's/);[[:space:]]*\/\/.*/);/' "$1" > "$2"
|
||||
}
|
||||
|
||||
# Applies latest version of user.js and any custom overrides
|
||||
update_userjs () {
|
||||
declare -r newfile="$(download_file 'https://raw.githubusercontent.com/arkenfox/user.js/master/user.js')"
|
||||
[ -z "${newfile}" ] && echo -e "${RED}Error! Could not download user.js${NC}" && return 1 # check if download failed
|
||||
|
||||
echo -e "Please observe the following information:
|
||||
Firefox profile: ${ORANGE}$(pwd)${NC}
|
||||
Available online: ${ORANGE}$(get_userjs_version $newfile)${NC}
|
||||
Currently using: ${ORANGE}$(get_userjs_version user.js)${NC}\n\n"
|
||||
|
||||
if [ $CONFIRM = 'yes' ]; then
|
||||
echo -e "This script will update to the latest user.js file and append any custom configurations from user-overrides.js. ${RED}Continue Y/N? ${NC}"
|
||||
read -p "" -n 1 -r
|
||||
echo -e "\n"
|
||||
if [[ $REPLY =~ ^[Nn]$ ]]; then
|
||||
echo -e "${RED}Process aborted${NC}"
|
||||
rm $newfile
|
||||
return 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# Copy a version of user.js to diffs folder for later comparison
|
||||
if [ "$COMPARE" = true ]; then
|
||||
mkdir -p userjs_diffs
|
||||
cp user.js userjs_diffs/past_user.js &>/dev/null
|
||||
fi
|
||||
|
||||
# backup user.js
|
||||
mkdir -p userjs_backups
|
||||
local bakname="userjs_backups/user.js.backup.$(date +"%Y-%m-%d_%H%M")"
|
||||
[ $BACKUP = 'single' ] && bakname='userjs_backups/user.js.backup'
|
||||
cp user.js "$bakname" &>/dev/null
|
||||
|
||||
mv "${newfile}" user.js
|
||||
echo -e "Status: ${GREEN}user.js has been backed up and replaced with the latest version!${NC}"
|
||||
|
||||
if [ "$ESR" = true ]; then
|
||||
sed -e 's/\/\* \(ESR[0-9]\{2,\}\.x still uses all.*\)/\/\/ \1/' user.js > user.js.tmp && mv user.js.tmp user.js
|
||||
echo -e "Status: ${GREEN}ESR related preferences have been activated!${NC}"
|
||||
fi
|
||||
|
||||
# apply overrides
|
||||
if [ "$SKIPOVERRIDE" = false ]; then
|
||||
while IFS=',' read -ra FILES; do
|
||||
for FILE in "${FILES[@]}"; do
|
||||
add_override "$FILE"
|
||||
done
|
||||
done <<< "$OVERRIDE"
|
||||
fi
|
||||
|
||||
# create diff
|
||||
if [ "$COMPARE" = true ]; then
|
||||
pastuserjs='userjs_diffs/past_user.js'
|
||||
past_nocomments='userjs_diffs/past_userjs.txt'
|
||||
current_nocomments='userjs_diffs/current_userjs.txt'
|
||||
|
||||
remove_comments $pastuserjs $past_nocomments
|
||||
remove_comments user.js $current_nocomments
|
||||
|
||||
diffname="userjs_diffs/diff_$(date +"%Y-%m-%d_%H%M").txt"
|
||||
diff=$(diff -w -B -U 0 $past_nocomments $current_nocomments)
|
||||
if [ ! -z "$diff" ]; then
|
||||
echo "$diff" > "$diffname"
|
||||
echo -e "Status: ${GREEN}A diff file was created:${NC} ${PWD}/${diffname}"
|
||||
else
|
||||
echo -e "Warning: ${ORANGE}Your new user.js file appears to be identical. No diff file was created.${NC}"
|
||||
[ $BACKUP = 'multiple' ] && rm $bakname &>/dev/null
|
||||
fi
|
||||
rm $past_nocomments $current_nocomments $pastuserjs &>/dev/null
|
||||
fi
|
||||
|
||||
[ "$VIEW" = true ] && open_file "${PWD}/user.js"
|
||||
}
|
||||
|
||||
#########################
|
||||
# Execute #
|
||||
#########################
|
||||
|
||||
if [ $# != 0 ]; then
|
||||
# Display usage if first argument is -help or --help
|
||||
if [ $1 = '--help' ] || [ $1 = '-help' ]; then
|
||||
usage
|
||||
else
|
||||
while getopts ":hp:ludsno:bcvre" opt; do
|
||||
case $opt in
|
||||
h)
|
||||
usage
|
||||
;;
|
||||
p)
|
||||
PROFILE_PATH=${OPTARG}
|
||||
;;
|
||||
l)
|
||||
PROFILE_PATH='list'
|
||||
;;
|
||||
u)
|
||||
UPDATE='yes'
|
||||
;;
|
||||
d)
|
||||
UPDATE='no'
|
||||
;;
|
||||
s)
|
||||
CONFIRM='no'
|
||||
;;
|
||||
n)
|
||||
SKIPOVERRIDE=true
|
||||
;;
|
||||
o)
|
||||
OVERRIDE=${OPTARG}
|
||||
;;
|
||||
b)
|
||||
BACKUP='single'
|
||||
;;
|
||||
c)
|
||||
COMPARE=true
|
||||
;;
|
||||
v)
|
||||
VIEW=true
|
||||
;;
|
||||
e)
|
||||
ESR=true
|
||||
;;
|
||||
r)
|
||||
tfile="$(download_file 'https://raw.githubusercontent.com/arkenfox/user.js/master/user.js')"
|
||||
[ -z "${tfile}" ] && echo -e "${RED}Error! Could not download user.js${NC}" && exit 1 # check if download failed
|
||||
mv $tfile "${tfile}.js"
|
||||
echo -e "${ORANGE}Warning: user.js was saved to temporary file ${tfile}.js${NC}"
|
||||
open_file "${tfile}.js"
|
||||
exit 0
|
||||
;;
|
||||
\?)
|
||||
echo -e "${RED}\n Error! Invalid option: -$OPTARG${NC}" >&2
|
||||
usage
|
||||
;;
|
||||
:)
|
||||
echo -e "${RED}Error! Option -$OPTARG requires an argument.${NC}" >&2
|
||||
exit 2
|
||||
;;
|
||||
esac
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
show_banner
|
||||
update_updater $@
|
||||
|
||||
getProfilePath # updates PROFILE_PATH or exits on error
|
||||
cd "$PROFILE_PATH" && update_userjs
|
||||
|
||||
cd "$CURRDIR"
|
||||
|
1
wikipiki/License-MIT-yellow.svg
Normal file
1
wikipiki/License-MIT-yellow.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="78" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="a"><rect width="78" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#a)"><path fill="#555" d="M0 0h47v20H0z"/><path fill="#dfb317" d="M47 0h31v20H47z"/><path fill="url(#b)" d="M0 0h78v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="110"> <text x="245" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="370">license</text><text x="245" y="140" transform="scale(.1)" textLength="370">license</text><text x="615" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="210">MIT</text><text x="615" y="140" transform="scale(.1)" textLength="210">MIT</text></g> </svg>
|
After Width: | Height: | Size: 950 B |
Binary file not shown.
Before Width: | Height: | Size: 3.3 KiB |
Binary file not shown.
Before Width: | Height: | Size: 46 KiB |
Binary file not shown.
Before Width: | Height: | Size: 85 KiB |
Binary file not shown.
Before Width: | Height: | Size: 95 KiB |
Binary file not shown.
Before Width: | Height: | Size: 3.1 KiB |
Reference in New Issue
Block a user