aboutsummaryrefslogtreecommitdiff
path: root/share/templater/basic/setup
blob: b90f5b287b882b3b52d8b0c442fab9e8a3475a0e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash
#
# Basic files templater module.
#

# Parameters
SHARE="$1"
PROJECT="$(basename `pwd`)"

# Include basic functions
source $SHARE/templater/functions || exit 1

# Basic implementation
function templater_basic {
  if [ ! -e "README.md" ]; then
    echo "$PROJECT"                           > README.md
    basename $PROJECT | sed -e 's|.|=|g'     >> README.md
    #echo ""                                 >> README.md
    #echo "This is the $PROJECT repository." >> README.md

    echo "TODO"                > TODO.md
    echo "===="               >> TODO.md
    #echo ""                   >> TODO.md
    #echo "* Nothing here? :P" >> TODO.md

    touch ChangeLog
  else
    templater_echo "Basic files already set"
  fi
}

# Dispatch
templater_basic