fix compatibility with pouchdb 5.4.x
This commit is contained in:
parent
7aaba6be26
commit
d1226c6936
|
@ -1,24 +1,22 @@
|
|||
language: node_js
|
||||
|
||||
sudo: false
|
||||
services:
|
||||
- couchdb
|
||||
|
||||
node_js:
|
||||
- "stable"
|
||||
- "5"
|
||||
sudo: false
|
||||
script: npm run $COMMAND
|
||||
before_script:
|
||||
- "export DISPLAY=:99.0"
|
||||
- "sh -e /etc/init.d/xvfb start"
|
||||
- "npm install add-cors-to-couchdb"
|
||||
- "./node_modules/.bin/add-cors-to-couchdb"
|
||||
|
||||
env:
|
||||
matrix:
|
||||
- COMMAND=test
|
||||
- CLIENT=selenium:firefox COMMAND=test
|
||||
- CLIENT=selenium:phantomjs COMMAND=test
|
||||
- COMMAND=coverage
|
||||
|
||||
branches:
|
||||
only:
|
||||
- master
|
||||
|
|
|
@ -1,12 +1,6 @@
|
|||
'use strict';
|
||||
|
||||
var Promise;
|
||||
/* istanbul ignore next */
|
||||
if (typeof window !== 'undefined' && window.PouchDB) {
|
||||
Promise = window.PouchDB.utils.Promise;
|
||||
} else {
|
||||
Promise = typeof global.Promise === 'function' ? global.Promise : require('lie');
|
||||
}
|
||||
var Promise = require('pouchdb-promise');
|
||||
/* istanbul ignore next */
|
||||
exports.once = function (fun) {
|
||||
var called = false;
|
||||
|
@ -92,4 +86,4 @@ exports.MD5 = function (string) {
|
|||
return crypto.createHash('md5').update(string).digest('hex');
|
||||
};
|
||||
|
||||
exports.extend = require('pouchdb-extend');
|
||||
exports.extend = require('pouchdb-extend');
|
36
package.json
36
package.json
|
@ -2,7 +2,7 @@
|
|||
"name": "pouchdb-quick-search",
|
||||
"version": "1.1.1",
|
||||
"description": "PouchDB Quick Search - persisted full-text search for PouchDB",
|
||||
"main": "index.js",
|
||||
"main": "lib/index.js",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/nolanlawson/pouchdb-quick-search.git"
|
||||
|
@ -23,9 +23,9 @@
|
|||
"scripts": {
|
||||
"test-node": "TEST_DB=testdb istanbul test ./node_modules/mocha/bin/_mocha test/test.js",
|
||||
"test-browser": "./bin/test-browser.js",
|
||||
"jshint": "jshint -c .jshintrc *.js test/test.js",
|
||||
"jshint": "jshint -c .jshintrc lib/*.js test/test.js",
|
||||
"test": "npm run jshint && ./bin/run-test.sh",
|
||||
"build": "mkdir -p dist && browserify index.js -o dist/pouchdb.quick-search.js && npm run min",
|
||||
"build": "mkdir -p dist && browserify . -t es3ify -o dist/pouchdb.quick-search.js && npm run min",
|
||||
"min": "uglifyjs dist/pouchdb.quick-search.js -mc > dist/pouchdb.quick-search.min.js",
|
||||
"dev": "browserify test/test.js > test/test-bundle.js && npm run dev-server",
|
||||
"dev-server": "./bin/dev-server.js",
|
||||
|
@ -40,32 +40,26 @@
|
|||
"md5-jkmyers": "0.0.1",
|
||||
"pouchdb-extend": "^0.1.0",
|
||||
"pouchdb-mapreduce-no-ddocs": "^2.3.1",
|
||||
"pouchdb-promise": "5.4.4",
|
||||
"uniq": "^1.0.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"bluebird": "^1.0.7",
|
||||
"browserify": "~2.36.0",
|
||||
"chai": "~1.8.1",
|
||||
"chai-as-promised": "~4.1.0",
|
||||
"browserify": "^12.0.2",
|
||||
"chai": "^3.5.0",
|
||||
"chai-as-promised": "^5.3.0",
|
||||
"http-server": "~0.5.5",
|
||||
"istanbul": "^0.2.7",
|
||||
"jshint": "~2.3.0",
|
||||
"mocha": "~1.18",
|
||||
"phantomjs": "^1.9.7-5",
|
||||
"pouchdb": "5.2.1",
|
||||
"jshint": "~2.8.0",
|
||||
"mocha": "^2.4.5",
|
||||
"phantomjs-prebuilt": "^2.1.7",
|
||||
"pouchdb": "^5.4.0",
|
||||
"request": "^2.36.0",
|
||||
"sauce-connect-launcher": "^0.11.1",
|
||||
"selenium-standalone": "^4.7.0",
|
||||
"sauce-connect-launcher": "^0.14.0",
|
||||
"selenium-standalone": "^5.1.0",
|
||||
"uglify-js": "^2.4.13",
|
||||
"watchify": "~0.4.1",
|
||||
"watchify": "^3.1.0",
|
||||
"wd": "^0.2.21"
|
||||
},
|
||||
"browser": {
|
||||
"crypto": false
|
||||
},
|
||||
"browserify": {
|
||||
"transform": [
|
||||
"es3ify"
|
||||
]
|
||||
}
|
||||
"lib": ["lib", "dist"]
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue