Re: [Wikitech-l] Workflow for updating javascript tools on wiki?

2020-11-01 Thread revi
Not sure if this is what you're looking for, but 
https://github.com/femiwiki/remote-gadgets comes to mind.

나의 iPhone에서 보냄

> 2020. 11. 1. 21:03, Gergo Tisza  작성:
> 
> 
>> On Mon, Oct 26, 2020 at 9:27 AM Roy Smith  wrote:
> 
>> I maintain spi-tools.js.  The source is in github.  At the moment, my 
>> "release process" (if you could call it that) is to edit 
>> User:RoySmith/spi-tools.js and copy-paste the new version.  This works, but 
>> it's clunky.  Is there some pre-existing tool for this?
> 
> There is some discussion in T71445 and T187749 but nothing usable. I think 
> some frwiki editors had plans for a bot but I don't know if anything came out 
> of it. The closest tool I'm aware of is Dibabel but that copies the code from 
> another wiki, not Github. (Also, it's meant for Lua code, which does not pose 
> similar security risks.)
> 
> Updating the page from a CI script is not too hard but rather scary 
> security-wise. Writing a deploy script in Pywikibot or some similar framework 
> seems pretty straightforward though, reasonably secure, and not too 
> inconvenient to do an extra CLI command for deploying.
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Workflow for updating javascript tools on wiki?

2020-11-01 Thread Gergo Tisza
On Mon, Oct 26, 2020 at 9:27 AM Roy Smith  wrote:

> I maintain spi-tools.js
> .  The source
> is in github.  At the moment, my "release process" (if you could call it
> that) is to edit
> User:RoySmith/spi-tools.js and copy-paste the new version.  This works,
> but it's clunky.  Is there some pre-existing tool for this?
>

There is some discussion in T71445
 and T187749
 but nothing usable. I think
some frwiki editors had plans for a bot but I don't know if anything came
out of it. The closest tool I'm aware of is Dibabel
 but that copies the code from another
wiki, not Github. (Also, it's meant for Lua code, which does not pose
similar security risks.)

Updating the page from a CI script is not too hard but rather scary
security-wise. Writing a deploy script in Pywikibot or some
similar framework seems pretty straightforward though, reasonably secure,
and not too inconvenient to do an extra CLI command for deploying.
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Workflow for updating javascript tools on wiki?

2020-10-29 Thread AntiCompositeNumber
The Twinkle project uses a Perl script to sync from Github to on-wiki
JS: 

IIRC it's run manually, but one could conceivably run something
similar in a CI/CD pipeline. That would, of course, mean storing
interface administrator credentials and the tools to use them on
third-party servers, which has some security risks. Using something
similar to 

and handling the MW auth and deployment from WMCS servers may reduce
some of those risks.

ACN

On Thu, Oct 29, 2020 at 11:09 AM Scott Bassett  wrote:
>
> Hello Roy-
>
> I don't believe there is any release or deployment process for userJS on the 
> projects, certainly nothing formal or standardized.  In some way, Gadgets 
> 2.0/3.0 was designed with these issues in mind, but that project is currently 
> stalled, as far as I know.  What you're doing is likely what I and other WMF 
> folks would recommend (version control, tests if feasible, careful deployment 
> with an announcement to users if you have some channel of communication, 
> etc).  If you'd ever like a quick security review of the code or possibly 
> some aggregated data on its usage, feel free to create a task in Phabricator.
>
>
> On Mon, Oct 26, 2020 at 11:27 AM Roy Smith  wrote:
>>
>> I maintain spi-tools.js.  The source is in github.  At the moment, my 
>> "release process" (if you could call it that) is to edit
>> User:RoySmith/spi-tools.js and copy-paste the new version.  This works, but 
>> it's clunky.  Is there some pre-existing tool for this?
>>
>> I could build some little tool to to do this, but if something already 
>> exists, no need to reinvent the wheel.
>>
>> ___
>> Wikitech-l mailing list
>> Wikitech-l@lists.wikimedia.org
>> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
>
>
> --
> Scott Bassett
> sbass...@wikimedia.org
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l

___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Workflow for updating javascript tools on wiki?

2020-10-29 Thread Scott Bassett
Hello Roy-

I don't believe there is any release or deployment process for userJS on
the projects, certainly nothing formal or standardized.  In some way,
Gadgets 2.0/3.0 was designed with these issues in mind, but that project is
currently stalled, as far as I know.  What you're doing is likely what I
and other WMF folks would recommend (version control, tests if feasible,
careful deployment with an announcement to users if you have some channel
of communication, etc).  If you'd ever like a quick security review of the
code or possibly some aggregated data on its usage, feel free to create a
task in Phabricator.


On Mon, Oct 26, 2020 at 11:27 AM Roy Smith  wrote:

> I maintain spi-tools.js
> .  The source
> is in github.  At the moment, my "release process" (if you could call it
> that) is to edit
> User:RoySmith/spi-tools.js and copy-paste the new version.  This works,
> but it's clunky.  Is there some pre-existing tool for this?
>
> I could build some little tool to to do this, but if something already
> exists, no need to reinvent the wheel.
>
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>


-- 
Scott Bassett
sbass...@wikimedia.org
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


[Wikitech-l] Workflow for updating javascript tools on wiki?

2020-10-26 Thread Roy Smith
I maintain spi-tools.js 
.  The source is in 
github.  At the moment, my "release process" (if you could call it that) is to 
edit 
User:RoySmith/spi-tools.js and copy-paste the new version.  This works, but 
it's clunky.  Is there some pre-existing tool for this?

I could build some little tool to to do this, but if something already exists, 
no need to reinvent the wheel.

___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l