Skip to content

Commit

Permalink
Move generated code under generated-folder
Browse files Browse the repository at this point in the history
  • Loading branch information
eeroan committed Mar 10, 2016
1 parent 724f154 commit f190e97
Show file tree
Hide file tree
Showing 11 changed files with 703 additions and 316 deletions.
997 changes: 692 additions & 305 deletions src/history/historyData.js → generated/historyData.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/locations.js → generated/locations.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ module.exports = [ { title: 'tali',
address: 'Koivu-Mankkaan tie 5, 02200 Espoo',
tel: '09 502 4700' },
{ title: 'hiekkaharju',
lat: 60.3048739,
lng: 25.052336,
lat: 60.3043802,
lng: 25.0522693,
url: 'https://www.slsystems.fi/hiekkaharjuntenniskeskus/',
address: 'Tennistie 5, 01370 Vantaa',
tel: '09 8731923' },
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion scripts/fetchHistory.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ dao.getHistoryData((err, data) => {
} else {
var fileName = 'historyData.js'
console.log('Writing history data to ' + fileName)
fs.writeFileSync(__dirname + '/../src/history/' + fileName, format.formatModule(data))
fs.writeFileSync(__dirname + '/../generated/' + fileName, format.formatModule(data))
}
})
2 changes: 1 addition & 1 deletion scripts/fetchPrices.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ function fetchAll() {
Bacon.combineTemplate(_.mapValues(sheets, fetchForOrCombineTemplate))
.onValue(function (data) {
console.log('Writing rates to ' + fileName)
fs.writeFileSync(__dirname + '/../src/' + fileName, format.formatModule(data))
fs.writeFileSync(__dirname + '/../generated/' + fileName, format.formatModule(data))
})
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/updateLocations.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function locations() {
})
})).onValue(function (data) {
console.log('Writing locations to ' + fileName)
fs.writeFileSync(__dirname + '/../src/' + fileName, format.formatModule(data))
fs.writeFileSync(__dirname + '/../generated/' + fileName, format.formatModule(data))
})
}

Expand Down
2 changes: 1 addition & 1 deletion src/dao/dao.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ var webTimmi = require('./webTimmiCrawler')
var DateTime = require('dateutils').DateTime
var MongoClient = require('mongodb').MongoClient
var mongoUri = process.env.MONGOLAB_URI || process.env.MONGOHQ_URL || 'mongodb://localhost/test';
var rates = require('../rates')
var rates = require('../../generated/rates')
var format = require('../format')

module.exports = {
Expand Down
2 changes: 1 addition & 1 deletion src/front.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ attachFastClick(document.body)
var $window = $(window)
var $document = $(document)
var markupForDateRange = require('./markupForDateRange')
var locations = require('./locations')
var locations = require('../generated/locations')
const format = require('./format')
var didScroll = false
var alreadyLoadingMoreResults = false
Expand Down
4 changes: 2 additions & 2 deletions src/history/history.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
#!/usr/bin/env node
const _ = require('lodash')
const historyData = require('./historyData')
const historyData = require('../../generated/historyData')
const DateTime = require('dateutils').DateTime
const DateFormat = require('dateutils').DateFormat
const DateLocale = require('dateutils').DateLocale
const format = require('../format')
const rates = require('../rates')
const rates = require('../../generated/rates')
const historyHtml = require('./history.html')
const headHtml = require('../head.html')
const dao = require('../dao/dao')
Expand Down
2 changes: 1 addition & 1 deletion src/mapView.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
var locations = require('./locations')
var locations = require('../generated/locations')

module.exports = {
renderMap: renderMap
Expand Down
2 changes: 1 addition & 1 deletion src/markupForDateRange.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
var locations = require('./locations')
var locations = require('../generated/locations')
var _ = require('lodash')
const dateutils = require('dateutils')
var DateTime = dateutils.DateTime
Expand Down

0 comments on commit f190e97

Please sign in to comment.