generated from nhcarrigan/template
feat: mentorship improvements and name mention notifications (#14)
## Summary - **Name/title mention notifications**: Amari now notifies Naomi when a message contains her name, common nicknames (`nomi`, `nao`, `nae`, `naonao`), or honorifics (`goddess`, `queen`, `mistress`, `your/her majesty`, `your/her highness`). Uses the same cooldown logic as mention forwarding. - **Simplified mentee onboarding**: Replaced the lengthy welcome message with a concise prompt asking the new mentee to ping Naomi with their GitHub username and name. - **Removed offboard notification**: `logMenteeLeave` now only logs a metric silently — no more "user must be offboarded" messages in the channel. - **Deduplicated welcome messages**: Welcomed mentee IDs are persisted to `data/welcomed.txt` so the onboarding message is only ever sent once, even if the role is re-assigned. ## Test plan - [ ] Assign mentorship role to a user and confirm the new onboarding message appears - [ ] Re-assign the role to the same user and confirm no duplicate message is sent - [ ] Remove a mentee from the server and confirm no offboard message is posted - [ ] Send a message containing a matched name/honorific and confirm Naomi receives a DM forwarding it ✨ This PR was created with help from Hikari~ 🌸 Co-authored-by: Naomi Carrigan <commits@nhcarrigan.com> Reviewed-on: #14 Co-authored-by: Hikari <hikari@nhcarrigan.com> Co-committed-by: Hikari <hikari@nhcarrigan.com>
This commit was merged in pull request #14.
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
*/
|
||||
|
||||
import { ids } from "../config/ids.js";
|
||||
import { notifyNameMention } from "../modules/notifyNameMention.js";
|
||||
import { respondToMention } from "../modules/respondToMention.js";
|
||||
import { updateMentorshipThread } from "../modules/updateMentorshipThread.js";
|
||||
import type { Amari } from "../interfaces/amari.js";
|
||||
@@ -29,4 +30,5 @@ export const handleMessageCreate = async(
|
||||
}
|
||||
await updateMentorshipThread(amari, message);
|
||||
await respondToMention(amari, message);
|
||||
await notifyNameMention(amari, message);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user