Best method for updating code

How, what and why to code in BYOND.

Moderators: MisterPerson, Code Maintainers

glizzzy
 
Joined: Thu Jan 23, 2020 1:04 am
Byond Username: Glizzzy

Best method for updating code

Postby glizzzy » Thu Jan 23, 2020 1:23 am #537010

Hey All,

Just wanted to pop in to ask a question regarding updating the source code while I create a map. The questions is thus:

How do I go about creating a map while being able to update the source code and keep my changes? Once I "pull" I think from github will it merge the files or replace mine with the new?

If clarification is needed I'd love to explain further. I just really want to create a map. I've messed around with it for quite some time.



User avatar
Qustinnus
TGMC Maintainer
 
Joined: Tue Nov 07, 2017 12:30 am
Byond Username: Qustinnus

Re: Best method for updating code

Postby Qustinnus » Thu Jan 23, 2020 1:43 am #537012

If I understand you correctly; you should be fine. Pulling essentialy gets any files that have changed and tries to merge them. If there's a merge conflict it will tell you. If you're making a new map this should never cause issues as you're not changing files that the pull would have to merge.

SpaceManiac
Code Maintainer
 
Joined: Fri Sep 22, 2017 4:06 am
Byond Username: SpaceManiac
Github Username: SpaceManiac

Re: Best method for updating code

Postby SpaceManiac » Thu Jan 23, 2020 1:53 am #537014

Start with this section in the guide:
https://tgstation13.org/wiki/Setting_up ... _your_Repo

glizzzy
 
Joined: Thu Jan 23, 2020 1:04 am
Byond Username: Glizzzy

Re: Best method for updating code

Postby glizzzy » Thu Jan 23, 2020 2:22 am #537017

Qustinnus wrote:If I understand you correctly; you should be fine. Pulling essentialy gets any files that have changed and tries to merge them. If there's a merge conflict it will tell you. If you're making a new map this should never cause issues as you're not changing files that the pull would have to merge.


Ah dope. So I can just check every now and then and update the code pretty much base tg I dont think i'll make many changes and develop my map without worrying of getting stuck on an old source?

How about sprites say I change the chair sprites, will it overwrite my chair sprites pulling the newest code?

User avatar
Qustinnus
TGMC Maintainer
 
Joined: Tue Nov 07, 2017 12:30 am
Byond Username: Qustinnus

Re: Best method for updating code

Postby Qustinnus » Thu Jan 23, 2020 2:54 am #537026

It'll throw a merge conflict, you'd need to fix it by manually copy pasting the sprites you want

glizzzy
 
Joined: Thu Jan 23, 2020 1:04 am
Byond Username: Glizzzy

Re: Best method for updating code

Postby glizzzy » Thu Jan 23, 2020 3:07 am #537027

Qustinnus wrote:It'll throw a merge conflict, you'd need to fix it by manually copy pasting the sprites you want


Sick. Thanks for all the help!

SpaceManiac
Code Maintainer
 
Joined: Fri Sep 22, 2017 4:06 am
Byond Username: SpaceManiac
Github Username: SpaceManiac

Re: Best method for updating code

Postby SpaceManiac » Thu Jan 23, 2020 3:15 am #537031

there's a script for icon conflicts https://github.com/tgstation/tgstation/ ... -conflicts

User avatar
Qustinnus
TGMC Maintainer
 
Joined: Tue Nov 07, 2017 12:30 am
Byond Username: Qustinnus

Re: Best method for updating code

Postby Qustinnus » Thu Jan 23, 2020 5:48 am #537039

wont that fuck up if theres icon with the same name?

SpaceManiac
Code Maintainer
 
Joined: Fri Sep 22, 2017 4:06 am
Byond Username: SpaceManiac
Github Username: SpaceManiac

Re: Best method for updating code

Postby SpaceManiac » Fri Jan 24, 2020 2:41 am #537124

it will yell at you but still do its job if it attempts to operate on an icon file with two of the same icon state
this is also displayed as an error in Dream Maker anyways, so just fix it


Return to Coding

Who is online

Users browsing this forum: No registered users