Skip to content
This repository has been archived by the owner on Feb 17, 2022. It is now read-only.

Commit

Permalink
Merge pull request #4 from Firstbloodio/develop
Browse files Browse the repository at this point in the history
See comment
  • Loading branch information
zackcoburn authored Oct 29, 2018
2 parents fb7b11d + 1a8c7c0 commit f182999
Show file tree
Hide file tree
Showing 7 changed files with 30 additions and 13 deletions.
22 changes: 18 additions & 4 deletions dapp/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# FirstBlood Dapp Installation Guide

This project was generated with Node JS, Electron Framework & Angular JS.
This project was generated with Node JS, Electron Framework & Angular JS. This guide explains how to build the project from source.

## Constants

Expand All @@ -18,15 +18,29 @@ This project was generated with Node JS, Electron Framework & Angular JS.
* Run `npm install` in root directory
* Run `npm install` in `app/resources` directory
* Run `bower install` in `app/frontend` directory
* For Launch application in local system without build, Run `npm start`
* To launch application in local system without build, Run `npm start`

## Version number

Update the version number in `app/frontend/modules/common/views/left_side_menu.html` and `package.json`

## Create build for Windows

After setup Run `npm run build.win`
After setup, run `npm run build.win`

## Create build for Mac

After setup Run `npm run build.mac`
After setup, run `npm run build.mac`

## Database location

* On Windows, `C:\Users\[USERNAME]\AppData\Local\Programs\FirstBlood\resources\app\firstblood.db`
* On Mac, `/Users/[USERNAME]/firstblood.db`

## Log file location

* On Windows, `C:\Users\[USERNAME]\.pm2\logs`
* On Mac, `/Users/[USERNAME]/.pm2/logs`

## Server Info

Expand Down
4 changes: 2 additions & 2 deletions dapp/app/frontend/modules/common/views/left_side_menu.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@
<li><a class="link-logout" data-keyboard="true" data-toggle="modal" data-target="#logout"></a></li>
</ul>
<span class="txt-version txt-synced">Synced blocks<em>{{blockrange.minBlock}} - {{blockrange.maxBlock}}</em></span>
<span class="txt-version">Version 1.0.0</span>
</aside>
<span class="txt-version">Version 1.0.2</span>
</aside>
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ <h1 id="logo-login"><img class="logo"/></h1>
jQuery(($) => {
const element = $('.txt-disclaimer')[0];
element.onscroll = () => {
if(element.scrollTop + element.clientHeight == element.scrollHeight) {
if(element.scrollTop + element.clientHeight >= element.scrollHeight) {
$('.txt-disclaimer-explanation').hide();
$('.txt-agreed').show();
}
Expand Down
5 changes: 4 additions & 1 deletion dapp/app/resources/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ const router = express.Router();
const app = express();
const tables = require('./routes/tables');
const constant = require('./routes/constant.js');
const morgan = require('morgan');
require('dotenv').config()

app.use(express.json());
Expand All @@ -27,6 +28,8 @@ var allowCrossDomain = function(req, res, next) {
app.use(allowCrossDomain);
app.disable('etag');

app.use(morgan(':method :url :status :res[content-length] - :response-time ms'));

const configRouter = require('./routes/configuration');
const infuraRouter = require('./routes/infura');
const challengeRouter = require('./routes/challenge');
Expand Down Expand Up @@ -60,4 +63,4 @@ var listener = app.listen(constant.port, function() {
console.log("server started at port ", listener.address().port);
});

module.exports = app;
module.exports = app;
4 changes: 2 additions & 2 deletions dapp/app/resources/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"private": true,
"scripts": {
"start": "node ./bin/www",
"postinstall": "npm rebuild sqlite3 --target=5.0.0 && npm rebuild sqlite3 --target=6.0.0 && npm rebuild sqlite3 --target=7.0.0 && npm rebuild sqlite3 --target=8.0.0 && npm rebuild sqlite3 --target=9.0.0 && npm rebuild sqlite3 --target=10.0.0"
"postinstall": "npm rebuild sqlite3 --target=5.0.0 && npm rebuild sqlite3 --target=6.0.0 && npm rebuild sqlite3 --target=7.0.0 && npm rebuild sqlite3 --target=8.0.0 && npm rebuild sqlite3 --target=9.0.0 && npm rebuild sqlite3 --target=10.0.0 && npm rebuild sqlite3 --target=5.0.0 --target_platform=win32 && npm rebuild sqlite3 --target=6.0.0 --target_platform=win32 && npm rebuild sqlite3 --target=7.0.0 --target_platform=win32 && npm rebuild sqlite3 --target=8.0.0 --target_platform=win32 && npm rebuild sqlite3 --target=9.0.0 && npm rebuild sqlite3 --target=10.0.0 --target_platform=win32"
},
"dependencies": {
"async": "^2.6.1",
Expand All @@ -22,7 +22,7 @@
"express-session": "^1.15.6",
"express-validator": "^5.2.0",
"http-errors": "~1.6.2",
"morgan": "~1.9.0",
"morgan": "^1.9.1",
"node-rest-client": "^3.1.0",
"rebuild": "^0.1.2",
"request-promise": "^4.2.2",
Expand Down
4 changes: 2 additions & 2 deletions dapp/package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "FirstBlood",
"version": "1.0.0",
"version": "1.0.2",
"main": "main.js",
"license": "GPL-3.0",
"license": "MIT",
"private": true,
"productName": "FirstBlood",
"description": "FirstBlood",
Expand Down
2 changes: 1 addition & 1 deletion dapp/start-electron.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,4 @@ muon.on('SIGTERM', () => {

muon.on('SIGINT', () => {
electron.kill('SIGINT')
})
})

0 comments on commit f182999

Please sign in to comment.