jerone / UserScripts

🐵 My UserScripts
https://github.com/jerone/UserScripts#readme
GNU General Public License v3.0
339 stars 39 forks source link

Turn as WebExtension #109

Closed Mte90 closed 8 years ago

Mte90 commented 8 years ago

I use greasemonkey only for that scripts so it is possible to wrap the script in a WebExtension? In this way works for Firefox and Chrome and avoid the Greasemonkey system. https://hacks.mozilla.org/2015/09/lets_write_a_webextension/

jerone commented 8 years ago

Which script are you talking about? I've got multiple...

Mte90 commented 8 years ago

I think of the github scripts, maybe an option to enable the specific feature will be not bad.

jerone commented 8 years ago

I have currently no plans to turn my userscripts into webextentions.

Mte90 commented 7 years ago

In case I can do it, it's very simple now and works also on Firefox, Chrome and Opera. I removed greasemonkey to improve the browser experience but I miss that scripts :-)

jerone commented 7 years ago

Is there an converter tool / tutorial for UserScript to WebExtension ?

Mte90 commented 7 years ago

No because the webextension for firefox are the same google chrome extension. So this script are like content scripts so you need only a manifest.json (for the urls where the script need to be injected): https://developer.mozilla.org/en-US/Add-ons/WebExtensions

jerone commented 7 years ago

So, I was able to setup a local WebExtension for Firefox with one of my scripts and successfully running it for a few days now. Was incredibly easy to do.

Why I asked if there is a tool, is for the steps after the setup phase. Both GreasyFork and OUJS allow the online script to be connected to the source code on GitHub. Meaning that as soon as I update an userscript on this repo, both GreasyFork and OUJS will update too, and users are able to update. No additional steps required! For WebExtensions more steps are required (from what I've read); zipping, uploading to AMO, sending for review, waiting for review (days...), if issues then fixing those and re-sending for review, and then publishing. Repeating the same steps for Google Chrome too.

For now, those additional steps are in my opinion not yet worth converting all my userscripts to WebExtensions. This might change if those additional steps could be reduced with some tool or when I'm done with GreaseMonkey.

Mte90 commented 7 years ago

Yeah I know release a new extension can be boring but depends how much often you release a script. I think that you can do an unique extension with a panel to enable the specific script in that way you can avoid to release many of them. Or chose to release the scripts that get less updates.

jerone commented 7 years ago

... with a panel to enable the specific script ...

Something similar to Octopatcher and Github Enhancement Suite ?

Mte90 commented 7 years ago

Yep, I am already use Octopatcher :-)