unison/unison-src/transcripts/reset.output.md

199 lines
3.0 KiB
Markdown
Raw Permalink Normal View History

``` unison
2024-07-06 02:55:07 +03:00
def = "first value"
2023-06-05 16:13:08 +03:00
```
``` ucm
2023-06-05 16:13:08 +03:00
Loading changes detected in scratch.u.
2023-06-05 16:13:08 +03:00
I found and typechecked these definitions in scratch.u. If you
do an `add` or `update`, here's how your codebase would
change:
⍟ These new definitions are ok to `add`:
2024-07-06 02:55:07 +03:00
def : Text
2023-06-05 16:13:08 +03:00
```
``` unison
2024-07-06 02:55:07 +03:00
def = "second value"
```
Can reset to a value from history by number.
``` ucm
2024-07-06 02:55:07 +03:00
scratch/main> update
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
Okay, I'm searching the branch for code that needs to be
updated...
Done.
2023-06-05 16:13:08 +03:00
scratch/main> history
2023-06-05 16:13:08 +03:00
Note: The most recent namespace hash is immediately below this
message.
2024-07-06 02:55:07 +03:00
⊙ 1. #5vq851j3hg
2023-06-05 16:13:08 +03:00
+ Adds / updates:
2024-07-06 02:55:07 +03:00
def
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
⊙ 2. #ujvq6e87kp
+ Adds / updates:
def
□ 3. #4bigcpnl7t (start of history)
2023-06-05 16:13:08 +03:00
scratch/main> reset 2
2023-06-05 16:13:08 +03:00
Done.
2024-07-06 02:55:07 +03:00
scratch/main> view def
def : Text
def = "first value"
scratch/main> history
2023-06-05 16:13:08 +03:00
Note: The most recent namespace hash is immediately below this
message.
2024-07-06 02:55:07 +03:00
⊙ 1. #ujvq6e87kp
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
+ Adds / updates:
def
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
□ 2. #4bigcpnl7t (start of history)
2023-06-05 16:13:08 +03:00
```
2024-07-06 02:55:07 +03:00
Can reset to a value from reflog by number.
2023-06-05 16:13:08 +03:00
``` ucm
2024-07-06 02:55:07 +03:00
scratch/main> reflog
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
Below is a record of recent changes, you can use
`reset #abcdef` to reset the current branch to a previous
state.
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
Tip: Use `diff.namespace 1 7` to compare between points in
history.
2023-06-05 16:13:08 +03:00
2024-07-10 00:45:11 +03:00
Branch Hash Description
1. scratch/main #ujvq6e87kp reset ujvq6e87kp4288eq3al9v5luctic0ocd7ug1fu0go5bicrr2vfnrb0...
2. scratch/main #5vq851j3hg update
3. scratch/main #ujvq6e87kp update
4. scratch/main #4bigcpnl7t builtins.merge
5. scratch/main #sg60bvjo91 Project Created
2024-07-06 02:55:07 +03:00
-- Reset the current branch to the first history element
scratch/main> reset 2
Done.
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
scratch/main> view def
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
def : Text
def = "second value"
2023-06-05 16:13:08 +03:00
scratch/main> history
2023-06-05 16:13:08 +03:00
Note: The most recent namespace hash is immediately below this
message.
2024-07-06 02:55:07 +03:00
⊙ 1. #5vq851j3hg
2023-06-05 16:13:08 +03:00
+ Adds / updates:
2024-07-06 02:55:07 +03:00
def
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
⊙ 2. #ujvq6e87kp
+ Adds / updates:
def
□ 3. #4bigcpnl7t (start of history)
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
```
# reset branch
2023-06-05 16:13:08 +03:00
``` ucm
2024-07-06 02:55:07 +03:00
foo/main> history
Note: The most recent namespace hash is immediately below this
message.
□ 1. #sg60bvjo91 (start of history)
2023-11-14 06:36:03 +03:00
2023-06-05 16:13:08 +03:00
```
``` unison
2024-07-06 02:55:07 +03:00
a = 5
```
2023-06-05 16:13:08 +03:00
``` ucm
2024-07-06 02:55:07 +03:00
foo/main> update
Okay, I'm searching the branch for code that needs to be
updated...
Done.
foo/empty> reset /main:
2024-07-06 02:55:07 +03:00
Done.
foo/empty> view a
a : ##Nat
a = 5
foo/empty> history
Note: The most recent namespace hash is immediately below this
message.
□ 1. #5l94rduvel (start of history)
2023-06-05 16:13:08 +03:00
```
2024-07-06 02:55:07 +03:00
## second argument is always interpreted as a branch
``` unison
2024-07-06 02:55:07 +03:00
main.a = 3
```
``` ucm
2024-07-06 02:55:07 +03:00
foo/main> update
Okay, I'm searching the branch for code that needs to be
updated...
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
Done.
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
foo/main> history
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
Note: The most recent namespace hash is immediately below this
message.
⊙ 1. #0i64kpfccl
+ Adds / updates:
main.a
□ 2. #5l94rduvel (start of history)
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
foo/main> reset 2 main
2023-06-05 16:13:08 +03:00
2024-07-06 02:55:07 +03:00
Done.
2023-06-07 19:48:25 +03:00
2024-07-06 02:55:07 +03:00
```