Compare and merge two versions of a set of source blocks
2 PART 100 150 MATCHING 2 PART 100 200 4 AGAINST
Integrated with block editor
L, O (without diff) V, W (with diff highlighted)
KEEP, TOSS to finish a block
polyFORTH AUDIT
History
SCCS
SCCS = Source Code Control System
SCCS (SNOBOL) - 1972
SCCS (C) - 1977
Store version history per file
Record changes a series of edits
Used as internal format of BitKeeper, Teamware
RCS - 1982
RCS = Revision Control System
Store version history per file
Files are checked in and out with locking
Support for branches and merging
Used internally by CVS
Sharing often via NFS or other file shares
RCS Usage
( create a new file called foo.txt)
ci foo.txt
co foo.txt
( compile or otherwise use it )
co -l foo.txt
( edit foo.txt )
ci foo.txt
RCS Branches
diff - 1974
diff a.txt b.txt
2,3c2,3< In this example, some
< things will be changed.
---
> In this example, one
> thing will be changed.
This is an example.
In this example, some
things will be changed.
The quick brown fox jumped
over the lazy dog.
This is an example.
In this example, one
thing will be changed.
The quick brown fox jumped
over the lazy dog.
diff (unified) - 1990
diff -u a.txt b.txt
--- a.txt 2019-10-25 22:56:26.000000000 -0700+++ b.txt 2019-10-25 22:56:52.000000000 -0700
@@ -1,6+1,6 @@
This is an example.
-In this example, some-things will be changed.+In this example, one+thing will be changed.
The quick brown fox jumped
over the lazy dog.
This is an example.
In this example, some
things will be changed.
The quick brown fox jumped
over the lazy dog.
This is an example.
In this example, one
thing will be changed.
The quick brown fox jumped
over the lazy dog.
patch - 1985
Reverse what diff does!
Created by Larry Wall (inventor of Perl)
Developers can now send "patches"
Diffs can sometimes apply even if things change
Diffs can partially apply
CVS - 1990
CVS = Concurrent Version System
Created by Dick Grune to work with his grad students
Checkouts can be edited conncurrently
Before a develop can commit they have update and resolve conflicts
pick 4ffe208 Adding more to the talk.
pick c16e35a More improvements.
pick 1993d9d More
# Rebase 933b026..1993d9d onto 933b026 (3 commands)
#
# Commands:
# p, pick = use commit
# r, reword = use commit, but edit the commit message
# e, edit = use commit, but stop for amending
# s, squash = use commit, but meld into previous commit
# f, fixup = like "squash", but discard this commit's log message
# x, exec = run command (the rest of the line) using shell
# d, drop = remove commit
# l, label