minetest-mods / minetest-mods.github.io

Rules and Regulations of the Minetest-Mods team and content.
https://minetest-mods.github.io/
10 stars 3 forks source link

Membership request #127

Closed Niklp09 closed 1 year ago

Niklp09 commented 1 year ago

Many minetest-mods projects are more or less dead. The main issue is IMO that no one (except Krock) merges actively PR's. Therefore, I apply to take over tasks here. I'm contributing to some mods here, mainly maintenance and bugfixes. I'm a staff member of mt-mods too. If you don't want to grant me access, please consider to grant other active people like @BuckarooBanzay (if he wants) more access.

BuckarooBanzay commented 1 year ago

(if he wants) more access.

i'm good and have enough projects to maintain :laughing:

but +1 for Niklp as maintainer :+1:

sfan5 commented 1 year ago

I've sent an invitations, please ping me again once you have accepted it.

Panquesito7 commented 1 year ago

Great to see more active maintainers! I'm all for this. 👍

Niklp09 commented 1 year ago

@sfan5 accepted. tyvm.

sfan5 commented 1 year ago

Wait, do you have write access to repos already? I thought I had to grant that separately.

Niklp09 commented 1 year ago

Wait, do you have write access to repos already? I thought I had to grant that separately.

No, I have no write or edit access yet.

sfan5 commented 1 year ago

Apparently github only allows me to manage role access one-by-one. I don't have time to sit here for an hour doing this for 200 repos, so I'll have to script. Might be some days until I get to it.

Panquesito7 commented 1 year ago

Apparently github only allows me to manage role access one-by-one. I don't have time to sit here for an hour doing this for 200 repos, so I'll have to script. Might be some days until I get to it.

You can create a team that has access to all repositories with write access and add the members (in this case, @Niklp09). This is very easy to perform and shouldn't take long.

sfan5 commented 1 year ago

How? Note that I don't want to grant the "Owner" role.

sfan5 commented 1 year ago

Okay nevermind. Scripting it in-browser was easier than expected:

// add every repo to the team
await (async function() {
    const src = 'https://api.github.com/orgs/minetest-mods/repos?per_page=999'; // edit to add page=2 etc.
    const data = await (await fetch(src)).json();
    const form = document.querySelector('details-dialog form[action$=repositories]');
    const fd = new URLSearchParams(new FormData(form));
    for (const x of data) {
        fd.set("member", x.full_name);
        await fetch(form.action, {
            method: form.method,
            body: fd
        });
        await new Promise(r => setTimeout(r, 200));
    }
})();

// change all permissions to 'Write'
for (const e of document.querySelectorAll('.js-permission-menu-form')) {
    e.querySelector('summary').innerText !== "Write" && e.querySelector('button[value=push]').click()
}