diff --git a/.bowerrc b/.bowerrc deleted file mode 100644 index 6866ac2..0000000 --- a/.bowerrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "directory": "vendor" -} diff --git a/.gitignore b/.gitignore index b7d6fa6..9993285 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,10 @@ -.phpintel -vendor/ +/.phpintel +/.env +/.idea/ +/vendor/ +/node_modules/ +/composer.lock +/package-lock.json +/public/css/ +/public/js/ +/public/img/ diff --git a/gulpfile.js b/gulpfile.js new file mode 100644 index 0000000..b995a6c --- /dev/null +++ b/gulpfile.js @@ -0,0 +1,41 @@ +var gulp = require('gulp'); +var copy = require('gulp-copy'); +var del = require('del'); + +gulp.task('default', ['img', 'css', 'js']); + +gulp.task('clean:img', function () { + return del(['public/img']); +}); + +gulp.task('img', ['clean:img'], function () { + return gulp.src('resources/img/**/*') + .pipe(gulp.dest('public/img')); +}); + +gulp.task('clean:css', function () { + return del(['public/css']); +}); + +gulp.task('css', ['clean:css'], function () { + gulp.src(['resources/css/**/*.css']) + .pipe(gulp.dest('public/css')); + + gulp + .src([ + 'node_modules/bootstrap/dist/css/bootstrap.min.css', + 'node_modules/x-editable/dist/bootstrap3-editable/css/bootstrap-editable.css', + 'node_modules/bootstrap-table/dist/bootstrap-table.min.css', + 'node_modules/bootstrap-datepicker/dist/css/bootstrap-datepicker3.css' + ]) + .pipe(gulp.dest('public/css')); +}); + +gulp.task('clean:js', function () { + return del(['public/assets/js']); +}); + +gulp.task('js', ['clean:js'], function () { + gulp.src(['resources/js/**/*.js']) + .pipe(gulp.dest('public/js')); +}); diff --git a/bower.json b/package.json similarity index 54% rename from bower.json rename to package.json index fb22230..3475347 100644 --- a/bower.json +++ b/package.json @@ -2,21 +2,34 @@ "name": "openvpn-admin", "version": "0.3.2", "description": "Setup and administration of openvpn with a web interface", - "dependencies": { - "bootstrap": "^3.3.7", - "bootstrap-table": "^1.11.0", - "jquery": "^2.2.4", - "x-editable": "^1.5.1", - "bootstrap-datepicker": "^1.6.4" + "homepage": "https://github.com/EvilFreelancer/OpenVPN-Admin#readme", + "repository": { + "type": "git", + "url": "git+https://github.com/EvilFreelancer/OpenVPN-Admin.git" }, + "authors": [ + "Florian Bigard " + ], "keywords": [ "openvpn", "admin", "setup" ], - "authors": [ - "Florian Bigard " - ], "license": "GPLv3", - "private": true + "bugs": { + "url": "https://github.com/EvilFreelancer/OpenVPN-Admin/issues" + }, + "dependencies": { + "gulp": "^3.9.0", + "gulp-copy": "^1.1.0", + "del": "^2.0.0", + "bootstrap": "^3.3.7", + "bootstrap-table": "^1.11.0", + "jquery": "^2.2.4", + "x-editable": "^1.5.1", + "bootstrap-datepicker": "^1.6.4" + }, + "scripts": { + "postinstall": "gulp" + } } diff --git a/desinstall.sh b/public/desinstall.sh similarity index 100% rename from desinstall.sh rename to public/desinstall.sh diff --git a/include/config.php b/public/include/config.php similarity index 100% rename from include/config.php rename to public/include/config.php diff --git a/include/connect.php b/public/include/connect.php similarity index 100% rename from include/connect.php rename to public/include/connect.php diff --git a/include/functions.php b/public/include/functions.php similarity index 100% rename from include/functions.php rename to public/include/functions.php diff --git a/include/grids.php b/public/include/grids.php similarity index 100% rename from include/grids.php rename to public/include/grids.php diff --git a/include/html/form/configuration.php b/public/include/html/form/configuration.php similarity index 100% rename from include/html/form/configuration.php rename to public/include/html/form/configuration.php diff --git a/include/html/form/installation.php b/public/include/html/form/installation.php similarity index 100% rename from include/html/form/installation.php rename to public/include/html/form/installation.php diff --git a/include/html/form/login.php b/public/include/html/form/login.php similarity index 100% rename from include/html/form/login.php rename to public/include/html/form/login.php diff --git a/include/html/grids.php b/public/include/html/grids.php similarity index 100% rename from include/html/grids.php rename to public/include/html/grids.php diff --git a/include/html/menu.php b/public/include/html/menu.php similarity index 100% rename from include/html/menu.php rename to public/include/html/menu.php diff --git a/index.php b/public/index.php similarity index 91% rename from index.php rename to public/index.php index 8266dd8..4418211 100644 --- a/index.php +++ b/public/index.php @@ -95,13 +95,13 @@ OpenVPN-Admin - - - - - + + + + + - +