How to edit forked code and compile it without re-downloading original repo files?

  1. I forked a repo

  2. I changed couple of files and…

  3. I clone with git clone

  4. I write “make” and hit enter

  5. all edited files are replaced withthe ones from original repo

even if I change them locally anyway files downloaded and replaced before compile from original repo.

sorry it can be a newbie question but. how can I force golang to build it with my changed source codes?


This is an interesting question …

Unfortunately, given the information in your post, there’s no good way to answer it. Basically, make is a completely independent tool from Git. It is a build automation tool that can be programmed to do pretty much anything. From the behavior you’re describing, it sounds like the build process triggered by the make command in the repository you’re working with downloads the latest files from the original repository as one of its first build steps.

In order to figure out how to avoid doing this as part of that repository’s build process you would have to consult the build documentation for that repository, build things manually without the use of the make script there, or consult with the people who authored the repository you’ve forked.

I hope that helps!