[armedbear-devel] 20130823a Diffs for chemicalamba (Akka bridge in ABCL)
Mark Evenson
evenson at panix.com
Fri Aug 23 06:04:03 UTC 2013
On Aug 22, 2013, at 9:37 PM, ubikation _ <ubikation at gmail.com> wrote:
> Hey Mark,
>
> I really appreciate your help but I am having trouble understand the diffs that you are sending me. I understand that HG is generating them but I am having trouble recreating your state. What tools do you recommend? I understand that creating a huge class isn't a good Java practice and I'm happy to break it up but it was hard for me to figure out exactly what goes where according to your diffs.
[…]
For any software development, open or not, coming to terms with "diffs" is a basic skill that has no "right answer" for the tools one uses. A "diff" is a standardized format, used by a variety of tools including most IDEs these days.
But in the beginning there was the command line, so the first tools you should come to terms with are diff(1) and patch(1):
cmd$ [[[clone repo into "./chemicalambda"]]]
cmd$ cd chemicalambda
cmd$ patch -p 1 < file-that-contains-the-diff.diff
The "-p 1" strips the top-level of the hierarchy, and then patch reads the contents of stdin for changes to make. One will see either success or error messages in applying the diff. Re-do until you get the results you want, then deal with the changes in your own version control ecology.
What I like about hg is that one can just directly import a diff into the repo:
cmd$ hg import file-that-contains-the-diff.diff
but git certainly has similar functionality, somewhere.
I avoided a comprehensive understanding diffs for many years, much to my own detriment.
More information about the armedbear-devel
mailing list