diff --git a/new_theme.sh b/new_theme.sh index 51b0134..90b6941 100755 --- a/new_theme.sh +++ b/new_theme.sh @@ -6,15 +6,22 @@ read -p 'folder name : ' folderName read -p 'Theme label : ' themeLabel # Theme Color read -p 'Theme Color (hexa) : ' themeColor +# custom template +read -p 'Need custom templates (0/1) : ' variant cd ~/src/publik-base-theme/ -# create folder -themefolderPath=static/$folderName -mkdir $themefolderPath +# create folders +staticfolderPath=static/$folderName +mkdir $staticfolderPath +if [ $variant == 1 ] +then + variantfolderPath=templates/variants/$folderName + mkdir $variantfolderPath +fi # create config.json file -cat >${themefolderPath}/config.json <${staticfolderPath}/config.json <${themefolderPath}/config.json <${themefolderPath}/_vars.scss <${staticfolderPath}/_vars.scss <${themefolderPath}/_vars.scss <${themefolderPath}/style.scss <${staticfolderPath}/style.scss <