Created
August 2, 2010 11:10
-
-
Save mads-hartmann/504486 to your computer and use it in GitHub Desktop.
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
package com.sidewayscoding | |
import sbt._ | |
import org.lifty.engine._ | |
// the processor | |
class Processor extends SBTTemplateProcessor { | |
def templates = MyTemplate :: Nil | |
} | |
// The template | |
object MyTemplate extends Template with Create { | |
def name = "hello" | |
def description = "Creates a file with a greeting in it" | |
def arguments = Argument("name") :: Nil | |
def files = TemplateFile( | |
"%s/greetings.ssp".format(GlobalConfiguration.rootResources), | |
"output/greetings/${name}.txt" | |
) :: Nil | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment