Permalink
Browse files

add gh-pages deploy

  • Loading branch information...
rashfael committed Apr 23, 2016
1 parent a033629 commit 94ca933d0d54559e3a03a3c6004a239c0a23d00a
Showing with 53 additions and 7 deletions.
  1. +1 −0 .babelrc
  2. +1 −0 .gitignore
  3. +5 −5 README.md
  4. +11 −0 gulpfile.babel.js
  5. +6 −2 package.json
  6. +29 −0 webpack.production.config.js
View
@@ -0,0 +1 @@
{"presets": ["es2015"]}
View
@@ -9,3 +9,4 @@ node_modules
public
config.js
.publish
View
@@ -1,13 +1,15 @@
# feinstaub-map
## [Live Version](http://opendata-stuttgart.github.io/feinstaub-map/)
## Goals and ideas
* visualize recent sensor data on a map
* identify and add existing air quality data from external sources
* gather air quality data on-the-go, develop a mobile solution, measure tracks
* visualize the track data on a map, too
## Mobile sensor
## Mobile sensor
* add GPS to existing sensor setup, see [commit](https://github.com/opendata-stuttgart/sensors-software/commit/58ff3fc409eb353f7f1e25051d55f153be9601b7)
* enable push GPS data to Django API (changes for GPS measurements see [commit](https://github.com/opendata-stuttgart/feinstaub-api/commit/6b0a1d20685b5e9dd3dcb351e9b0b8860465e8df)) and/or via MQTT
@@ -16,7 +18,7 @@
## Visualisation
This map visualisation was hacked during the NASA Space-Apps challenge 2016
This map visualisation was hacked during the NASA Space-Apps challenge 2016
https://2016.spaceappschallenge.org/locations/stuttgart-germany
The necessary steps were:
@@ -37,10 +39,8 @@ The application itself was created in JavaScript on top of a [leaflet](http://le
The implemetation makes use of various frameworks and is on ECMA6 language level.
Used frameworks are:
* [leaflet](http://leafletjs.com/) (mapping framework)
* [lodash](https://lodash.com/) (map, reduce, reorder data sets)
* [vue](http://vuejs.org/)
* [webpack](https://webpack.github.io/) is used for deployment
View
@@ -0,0 +1,11 @@
import gulp from 'gulp'
import ghPages from 'gulp-gh-pages'
import webpack from 'webpack-stream'
import config from './webpack.production.config.js'
gulp.task('deploy', () => {
return gulp.src('src/main.js')
.pipe(webpack(config))
.pipe(ghPages())
})
View
@@ -5,7 +5,8 @@
"description": "",
"main": "index.js",
"scripts": {
"start": "webpack-dev-server --inline"
"start": "webpack-dev-server --inline --host 0.0.0.0",
"build": "webpack -p --config webpack.production.config.js"
},
"author": "",
"license": "ISC",
@@ -21,6 +22,8 @@
"babel-runtime": "^6.6.1",
"css-loader": "^0.23.1",
"file-loader": "^0.8.5",
"gulp": "^3.9.1",
"gulp-gh-pages": "^0.5.4",
"html-loader": "^0.4.3",
"html-webpack-plugin": "^2.15.0",
"jade": "^1.11.0",
@@ -33,7 +36,8 @@
"stylus-loader": "^2.0.0",
"url-loader": "^0.5.7",
"webpack": "^2.1.0-beta.5",
"webpack-dev-server": "^2.0.0-beta"
"webpack-dev-server": "^2.0.0-beta",
"webpack-stream": "^3.2.0"
},
"dependencies": {
"d3": "^3.5.16",
@@ -0,0 +1,29 @@
var path = require('path');
var webpack = require('webpack');
var HtmlWebpackPlugin = require('html-webpack-plugin');
module.exports = {
entry: [
'babel-polyfill',
'./src/style.styl',
'./src/main',
],
output: {
filename: 'main.js'
},
module: {
loaders: [
{ test: /\.js$/, include: path.join(__dirname, 'src'), loader: 'babel-loader', query: { presets: ['es2015'] }},
{ test: /\.jade$/, loader: "html!jade-html" },
{ test: /\.styl$/, loader: 'style!css!stylus' },
{ test: /\.css$/, loader: 'style!css' },
{ test: /\.(png|jpg)$/, loader: 'file-loader' }
// { test: /\.less$/, loader: "style!css!autoprefixer!less" },
]
},
plugins: [new HtmlWebpackPlugin({
template: './src/index.html'
})],
stylus: {
use: [require('nib')(),require('axis')(),require('rupture')(),require('autoprefixer-stylus')()]
}
};

0 comments on commit 94ca933

Please sign in to comment.