So in one of my tutorials i use git branches to show code as there are numerous modules not illustrating it well on the forums posts. So each branch is a modification described more in detail on the tutorial. However, because i was writing the tutorial without any clear destination i rewrote the code mid-tutorial making it a little harder to understand. I dont normally revert published commits so i am not sure of the commands used in this scenario.
Because its a tutorial repo i would rather not mess it up either, otherwise i wouldnt really care.
I could just link to the last current branch, but if they actually did poke around the repo it would be a little confusing with previously modified code that no longer exists. As well as the comparison page would not show all modifications associated with the tutorial. And i use that to indicate the changes that occurred in the tutorial.
All has already been published and pushed. I basically want to go from commit "added game over state and restart" to "cleanup3" as the in-between is a little confusing for a tutorial. Then rewrite the tutorial to never mention those commits.
Because its a tutorial repo i would rather not mess it up either, otherwise i wouldnt really care.
I could just link to the last current branch, but if they actually did poke around the repo it would be a little confusing with previously modified code that no longer exists. As well as the comparison page would not show all modifications associated with the tutorial. And i use that to indicate the changes that occurred in the tutorial.
tldr;
i want to delete mid-branches All has already been published and pushed. I basically want to go from commit "added game over state and restart" to "cleanup3" as the in-between is a little confusing for a tutorial. Then rewrite the tutorial to never mention those commits.
$git log commit e4dd5feaeac7832b0e352cdfe497109aa46139f2 Author: metulburr <[email protected]> Date: Sun Jan 26 18:02:54 2020 -0500 cleanup3 commit 81cdf2324b9adf793ac3480c3c8240b1b0bcec6e Author: metulburr <[email protected]> Date: Sun Jan 26 17:45:38 2020 -0500 cleanup2 commit c657adb0e0e4eec52bb3949dafbdb99e28b51880 Author: metulburr <[email protected]> Date: Sun Jan 26 17:31:03 2020 -0500 cleanup after menu commit ecef4a5220f182eac15fd3f6351f86e6dea4f833 Author: metulburr <[email protected]> Date: Sat Jan 25 22:51:47 2020 -0500 added game over and restart commit 787630dd7e44b44e4f25d0ca64737b7fa3020659 Author: metulburr <[email protected]> Date: Sat Jan 25 19:13:42 2020 -0500 added options menu commit 7944f090e52e3ca908fa6756ce71247b1c56151e Author: metulburr <[email protected]> Date: Sat Jan 25 18:57:35 2020 -0500 added basic menu system commit 3308118fbc6d41636fbad30759976c03dbc947ee Author: metulburr <[email protected]> Date: Sat Jan 25 18:00:39 2020 -0500 organizing states commit 04b3f8f8356d9ca77796b04f13ac6d461baf1560 Author: metulburr <[email protected]> Date: Fri Jan 24 23:48:46 2020 -0500 added state machine commit 810571ec6ed6d979346920dd7ed0e2d254692738 Author: metulburr <[email protected]> Date: Wed Nov 29 17:08:40 2017 -0500 moved all_in_one_file.py into data and renamed it to control.py commit 0f3405ee63e3f78b7e2d51fb8932650af321272d Author: metulburr <[email protected]> Date: Wed Nov 29 17:00:34 2017 -0500 moved player and enemy classes out of main file and into their own modules :
Recommended Tutorials: