{"thread":{"id":"3543","subject":"[PATCH] Use Cogito when possible in the \"tutorial\" test.","startedAt":"2006-03-04T01:23:34Z","lastAt":"2006-03-04T01:23:34Z","messageCount":1,"participants":["Pavel Roskin"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"17127","messageId":"20060304012333.10494.35600.stgit@dv.roinet.com","threadId":"3543","inReplyTo":null,"subject":"[PATCH] Use Cogito when possible in the \"tutorial\" test.","fromName":"Pavel Roskin","fromEmail":"proski@gnu.org","sentAt":"2006-03-04T01:23:34Z","receivedAt":"2006-03-04T01:23:34Z","isPatch":true,"sender":{"key":"proski@gnu.org","avatar":null},"body":"In particular, use Cogito branch support.  Document why git has to be\nused in some places.\n\nSigned-off-by: Pavel Roskin <proski@gnu.org>\n---\n\n Documentation/tutorial-script/script.sh |   29 +++++++++++++++++------------\n 1 files changed, 17 insertions(+), 12 deletions(-)\n\ndiff --git a/Documentation/tutorial-script/script.sh b/Documentation/tutorial-script/script.sh\nindex edcebda..4d6b732 100755\n--- a/Documentation/tutorial-script/script.sh\n+++ b/Documentation/tutorial-script/script.sh\n@@ -1,8 +1,9 @@\n #!/bin/bash\n #\n-# FIXME: This script has many GITisms. Some of them are unnecessary, while\n-# some stem from missing Cogito features (especially no support for pushing\n-# tags, and consequently no support for remotes/).\n+# FIXME: This script has some GITisms. They stem from missing Cogito\n+# features, such as exporting patches to mbox format, applying patches\n+# from e-mail, merging multiple tags at once, verifying signed tags and\n+# repacking the repository.\n \n \n # This function is appended as \"&& should_fail\" to commands which should\n@@ -34,7 +35,7 @@ cd $ALICE\n tar xf $TOP/0001-alice.tar\n cd rpn\n \n-# Being a tidy girl, she places it under git\n+# Being a tidy girl, she places it under Cogito\n echo \"Alice's first version\" | cg-init\n cg-tag -d \"First ever version of RPN\" rpn-0.1\n  \n@@ -108,8 +109,8 @@ cg-export ../rpn-0.3.tar.bz2\n ### Bob tells Alice of his changes, Alice prepares to get them.\n cd $ALICE/rpn\n \n-git checkout -b bob\n-git branch\n+cg-switch -r master bob\n+cg-status -g\n \n # Alice needs to register his remote branch\n cg-branch-add bobswork $BOB/rpn\n@@ -163,14 +164,16 @@ cg-commit -m \"Add proper header file for\n           -m \"Update dependencies in Makefile\"\n \n # Charlie emails the patch to Alice:\n+# cg-mkpatch -d .. -r rpn-0.3..master\n git format-patch -o .. --mbox --signoff -r rpn-0.3\n-      # Result is in $TOP/0014-charlie-email\n+# Only git can create mbox formatted output\n+# Compare the result to 0014-charlie-email\n \n \n ### Alice is busy meanwhile...\n cd $ALICE/rpn\n \n-git checkout master\n+cg-switch master\n \n patch -p1 -i $TOP/0015-alice-mod.patch\n \n@@ -189,21 +192,23 @@ cg-push public\n ### Alice gets Charlie's fix, creates a new branch for his changes\n cd $ALICE/rpn\n \n-git checkout master\n-git checkout -b charlie rpn-0.3\n-git branch\n+cg-switch -r rpn-0.3 charlie\n+cg-status -g\n \n+# Check what's inside the patch.  There is no Cogito equivalent yet.\n git apply --stat $TOP/0014-charlie-email\n git apply --summary $TOP/0014-charlie-email\n git apply --check $TOP/0014-charlie-email\n \n # Everything looks OK\n git applymbox $TOP/0014-charlie-email\n+# This doesn't work well yet\n+# cg-patch < $TOP/0014-charlie-email\n \n ### Alice integrates the changes in the branches for the next release\n cd $ALICE/rpn\n \n-git checkout master\n+cg-switch master\n # Alice tries \"git merge\" instead of \"cg-merge\" since she wanted to\n # merge both branches at once, which \"cg-merge\" cannot do.\n git merge \"Integrate changes from Bob and Charlie\" master bob charlie \\\n"}]}