Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
hsnaydd committed Aug 16, 2015
2 parents a25cd32 + a283e55 commit dc79fdb
Show file tree
Hide file tree
Showing 20 changed files with 1,307 additions and 1,356 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@
node_modules/
bower_components/
npm-debug.log
untracked/
untracked/
.sass-cache/
src/validetta.css.map
161 changes: 85 additions & 76 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -1,90 +1,99 @@
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),

buildDir: 'dist',
buildDir: 'dist',

banner: '/*!\n' +
' * Validetta (<%= pkg.homepage %>)\n' +
' * Version <%= pkg.version %> ( <%= grunt.template.today("dd-mm-yyyy") %> )\n'+
' * Licensed under <%= pkg.license.type %> (<%= pkg.license.url %>)\n' +
' * Copyright 2013-<%= grunt.template.today("yyyy") %> <%= pkg.author.name %> - <%= pkg.author.url %> \n' +
' */\n',
clean: {
dist: '<%= buildDir %>'
},
banner: '/*!\n' +
' * Validetta (<%= pkg.homepage %>)\n' +
' * Version <%= pkg.version %> ( <%= grunt.template.today("dd-mm-yyyy") %> )\n'+
' * Licensed under <%= pkg.license.type %> (<%= pkg.license.url %>)\n' +
' * Copyright 2013-<%= grunt.template.today("yyyy") %> <%= pkg.author.name %> - <%= pkg.author.url %> \n' +
' */\n',
clean: {
dist: '<%= buildDir %>'
},

sync: {
all: {
options: {
sync: ['version'],
from: 'package.json',
to: 'bower.json'
}
}
},
sync: {
all: {
options: {
sync: ['version'],
from: 'package.json',
to: 'bower.json'
}
}
},

replace: {
dist: {
options: {
patterns: [
{ match: 'version', replacement: '<%= pkg.version %>' }
]
},
files: [
{ expand: true, flatten: true, src: ['untracked/validetta.jquery.json'], dest: '' }
]
}
replace: {
dist: {
options: {
patterns: [
{ match: 'version', replacement: '<%= pkg.version %>' }
]
},
files: [
{ expand: true, flatten: true, src: ['untracked/validetta.jquery.json'], dest: '' }
]
}
},

concat: {
css: {
options: {
stripBanners: true,
banner: '<%= banner %>\n'
},
src: ['src/<%= pkg.name %>.css'],
dest: '<%= buildDir %>/<%= pkg.name %>.css'
},
js: {
options: {
stripBanners: true,
banner: '<%= banner %>\n'
},
src: ['src/<%= pkg.name %>.js'],
dest: '<%= buildDir %>/<%= pkg.name %>.js'
}
},
sass: {
dist: {
files: {
'src/validetta.css': 'src/validetta.scss'
}
}
},

cssmin: {
add_banner: {
options: {
banner: '<%= banner %>'
},
files: {
'<%= buildDir %>/<%= pkg.name %>.min.css': ['src/<%= pkg.name %>.css']
}
}
concat: {
css: {
options: {
stripBanners: true,
banner: '<%= banner %>\n'
},
src: ['src/<%= pkg.name %>.css'],
dest: '<%= buildDir %>/<%= pkg.name %>.css'
},
js: {
options: {
stripBanners: true,
banner: '<%= banner %>\n'
},
src: ['src/<%= pkg.name %>.js'],
dest: '<%= buildDir %>/<%= pkg.name %>.js'
}
},

uglify: {
options: {
banner: '<%= banner %>'
},
build: {
src: 'src/<%= pkg.name %>.js',
dest: '<%= buildDir %>/<%= pkg.name %>.min.js'
}
cssmin: {
add_banner: {
options: {
banner: '<%= banner %>'
},
files: {
'<%= buildDir %>/<%= pkg.name %>.min.css': ['src/<%= pkg.name %>.css']
}
});
}
},

uglify: {
options: {
banner: '<%= banner %>'
},
build: {
src: 'src/<%= pkg.name %>.js',
dest: '<%= buildDir %>/<%= pkg.name %>.min.js'
}
}
});

grunt.registerTask('default', 'build');
grunt.registerTask('build', ['clean', 'sync', 'replace', 'concat', 'cssmin', 'uglify']);
grunt.registerTask('default', 'build');
grunt.registerTask('build', ['clean', 'sync', 'replace', 'sass', 'concat', 'cssmin', 'uglify']);

grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-npm2bower-sync');
grunt.loadNpmTasks('grunt-replace');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-contrib-sass');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-npm2bower-sync');
grunt.loadNpmTasks('grunt-replace');
};
2 changes: 1 addition & 1 deletion LICENCE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (C) 2013 Hasan Aydoğdu, http://www.hasanaydogdu.com
Copyright (C) 2013-2015 Hasan Aydoğdu, http://www.hasanaydogdu.com

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
Expand Down
20 changes: 0 additions & 20 deletions demo/files/ajax.json

This file was deleted.

20 changes: 0 additions & 20 deletions demo/files/ajax.php

This file was deleted.

6 changes: 0 additions & 6 deletions demo/files/jquery.js

This file was deleted.

13 changes: 0 additions & 13 deletions demo/files/remote.php

This file was deleted.

145 changes: 0 additions & 145 deletions demo/index.html

This file was deleted.

Loading

0 comments on commit dc79fdb

Please sign in to comment.