Update transcripts

This commit is contained in:
Chris Penner 2024-01-08 13:56:24 -08:00
parent f2244f612e
commit 6f3bdb3ba7
4 changed files with 51 additions and 111 deletions

View File

@ -23,21 +23,21 @@ So `j1` and `j2` have common history up through `v4`, then `j1` deletes some def
First, we create some common history before a fork:
```ucm
.a> alias.term .builtin.Nat.+ delete1
.a> alias.term .builtin.Nat.* delete2
.a> alias.term .builtin.Nat.drop delete3
.a> alias.type .builtin.Nat Delete4
.> alias.term builtin.Nat.+ a.delete1
.> alias.term builtin.Nat.* a.delete2
.> alias.term builtin.Nat.drop a.delete3
.> alias.type builtin.Nat a.Delete4
```
Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previously and then adding one unrelated term via a merge with little history. It's this short history merge which will become a bad LCA of the empty namespace.
```ucm
.> fork a a2
.a> delete.term.verbose delete1
.a> delete.term.verbose delete2
.a> delete.term.verbose delete3
.a> delete.type.verbose Delete4
.newbranchA> alias.term .builtin.Float.+ dontDelete
.> delete.term.verbose a.delete1
.> delete.term.verbose a.delete2
.> delete.term.verbose a.delete3
.> delete.type.verbose a.Delete4
.> alias.term .builtin.Float.+ newbranchA.dontDelete
.> merge newbranchA a
.a> find
```
@ -45,12 +45,12 @@ Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previ
Meanwhile, `a2` adds some other unrelated terms, some via merging in namespaces with little history. When merging `a2` back into `a`, the deletes from their common history should be respected.
```ucm
.a2> alias.term .builtin.Text.take keep1
.a2> alias.term .builtin.Text.take keep2
.a2> alias.term .builtin.Text.take keep3
.a2> alias.term .builtin.Text.take keep4
.a2> alias.term .builtin.Text.take keep5
.newbranchA2> alias.term .builtin.Text.take keep6
.> alias.term builtin.Text.take a2.keep1
.> alias.term builtin.Text.take a2.keep2
.> alias.term builtin.Text.take a2.keep3
.> alias.term builtin.Text.take a2.keep4
.> alias.term builtin.Text.take a2.keep5
.> alias.term builtin.Text.take newbranchA2.keep6
.> merge newbranchA2 a2
.a2> find
```

View File

@ -20,21 +20,19 @@ So `j1` and `j2` have common history up through `v4`, then `j1` deletes some def
First, we create some common history before a fork:
```ucm
☝️ The namespace .a is empty.
.a> alias.term .builtin.Nat.+ delete1
.> alias.term builtin.Nat.+ a.delete1
Done.
.a> alias.term .builtin.Nat.* delete2
.> alias.term builtin.Nat.* a.delete2
Done.
.a> alias.term .builtin.Nat.drop delete3
.> alias.term builtin.Nat.drop a.delete3
Done.
.a> alias.type .builtin.Nat Delete4
.> alias.type builtin.Nat a.Delete4
Done.
@ -46,7 +44,7 @@ Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previ
Done.
.a> delete.term.verbose delete1
.> delete.term.verbose a.delete1
Name changes:
@ -57,7 +55,7 @@ Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previ
Tip: You can use `undo` or `reflog` to undo this change.
.a> delete.term.verbose delete2
.> delete.term.verbose a.delete2
Name changes:
@ -68,7 +66,7 @@ Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previ
Tip: You can use `undo` or `reflog` to undo this change.
.a> delete.term.verbose delete3
.> delete.term.verbose a.delete3
Name changes:
@ -79,7 +77,7 @@ Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previ
Tip: You can use `undo` or `reflog` to undo this change.
.a> delete.type.verbose Delete4
.> delete.type.verbose a.Delete4
Name changes:
@ -90,9 +88,7 @@ Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previ
Tip: You can use `undo` or `reflog` to undo this change.
☝️ The namespace .newbranchA is empty.
.newbranchA> alias.term .builtin.Float.+ dontDelete
.> alias.term .builtin.Float.+ newbranchA.dontDelete
Done.
@ -113,36 +109,34 @@ Now we fork `a2` off of `a`. `a` continues on, deleting the terms it added previ
.a> find
1. dontDelete : Float -> Float -> Float
1. dontDelete : ##Float -> ##Float -> ##Float
```
Meanwhile, `a2` adds some other unrelated terms, some via merging in namespaces with little history. When merging `a2` back into `a`, the deletes from their common history should be respected.
```ucm
.a2> alias.term .builtin.Text.take keep1
.> alias.term builtin.Text.take a2.keep1
Done.
.a2> alias.term .builtin.Text.take keep2
.> alias.term builtin.Text.take a2.keep2
Done.
.a2> alias.term .builtin.Text.take keep3
.> alias.term builtin.Text.take a2.keep3
Done.
.a2> alias.term .builtin.Text.take keep4
.> alias.term builtin.Text.take a2.keep4
Done.
.a2> alias.term .builtin.Text.take keep5
.> alias.term builtin.Text.take a2.keep5
Done.
☝️ The namespace .newbranchA2 is empty.
.newbranchA2> alias.term .builtin.Text.take keep6
.> alias.term builtin.Text.take newbranchA2.keep6
Done.
@ -172,12 +166,12 @@ Meanwhile, `a2` adds some other unrelated terms, some via merging in namespaces
2. delete2 : Delete4 -> Delete4 -> Delete4
3. delete3 : Delete4 -> Delete4 -> Delete4
4. builtin type Delete4
5. keep1 : Delete4 -> Text -> Text
6. keep2 : Delete4 -> Text -> Text
7. keep3 : Delete4 -> Text -> Text
8. keep4 : Delete4 -> Text -> Text
9. keep5 : Delete4 -> Text -> Text
10. keep6 : Delete4 -> Text -> Text
5. keep1 : Delete4 -> ##Text -> ##Text
6. keep2 : Delete4 -> ##Text -> ##Text
7. keep3 : Delete4 -> ##Text -> ##Text
8. keep4 : Delete4 -> ##Text -> ##Text
9. keep5 : Delete4 -> ##Text -> ##Text
10. keep6 : Delete4 -> ##Text -> ##Text
```
@ -232,24 +226,24 @@ At this point, all the things that `a` has deleted (`delete1`, `delete2`, etc) s
```ucm
.a> find
1. dontDelete : Float -> Float -> Float
2. keep1 : Delete4 -> Text -> Text
3. keep2 : Delete4 -> Text -> Text
4. keep3 : Delete4 -> Text -> Text
5. keep4 : Delete4 -> Text -> Text
6. keep5 : Delete4 -> Text -> Text
7. keep6 : Delete4 -> Text -> Text
1. dontDelete : ##Float -> ##Float -> ##Float
2. keep1 : ##Nat -> ##Text -> ##Text
3. keep2 : ##Nat -> ##Text -> ##Text
4. keep3 : ##Nat -> ##Text -> ##Text
5. keep4 : ##Nat -> ##Text -> ##Text
6. keep5 : ##Nat -> ##Text -> ##Text
7. keep6 : ##Nat -> ##Text -> ##Text
.asquash> find
1. dontDelete : Float -> Float -> Float
2. keep1 : Delete4 -> Text -> Text
3. keep2 : Delete4 -> Text -> Text
4. keep3 : Delete4 -> Text -> Text
5. keep4 : Delete4 -> Text -> Text
6. keep5 : Delete4 -> Text -> Text
7. keep6 : Delete4 -> Text -> Text
1. dontDelete : ##Float -> ##Float -> ##Float
2. keep1 : ##Nat -> ##Text -> ##Text
3. keep2 : ##Nat -> ##Text -> ##Text
4. keep3 : ##Nat -> ##Text -> ##Text
5. keep4 : ##Nat -> ##Text -> ##Text
6. keep5 : ##Nat -> ##Text -> ##Text
7. keep6 : ##Nat -> ##Text -> ##Text
```

View File

@ -1,18 +0,0 @@
Regression test for https://github.com/unisonweb/unison/issues/2567
```ucm:hide
.> alias.type ##Nat .foo.bar.Nat
```
```unison:hide
structural ability Foo where
blah : Nat -> Nat
zing.woot : Nat -> (Nat,Nat) -> Nat
```
```ucm
.some.subnamespace> add
.some.subnamespace> alias.term Foo.zing.woot Foo.woot
.> view Foo
.somewhere> view .some.subnamespace.Foo
```

View File

@ -1,36 +0,0 @@
Regression test for https://github.com/unisonweb/unison/issues/2567
```unison
structural ability Foo where
blah : Nat -> Nat
zing.woot : Nat -> (Nat,Nat) -> Nat
```
```ucm
☝️ The namespace .some.subnamespace is empty.
.some.subnamespace> add
⍟ I've added these definitions:
structural ability Foo
.some.subnamespace> alias.term Foo.zing.woot Foo.woot
Done.
.> view Foo
structural ability some.subnamespace.Foo where
blah : Nat ->{some.subnamespace.Foo} Nat
woot : Nat -> (Nat, Nat) ->{some.subnamespace.Foo} Nat
☝️ The namespace .somewhere is empty.
.somewhere> view .some.subnamespace.Foo
structural ability .some.subnamespace.Foo where
blah : Nat ->{.some.subnamespace.Foo} Nat
woot : Nat -> (Nat, Nat) ->{.some.subnamespace.Foo} Nat
```