How to Upgrade to Latest commits without altering my Custom modified codes
-
How can I upgrade to latest HISE commits without changing my modified codes. Every time I need to do my modifications manually because it replaces all my previous codes.
Is there any better approach to upgrade without loosing my previously modified/altered codes ? -
@DabDab When you want to customise Hise, don't do it in the
develop
branch, but:- create a branch for this purpose, like
develop_myCustomBranch
or whatever. - commit your customisations
- when you want to update from original develop, just make a merge
develop
->develop_myCustomBranch
- create a branch for this purpose, like
-
@ustk Do I need to create an A/c on GitHub ? Do I need to use GitHub for that ?
-
@DabDab Are you not using Git already for your own projects? If not, this would be the first and most important recommandation.
Then you can use a client to help dealing with the beast. I myself use GitHub Desktop to manage the different repos easily (might not be the best, but very easy for a start)
From here you will be able to create new repos, new branches, merge, cherry pick, etc...
This also allows you to run multiple Hise versions at the same time (often, I run a develop and a custom at the same time. Just don't forget to swap the branches when you need to export/build) Speaking of which... -
@ustk Thank you so much. Great, today I have got a new topic for research GITHUB.
-
@DabDab You don't need a github account, but you do need to use git
I made a video about this
-
I have been able to create Github A/c and Github Desktop. I have uploaded My Existing Custom HISE Repo to Github. But I have few questions @d-healey @ustk . It is adding my branch name
As far I know since it is a develop branch if I don't change the name other than HISE-develop HISE won't build (may be I am wrong).My second question is How to Merge the upgraded HISE commits with my repo without modifying /replacing my custom codes ? Is there any tutorial or guide ?
-
@DabDab said in How to Upgrade to Latest commits without altering my Custom modified codes:
Is there any tutorial
I made a video, check my YouTube
-
@DabDab Watch Dave's tutos as a starting point.
Then in your case, since the repos will be differentiated between Hise original and your custom version, I think the approach would be:- Git: create a new custom branch from original develop (so for now you have two identical branches, develop and custom)
- OS: assuming you have two Hise directories on your computer, drag and overwrite your changed files from your custom Hise folder to the main Hise folder
- Git: commit the changes in your custom branch
So in the end, you'll have the unchanged develop as well as your custom branch, so you can navigate between the two
-
@ustk said in How to Upgrade to Latest commits without altering my Custom modified codes:
Then in your case, since the repos will be differentiated between Hise original and your custom version, I think the approach would be:
Git: create a new custom branch from original develop (so for now you have two identical branches, develop and custom) OS: assuming you have two Hise directories on your computer, drag and overwrite your changed files from your custom Hise folder to the main Hise folder Git: commit the changes in your custom branch
Yep, this is basically the procedure. I call my branch development (I should probably change that), and when I need updates from Christoph I pull the develop branch and merge it into my development branch. I have Christoph's branch added as a remote so I can just refer to it as develop, but I could just use upstream/develop.
Here's the video I was referring to, you don't need to do anything on github if you don't want to, but I think it's easier to use github for creating the initial fork, and syncing between systems.
-
@d-healey said in How to Upgrade to Latest commits without altering my Custom modified codes:
you don't need to do anything on github if you don't want to, but I think it's easier to use github for creating the initial fork, and syncing between systems.
This, and the most important thing =>The extra security of having duplicates somewhere in the cloudy skies!
-
@ustk said in How to Upgrade to Latest commits without altering my Custom modified codes:
This, and the most important thing =>The extra security of having duplicates somewhere in the cloudy skies!
Definitely an advantage, but I don't like to rely on someone else's computer to be my backup. I use github + local backup + another cloud backup. For my own project I use Codeberg rather than github.
-
@ustk said in How to Upgrade to Latest commits without altering my Custom modified codes:
@DabDab Watch Dave's tutos as a starting point.
Then in your case, since the repos will be differentiated between Hise original and your custom version, I think the approach would be:- Git: create a new custom branch from original develop (so for now you have two identical branches, develop and custom)
- OS: assuming you have two Hise directories on your computer, drag and overwrite your changed files from your custom Hise folder to the main Hise folder
- Git: commit the changes in your custom branch
So in the end, you'll have the unchanged develop as well as your custom branch, so you can navigate between the two
I am using GitHub Desktop. Is it mandatory to use Git since I have installed GitHub Desktop already?
@d-healey showed how to do it with Git. I have no clue how to do it using Github Desktop.
-
@DabDab Git is the version control system. Github is a website for hosting git repositories. Github Desktop is a GUI for working with git and github - when you installed Github Desktop it also installed git.
-
@d-healey Okay. got it. I am little confused how to merge branches.
-
@DabDab I don't know the specifics of that app but the basic thing is you pull from the branch you want to get updates from, then make sure you're on the branch you want to merge into, and you do the merge.
git checkout develop git pull git checkout myBranch git merge develop
-
@d-healey Sure. But I will have to google how to do it using GitHub desktop.
-
@DabDab said in How to Upgrade to Latest commits without altering my Custom modified codes:
@d-healey Sure. But I will have to google how to do it using GitHub desktop.
Ok, but it's faster to type those 4 lines than to Google it :)
-
@DabDab Menu -> Branch -> Merge into current branch...
Dave! I got it in 3 moves!
-
With the help of you guys @d-healey @ustk I have been able to install and use Github Desktop and Git hub successfully. As @ustk said I have been managed to do so...
- Git: create a new custom branch from original develop (so for now you have two identical branches, develop and custom)
- OS: assuming you have two Hise directories on your computer, drag and overwrite your changed files from your custom Hise folder to the main Hise folder
- Git: commit the changes in your custom branch
So in the end, you'll have the unchanged develop as well as your custom branch, so you can navigate between the two
Now my Repo HISE looks something like this... (Ignore Hise-masterRDG)
I have created a separate branch namedDabbu
Now my question is :
- How Can I get update from @Christoph-Hart repo ?
- Do I need to delete my existing local directory (lets say D:\HISE) and clone the original repo every time ?
- If I do so , will I loose my branch that I have created named
Dabbu
?