Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Readd subject to change for site/project prefixes. #284

Merged
merged 1 commit into from
Aug 14, 2014

Conversation

Martii
Copy link
Member

@Martii Martii commented Jul 28, 2014

Depending on how the user.js engine standard sways this will most likely need to change... let the authors know beforehand.

Refs:

Depending on how the user.js standard sways this will most likely need to change.
@Martii
Copy link
Member Author

Martii commented Jul 29, 2014

@Ventero wrote: Cc: @arantius @johan @gera2ld @derjanb @OpenUserJs/admin @OpenUserJs/owners @OpenUserJs/backend @OpenUserJs/frontend

I don't see why GM should take special care of properly parsing headers it doesn't care about. There's no backwards compatibility to consider on our end, as all metadata keys GM ever supported contain only alphabetic characters.

If your concern is that using : for localization makes it harder for external applications/libraries to parse the metadata, then you should raise that issue in the original bug report, so that it can be discussed further. But if we take colons in metadata keys as some kind of "attribute specifier" (i.e. name:is-IS is the is-IS attribute of the name), then in my opinion it makes sense to specifically use the character that's already being used in that manner. That way, if GM ever decids to parse all metadata keys, the keys could just be parsed as // @key:subkey1:subkey2:.... This would lead to all oujs:... keys being grouped together, as they should.

Either way, this discussion should probably be continued in greasemonkey/greasemonkey#1963.

I am guessing from this recent statement that Ventero doesn't seem to care anymore if we bust (e.g. kill) GM's proper parsing of the metadata block. I understand the popularity vote is another : from the standard Userscripts.org added and maintained since 2005 (9 years) plus our support. I believe strongly that OUJS will do our best to maintain a good spirit of cooperation between all the user.js engines, including Greasemonkey, to facilitate teamwork rather than the perceived frustration just encountered recently from him. I've spent a few hours trying different methodologies myself and I can't seem to come up with a better solution.

Changing label to expedite @sizzlemctwizzle since this needs to go in asap please. I'll be starting up another issue ticket on our site to address this in a bit. #285

@arantius @johan
As we all should know by now the moderation of greasemonkey/greasemonkey disallows me to comment directly on GM. I would suggest that his secondary regular expression would be more suitable so it keeps anyones prefixing together as much as possible as shown by this example:

var re = /\/\/ @(\S+?)(?::([a-zA-Z-]+))?(?:\s+(.*))?$/;

console.log('// @run-at document-end'.match(re));
console.log('// @run-at:fr-FR document-end'.match(re));
console.log('// @run-at:fr-FR'.match(re));
console.log('// @run-at'.match(re));
console.log('// @oujs:run-at document-end'.match(re));
console.log('// @oujs:run-at:fr-FR document-end'.match(re));
console.log('// @oujs:run-at:fr-FR'.match(re));
console.log('// @oujs:run-at:'.match(re));
Array [ "// @run-at document-end",            "run-at",       undefined, "document-end" ] Scratchpad/1:3
Array [ "// @run-at:fr-FR document-end",      "run-at",       "fr-FR",   "document-end" ] Scratchpad/1:4
Array [ "// @run-at:fr-FR",                   "run-at",       "fr-FR",   undefined      ] Scratchpad/1:5
Array [ "// @run-at",                         "run-at",       undefined, undefined      ] Scratchpad/1:6
Array [ "// @oujs:run-at document-end",       "oujs",         "run-at",  "document-end" ] Scratchpad/1:7
Array [ "// @oujs:run-at:fr-FR document-end", "oujs:run-at",  "fr-FR",   "document-end" ] Scratchpad/1:8
Array [ "// @oujs:run-at:fr-FR",              "oujs:run-at",  "fr-FR",   undefined      ] Scratchpad/1:9
Array [ "// @oujs:run-at:",                   "oujs:run-at:", undefined, undefined      ] Scratchpad/1:10

Martii added a commit that referenced this pull request Aug 14, 2014
Readd `subject to change` for site/project prefixes.

--- 

As per sizzles temporary request auto-merging for eventual deployment *hopefully today*
@Martii Martii merged commit c38706a into OpenUserJS:master Aug 14, 2014
@Martii Martii deleted the collaborationBackToExperimental branch August 14, 2014 22:02
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 24, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
UI Pertains inclusively to the User Interface.
Development

Successfully merging this pull request may close these issues.

1 participant