Giter Club home page Giter Club logo

Comments (2)

MitchTalmadge avatar MitchTalmadge commented on July 21, 2024

Hey! All you have to do is use ECHOBOT_CONFIG_JSON as the key and copy-paste the entire contents of config.json as the value. By formatting not mattering I just mean you can disregard line breaks or spaces or tabs. JSON does not care about those. It's just to make it pretty.

from discord-echobot.

chris-larsen avatar chris-larsen commented on July 21, 2024

Hey! All you have to do is use ECHOBOT_CONFIG_JSON as the key and copy-paste the entire contents of config.json as the value. By formatting not mattering I just mean you can disregard line breaks or spaces or tabs.

Thank you for the prompt reply! I went ahead and did that and something about the array brackets ] is breaking my start.

2021-03-02T20:58:05.294458+00:00 app[web.1]: > node ./bin/echobot.js
2021-03-02T20:58:05.294458+00:00 app[web.1]: 
2021-03-02T20:58:05.830986+00:00 app[web.1]: undefined:7
2021-03-02T20:58:05.831024+00:00 app[web.1]:       ],
2021-03-02T20:58:05.831025+00:00 app[web.1]:       ^
2021-03-02T20:58:05.831025+00:00 app[web.1]: 
2021-03-02T20:58:05.831028+00:00 app[web.1]: SyntaxError: Unexpected token ] in JSON at position 154
2021-03-02T20:58:05.831029+00:00 app[web.1]:     at JSON.parse (<anonymous>)
2021-03-02T20:58:05.831030+00:00 app[web.1]:     at EchoBot.loadConfiguration (/app/bin/echobot.js:39:27)
2021-03-02T20:58:05.831031+00:00 app[web.1]:     at new EchoBot (/app/bin/echobot.js:29:19)
2021-03-02T20:58:05.831031+00:00 app[web.1]:     at Object.<anonymous> (/app/bin/echobot.js:257:1)
2021-03-02T20:58:05.831032+00:00 app[web.1]:     at Module._compile (internal/modules/cjs/loader.js:1158:30)
2021-03-02T20:58:05.831033+00:00 app[web.1]:     at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10)
2021-03-02T20:58:05.831034+00:00 app[web.1]:     at Module.load (internal/modules/cjs/loader.js:1002:32)
2021-03-02T20:58:05.831034+00:00 app[web.1]:     at Function.Module._load (internal/modules/cjs/loader.js:901:14)
2021-03-02T20:58:05.831036+00:00 app[web.1]:     at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12)
2021-03-02T20:58:05.831036+00:00 app[web.1]:     at internal/main/run_main_module.js:18:47

Here's what my config looks like that I'm pasting into the ECHOBOT_CONFIG_JSON value section:

{
  "token": "redacted token for public github issue comment",
  "redirects": [
    {
      "sources": [
        "redacted source for public github issue comment",
      ],
      "destinations": [
        "redacted destination for public github issue comment",
      ],
      "options": {
        "title": "New Copied Message",
        "richEmbed": true,
        "richEmbedColor": 30975,
        "includeSource": true,
        "removeEveryone": true,
        "removeHere": true,
        "copyRichEmbed": true,
        "copyAttachments": true,
        "minLength": 0,
        "allowList": []
      }
    }
  ]
}

EDIT: Closing this issue. I had commas after single values in the source/destination ! Woops! Thank you for all the help!

from discord-echobot.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.