-
Notifications
You must be signed in to change notification settings - Fork 1
/
.finicky.js
55 lines (54 loc) · 1.3 KB
/
.finicky.js
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
// Generated by Finicky Kickstart
// Save as ~/.finicky.js
//
// Tool to add rules: https://finicky-kickstart.now.sh
// or https://finicky-kickstart.vercel.app/
module.exports = {
defaultBrowser: ["Firefox", "Google Chrome"],
handlers: [
{
match: /^https?:\/\/datavant.*\.$/,
browser: "Google Chrome",
},
{
match: /^https?:\/\/stripe\.com$/,
browser: "Firefox",
},
{
match: /zoom\.us\/join/,
browser: "us.zoom.xos",
},
{
// Open any link clicked in Mail & Outlook in Google Chrome
match: ({ opener, keys }) => {
return ["Slack"].includes(opener.name) && finicky.getKeys().option;
},
browser: "Google Chrome",
},
],
rewrite: [
{
match(all) {
finicky.log(JSON.stringify(all, null, 2));
return false;
},
url: ({ url }) => url,
},
{
match: ({ url }) => url.host.includes("zoom.us") && url.pathname.includes("/j/"),
url({ url }) {
try {
var pass = "&pwd=" + url.search.match(/pwd=(\w*)/)[1];
} catch {
var pass = "";
}
var conf = "confno=" + url.pathname.match(/\/j\/(\d+)/)[1];
return {
search: conf + pass,
pathname: "/join",
protocol: "zoommtg",
};
},
},
],
};