-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 96dab32
Showing
13 changed files
with
159 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
node_modules | ||
/www | ||
*.log | ||
secrets.* |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"globals": { | ||
"site": { | ||
"language": "en", | ||
|
||
"name": "Harp Starter" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
var argv = require('yargs').argv; | ||
var harp = require('harp'); | ||
var rsync = require('rsyncwrapper').rsync; | ||
var util = require('util'); | ||
|
||
|
||
global.moment = require('moment'); | ||
global._ = require('underscore'); | ||
|
||
|
||
var build = function() { | ||
util.log('Compiling...'); | ||
harp.compile('.', './www', function(err) { | ||
if (err) { | ||
util.log('Compile failed with errors:'); | ||
util.log(err); | ||
} else { | ||
util.log('Compile completed without errors'); | ||
} | ||
}); | ||
}; | ||
|
||
var serve = function() { | ||
var port = argv.port || '9000'; | ||
console.log('Serving on port 9000'); | ||
harp.server('.', { | ||
port: port | ||
}); | ||
}; | ||
|
||
var deploy = function() { | ||
|
||
}; | ||
|
||
|
||
switch (argv._[0]) { | ||
case 'serve': | ||
serve(); | ||
break; | ||
case 'build': | ||
build(); | ||
break; | ||
default: | ||
util.log('No command specified.'); | ||
break; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
{ | ||
"name": "harp-starter", | ||
"version": "1.0.0", | ||
"description": "A starting point for a harp static site, with support for external npm modules", | ||
"main": "index.js", | ||
"scripts": { | ||
"serve": "node index.js serve", | ||
"build": "node index.js build" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/evendev/harp-starter.git" | ||
}, | ||
"keywords": [ | ||
"bootstrap", | ||
"browserify", | ||
"harp", | ||
"harpjs", | ||
"jquery", | ||
"moment", | ||
"underscore" | ||
], | ||
"author": "Steve Jamesson", | ||
"license": "ISC", | ||
"bugs": { | ||
"url": "https://github.com/evendev/harp-starter/issues" | ||
}, | ||
"homepage": "https://github.com/evendev/harp-starter#readme", | ||
"devDependencies": { | ||
"bootstrap": "^3.3.5", | ||
"browserify": "^11.0.1", | ||
"harp": "^0.17.0", | ||
"jquery": "^2.1.4", | ||
"moment": "^2.10.6", | ||
"rsyncwrapper": "^0.4.3", | ||
"underscore": "^1.8.3", | ||
"util": "^0.10.3", | ||
"yargs": "^3.19.0" | ||
} | ||
} |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
!= yield |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
extends main | ||
|
||
block main | ||
.container | ||
block container |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
doctype html | ||
html(lang='#{ site.language }') | ||
head | ||
block head | ||
meta(charset='utf-8') | ||
meta(http-equiv='X-UA-Compatible', content='IE=edge') | ||
meta(name='viewport', content='width=device-width, initial-scale=1.0') | ||
title | ||
block title | ||
= site.name | ||
body | ||
block body |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
extends html | ||
|
||
block append head | ||
link(rel='stylesheet', href='/assets/css/app.css') | ||
|
||
block body | ||
block main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
@import '../../../node_modules/bootstrap/less/bootstrap'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
extends _layouts/container | ||
|
||
block prepend title | ||
| Welcome - | ||
|
||
block container | ||
:markdown | ||
# Welcome to `harp-starter` | ||
|
||
## Build | ||
|
||
```bash | ||
npm run build | ||
``` | ||
|
||
## Serve | ||
|
||
```bash | ||
npm run serve [--port=9000] | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"servers": { | ||
"prod": { | ||
"user": "", | ||
"host": "", | ||
"path": "/path/to/public/html" | ||
}, | ||
"dev": { | ||
"user": "", | ||
"host": "", | ||
"path": "/path/to/public/html" | ||
} | ||
} | ||
} |