<commit_before>#!/bin/bash
# Theme starting bash script by rolle (github.com/ronilaukkarinen & github.com/digitoimistodude)

txtbold=$(tput bold)
boldyellow=${txtbold}$(tput setaf 3)
boldgreen=${txtbold}$(tput setaf 2)
boldwhite=${txtbold}$(tput setaf 7)
yellow=$(tput setaf 3)
green=$(tput setaf 2)
white=$(tput setaf 7)
txtreset=$(tput sgr0)

while true; do
read -p "${boldyellow}Project created? (y/n)${txtreset} " yn
    case $yn in
        [Yy]* ) break;;
        [Nn]* ) exit;;
        * ) echo "Please answer y or n.";;
    esac
done

# TODO:
# read -p "${boldyellow}Tuleeko teemaan asia X? (y/n)${txtreset} " CONT
# if [ "$CONT" == "y" ]; then
#   echo "yaaa";
# else
#   echo "booo";
# fi

echo "${boldyellow}Project name in lowercase:${txtreset} "
read -e PROJECTNAME
echo "${boldyellow}Theme name in lowercase (no spaces or special characters):${txtreset} "
read -e THEMENAME

# TODO:
# read -p "${boldyellow}Use as base: a) twitter bootstrap, b) skeleton?${txtreset} " CONT
# if [ "$CONT" == "a" ]; then
# BASE="bootstrap"
# else
# BASE="skeleton"
# fi

PROJECTPATH="${HOME}/Projects/${PROJECTNAME}"
STARTERTHEMEPATH="${HOME}/dudestarter"
PROJECTTHEMEPATH="${HOME}/Projects/${PROJECTNAME}/content/themes/${THEMENAME}"

echo "${yellow}Checking dudestarter updates...${txtreset}"
cd $HOME
git clone <EMAIL>:digitoimistodude/dudestarter.git
cd $STARTERTHEMEPATH
git pull
echo "${yellow}Copying starter theme to project folder ${HOME}/Projects/${PROJECTNAME}/content/themes/${THEMENAME}${txtreset}"

cp -R ${STARTERTHEMEPATH} ${PROJECTTHEMEPATH} 
echo "${yellow}Generating theme files${txtreset}"

sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/404.php > ${PROJECTTHEMEPATH}/404.php
echo "${boldgreen}404.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/archive.php > ${PROJECTTHEMEPATH}/archive.php
echo "${boldgreen}archive.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/comments.php > ${PROJECTTHEMEPATH}/comments.php
echo "${boldgreen}comments.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/footer.php > ${PROJECTTHEMEPATH}/footer.php
echo "${boldgreen}footer.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/header.php > ${PROJECTTHEMEPATH}/header.php
echo "${boldgreen}header.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/index.php > ${PROJECTTHEMEPATH}/index.php
echo "${boldgreen}index.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/page.php > ${PROJECTTHEMEPATH}/page.php
echo "${boldgreen}page.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/search.php > ${PROJECTTHEMEPATH}/search.php
echo "${boldgreen}search.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/sidebar.php > ${PROJECTTHEMEPATH}/sidebar.php
echo "${boldgreen}sidebar.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/front-page.php > ${PROJECTTHEMEPATH}/front-page.php
echo "${boldgreen}front-page.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/single.php > ${PROJECTTHEMEPATH}/single.php
echo "${boldgreen}single.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/functions.php > ${PROJECTTHEMEPATH}/functions.php
echo "${boldgreen}functions.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/style.css > ${PROJECTTHEMEPATH}/style.css
echo "${boldgreen}style.css generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content.php > ${PROJECTTHEMEPATH}/template-parts/content.php
echo "${boldgreen}content.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-none.php > ${PROJECTTHEMEPATH}/template-parts/content-none.php
echo "${boldgreen}content-none.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-page.php > ${PROJECTTHEMEPATH}/template-parts/content-page.php
echo "${boldgreen}content-page.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-search.php > ${PROJECTTHEMEPATH}/template-parts/content-search.php
echo "${boldgreen}content-search.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-single.php > ${PROJECTTHEMEPATH}/template-parts/content-single.php
echo "${boldgreen}content-single.php generated${txtreset}"

if [ "$CONT" == "b" ]; then
echo "${yellow}Generating grids for skeleton${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/404.php > ${PROJECTTHEMEPATH}/404.php
echo "${boldgreen}404.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/archive.php > ${PROJECTTHEMEPATH}/archive.php
echo "${boldgreen}archive.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/comments.php > ${PROJECTTHEMEPATH}/comments.php
echo "${boldgreen}comments.php generated${txtreset}"
echo "${yellow}Generating grids for skeleton${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/footer.php > ${PROJECTTHEMEPATH}/footer.php
echo "${boldgreen}footer.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/header.php > ${PROJECTTHEMEPATH}/header.php
echo "${boldgreen}header.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/index.php > ${PROJECTTHEMEPATH}/index.php
echo "${boldgreen}index.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/page.php > ${PROJECTTHEMEPATH}/page.php
echo "${boldgreen}page.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/search.php > ${PROJECTTHEMEPATH}/search.php
echo "${boldgreen}search.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/sidebar.php > ${PROJECTTHEMEPATH}/sidebar.php
echo "${boldgreen}sidebar.php generated${txtreset}"
sed -e "s/\col-md-2/two columns/" -e "s/\col-md-3/three columns/" -e "s/\col-md-4/four columns/" -e "s/\col-md-5/five columns/" -e "s/\col-md-6/six columns/" -e "s/\col-md-7/seven columns/" -e "s/\col-md-8/eight columns/" -e "s/\col-md-9/nine columns/" -e "s/\col-md-10/ten columns/" -e "s/\col-md-11/eleven columns/" -e "s/\col-xs-2/two columns/" -e "s/\col-xs-3/three columns/" -e "s/\col-xs-4/four columns/" -e "s/\col-xs-5/five columns/" -e "s/\col-xs-6/six columns/" -e "s/\col-xs-7/seven columns/" -e "s/\col-xs-8/eight columns/" -e "s/\col-xs-9/nine columns/" -e "s/\col-xs-10/ten columns/" -e "s/\col-xs-11/eleven columns/" ${STARTERTHEMEPATH}/single.php > ${PROJECTTHEMEPATH}/single.php
echo "${boldgreen}single.php generated${txtreset}"

# TODO:
#echo "${yellow}Generating responsive nav${txtreset}"
#awk '/bootstrap-js/ { print; print "new line"; next }1' ${PROJECTTHEMEPATH}/index.php > test.php.edited && rm test.php && mv test.php.edited test.php

fi

echo "${yellow}Setting up package.json & gulpfile.js from devpackages github${txtreset}"
cd ${PROJECTPATH}
git clone <EMAIL>:digitoimistodude/devpackages.git
echo "${yellow}Generating package.json from <EMAIL>:digitoimistodude/devpackages.git${txtreset}"
sed -e "s/\PROJECTNAME/$PROJECTNAME/" -e "s/\PROJECTNAME/$PROJECTNAME/" -e "s/\PROJECTNAME/$PROJECTNAME/" $PROJECTPATH/devpackages/package.json > "$PROJECTPATH/package.json"
echo "${yellow}Installing and updating local node.js packages (may take a while)${txtreset}"<commit_msg>Disable skeleton grids for good<commit_after>#!/bin/bash
# Theme starting bash script by rolle (github.com/ronilaukkarinen & github.com/digitoimistodude)

txtbold=$(tput bold)
boldyellow=${txtbold}$(tput setaf 3)
boldgreen=${txtbold}$(tput setaf 2)
boldwhite=${txtbold}$(tput setaf 7)
yellow=$(tput setaf 3)
green=$(tput setaf 2)
white=$(tput setaf 7)
txtreset=$(tput sgr0)

while true; do
read -p "${boldyellow}Project created? (y/n)${txtreset} " yn
    case $yn in
        [Yy]* ) break;;
        [Nn]* ) exit;;
        * ) echo "Please answer y or n.";;
    esac
done

# TODO:
# read -p "${boldyellow}Tuleeko teemaan asia X? (y/n)${txtreset} " CONT
# if [ "$CONT" == "y" ]; then
#   echo "yaaa";
# else
#   echo "booo";
# fi

echo "${boldyellow}Project name in lowercase:${txtreset} "
read -e PROJECTNAME
echo "${boldyellow}Theme name in lowercase (no spaces or special characters):${txtreset} "
read -e THEMENAME

PROJECTPATH="${HOME}/Projects/${PROJECTNAME}"
STARTERTHEMEPATH="${HOME}/dudestarter"
PROJECTTHEMEPATH="${HOME}/Projects/${PROJECTNAME}/content/themes/${THEMENAME}"

echo "${yellow}Checking dudestarter updates...${txtreset}"
cd $HOME
git clone <EMAIL>:digitoimistodude/dudestarter.git
cd $STARTERTHEMEPATH
git pull
echo "${yellow}Copying starter theme to project folder ${HOME}/Projects/${PROJECTNAME}/content/themes/${THEMENAME}${txtreset}"

cp -R ${STARTERTHEMEPATH} ${PROJECTTHEMEPATH} 
echo "${yellow}Generating theme files${txtreset}"

sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/404.php > ${PROJECTTHEMEPATH}/404.php
echo "${boldgreen}404.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/archive.php > ${PROJECTTHEMEPATH}/archive.php
echo "${boldgreen}archive.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/comments.php > ${PROJECTTHEMEPATH}/comments.php
echo "${boldgreen}comments.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/footer.php > ${PROJECTTHEMEPATH}/footer.php
echo "${boldgreen}footer.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/header.php > ${PROJECTTHEMEPATH}/header.php
echo "${boldgreen}header.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/index.php > ${PROJECTTHEMEPATH}/index.php
echo "${boldgreen}index.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/page.php > ${PROJECTTHEMEPATH}/page.php
echo "${boldgreen}page.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/search.php > ${PROJECTTHEMEPATH}/search.php
echo "${boldgreen}search.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/sidebar.php > ${PROJECTTHEMEPATH}/sidebar.php
echo "${boldgreen}sidebar.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/front-page.php > ${PROJECTTHEMEPATH}/front-page.php
echo "${boldgreen}front-page.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/single.php > ${PROJECTTHEMEPATH}/single.php
echo "${boldgreen}single.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/functions.php > ${PROJECTTHEMEPATH}/functions.php
echo "${boldgreen}functions.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/style.css > ${PROJECTTHEMEPATH}/style.css
echo "${boldgreen}style.css generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content.php > ${PROJECTTHEMEPATH}/template-parts/content.php
echo "${boldgreen}content.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-none.php > ${PROJECTTHEMEPATH}/template-parts/content-none.php
echo "${boldgreen}content-none.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-page.php > ${PROJECTTHEMEPATH}/template-parts/content-page.php
echo "${boldgreen}content-page.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-search.php > ${PROJECTTHEMEPATH}/template-parts/content-search.php
echo "${boldgreen}content-search.php generated${txtreset}"
sed -e "s/\THEMENAME/$THEMENAME/" ${STARTERTHEMEPATH}/template-parts/content-single.php > ${PROJECTTHEMEPATH}/template-parts/content-single.php
echo "${boldgreen}content-single.php generated${txtreset}"

# TODO:
#echo "${yellow}Generating responsive nav${txtreset}"
#awk '/bootstrap-js/ { print; print "new line"; next }1' ${PROJECTTHEMEPATH}/index.php > test.php.edited && rm test.php && mv test.php.edited test.php

fi

echo "${yellow}Setting up package.json & gulpfile.js from devpackages github${txtreset}"
cd ${PROJECTPATH}
git clone <EMAIL>:digitoimistodude/devpackages.git
echo "${yellow}Generating package.json from <EMAIL>:digitoimistodude/devpackages.git${txtreset}"
sed -e "s/\PROJECTNAME/$PROJECTNAME/" -e "s/\PROJECTNAME/$PROJECTNAME/" -e "s/\PROJECTNAME/$PROJECTNAME/" $PROJECTPATH/devpackages/package.json > "$PROJECTPATH/package.json"
echo "${yellow}Installing and updating local node.js packages (may take a while)${txtreset}"
{'fraction_non_alphanumeric': 0.2169057322817975, 'fraction_numerical': 0.016249404541364528, 'mean_word_length': 3.9100831600831603, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 59, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3247247', 'n_tokens_mistral': 7374, 'n_tokens_neox': 7128, 'n_words': 1433}