Skip to content

Commit

Permalink
Merge branch 'build-system'
Browse files Browse the repository at this point in the history
Conflicts:
	project/static/css/base.css
	project/static/css/feed.css
	project/templates/base.html
	project/templates/pages/mainpage.html
  • Loading branch information
n.lyubchich committed Jul 24, 2015
2 parents 0123621 + 2ca2840 commit 6085dbb
Show file tree
Hide file tree
Showing 20 changed files with 638 additions and 7,391 deletions.
13 changes: 13 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -106,4 +106,17 @@ com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties

# vim files:
[._]*.s[a-w][a-z]
[._]s[a-w][a-z]
*.un~
Session.vim
.netrwhist
*~

# Frontend stuff:
node_modules/
bower_components/

# frontend dist:
project/static/dist/
28 changes: 28 additions & 0 deletions bower.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"name": "meowth",
"version": "1.0.0",
"homepage": "https://github.com/uaprom-summer-2015/Meowth",
"authors": [
"Team A"
],
"description": "HR portal written during the internship at Prom.ua",
"keywords": [
"hrportal",
"internship",
"Prom.ua",
"python"
],
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"test",
"tests"
],
"dependencies": {
"bootstrap": "~3.3.5",
"bootstrap-stylus": "~4.0.5",
"bootstrap-select": "~1.6.5",
"blueimp-bootstrap-image-gallery": "~3.1.2"
}
}
50 changes: 50 additions & 0 deletions gulpfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
var gulp = require('gulp');
var pkginfo = require('./package.json');

var browserify = require('browserify');
var buffer = require('vinyl-buffer');
var del = require('del');
var gutil = require('gulp-util');
var rename = require('gulp-rename');
var source = require('vinyl-source-stream');
var stylus = require('gulp-stylus');
var uglify = require('gulp-uglify');



gulp.task('build', ['build:scripts', 'build:styles']);


gulp.task('build:scripts', function() {
browserify({
entries: pkginfo.assets.scripts.entries,
paths: pkginfo.assets.scripts.paths
}).bundle()
.pipe(source('bundle.js'))
.pipe(buffer())
.pipe(gutil.env.type === 'production' ? uglify() : gutil.noop())
.pipe(gulp.dest(pkginfo.dist));
});


gulp.task('build:styles', function() {
gulp.src(pkginfo.assets.styles.entries).pipe(stylus({
compress: true,
'include css': true,
include: pkginfo.stylus.includes
}))
.pipe(rename('bundle.css'))
.pipe(gulp.dest(pkginfo.dist));
});


gulp.task('watch', ['build'], function() {
gulp.watch(pkginfo.assets.scripts.watches, ['build:scripts']);
gulp.watch(pkginfo.assets.styles.watches, ['build:styles']);
});


gulp.task('clean', function(callback) {
glob = pkginfo.dist + '/*';
del([glob, '!.gitignore'], callback);
});
78 changes: 78 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
{
"name": "meowth",
"version": "1.0.0",
"description": "HR portal written during the internship at Prom.ua",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git+https://github.com/uaprom-summer-2015/Meowth.git"
},
"keywords": [
"internship",
"prom.ua",
"hrportal",
"python",
"postgresql"
],
"author": "Team A",
"bugs": {
"url": "https://github.com/uaprom-summer-2015/Meowth/issues"
},
"homepage": "https://github.com/uaprom-summer-2015/Meowth#readme",
"dependencies": {
"bower": "^1.4.1",
"debowerify": "^1.3.1",
"del": "^1.2.0",
"gulp": "^3.9.0",
"gulp-rename": "^1.2.2",
"gulp-stylus": "^2.0.5",
"gulp-uglify": "^1.2.0",
"gulp-util": "^3.0.6",
"reactify": "^1.1.1",
"vinyl-buffer": "^1.0.0",
"vinyl-source-stream": "^1.1.0",
"browserify": "~11.0.0"
},
"stylus": {
"includes": [
"./bower_components/bootstrap-stylus",
"./bower_components"
]
},
"browserify": {
"transform": [
"debowerify",
"reactify"
],
"extensions": [
".js",
".jsx"
]
},
"assets": {
"scripts": {
"entries": [
"./project/static/src/js/main.js"
],
"watches": [
"./project/static/src/js/**/*.js",
"./project/static/src/js/**/*.jsx"
],
"paths": [
"./node_modules",
"./project/static/src/js"
]
},
"styles": {
"entries": [
"./project/static/src/css/main.styl"
],
"watches": [
"./project/static/src/css/**/*.styl"
]
}
},
"dist": "./project/static/dist"
}
45 changes: 0 additions & 45 deletions project/static/css/base.css

This file was deleted.

87 changes: 0 additions & 87 deletions project/static/css/bootstrap-image-gallery.css

This file was deleted.

Loading

0 comments on commit 6085dbb

Please sign in to comment.