mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-04-13 19:40:06 -04:00
Move temp file in a tmp dir when generating dist files, tidy up Gruntfile.js
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -1,6 +1,6 @@
|
||||
node_modules
|
||||
bower_components
|
||||
dist/*_bower.*
|
||||
tmp
|
||||
application/config/email.php
|
||||
application/config/database.php
|
||||
*.patch
|
||||
|
||||
32
Gruntfile.js
32
Gruntfile.js
@@ -17,11 +17,11 @@ module.exports = function(grunt) {
|
||||
bower_concat: {
|
||||
all: {
|
||||
mainFiles: {
|
||||
'bootswatch-dist': ['bootstrap/dist/js/bootstrap.js']
|
||||
'bootswatch-dist': ['bootstrap/dist/js/bootstrap.js'],
|
||||
},
|
||||
dest: {
|
||||
'js': 'dist/opensourcepos_bower.js',
|
||||
'css': 'dist/opensourcepos_bower.css'
|
||||
'js': 'tmp/opensourcepos_bower.js',
|
||||
'css': 'tmp/opensourcepos_bower.css'
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -30,20 +30,28 @@ module.exports = function(grunt) {
|
||||
// Bower components folder will be removed afterwards
|
||||
// clean: true
|
||||
},
|
||||
bootstrap: {
|
||||
targetdist: {
|
||||
options: {
|
||||
destPrefix: 'dist'
|
||||
},
|
||||
files: {
|
||||
'jquery-ui.css': 'jquery-ui/themes/base/jquery-ui.css',
|
||||
'jquery-ui.css': 'jquery-ui/themes/base/jquery-ui.css',
|
||||
'bootstrap.min.css': 'bootswatch-dist/css/bootstrap.min.css'
|
||||
}
|
||||
}
|
||||
}/*,
|
||||
targettmp: {
|
||||
options: {
|
||||
destPrefix: 'tmp'
|
||||
},
|
||||
files: {
|
||||
// add here anything that should be copied in a tmp directory
|
||||
}
|
||||
}*/
|
||||
},
|
||||
cssmin: {
|
||||
target: {
|
||||
files: {
|
||||
'dist/<%= pkg.name %>.min.css': ['dist/opensourcepos_bower.css', 'css/*.css', '!css/login.css', '!css/invoice_email.css']
|
||||
'dist/<%= pkg.name %>.min.css': ['tmp/opensourcepos_bower.css', 'css/*.css', '!css/login.css', '!css/invoice_email.css']
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -53,7 +61,7 @@ module.exports = function(grunt) {
|
||||
separator: ';'
|
||||
},
|
||||
files: {
|
||||
'dist/<%= pkg.name %>.js': ['dist/opensourcepos_bower.js', 'js/jquery*', 'js/*.js']
|
||||
'dist/<%= pkg.name %>.js': ['tmp/opensourcepos_bower.js', 'js/*.js']
|
||||
}
|
||||
},
|
||||
sql: {
|
||||
@@ -107,7 +115,7 @@ module.exports = function(grunt) {
|
||||
closeTag: '<!-- end mincss template tags -->',
|
||||
absolutePath: true
|
||||
},
|
||||
src: [ 'dist/*.css', '!dist/opensourcepos_bower.css' ],
|
||||
src: [ 'dist/*.css' ],
|
||||
dest: 'application/views/partial/header.php',
|
||||
},
|
||||
mincss_header_templates: {
|
||||
@@ -117,7 +125,7 @@ module.exports = function(grunt) {
|
||||
closeTag: '<!-- end mincss template tags -->',
|
||||
absolutePath: true
|
||||
},
|
||||
src: [ 'dist/*.css', '!dist/bootstrap.min.css', '!dist/opensourcepos_bower.css' ],
|
||||
src: [ 'dist/*.css', '!dist/bootstrap.min.css' ],
|
||||
dest: 'templates/spacelab/views/partial/header.php'
|
||||
},
|
||||
css_login: {
|
||||
@@ -127,7 +135,7 @@ module.exports = function(grunt) {
|
||||
closeTag: '<!-- end css template tags -->',
|
||||
absolutePath: true
|
||||
},
|
||||
src: [ 'dist/jquery-ui.min.css', 'dist/bootstrap.min.css', 'css/login.css' ],
|
||||
src: [ 'dist/bootstrap.min.css', 'css/login.css' ],
|
||||
dest: 'application/views/login.php'
|
||||
},
|
||||
js: {
|
||||
@@ -137,7 +145,7 @@ module.exports = function(grunt) {
|
||||
closeTag: '<!-- end js template tags -->',
|
||||
absolutePath: true
|
||||
},
|
||||
src: [ 'js/jquery*', 'js/*.js' ],
|
||||
src: [ 'js/*.js' ],
|
||||
dest: 'application/views/partial/header.php',
|
||||
dest: 'templates/spacelab/views/partial/header.php'
|
||||
},
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
<link rel="stylesheet" type="text/css" href="dist/opensourcepos.min.css?rel=6ad34bf178"/>
|
||||
<!-- end mincss template tags -->
|
||||
<!-- start minjs template tags -->
|
||||
<script type="text/javascript" src="dist/opensourcepos.min.js?rel=1bec5a999a" language="javascript"></script>
|
||||
<script type="text/javascript" src="dist/opensourcepos.min.js?rel=593270d361" language="javascript"></script>
|
||||
<!-- end minjs template tags -->
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
"jquery": "~1.12.3",
|
||||
"jquery-ui": "1.11.4",
|
||||
"swfobject-bower": "2.3.0",
|
||||
"tablesorter": "jquery.tablesorter#^2.25.7",
|
||||
"tablesorter": "jquery.tablesorter#^2.25.8",
|
||||
"bootstrap3-dialog": "bootstrap-dialog#^1.35.1",
|
||||
"jasny-bootstrap": "^3.1.3",
|
||||
"bootswatch-dist": "3.3.6-flatly",
|
||||
|
||||
181
dist/opensourcepos.js
vendored
181
dist/opensourcepos.js
vendored
File diff suppressed because one or more lines are too long
11
dist/opensourcepos.min.js
vendored
11
dist/opensourcepos.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -47,9 +47,9 @@
|
||||
<script src="bower_components/bootstrap-daterangepicker/daterangepicker.js"></script>
|
||||
<!-- endbower -->
|
||||
<!-- start js template tags -->
|
||||
<script type="text/javascript" src="js/jquery.tablesorter.staticrow.js" language="javascript"></script>
|
||||
<script type="text/javascript" src="js/common.js" language="javascript"></script>
|
||||
<script type="text/javascript" src="js/imgpreview.full.jquery.js" language="javascript"></script>
|
||||
<script type="text/javascript" src="js/jquery.tablesorter.staticrow.js" language="javascript"></script>
|
||||
<script type="text/javascript" src="js/manage_tables.js" language="javascript"></script>
|
||||
<script type="text/javascript" src="js/nominatim.autocomplete.js" language="javascript"></script>
|
||||
<script type="text/javascript" src="js/phpjsdate.js" language="javascript"></script>
|
||||
@@ -65,7 +65,7 @@
|
||||
<!-- end mincss template tags -->
|
||||
<link rel="stylesheet" type="text/css" href="templates/spacelab/css/style.css"/>
|
||||
<!-- start minjs template tags -->
|
||||
<script type="text/javascript" src="dist/opensourcepos.min.js?rel=1bec5a999a" language="javascript"></script>
|
||||
<script type="text/javascript" src="dist/opensourcepos.min.js?rel=593270d361" language="javascript"></script>
|
||||
<!-- end minjs template tags -->
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user