You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

26 lines
765 B

#!/bin/bash
if [ -f ".repo_initialized" ]; then
echo "This repo is already initialized!"
else
if [ -f "README_PROJECT_TEMPLATE.md" ]; then
echo "First run after creation from template."
rm -f README.md
mv README_PROJECT_TEMPLATE.md README.md
touch .repo_initialized
echo "This file is checked by the 'init_after_clone' script." >> .repo_initialized
git add README.md README_PROJECT_TEMPLATE.md
git commit -m "chore: replace template readme"
git config --local core.hooksPath .githooks
source ./clean_and_recreate_all --no-prompt --import-hw-platform-only
else
git config --local core.hooksPath .githooks
source ./clean_and_recreate_all --no-prompt
fi
fi