Read the statement by Michael Teeuw here.
GIT and updates to Weather Module
-
Hello! I just need a sanity-check from the smart people on this forum to make sure I understand what I’m doing:
I’ve built/tested a new Provider for the (new) default weather module. This Provider allows the use of Environment Canada current/forecast weather data on MM. My code also requires a few small tweaks to existing code in the weather module.
While I’m an (ahem) older Developer, I don’t have a ton of experience with Github, so I just want to make sure I understand the steps to submit my updates to the default weather module. Here’s my understanding of things:
-
Fork my own copy of the MagicMirror repository into my Github account.
-
Make my changes - i.e. update the existing modules that need changes plus add my new Provider code
-
For each module a I change, I need to Commit to the master branch (assuming this is the master for my own forked copy of MM repository)
-
Once I have made/committed all my changes, I create a Pull Request that outlines what I have done. I assume a single PR will cover all the scripts I am touching?
-
The PR will be assessed, with maybe questions asked, additional updates requested, whatever. If accepted, my changes in my MM repository will be merged into the main MM repository
Do I have all this right? Sorry for the newbie questions - just new to this stuff and don’t want to screw up.
Thanks!
-
-
@crazylegs almost correct steps.
the fork is the key, now u have your copy to.modify
make your own branch for changes
on master branch (git branch has *next to master)
git checkout -b your_new_branch_name
-
2 more things:
- the new branch you are using should start on the mm-branch
develop
(notmaster
) - when creating the PR on github you have to manually change the base branch from
master
todevelop
These rules are specific to the mm-repo. Because of quarterly releases the
master
branch only changes 4 times in a year. The development between the releases is done ondevelop
. - the new branch you are using should start on the mm-branch
-
@karsten13 thanks forgot develop again!!
-
Thank you both so much for your guidance! It is much appreciated and I believe I understand what I need to do.