Modify deploy.js to accept site and accessToken variables from credentials file#128
Open
bunnypranav wants to merge 1 commit into
Open
Modify deploy.js to accept site and accessToken variables from credentials file#128bunnypranav wants to merge 1 commit into
bunnypranav wants to merge 1 commit into
Conversation
Contributor
Author
|
Hi @NovemLinguae, any update on this? Thanks :) |
Contributor
Author
|
Hi @siddharthvp, Novem asked me to request a review from you, as they are on a break for a couple months. Thanks! :) |
e752fa9 to
4db36fe
Compare
siddharthvp
requested changes
Jan 25, 2026
siddharthvp
left a comment
Member
There was a problem hiding this comment.
There are syntax errors in this file.
4db36fe to
2c87d65
Compare
2 tasks
Contributor
Author
|
Should have caught that earlier, fixed. |
siddharthvp
requested changes
Jan 25, 2026
2c87d65 to
8d019df
Compare
siddharthvp
requested changes
Mar 22, 2026
…tials file * This allows the script to work with https://gadget-deploy.toolforge.org/, a three-click gadget GitHub-to-wiki deploy tool for interface administrators. * Takes in the site value as apiUrl for the --quick mode, if it exists * Update loading of credentials.json to a dictionary for better flexibility
8d019df to
8f4d745
Compare
Contributor
Author
|
Hope my changes work! |
Member
|
Suggest testing instead of just hoping that it'd work. |
Contributor
Author
|
I thought about that, but I was wondering how can I test since I am not a interface admin. Could you help me with this? |
Member
|
You can temporarily change the page names to point to your userspace. |
Member
|
If someone wants to reply with a "steps to test", would be happy to test it and report back. |
Member
|
NovemLinguae
requested changes
May 1, 2026
| apiUrl: `https://${wiki}.wikipedia.org/w/api.php`, | ||
| username: username, | ||
| password: password | ||
| const api = await Mwn.init({ |
Member
There was a problem hiding this comment.
PS D:\other-peoples-githubs\xfdcloser> node bin/deploy.js --quick
QUICK MODE: Using defaults (site from credentials.json, beta, blank edit summary, auto-continue)
Edit summary is: "v4.0.16 at 8f4d745: Updated from repository"
D:\other-peoples-githubs\xfdcloser\bin\deploy.js:135
const api = await Mwn.init({
^
TypeError: Cannot read properties of undefined (reading 'init')
at deploy (D:\other-peoples-githubs\xfdcloser\bin\deploy.js:135:25)
at Object.<anonymous> (D:\other-peoples-githubs\xfdcloser\bin\deploy.js:171:1)
at Module._compile (node:internal/modules/cjs/loader:1692:14)
at Object..js (node:internal/modules/cjs/loader:1824:10)
at Module.load (node:internal/modules/cjs/loader:1427:32)
at Module._load (node:internal/modules/cjs/loader:1250:12)
at TracingChannel.traceSync (node:diagnostics_channel:322:14)
at wrapModuleLoad (node:internal/modules/cjs/loader:235:24)
at Module.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:152:5)
at node:internal/main/run_main_module:33:47
Node.js v24.4.1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Partially resolves #101
Related PR in gadget-deploy repo wikimedia-gadgets/gadget-deploy#4