mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-05-02 21:29:12 -04:00
not working atm
This commit is contained in:
parent
1702c7c34e
commit
4fbf0e8e2a
68 changed files with 238 additions and 9606 deletions
|
@ -8,7 +8,7 @@ if (process.argv.length != 2) {
|
|||
}
|
||||
|
||||
// load and initialize NPM
|
||||
const npm = require('../src/node_modules/npm');
|
||||
const npm = require('npm');
|
||||
npm.load({}, async () => {
|
||||
try {
|
||||
// initialize the database
|
||||
|
|
|
@ -11,7 +11,7 @@ if (process.argv.length != 3) {
|
|||
const padId = process.argv[2];
|
||||
|
||||
// load and initialize NPM;
|
||||
const npm = require('../src/node_modules/npm');
|
||||
const npm = require('npm');
|
||||
npm.load({}, async () => {
|
||||
try {
|
||||
// initialize database
|
||||
|
@ -20,7 +20,7 @@ npm.load({}, async () => {
|
|||
await db.init();
|
||||
|
||||
// load modules
|
||||
const Changeset = require('ep_etherpad-lite/static/js/Changeset');
|
||||
const Changeset = require('../src/static/js/Changeset');
|
||||
const padManager = require('../src/node/db/PadManager');
|
||||
|
||||
const exists = await padManager.doesPadExists(padId);
|
||||
|
|
|
@ -15,9 +15,9 @@ const expect = require('expect.js');
|
|||
const diff = require('diff');
|
||||
var async = require('async');
|
||||
|
||||
const npm = require('../src/node_modules/npm');
|
||||
var async = require('ep_etherpad-lite/node_modules/async');
|
||||
const Changeset = require('ep_etherpad-lite/static/js/Changeset');
|
||||
const npm = require('npm');
|
||||
var async = require('async');
|
||||
const Changeset = require('../src/static/js/Changeset');
|
||||
|
||||
npm.load({}, async () => {
|
||||
try {
|
||||
|
@ -27,7 +27,7 @@ npm.load({}, async () => {
|
|||
await db.init();
|
||||
|
||||
// load modules
|
||||
const Changeset = require('ep_etherpad-lite/static/js/Changeset');
|
||||
const Changeset = require('../src/static/js/Changeset');
|
||||
const padManager = require('../src/node/db/PadManager');
|
||||
|
||||
const exists = await padManager.doesPadExists(padId);
|
||||
|
|
|
@ -32,7 +32,7 @@ if [ "$(id -u)" -eq 0 ] && [ $ignoreRoot -eq 0 ]; then
|
|||
fi
|
||||
|
||||
#Clean the current environment
|
||||
rm -rf src/node_modules
|
||||
rm -rf node_modules
|
||||
|
||||
#Prepare the environment
|
||||
bin/installDeps.sh "$@" || exit 1
|
||||
|
@ -41,4 +41,4 @@ bin/installDeps.sh "$@" || exit 1
|
|||
echo "Started Etherpad..."
|
||||
|
||||
SCRIPTPATH=$(pwd -P)
|
||||
node $(compute_node_args) "${SCRIPTPATH}/node_modules/ep_etherpad-lite/node/server.js" "$@"
|
||||
node $(compute_node_args) "${SCRIPTPATH}/src/node/server.js" "$@"
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
const startTime = Date.now();
|
||||
const fs = require('fs');
|
||||
const ueberDB = require('../src/node_modules/ueberdb2');
|
||||
const mysql = require('../src/node_modules/ueberdb2/node_modules/mysql');
|
||||
const async = require('../src/node_modules/async');
|
||||
const Changeset = require('ep_etherpad-lite/static/js/Changeset');
|
||||
const randomString = require('ep_etherpad-lite/static/js/pad_utils').randomString;
|
||||
const AttributePool = require('ep_etherpad-lite/static/js/AttributePool');
|
||||
const ueberDB = require('ueberdb2');
|
||||
const mysql = require('ueberdb2/node_modules/mysql');
|
||||
const async = require('async');
|
||||
const Changeset = require('../src/static/js/Changeset');
|
||||
const randomString = require('../src/static/js/pad_utils').randomString;
|
||||
const AttributePool = require('../src/static/js/AttributePool');
|
||||
|
||||
const settingsFile = process.argv[2];
|
||||
const sqlOutputFile = process.argv[3];
|
||||
|
|
|
@ -7,9 +7,9 @@ const m = (f) => `${__dirname}/../${f}`;
|
|||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
const querystring = require('querystring');
|
||||
const request = require(m('src/node_modules/request'));
|
||||
const request = require('request');
|
||||
const settings = require(m('src/node/utils/Settings'));
|
||||
const supertest = require(m('src/node_modules/supertest'));
|
||||
const supertest = require('supertest');
|
||||
|
||||
(async () => {
|
||||
const api = supertest(`http://${settings.ip}:${settings.port}`);
|
||||
|
|
|
@ -20,7 +20,7 @@ end script
|
|||
|
||||
script
|
||||
cd $EPHOME/
|
||||
exec su -s /bin/sh -c 'exec "$0" "$@"' $EPUSER -- node node_modules/ep_etherpad-lite/node/server.js \
|
||||
exec su -s /bin/sh -c 'exec "$0" "$@"' $EPUSER -- node src/node/server.js \
|
||||
>> $EPLOGS/access.log \
|
||||
2>> $EPLOGS/error.log
|
||||
echo "Etherpad is running on http://localhost:9001 - To change settings edit /opt/etherpad/settings.json"
|
||||
|
|
|
@ -15,4 +15,4 @@ echo "Open 'chrome://inspect' on Chrome to start debugging."
|
|||
|
||||
# Use 0.0.0.0 to allow external connections to the debugger
|
||||
# (ex: running Etherpad on a docker container). Use default port # (9229)
|
||||
node $(compute_node_args) --inspect=0.0.0.0:9229 node_modules/ep_etherpad-lite/node/server.js "$@"
|
||||
node $(compute_node_args) --inspect=0.0.0.0:9229 src/node/server.js "$@"
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
* because sometimes a brick is required to fix a face.
|
||||
*/
|
||||
|
||||
const request = require('../src/node_modules/request');
|
||||
const request = require('request');
|
||||
const settings = require(`${__dirname}/../tests/container/loadSettings`).loadSettings();
|
||||
const supertest = require(`${__dirname}/../src/node_modules/supertest`);
|
||||
const supertest = require('supertest');
|
||||
const api = supertest(`http://${settings.ip}:${settings.port}`);
|
||||
const path = require('path');
|
||||
const fs = require('fs');
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
* to fix a window.
|
||||
*/
|
||||
|
||||
const request = require('../src/node_modules/request');
|
||||
const request = require('request');
|
||||
const settings = require(`${__dirname}/../tests/container/loadSettings`).loadSettings();
|
||||
const supertest = require(`${__dirname}/../src/node_modules/supertest`);
|
||||
const supertest = require('supertest');
|
||||
const api = supertest(`http://${settings.ip}:${settings.port}`);
|
||||
const path = require('path');
|
||||
const fs = require('fs');
|
||||
|
|
|
@ -12,7 +12,7 @@ if (process.argv.length != 3) {
|
|||
// get the padID
|
||||
const padId = process.argv[2];
|
||||
|
||||
const npm = require('../src/node_modules/npm');
|
||||
const npm = require('npm');
|
||||
|
||||
npm.load({}, async (er) => {
|
||||
if (er) {
|
||||
|
@ -27,7 +27,7 @@ npm.load({}, async (er) => {
|
|||
await db.init();
|
||||
|
||||
// load extra modules
|
||||
const dirtyDB = require('../src/node_modules/dirty');
|
||||
const dirtyDB = require('dirty');
|
||||
const padManager = require('../src/node/db/PadManager');
|
||||
const util = require('util');
|
||||
|
||||
|
|
|
@ -22,4 +22,4 @@ echo "Running directly, without checking/installing dependencies"
|
|||
cd "${DIR}/.."
|
||||
|
||||
# run Etherpad main class
|
||||
node $(compute_node_args) "${DIR}/../node_modules/ep_etherpad-lite/node/server.js" "$@"
|
||||
node $(compute_node_args) "${DIR}/../src/node/server.js" "$@"
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
const startTime = Date.now();
|
||||
|
||||
require('ep_etherpad-lite/node_modules/npm').load({}, (er, npm) => {
|
||||
require('npm').load({}, (er, npm) => {
|
||||
const fs = require('fs');
|
||||
|
||||
const ueberDB = require('ep_etherpad-lite/node_modules/ueberdb2');
|
||||
const settings = require('ep_etherpad-lite/node/utils/Settings');
|
||||
const log4js = require('ep_etherpad-lite/node_modules/log4js');
|
||||
const ueberDB = require('ueberdb2');
|
||||
const settings = require('../src/node/utils/Settings');
|
||||
const log4js = require('log4js');
|
||||
|
||||
const dbWrapperSettings = {
|
||||
cache: 0,
|
||||
|
|
|
@ -37,9 +37,7 @@ log "Ensure that all dependencies are up to date... If this is the first time y
|
|||
(
|
||||
npm ci
|
||||
) || {
|
||||
rm -rf src/node_modules
|
||||
rm -rf node_modules
|
||||
git restore node_modules/ep_etherpad-lite
|
||||
exit 1
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require('ep_etherpad-lite/node_modules/npm').load({}, (er, npm) => {
|
||||
require('npm').load({}, (er, npm) => {
|
||||
process.chdir(`${npm.root}/..`);
|
||||
|
||||
// This script requires that you have modified your settings.json file
|
||||
|
@ -9,10 +9,10 @@ require('ep_etherpad-lite/node_modules/npm').load({}, (er, npm) => {
|
|||
// `node --max-old-space-size=4096 bin/migrateDirtyDBtoRealDB.js`
|
||||
|
||||
|
||||
const settings = require('ep_etherpad-lite/node/utils/Settings');
|
||||
let dirty = require('../src/node_modules/dirty');
|
||||
const ueberDB = require('../src/node_modules/ueberdb2');
|
||||
const log4js = require('../src/node_modules/log4js');
|
||||
const settings = require('../src/node/utils/Settings');
|
||||
let dirty = require('dirty');
|
||||
const ueberDB = require('ueberdb2');
|
||||
const log4js = require('log4js');
|
||||
const dbWrapperSettings = {
|
||||
cache: '0', // The cache slows things down when you're mostly writing.
|
||||
writeInterval: 0, // Write directly to the database, don't buffer
|
||||
|
|
|
@ -115,7 +115,7 @@ You can build the docs e.g. produce html, using `make docs`. At some point in th
|
|||
## Testing
|
||||
Front-end tests are found in the `tests/frontend/` folder in the repository. Run them by pointing your browser to `<yourdomainhere>/tests/frontend`.
|
||||
|
||||
Back-end tests can be run from the `src` directory, via `npm test`.
|
||||
Back-end tests can be run via `npm run test`.
|
||||
|
||||
## Things you can help with
|
||||
Etherpad is much more than software. So if you aren't a developer then worry not, there is still a LOT you can do! A big part of what we do is community engagement. You can help in the following ways
|
||||
|
|
|
@ -23,7 +23,7 @@ Visit http://whatever/tests/frontend/ to run the frontend tests.
|
|||
|
||||
### backend
|
||||
|
||||
Type ``cd src && npm run test`` to run the backend tests.
|
||||
Type ``npm run test`` to run the backend tests.
|
||||
|
||||
## LICENSE
|
||||
Apache 2.0
|
||||
|
|
|
@ -29,7 +29,7 @@ jobs:
|
|||
with:
|
||||
repository: ether/etherpad-lite
|
||||
|
||||
- name: Install all dependencies and symlink for ep_etherpad-lite
|
||||
- name: Install all dependencies
|
||||
run: bin/installDeps.sh
|
||||
|
||||
# clone this repository into node_modules/ep_plugin-name
|
||||
|
|
|
@ -8,9 +8,9 @@ if (process.argv.length != 4 && process.argv.length != 5) {
|
|||
process.exit(1);
|
||||
}
|
||||
|
||||
const npm = require('../src/node_modules/npm');
|
||||
const async = require('../src/node_modules/async');
|
||||
const ueberDB = require('../src/node_modules/ueberdb2');
|
||||
const npm = require('npm');
|
||||
const async = require('async');
|
||||
const ueberDB = require('ueberdb2');
|
||||
|
||||
const padId = process.argv[2];
|
||||
const newRevHead = process.argv[3];
|
||||
|
@ -75,7 +75,7 @@ async.series([
|
|||
function (callback) {
|
||||
// Rebuild Pad from revisions up to and including the new revision head
|
||||
AuthorManager = require('../src/node/db/AuthorManager');
|
||||
Changeset = require('ep_etherpad-lite/static/js/Changeset');
|
||||
Changeset = require('../src/static/js/Changeset');
|
||||
// Author attributes are derived from changesets, but there can also be
|
||||
// non-author attributes with specific mappings that changesets depend on
|
||||
// and, AFAICT, cannot be recreated any other way
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
const fs = require('fs');
|
||||
const child_process = require('child_process');
|
||||
const semver = require('../src/node_modules/semver');
|
||||
const semver = require('semver');
|
||||
|
||||
/*
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ if (process.argv.length != 3) {
|
|||
// get the padID
|
||||
const padId = process.argv[2];
|
||||
|
||||
const npm = require('../src/node_modules/npm');
|
||||
const npm = require('npm');
|
||||
npm.load({}, async (er) => {
|
||||
if (er) {
|
||||
console.error(`Could not load NPM: ${er}`);
|
||||
|
|
|
@ -32,4 +32,4 @@ bin/installDeps.sh "$@" || exit 1
|
|||
log "Starting Etherpad..."
|
||||
|
||||
SCRIPTPATH=$(pwd -P)
|
||||
exec node $(compute_node_args) "$SCRIPTPATH/node_modules/ep_etherpad-lite/node/server.js" "$@"
|
||||
exec node $(compute_node_args) "$SCRIPTPATH/src/node/server.js" "$@"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue