func (l *FilesystemLoader) Load(name string) (Template, error) {
	path := filepath.Join(l.rootDir, name)
	f, err := os.Open(path)
	if err != nil {
		return nil, err
	}
	return &fileTemplate{name, f}, nil
}
Load on a FileSystemLoader attempts to load the given file, relative to the
configured root directory.
package stick
import (
	"bytes"
	"io"
	"os"
	"path/filepath"
)
type Loader interface {
	Load(name string) (Template, error)
}
type stringTemplate struct {
	name     string
	contents string
}
func (t *stringTemplate) Name() string {
	return t.name
}
func (t *stringTemplate) Contents() io.Reader {
	return bytes.NewBufferString(t.contents)
}
type StringLoader struct{}
func (l *StringLoader) Load(name string) (Template, error) {
	return &stringTemplate{name, name}, nil
}
type MemoryLoader struct {
	Templates map[string]string
}
func (l *MemoryLoader) Load(name string) (Template, error) {
	v, ok := l.Templates[name]
	if !ok {
		return nil, os.ErrNotExist
	}
	return &stringTemplate{name, v}, nil
}
type fileTemplate struct {
	name   string
	reader io.Reader
}
func (t *fileTemplate) Name() string {
	return t.name
}
func (t *fileTemplate) Contents() io.Reader {
	return t.reader
}
type FilesystemLoader struct {
	rootDir string
}
func NewFilesystemLoader(rootDir string) *FilesystemLoader {
	return &FilesystemLoader{rootDir}
}