LifeCycle
Source control, forking, branching, building, testing and verification, pull requests, merging, deployment
Source control
You can create a comit inside of vscode in the Source control side pannal that looks like a branch. Inside of here you can comit, pull, merge, etc this allows you to save your changes into Github
Forking
To create a fork inside of github you need to visit the github page of the repo you want to fork and click the Fork button dropsdown arrow and select new repo. When picking the Fork button you can create pull requests. You can also use the repo as a template if you want to make your repo independent from the mian one
Branching
Inside of your repo you can create branches that allow you to make changes that are not on the main branch. You can use branches to test furtures before moving them onto a main branch. You can also use branches when in a team to have areas for each member to pu there work in
Building
After having all of your tools installed and ready to go create a new terminal in VS Code to type in cmds. IF there is no Venv To the left of the directory run source venv/bin/activate inside the terminal.(this should be done inside of the windows terminal before running code .) to build your site use “make” to build
ERR FIXES: sometimes you may run into errors here is how to fix some of them
Run Bundle Install Make sure all tools are installed by looking at there version Check if any files have wrong names like spaces,repeat names, etc re install tools
Testing
After running make you will be given a link, inside of this link will be your repos website were you can test enything you have added. Dont forget to open the console by right clicking -> inspect element
pull requests
When commiting to git hub with your final changes and ready to add them into the teacher repo you need to create a pull request. Before creating one make sure in the action tab that there are no failed actions and all actions are finsihed loading. To create a pull reuest you must click the contribute buttton found at the top of your repo page. Dont see it? Make sure that you forked the repo and did not make a template. After creating the pull request add a discription of what you added/changed and send the pull request. If the request is rejected go to the pull request and see what the person said whats wrong and fix it asap!
merging
Merging is how you merge changes from one branch onto another. This is what makes pull requests work. When on the reciveing end of a pull request you will need to check if there are conflicts before merging the pull request. You can do this inside of the pull request as github tells you if some code is conflicting. Before merging you should go through all the added/changed files for errors. If everything looks good just click the merge button
( not in context with text above) After sending a pull request dont foget to sync your fork so your fork does not fall behind and cause new conflicts
deployment
deployment happens after any changes happen in your github repo. You can see what is happining inside of the Actions tab inside your repo. If the deploy fails it will give you an err msg with syntax. If this happenes go to vs code, make sure you pulled, and run make. If the make fails it will tell you where the err is. If nothing happenes use ChatGPT or any AI to help resolve your issue. After the deployment is successful there will be a link to your repos site that you can run on other computers besides yours!