8
8
# Remember to chmod +x git-basics.sh first, then paste this command in your terminal
9
9
# sh -c "$(curl -fsSL https://raw.githubusercontent.com/wilsonmar/git-utilities/master/git-basics.sh)"
10
10
11
- RUNTYPE=" reuse "
12
- # remove
13
- # update
14
- # reuse (previous version of repository )
15
-
11
+ RUNTYPE=" "
12
+ # remove
13
+ # update
14
+ # reset (to wipe out files saved in git-utilities )
15
+ # reuse (previous version of repository)
16
16
17
17
function fancy_echo() {
18
18
local fmt=" $1 " ; shift
@@ -224,7 +224,7 @@ c_echo "hub delete \"$OTHER_REPO\""
224
224
hub delete " $OTHER_REPO "
225
225
echo " Not Found is OK if it was not created last run."
226
226
227
- fancy_echo " 3.4 Use hub to clone and fork ..."
227
+ fancy_echo " 3.4 Use hub to clone \" $OTHER_ACCT / $OTHER_REPO \" ..."
228
228
c_echo " cd && cd \" $WORKSPACE_FOLDER \" "
229
229
cd && cd " $WORKSPACE_FOLDER "
230
230
@@ -236,23 +236,29 @@ c_echo "cd \"$OTHER_REPO\" && PWD && git remote -v && ls -al ..."
236
236
git remote -v
237
237
ls -al
238
238
239
+ fancy_echo " 3.5 Use hub to fork \" $OTHER_ACCT /$OTHER_REPO \" ..."
239
240
c_echo " hub fork \" $OTHER_ACCT /$OTHER_REPO \" "
240
- hub fork " $OTHER_ACCT /$OTHER_REPO "
241
+ hub fork " $OTHER_ACCT /$OTHER_REPO "
241
242
242
243
c_echo " cd \" $OTHER_REPO \" && PWD && git remote -v && ls -al ..."
243
244
cd " $OTHER_REPO "
244
245
echo " PWD=$PWD "
245
246
git remote -v
246
247
ls -al
247
248
248
- hub remote add " $MYACCT " # wilsonmar
249
- git remote rename origin upstream
250
- git remote rename " $MYACCT " origin
249
+ c_echo " hub remote add \" $MYACCT \" "
250
+ hub remote add " $MYACCT " # wilsonmar
251
+
252
+ c_echo " git remote rename origin upstream"
253
+ git remote rename origin upstream
254
+
255
+ c_echo " git remote rename " $MYACCT " origin"
256
+ git remote rename " $MYACCT " origin
251
257
252
258
c_echo " git pull --all"
253
259
git pull --all
254
260
255
- fancy_echo " 3.5 git remote -v ... "
261
+ fancy_echo " 3.5 git remote -v"
256
262
git remote -v
257
263
258
264
fancy_echo " 3.6 Manually see the fork in your cloud account ..."
@@ -371,11 +377,12 @@ fancy_echo "6.7 git push origin :feat1 # to remove in cloud"
371
377
372
378
# Check manually on GitHub for new tag.
373
379
374
- fancy_echo " 8.1 Use a different browser to login to $OTHER_ACCT /$OTHER_REPO ... "
375
- read -rsp $' Press any key after adding a file ...\n ' -n 1 key
380
+ fancy_echo " 7.x Request request, use a different browser to $OTHER_ACCT /$OTHER_REPO . "
381
+ read -rsp $' Press any key after adding a file in $OTHER_ACCT/$OTHER_REPO ...\n ' -n 1 key
376
382
# See https://unix.stackexchange.com/questions/134437/press-space-to-continue
377
383
# See https://stackoverflow.com/questions/92802/what-is-the-linux-equivalent-to-dos-pause
378
384
385
+
379
386
fancy_echo " 8.2 git remote add upstream https://$GITHOST /$OTHER_ACCT /$OTHER_REPO ..."
380
387
git remote add upstream " https://$GITHOST /$OTHER_ACCT /$OTHER_REPO "
381
388
echo " >>> No output expected."
@@ -412,8 +419,8 @@ fancy_echo "9.3 git diff master..origin/master"
412
419
git diff master..origin/master
413
420
# gitk master..origin/master
414
421
415
- fancy_echo " 9.4 git merge origin/master -m\" 9.4 thank you\" "
416
- git merge origin/master -m " 9.4 thank you"
422
+ fancy_echo " 9.4 git merge origin/master -m\" 9.4 thank you\" --no-edit "
423
+ git merge origin/master -m " 9.4 thank you" --no-edit
417
424
418
425
419
426
FREE_DISKBLOCKS_END=$( df | sed -n -e ' 2{p;q}' | cut -d' ' -f 6)
0 commit comments