Greasemonkey: V4 @match๋Š” V3 ๋ฐ TamperMonkey์™€ ๋‹ค๋ฅด๊ฒŒ ์ž‘๋™ํ•ฉ๋‹ˆ๋‹ค.

์— ๋งŒ๋“  2017๋…„ 11์›” 15์ผ  ยท  8์ฝ”๋ฉ˜ํŠธ  ยท  ์ถœ์ฒ˜: greasemonkey/greasemonkey

๋‚ด ์Šคํฌ๋ฆฝํŠธ์—๋Š” ๋‹ค์Œ ํ•ญ๋ชฉ์ด ์žˆ์Šต๋‹ˆ๋‹ค(์ธํŠธ๋ผ๋„ท ์ฃผ์†Œ์—์„œ ์‚ญ์ œ๋จ).

// <strong i="6">@match</strong>        http://*.some-net.net/*
// <strong i="7">@match</strong>        http://*.some-net.net/*
// <strong i="8">@match</strong>        https://*.some-othernet.net/*
// <strong i="9">@match</strong>        https://*.some-othernet.net/*

V3/tampermonkey์—์„œ๋Š” ๋‹ค์Œ์˜ ๋ชจ๋“  ์ฃผ์†Œ ์˜ˆ์ œ(http ๋ฐ https ๋ชจ๋‘)์— ๋Œ€ํ•ด ์ž‘๋™ํ•ฉ๋‹ˆ๋‹ค.

[1] service.some-net.net
[2] service.some-othernet.net
[3] service.some-net. ์ˆœ:1234
[4] service.some-othernet. ์ˆœ:1234
[5] service.customer.some-net. ์ˆœ:1234
[6] service.customer.location.some-net.net

๊ทธ๋Ÿฌ๋‚˜ V4 [3][4] ๋ฐ [5]์—์„œ ์ž‘๋™ํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค. [3] ์ˆ˜์ • ์‚ฌํ•ญ์€ ํฌํŠธ์™€ ์ผ์น˜ํ•˜๋„๋ก ์ถ”๊ฐ€ํ•˜๋Š” ๊ฒƒ์ด ์—ˆ์Šต๋‹ˆ๋‹ค.

// <strong i="23">@match</strong>        http://*.some-net.net:*/*
// <strong i="24">@match</strong>        http://*.some-net.net:*/*
// <strong i="25">@match</strong>        https://*.some-othernet.net:*/*
// <strong i="26">@match</strong>        https://*.some-othernet.net:*/*

[5]์— ๊ด€ํ•ด์„œ๋Š” ์ด๊ฒƒ์„ ์‹œ๋„ํ–ˆ์ง€๋งŒ ๋„์›€์ด๋˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.

// <strong i="30">@match</strong>        http://*.*.some-net.net:*/*
// <strong i="31">@match</strong>        http://*.*.some-net.net:*/*
// <strong i="32">@match</strong>        https://*.*.some-othernet.net:*/*
// <strong i="33">@match</strong>        https://*.*.some-othernet.net:*/*

๊ทธ๋ฆฌ๊ณ  ์ด๊ฒƒ์€ [6] ์ฒซ ๋ฒˆ์งธ (์›๋ž˜) ๊ทœ์น™ ์„ธํŠธ ๋‹จ๋…์œผ๋กœ ์ž‘์—…ํ•˜๊ธฐ ๋•Œ๋ฌธ์— ๋‚˜์—๊ฒŒ ์˜๋ฏธ๊ฐ€ ์—†์Šต๋‹ˆ๋‹ค.

๋ชจ๋“  8 ๋Œ“๊ธ€

๊ณต์‹ ๋ฌธ์„œ ๋Š” ๊ฐ„๊ฒฐํ•˜๋ฉฐ ํฌํŠธ๋ฅผ ์ „ํ˜€ ์–ธ๊ธ‰ํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค. ํšŒ๊ท€๋ฅผ ๋ฐฉ์ง€ํ•˜๊ธฐ ์œ„ํ•ด ์ˆ˜์ •ํ•  ๋•Œ ํ…Œ์ŠคํŠธ๋ฅผ ํฌํ•จํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

์ƒˆ/์ด์ „ ์ฝ”๋“œ๋ฅผ ๋น„๊ตํ•˜๋ฉด ๋‹ค์Œ๊ณผ ๊ฐ™์Šต๋‹ˆ๋‹ค.

์–ด๋–ป๊ฒŒ ์ด๋Ÿฐ ์ผ์ด ์ผ์–ด ๋‚ฌ๋Š”์ง€ ํ™•์‹คํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค. ๋ณ€๊ฒฝ๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค.

๊ธ€์Ž„, ์•„๋งˆ๋„ ํ˜„์žฌ URL์„ ์–ป๋Š” ๋ฐ ์‚ฌ์šฉ๋˜๋Š” ๋ฐฉ๋ฒ•์ด ๋ณ€๊ฒฝ๋˜์—ˆ์„ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ์ƒˆ Firefox๋ฅผ ์‚ฌ์šฉํ•˜๋Š” ๋ชจ๋“  ์‚ฌ๋žŒ์—๊ฒŒ ์ด ๋ฌธ์ œ๊ฐ€ ์žˆ์œผ๋ฉฐ ์ด์ „ FF/Chrome์„ ์‚ฌ์šฉํ•˜๋Š” ๋‹ค๋ฅธ ์‚ฌ๋žŒ์—๊ฒŒ๋Š” ์ž‘๋™ํ•ฉ๋‹ˆ๋‹ค.
๋ถˆํ–‰ํžˆ๋„ ์ผ๋ถ€ ์ธ์‡„๋ฌผ์„ ์ถ”๊ฐ€ํ•˜๊ธฐ ์œ„ํ•ด XPI๋ฅผ ์ˆ˜์ •ํ•˜๋ ค๊ณ  ํ•  ๋•Œ ์„œ๋ช…์ด ํ•„์š”ํ•˜๋‹ค๋Š” ๊ฒƒ์„ ์•Œ์•˜์Šต๋‹ˆ๋‹ค....

๋งค์น˜์™€ ํฌํŠธ์— ๋Œ€ํ•œ Bugzilla๊ฐ€ ์žˆ์Šต๋‹ˆ๋‹ค. ํ•ด์ƒ๋„๊ฐ€ ๋ฌด์—‡์ธ์ง€ ํ™•์‹คํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค. ๋‚ด๊ฐ€ ๊ทธ๊ฒƒ์„ ์ฐพ์„ ์ˆ˜ ์žˆ๋Š”์ง€ ๋ณผ ๊ฒƒ์ž…๋‹ˆ๋‹ค.

๊ฒฝ๊ธฐ์™€ ํ•ญ๊ตฌ์˜ Buzilla. ์—ฌ๊ธฐ .

์ž, 3.x ์ผ ์ „์— ์šฐ๋ฆฌ๋Š” host , port ๋ฐ hostport ๊ฐ€ ๋ณ„๋„๋กœ ์žˆ๋Š” nsIURI ๋ฅผ ์‚ฌ์šฉํ–ˆ์Šต๋‹ˆ๋‹ค. ์ด์ œ host ๋ผ๋Š” ์ด๋ฆ„์ด ์žˆ๋Š” URL ์„ ์‚ฌ์šฉํ•ด์•ผ ํ•˜์ง€๋งŒ hostport ๋ฅผ ์˜๋ฏธํ•ฉ๋‹ˆ๋‹ค. hostname ๋ฅผ ์‚ฌ์šฉํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

๋ฌธ์ œ ๊ธฐ๋Šฅ๊ณผ ์ง์ ‘์ ์ธ ๊ด€๋ จ์€ ์—†์ง€๋งŒ FF ๊ตฌํ˜„๊ณผ์˜ ํ˜ธํ™˜์„ฑ์„ ๋ณด์žฅํ•ฉ๋‹ˆ๋‹ค. API๊ฐ€ ๊ตฌํ˜„๋˜์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

https://bugzilla.mozilla.org/show_bug.cgi?id=1395278

์ด ์ˆ˜์ • ์‚ฌํ•ญ์€ 4.1beta6์— ์žˆ์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ์ด๊ฒƒ์„ ํ…Œ์ŠคํŠธํ•˜๊ณ  ํ™•์ธํ•˜๋Š” ๊ฒƒ์€ ๋งค์šฐ ๊ฐ์‚ฌํ•  ๊ฒƒ์ž…๋‹ˆ๋‹ค!

https://addons.mozilla.org/firefox/downloads/file/800957/greasemonkey-4.1beta6-an+fx.xpi?src=devhub

์ง€๊ธˆ ํ™•์ธํ–ˆ๊ณ  ์ œ๋Œ€๋กœ ์ž‘๋™ํ•˜๋Š” ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค. ๊ฐ์‚ฌ ํ•ด์š”!

์ด ํŽ˜์ด์ง€๊ฐ€ ๋„์›€์ด ๋˜์—ˆ๋‚˜์š”?
0 / 5 - 0 ๋“ฑ๊ธ‰