diff --git a/README.md b/README.md index 24ab0cc..9ecadc1 100644 --- a/README.md +++ b/README.md @@ -15,17 +15,19 @@ This is a backwards compatible continuation of the [work by Andrew Belt](https:/ ## Installing 1. [Clone](https://help.github.com/articles/cloning-a-repository/) the repository: `git clone https://github.com/hack-chat/main.git` +1. Change the directory: `cd main` 1. Install the dependencies using a package manager of your choice: - npm: `npm install` - yarn: `yarn install` -1. Configure: `node main/server/main.js` +1. Configure: `node server/main.js` If you change the `websocketPort` option during the config setup then these changes will need to be reflected on [line 59 of client.js](https://github.com/hack-chat/main/blob/master/client/client.js#L59). # Usage -1. Start the server with a process manager. For example, with [PM2](https://github.com/Unitech/pm2): `pm2 start main/server/main.js --name HackChat` -1. Launch: `main/client/index.html` +1. `cd` into the repository: `cd main` +1. Start the server with a process manager. For example, with [PM2](https://github.com/Unitech/pm2): `pm2 start server/main.js --name HackChat` +1. Launch: `client/index.html` 1. (OPTIONAL) If you want to deploy your hack.chat instance to a server, push everything except the `node_modules` directory and install the dependencies using a package manager of your choice: - npm: `npm install` - yarn: `yarn install` diff --git a/server/commands/admin/addmod.js b/server/src/commands/admin/addmod.js similarity index 100% rename from server/commands/admin/addmod.js rename to server/src/commands/admin/addmod.js diff --git a/server/commands/admin/listusers.js b/server/src/commands/admin/listusers.js similarity index 100% rename from server/commands/admin/listusers.js rename to server/src/commands/admin/listusers.js diff --git a/server/commands/admin/reload.js b/server/src/commands/admin/reload.js similarity index 100% rename from server/commands/admin/reload.js rename to server/src/commands/admin/reload.js diff --git a/server/commands/admin/saveconfig.js b/server/src/commands/admin/saveconfig.js similarity index 100% rename from server/commands/admin/saveconfig.js rename to server/src/commands/admin/saveconfig.js diff --git a/server/commands/admin/shout.js b/server/src/commands/admin/shout.js similarity index 100% rename from server/commands/admin/shout.js rename to server/src/commands/admin/shout.js diff --git a/server/commands/core/changenick.js b/server/src/commands/core/changenick.js similarity index 100% rename from server/commands/core/changenick.js rename to server/src/commands/core/changenick.js diff --git a/server/commands/core/chat.js b/server/src/commands/core/chat.js similarity index 100% rename from server/commands/core/chat.js rename to server/src/commands/core/chat.js diff --git a/server/commands/core/disconnect.js b/server/src/commands/core/disconnect.js similarity index 100% rename from server/commands/core/disconnect.js rename to server/src/commands/core/disconnect.js diff --git a/server/commands/core/help.js b/server/src/commands/core/help.js similarity index 100% rename from server/commands/core/help.js rename to server/src/commands/core/help.js diff --git a/server/commands/core/invite.js b/server/src/commands/core/invite.js similarity index 100% rename from server/commands/core/invite.js rename to server/src/commands/core/invite.js diff --git a/server/commands/core/join.js b/server/src/commands/core/join.js similarity index 100% rename from server/commands/core/join.js rename to server/src/commands/core/join.js diff --git a/server/commands/core/morestats.js b/server/src/commands/core/morestats.js similarity index 100% rename from server/commands/core/morestats.js rename to server/src/commands/core/morestats.js diff --git a/server/commands/core/move.js b/server/src/commands/core/move.js similarity index 100% rename from server/commands/core/move.js rename to server/src/commands/core/move.js diff --git a/server/commands/core/stats.js b/server/src/commands/core/stats.js similarity index 100% rename from server/commands/core/stats.js rename to server/src/commands/core/stats.js diff --git a/server/commands/mod/ban.js b/server/src/commands/mod/ban.js similarity index 100% rename from server/commands/mod/ban.js rename to server/src/commands/mod/ban.js diff --git a/server/commands/mod/kick.js b/server/src/commands/mod/kick.js similarity index 100% rename from server/commands/mod/kick.js rename to server/src/commands/mod/kick.js diff --git a/server/commands/mod/unban.js b/server/src/commands/mod/unban.js similarity index 100% rename from server/commands/mod/unban.js rename to server/src/commands/mod/unban.js diff --git a/server/core/rateLimiter.js b/server/src/core/rateLimiter.js similarity index 100% rename from server/core/rateLimiter.js rename to server/src/core/rateLimiter.js diff --git a/server/core/server.js b/server/src/core/server.js similarity index 100% rename from server/core/server.js rename to server/src/core/server.js diff --git a/server/managers/commands.js b/server/src/managers/commands.js similarity index 100% rename from server/managers/commands.js rename to server/src/managers/commands.js diff --git a/server/managers/config.js b/server/src/managers/config.js similarity index 100% rename from server/managers/config.js rename to server/src/managers/config.js diff --git a/server/managers/imports-manager.js b/server/src/managers/imports-manager.js similarity index 100% rename from server/managers/imports-manager.js rename to server/src/managers/imports-manager.js diff --git a/server/managers/index.js b/server/src/managers/index.js similarity index 100% rename from server/managers/index.js rename to server/src/managers/index.js diff --git a/server/managers/stats.js b/server/src/managers/stats.js similarity index 100% rename from server/managers/stats.js rename to server/src/managers/stats.js diff --git a/server/scripts/configure.js b/server/src/scripts/configure.js similarity index 100% rename from server/scripts/configure.js rename to server/src/scripts/configure.js diff --git a/server/scripts/debug.js b/server/src/scripts/debug.js similarity index 100% rename from server/scripts/debug.js rename to server/src/scripts/debug.js diff --git a/server/scripts/dev.js b/server/src/scripts/dev.js similarity index 100% rename from server/scripts/dev.js rename to server/src/scripts/dev.js