diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..3f3206a --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) Maxwell Simmer (http://maxwellsimmer.com) 2019 + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..d69c583 --- /dev/null +++ b/README.md @@ -0,0 +1,18 @@ +# torrent-dashboard + +An Express app for managing Transmit clients + +## Install + +``` +npm i && npm run vendor +``` + +## Develop + +``` +npm run start:dev +``` + +Then navigate to http://localhost:3000/ + diff --git a/package.json b/package.json index 5578b26..71a3036 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "vendor": "node scripts/copy-vendor-scripts.js", "reset": ". ./env.sh && node scripts/reset-database.js", "start": "npm run vendor && node ./bin/www", - "start:dev": ". ./env.sh && DEBUG=dashboard:* node ./bin/www" + "start:dev": ". ./env.sh && npm run vendor && DEBUG=dashboard:* node ./bin/www" }, "dependencies": { "cookie-parser": "~1.4.4", @@ -21,5 +21,20 @@ }, "devDependencies": { "eslint": "^6.4.0" - } + }, + "description": "## Install", + "main": "bin/www", + "directories": { + "lib": "lib" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/msimmer/torrent-dashboard.git" + }, + "author": "Maxwell Simmer (http://maxwellsimmer.com)", + "license": "MIT", + "bugs": { + "url": "https://github.com/msimmer/torrent-dashboard/issues" + }, + "homepage": "https://github.com/msimmer/torrent-dashboard#readme" } diff --git a/routes/torrents.js b/routes/torrents.js index 23c63b8..67e1ea8 100644 --- a/routes/torrents.js +++ b/routes/torrents.js @@ -89,7 +89,7 @@ router.post('/remove', (req, res) => { api.removeTorrents(ports, torrents, error1 => { if (error1) return res.send({ error: error1, data: {} }) - // Update the torrents in the database by setting them to 'active' + // Update the torrents in the database by setting them to 'inactive' db.removeTorrents(torrentIds, error2 => { res.send({ error: error2, data: {} }) })