Compare commits
No commits in common. "develop" and "feature/13-route-search" have entirely different histories.
develop
...
feature/13
38
script.sh
Executable file
38
script.sh
Executable file
@ -0,0 +1,38 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
echo -n 'Country: '; read Country
|
||||||
|
echo -n 'Countries: '; read Countries
|
||||||
|
|
||||||
|
country=$(echo ${Country} | sed 's/[A-Z]/\L&/g')
|
||||||
|
countries=$(echo ${Countries} | sed 's/[A-Z]/\L&/g')
|
||||||
|
|
||||||
|
rm -Rf ./AutobusApi.Application/${Countries}/*
|
||||||
|
|
||||||
|
cp -r ./AutobusApi.Application/Countries/* ./AutobusApi.Application/${Countries}/
|
||||||
|
|
||||||
|
find ./AutobusApi.Application/${Countries} -type f | xargs -I {} perl -0777 -i -pe "s/Countries/${Countries}/g" {}
|
||||||
|
find ./AutobusApi.Application/${Countries} -type f | xargs -I {} perl -0777 -i -pe "s/Country/${Country}/g" {}
|
||||||
|
find ./AutobusApi.Application/${Countries} -type f | xargs -I {} perl -0777 -i -pe "s/countries/${countries}/g" {}
|
||||||
|
find ./AutobusApi.Application/${Countries} -type f | xargs -I {} perl -0777 -i -pe "s/country/${country}/g" {}
|
||||||
|
|
||||||
|
for dir in $(find ./AutobusApi.Application/${Countries} -type d | grep Country); do
|
||||||
|
mv ${dir} $(echo ${dir} | sed -e "s/Country/${Country}/g")
|
||||||
|
done
|
||||||
|
|
||||||
|
for dir in $(find ./AutobusApi.Application/${Countries} -type d | grep Countries); do
|
||||||
|
mv ${dir} $(echo ${dir} | sed -e "s/Countries/${Countries}/g")
|
||||||
|
done
|
||||||
|
|
||||||
|
for file in $(find ./AutobusApi.Application/${Countries} -type f | grep Country); do
|
||||||
|
mv ${file} $(echo ${file} | sed -e "s/Country/${Country}/g")
|
||||||
|
done
|
||||||
|
|
||||||
|
for file in $(find ./AutobusApi.Application/${Countries} -type f | grep Countries); do
|
||||||
|
mv ${file} $(echo ${file} | sed -e "s/Countries/${Countries}/g")
|
||||||
|
done
|
||||||
|
|
||||||
|
cp ./AutobusApi.Api/Controllers/CountryController.cs ./AutobusApi.Api/Controllers/${Country}Controller.cs
|
||||||
|
sed -i -e "s/Country/${Country}/g" ./AutobusApi.Api/Controllers/${Country}Controller.cs
|
||||||
|
sed -i -e "s/Countries/${Countries}/g" ./AutobusApi.Api/Controllers/${Country}Controller.cs
|
||||||
|
sed -i -e "s/country/${country}/g" ./AutobusApi.Api/Controllers/${Country}Controller.cs
|
||||||
|
sed -i -e "s/countries/${countries}/g" ./AutobusApi.Api/Controllers/${Country}Controller.cs
|
Loading…
Reference in New Issue
Block a user