Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixup! Helper for tagging tutorial steps
- Loading branch information
1 parent
f7bc469
commit 2cf8faa
Showing
1 changed file
with
22 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,35 @@ | ||
#!/bin/bash | ||
|
||
declare -a commits=( | ||
"Create the bundle" | ||
"Structure the bundle" | ||
"Implement the Tweet\Value class" | ||
"Implement the Tweet\Type class" | ||
"Register the Field Type as a service" | ||
"Implement the Legacy Storage Engine Converter" | ||
"Add field view and field definition view templates" | ||
) | ||
"Create the bundle" | ||
"Structure the bundle" | ||
"Implement the Tweet\\\Value class" | ||
"Implement the Tweet\\\Type class" | ||
"Register the Field Type as a service" | ||
"Implement the Legacy Storage Engine Converter" | ||
"Add field view and field definition view templates" | ||
) | ||
declare -a tags=( | ||
"step1_create_the_bundle" | ||
"step2_structure_the_bundle" | ||
"step3_implement_the_tweet_value_class" | ||
"step4_implement_the_tweet_type_class" | ||
"step5_register_the_field_type_as_a_service" | ||
"step6_implement_the_legacy_storage_engine_converter" | ||
"step7_add_field_view_and_field_definition_view_templates" | ||
) | ||
"step1_create_the_bundle" | ||
"step2_structure_the_bundle" | ||
"step3_implement_the_tweet_value_class" | ||
"step4_implement_the_tweet_type_class" | ||
"step5_register_the_field_type_as_a_service" | ||
"step6_implement_the_legacy_storage_engine_converter" | ||
"step7_add_field_view_and_field_definition_view_templates" | ||
) | ||
|
||
numberOfCommits=${#commits[@]} | ||
|
||
for (( i=0; i<${numberOfCommits}; i++ )); | ||
do | ||
SHA1=`git log --oneline --all --grep "${commits[$i]}" | cut -d" " -f1` | ||
git tag "${tags[$i]}" ${SHA1} | ||
git tag -d "${tags[$i]}" 2> /dev/null | ||
SHA1=`git log --oneline --grep "${commits[$i]}" | cut -d" " -f1` | ||
if [ ${SHA1} ] ; then | ||
git tag "${tags[$i]}" ${SHA1} | ||
fi | ||
done | ||
|
||
git push --tags | ||
git push --tags --force | ||
|
||
echo "Tags created and pushed." |