5 Commits

Author SHA1 Message Date
61d4e121a9 added some more timestamps to make things easier on myself 2026-03-15 17:43:13 +11:00
63b2f182bb fixed typo 2026-03-15 13:39:56 +11:00
baf2f51773 added stuff i forgot cos im silly and am a bit rash 2026-03-13 23:56:35 +11:00
6c9c253a70 increased logging verbosity (with and without DEBUG env variable), added logic to exit bot and restart container on unhandled errors 2026-03-13 23:39:54 +11:00
c2a88804ad docs: Update readme and other tweaks (#37)
* edited build-main.yml to have workflow_dispatch

* re-added pgadmindata to docker compose

* removed disclaimer about being run on my personal laptop as that's no longer true

---------

Co-authored-by: Aster Fialla <asterfialla@gmail.com>
2026-03-11 21:27:41 -04:00
4 changed files with 9 additions and 4 deletions

View File

@@ -6,6 +6,8 @@ on:
pull_request: pull_request:
branches: ["main"] branches: ["main"]
workflow_dispatch:
jobs: jobs:
build: build:

View File

@@ -7,8 +7,6 @@ PluralFlux is a proxybot akin to PluralKit and Tupperbox, but for [Fluxer](https
[Sponsor the project](https://github.com/sponsors/pieartsy) [Sponsor the project](https://github.com/sponsors/pieartsy)
If it's not running at the moment, it's because my computer crashed or something. I'm looking to move running it to a somewhat more permanent solution.
## Commands ## Commands
All commands are prefixed by `pf;`. Currently only a few are implemented. All commands are prefixed by `pf;`. Currently only a few are implemented.

View File

@@ -22,4 +22,5 @@ services:
volumes: volumes:
- pgadmindata:/var/lib/pgadmin - pgadmindata:/var/lib/pgadmin
volumes: volumes:
pgdata: pgdata:
pgadmindata:

View File

@@ -10,6 +10,7 @@ const { AppDataSource } = require("../database/data-source");
env.config(); env.config();
const token = process.env.FLUXER_BOT_TOKEN; const token = process.env.FLUXER_BOT_TOKEN;
const debug = process.env.debug;
if (!token) { if (!token) {
console.error("Missing FLUXER_BOT_TOKEN environment variable."); console.error("Missing FLUXER_BOT_TOKEN environment variable.");
@@ -63,12 +64,15 @@ module.exports.handleMessageCreate = async function(message) {
} }
} }
catch(error) { catch(error) {
console.error(error); if(debug){console.error("An error occurred at unix timestamp " + Date.now() + "while processing the command: " + message + " with error:" + error);}
else{console.error(error);}
process.exit(2); //need this for now just to make sure the bot continues to restart on errors, since it would seem that fluxer.js doesn't define custom error types. TODO: map out some exit codes
} }
} }
client.on(Events.Ready, () => { client.on(Events.Ready, () => {
console.log(`Logged in as ${client.user?.username}`); console.log(`Logged in as ${client.user?.username}`);
if(debug){console.log(Date.now() + `: Currently running in debug mode!`)}
}); });
let guildCount = 0; let guildCount = 0;