[Slackbuilds-users] Updates - 20240106.1
Petar Petrov
slackalaxy at gmail.com
Tue Jan 9 17:47:58 UTC 2024
thank you, that's very useful!
-p
On Tue, 9 Jan 2024 at 19:25, Jeremy Hansen <jebrhansen+SBo at gmail.com> wrote:
>
>
>
> On Tue, Jan 9, 2024, 9:26 AM Petar Petrov <slackalaxy at gmail.com> wrote:
>>
>> >And then on github I simply make a pull request
>> how do you "simply make a pull request"?
>>
>> -p
>
>
> I'm a relative git and GitHub newb, but here's what I did to start working with GitHub. (For those who are far more knowledgeable than me, if there are improvements to be made, please let me know.) I'm sure GitLab is similar, but they have slight variations in terminology.
>
> This is aimed at other git/GitHub newbs... if you aren't one, I apologize.
>
> To get started, do the following:
>
> 1. Fork SBo's GitHub repo through the GitHub interface (you need to have a GitHub account and be logged into it to fork).
> 2. Clone your newly forked repo onto your computer.
> git clone $your_new_repo_address
> 3. Set SBo's GitHub as upstream to make getting public updates easier.
> git remote add upstream git://github.com/SlackBuildsOrg/slackbuilds.git
>
> If you've never used git on your computer to make commits before, you'll need to tell git who you are so it can know who to attribute your commits to:
>
> git config --global user.email "you at example.com"
> git config --global user.name "Your Name"
>
> Now you're ready to start updating on your local computer.
>
> 1. Create a new branch for the package you're updating and switch to that branch. Typically this will be the package name that you're updating, but naming schemes are more for you than anything. The name of the branch won't affect the SBo admins reviewing your pull request.
> git checkout -B $branch_name
> 2. Make the changes to the files and verify everything works. This may require moving those files to a clean VM to verify they build properly in a clean environment.
> 3. Commit those changes to that branch on your local repo:
> git commit -m "network/discord: Update version to 1.2.3" location/to/changes
> (If there are multiple package changes due to dependency bumps or similar, do an individual commit for each package.)
> 4. Once all commits are complete that apply to your update, push those commits to your GitHub repo, forcing GitHub to create a new remote branch (since it only exists locally):
> git push -f origin $branch_name
> 5. Git will provide a link in the output you can visit to submit the pull request (PR) or you can just browse to your GitHub repo and you can submit the PR yourself (if the push was recent, it'll list the option at the top of the nation page, otherwise you can go into the branches area and can submit it that way.
> 6. Explain your changes, if necessary, when submitting the PR back to SBo's repo.
>
> Then it's just a matter of waiting for SBo admins to review your submission. If changes are needed, they'll suggest them. Once the changes are accepted, you can delete the branch on your repo online and on your local repo:
> git checkout master # first make sure you're on your master branch
> git branch -D $branch_name
>
> Once a public update is released, you can then update your local copy on the master branch using:
> git checkout master
> git pull upstream master
>
> From here, you can then create a new branch again to make more changes, commit them, push them back to GitHub, and submit a new PR.
>
> Always commit changes into a separate branch. If you commit changes to master, it'll give you problems when trying to sync with upstream after public updates.
>
> Hopefully this all makes sense. If there are any suggestions others have that might improve this, feel free to add them.
>
> Jeremy
>
> _______________________________________________
> SlackBuilds-users mailing list
> SlackBuilds-users at slackbuilds.org
> https://lists.slackbuilds.org/mailman/listinfo/slackbuilds-users
> Archives - https://lists.slackbuilds.org/pipermail/slackbuilds-users/
> FAQ - https://slackbuilds.org/faq/
>
More information about the SlackBuilds-users
mailing list