Skip to content

Commit

Permalink
Sync versions (resolves #7)
Browse files Browse the repository at this point in the history
  • Loading branch information
ClickerMonkey committed Aug 10, 2016
1 parent acc3d8a commit ec8ec36
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 9 deletions.
7 changes: 7 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
src/
test/
images/
docs/
.jshintrc
.travis.yml
jsdoc.json
19 changes: 15 additions & 4 deletions Gulpfile.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
'use strict';

var fs = require('fs');
var pkg = JSON.parse( fs.readFileSync('./package.json') );
var gulp = require('gulp');
var sourcemaps = require('gulp-sourcemaps');
var plugins = require('gulp-load-plugins')();
var gutil = require('gulp-util');
var shell = require('gulp-shell');
var size = require('gulp-check-filesize');
var jshint = require('gulp-jshint');
var rename = require('gulp-rename');
var insert = require('gulp-insert');

var build = {
filename: 'rekord-pouchdb.js',
Expand All @@ -17,14 +21,19 @@ var build = {
]
};

var comments = [
"/*", pkg.name, pkg.version, '-', pkg.description, 'by', pkg.author, "*/\n"
];

var executeMinifiedBuild = function(props)
{
return function() {
return gulp
.src( props.include )
.src( props.output + props.filename )
.pipe( rename( props.minified ) )
.pipe( sourcemaps.init() )
.pipe( plugins.concat( props.minified ) )
.pipe( plugins.uglify().on('error', gutil.log) )
.pipe( insert.prepend( comments.join(' ') ) )
.pipe( sourcemaps.write('.') )
.pipe( size({enableGzip: true}) )
.pipe( gulp.dest( props.output ) )
Expand All @@ -38,6 +47,7 @@ var executeBuild = function(props)
return gulp
.src( props.include )
.pipe( plugins.concat( props.filename ) )
.pipe( insert.prepend( comments.join(' ') ) )
.pipe( size({enableGzip: true}) )
.pipe( gulp.dest( props.output ) )
.pipe(jshint())
Expand All @@ -56,6 +66,7 @@ gulp.task('lint', function() {
;
});

gulp.task( 'js:min', executeMinifiedBuild( build ) );
gulp.task( 'js', executeBuild( build ) );
gulp.task( 'default', ['js:min', 'js']);
gulp.task( 'js:min', ['js'], executeMinifiedBuild( build ) );

gulp.task( 'default', ['js:min']);
5 changes: 3 additions & 2 deletions bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rekord-pouchdb",
"version": "1.0.1",
"version": "1.4.0",
"homepage": "https://github.com/Rekord/rekord-pouchdb",
"authors": [
"Philip Diffenderfer <pdiffenderfer@gmail.com>"
Expand All @@ -24,6 +24,7 @@
"tests"
],
"dependencies": {
"pouchdb": "~5.1.0"
"pouchdb": "~5.1.0",
"rekord": "~1.4.0"
}
}
1 change: 1 addition & 0 deletions build/rekord-pouchdb.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* rekord-pouchdb 1.4.0 - A rekord binding to pouchdb - implementing Rekord.rest, Rekord.live, & Rekord.store by Philip Diffenderfer */
(function(global, PouchDB, Rekord, undefined)
{

Expand Down
1 change: 1 addition & 0 deletions build/rekord-pouchdb.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build/rekord-pouchdb.min.js.map

Large diffs are not rendered by default.

6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rekord-pouchdb",
"version": "1.0.1",
"version": "1.4.0",
"description": "A rekord binding to pouchdb - implementing Rekord.rest, Rekord.live, & Rekord.store",
"author": "Philip Diffenderfer",
"license": "MIT",
Expand All @@ -15,8 +15,10 @@
"gulp": "^3.8.10",
"gulp-check-filesize": "^2.0.1",
"gulp-concat": "^2.4.3",
"gulp-insert": "^0.5.0",
"gulp-jshint": "^2.0.1",
"gulp-load-plugins": "^1.2.4",
"gulp-rename": "^1.2.2",
"gulp-shell": "^0.5.2",
"gulp-sourcemaps": "^1.3.0",
"gulp-uglify": "^1.0.2",
Expand All @@ -25,6 +27,6 @@
"jshint": "^2.9.2"
},
"dependencies": {
"rekord": "^1.2.0"
"rekord": "~1.4.0"
}
}

0 comments on commit ec8ec36

Please sign in to comment.