Unihedro / JavaBot

Java based chat bot that runs in Java room of Stack Overflow Chat.
Apache License 2.0
15 stars 4 forks source link

Elevated privileges now usable #65

Closed mvarendorff closed 7 years ago

mvarendorff commented 7 years ago

Summon, Unsummon and Shutdown are now only accessbile for defined userid's. Userid's that have access to those commands can be specified in the properties file using ADMINS as well as during runtime using commands addAdmin and removeAdmin. Changes are saved for later instances of the bot.

Note: Don't worry about the strange name there; messed up something as I pushed the commit from eclipse...

closes #37

Vogel612 commented 7 years ago

LGTM. @Unihedro you got any changes you want to see?

mvarendorff commented 7 years ago

I hope, I got the permission thing correctly. I was unsure whether to use static methods or create an Object with the BotConfig as field so I went with the static approach first. If this should be changed I can do so.

mvarendorff commented 7 years ago

No idea what went on there... Thanks for the hawk eye!

Unihedro commented 7 years ago

:+1: LGTM and the technical debt seems small enough; did not test

Unihedro commented 7 years ago

closes #37

Vogel612 commented 7 years ago

hmm ... okay GH can't quite keep up ...

@geisterfurz007 would you please move the commits after "corrected add to add and remove to remove" into a new pull request so that they can be properly reviewed? Thanks :+1:

mvarendorff commented 7 years ago

I am afraid that it seems like I need some assistance with that... I tried to revert the changes of the last commits, but that did not work out. Or can I just move the commits over to a new PR? I am fairly new to git and not familiar with the things to do, sorry.

Vogel612 commented 7 years ago

@geisterfurz007 no worries.

The following "dark magical rites of git" should help you:

git checkout master
git remote add blessed git@github.com:Unihedro/JavaBot.git
git fetch blessed
git rebase blessed/master
git push --force

let me explain a little what happens here.

  1. make sure we're on the correct branch
  2. grab a set of the changes that happened in this repo
    for that we add this repository as remote and fetch the changes
  3. move all the stuff we don't yet have in master here up onto master
  4. and put it remote explicitly overriding safety mechanisms

if you have any questions, feel invited to ping me 👍

mvarendorff commented 7 years ago

@Vogel612 Ok so if I understand correctly I used the master branch of this project to rever the changes on the master branch of my fork? So next thing to do would be creating a new pull request with the branch I worked on as the one to compare?

Vogel612 commented 7 years ago

@geisterfurz007 well ... not quite, but it's close enough.

Yes, usually you'd not make a pull request from master to master, but .. since you already worked on your master this is the simplest way to fix things up :)

I recommend you create topic branches from now on and sync your master with Unihedro/JavaBot:master regularly to reduce merge-conflicts. FWIW I took the liberty to open the follow-up pull request for you

mvarendorff commented 7 years ago

@Vogel612 Well if it was close enough I will take that for now! I had that in mind, but somewhere I lost it appearently... Thanks for opening!