component-template/bootstrap-new-component.sh
Radosław Piliszek 8bdb8afd5c Add a component bootstrapping helper
Change-Id: I45bae3170ee2914f50c93c8c4efcea030d19d4c0
2023-09-19 20:18:14 +02:00

18 lines
563 B
Bash
Executable File

#!/usr/bin/env bash
set -u
set -e
NAME=$1
cp -rf .gitignore .yamllint LICENSE noxfile.py java-spring-boot-demo zuul.d ../$NAME/
mkdir -p ../$NAME/charts
rsync --recursive --delete charts/nebulous-component-template/ ../$NAME/charts/nebulous-$NAME/
cd ../$NAME/
sed -i 's/nebulous-component-template-apply-helm-charts/nebulous-platform-apply-helm-charts/g' zuul.d/project.yaml
find -name .git -prune -o -type f -print0 | xargs -0 sed -i "s/component-template/${NAME}/g"
git review -s
git add -A
git commit -m 'Init repo from the component-template'
git review