-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes plugins: - associated-files - cleanurls - coffee - live-reload - sass - stylus Moved unstable plugins into new plugins-dev folder instead.
- Loading branch information
Showing
6 changed files
with
157 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,9 @@ | ||
.DS_Store | ||
.git* | ||
.travis* | ||
*.md | ||
Makefile | ||
|
||
src/ | ||
out/test/ | ||
test/ |
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 @@ | ||
# If you change something here, be sure to change it in package.json's scripts as well | ||
|
||
dev: | ||
./node_modules/.bin/coffee -w -o out/ -c src/ | ||
|
||
compile: | ||
./node_modules/.bin/coffee -o out/ -c src/ | ||
|
||
.PHONY: dev compile |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,38 @@ | ||
{ | ||
"name": "docpad-plugin-heroku", | ||
"version": "2.0.0", | ||
"description": "Deploy to Heroku easily and effortlessly with this DocPad plugin", | ||
"homepage": "https://github.com/bevry/docpad-extras", | ||
"keywords": [ | ||
"docpad", | ||
"docpad-plugin", | ||
"heroku", | ||
"deploy", | ||
"deployment" | ||
], | ||
"author": "Bevry Pty Ltd <us@bevry.me> (http://bevry.me)", | ||
"maintainers": [ | ||
"Benjamin Lupton <b@lupton.cc> (http://balupton.com)" | ||
], | ||
"contributors": [ | ||
"Benjamin Lupton <b@lupton.cc> (http://balupton.com)" | ||
], | ||
"bugs": { | ||
"url": "https://github.com/bevry/docpad-extras/issues" | ||
}, | ||
"repository" : { | ||
"type": "git", | ||
"url": "http://github.com/bevry/docpad-extras.git" | ||
}, | ||
"engines" : { | ||
"node": ">=0.4.0", | ||
"docpad": "6.x" | ||
}, | ||
"dependencies": { | ||
"bal-util": "1.12.x" | ||
}, | ||
"devDependencies": { | ||
"coffee-script": "1.3.x" | ||
}, | ||
"main": "./out/heroku.plugin.js" | ||
} |
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,53 @@ | ||
# Export Plugin | ||
module.exports = (BasePlugin) -> | ||
# Define Plugin | ||
class HerokuPlugin extends BasePlugin | ||
# Plugin name | ||
name: "heroku" | ||
|
||
# Files | ||
files: | ||
"config.json": """ | ||
{"version":"latest"} | ||
""" | ||
|
||
"Procfile": """ | ||
web: node server.js | ||
""" | ||
|
||
"server.js": """ | ||
require('docpad').createInstance(function(err,docpadInstance){ | ||
if (err) return console.log(err.stack); | ||
docpadInstance.action('generate server',function(err){ | ||
if (err) return console.log(err.stack); | ||
console.log('OK'); | ||
}); | ||
}); | ||
""" | ||
|
||
# Setup the Console Interface | ||
consoleSetup: (opts,next) -> | ||
# Prepare | ||
{docpadInterface,commanderInstance} = opts | ||
|
||
# Extend the CLI | ||
program | ||
.command('heroku ') | ||
.description("deploy to heroku") | ||
.action (command) -> | ||
docpadInterface.applyConfiguration(command) | ||
me.question(opts,docpadInterface.actionCompleted) | ||
|
||
# Done, return back to DocPad | ||
return next() | ||
|
||
|
||
# Ask the user a question | ||
question: (opts,next) -> | ||
# Prepare | ||
{docpadInterface,program} = opts | ||
|
||
# Get username | ||
program.promptSingleLine 'Type something?\n> ', (input) -> | ||
console.log "You typed: #{input}" | ||
next() |