SylvainAirCarnet

SCoL | Navigation | Archives | Tags | Recherche

24 septembre 2009 (jeudi)

Smart Google Subscriber fait désormais partie de Better GReader

Au milieu du mois d'août, sans trop y croire, j'avais suggéré à Gina Trapani de jeter un coup d'oeil à Smart Google Subscriber pour venir remplacer le bon vieux Smart Subscribe utilisé jusque là dans l'extension Firefox Better GReader. Après une réponse laconique, je pensais l'affaire enterrée. J'avais tort... Le script a été intégré à la version 0.8 de l'extension, en même temps que Helvetireader. Notons au passage que je n'ai été prévenu de rien, que Mihai, auteur de l'ancienne version (qui reste disponible dans l'extension) est cité dans l'annonce ainsi que l'auteur de Helvetireader. En revanche je n'ai pas vu mon nom cité...

Allez, ne boudons pas notre plaisir, d'autant que je ne poursuis pas la gloire. J'ai quand même droit dans l'annonce à un lien vers la page du script sur le AirCarnet, qui m'a valu près de 400 visiteurs, ainsi qu'à mon nom dans l'extension. Et surtout, le plaisir de savoir que mon travail va être utilisé par beaucoup plus de monde...

20 août 2009 (jeudi)

Si Google Reader devient anormalement lent sous Firefox

Depuis quelques jours, je trouvais que Google Reader était devenu anormalement lent. A la fois au chargement initial au chargement de chaque dossier. Pour les dossiers contenant le plus d'items non lus j'en étais arrivé à fermer Firefox qui était complètement bloqué, le processeur étant occupé par Firefox à 50% pendant des durées de plusieurs minutes.
Le problème venait, dans mon cas, d'un userscript installé avec Greasemonkey : longurl. J'ai donc posté un commentaire pour que l'auteur regarde si il peut faire quelque chose et ai désactivé longurl pour http://www.google.com/reader/* et https://www.google.com/reader/*.

Cela dit, d'autres causes sont tout à fait possibles : une rapide recherche montre que l'installation de Skype, qui installe un add-on pour Firefox, peut causer le même problème...

27 mai 2009 (mercredi)

GreaseMonkey Script Update Control

What is GM Script Update Control for?

  • Userscript developpers can include the script in their own to help their users to keep up-to-date.
  • Userscript users can include the script in any of their userscript coming from userscript.org to keep up-to-date. It's very easy to do with any text-editor...

How to use it?

Good old method : Copy and Paste

  1. Copy part of the source script between
    /* COPY ALL THIS -> END  */
    and
    /* END OF COPY ZONE */
  2. Paste it in your own script just after
    // ==/UserScript==
  3. Update the two vars for Id (Id is the ref number of the script in userscripts : http://userscripts.org/scripts/show/yourScriptId) and current version of your script (duplicate of @version yourScriptVersion metadata). Please, remember not to put any space in your version number use _ (underscore) instead.
    var myScriptId=yourScriptId
    var myScriptVersion="yourScriptVersion";
    You can also set control frequency in order to consume less bandwidth set this with this parameter :
    var GMSUCfreq=9;			// frequence of control updates (days)
  4. You might like to customize (very little)
    • Delay before alert disapears (set to 0 if you don't want it to disapear) :
      var GMSUCtime=16;		// delay before alert disapears. 
    • Choose your color palette :
      var GMSUCPal=cpUserscript; 	// colorPalette you prefer
      three are proposed : cpChrome, cpUserscript or cpFlickr, but you may ad any you want to create by defining a new one using var yourPalette=new colorPalette(background,highlight,foreground,light);
  5. That's all, enjoy...

Brand new method may be not working : @require

I did test this method on this testing script and it seems to work.

There are some limitation of @require usage in GreaseMonkey : The GM Script Update Control used by your script will be the one available at the date of the FIRST install by your users. If you update your script, GM_scriptVersionControl function WILL NOT upgrade to last version. Users will have to uninstall and reinstall your script to have it updated. It may cause some compatibility problems...

  1. ad the @require parameter in the header of your script
    // @require http://userscripts.org/scripts/source/35611.user.js
  2. redefine the mandatory parameters
    thisId=yourScriptId;
    thisVersion="yourScriptVersion";
  3. customize if you want with any of the other parameters. See above for more details
    GMSUCfreq=9;    // control frequency
    GMSUCtime=16; // disapearing delay
    GMSUCPal=cpUserscript; // color palette
  4. Launch the script in yours
    GM_scriptVersionControl();

Do i need to install it?

Definitely not. You may only copy-paste the function from the source script.
But you may find useful to be informed of future updates. If installed, the GmScript will prompt you about this...

Contribute

Translations

the alert message is displayed in French or in English (default) using the navigator.language property. If you put any translation in comment here or there, i will be pleased to implement it. Use the following models please :

// français
Txt[1]["fr"]="Vous utilisez la version";
Txt[2]["fr"]="du script";
Txt[3]["fr"]="La version officielle est différente";
Txt[4]["fr"]="installer";
Txt[5]["fr"]="voir le code";
Txt[6]["fr"]="propulsé par";
// english
Txt[1]["en"]="You're using";
Txt[2]["en"]="version of";
Txt[3]["en"]="script. Official release version is different";
Txt[4]["en"]="install";
Txt[5]["en"]="view code";
Txt[6]["en"]="powered by";

Color palette

If you think you're a color genius and defined a pretty nicest of the world colorPalette, post it here or there...

Anything else

As you can see through Revisions history, i'm very pleased about any comment you can do about this script and its functionalities. And I manage to take care of your idea when i got time for this. Please, don't wait and put anything you brain has in about this script here or there...

Licence

as I had no idea about licensing this work, i putted it under the creative-commons by-nc-sa one.

creative commons by-nc-sa logo

Revisions history

  • version 0.5 (2009 06 01)
    • testing enabling @require usage in order to please IzzySoft. Please note :
      • it may not work. I can't test it since none of the script containing @require can be installed on my computer and I don't know why,
      • your GM Script Update Control version will not be updated for your users each time your script is. Users will have to de-install and re-install to have last GM Script Update Control version.
    • added colorPalette management developped for Google Smart Subscriber and made some minor cosmetics "improvements".
  • version 0.4 (2009 04 17)
    • you may now set control frequency for your script in order to avoid too much bandwidth consumption. However, all users connected on release date will be proposed for an update... Special thanks to NOrack who gave me this idea.
  • version 0.3 (2009 04 12)
  • version 0.2 (2009 04 06)
    • fixed bug in Firefox 3.1b/3.5b : new way to handle characters by the DOM causing bad interpretation of version id. Script now cleaning version number for any space, null, return or any "strange" character.
    • fix userscript homepage bug when not logged in (google ad javascript comment marked with <!-- * */--> instead of /* */
    • version only verified in main window
  • version 0.1 (2008 11 26)
    • version 0.1.b (2009 01 21) : updated script to include new userscript.org script page layout (it's very versatile isn't it?)
    • modified display : three button to go to homepage, source code or install and a link to this page
    • minor bugs removed
  • version 0.0.4 (2008 11 14)
    • moved styling, alert text to avoid loading when not needed
    • added auto-hide of alert message to make script less obstrusive. You might disable it by editing parameters (see above)
    • some customization now (colors) ;-)
  • version 0.0.3 (2008 10 21)
    • gave up remote calling (for the moment)
    • inverted id and version vars (it's way more logical now ;-)
    • rewrited code to embed all parameters (lang, style...) in function
  • version 0.0.2
    • added en/fr language support
    • testing script without @include meta
  • version 0.0.1
    • a : bugs correction
    • added scriptId
  • version 0.0.0 : initial release

19 mai 2009 (mardi)

Smart Google Subscriber [fr]

Smart Google Subscriber est un script Greasemonkey qui aide à l'abonnement aux flux rss des dans Google Reader.
Sur chaque page visitée comportant des liens vers des flux rss (ou xml ou atom ou rdf), le script affiche une petite icone dans le coin en haut à gauche de l'écran qui vous indique si et au(x)quel(s) des flux vous êtes déjà abonné.

Lire la suite...

Smart Google Subscriber

Smart Google Subscriber is a Greasemonkey userscript designed to help you subscribing to rss, atom and xml feeds in Google Reader.
On each page you visit pointing to a rss feed (or xml, or atom, or rdf), the script displays a small icon in the upper left corner of the page telling you whether you already suscribed to the page feeds and which ones.

Lire la suite...