/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to doc/en/user-guide/undoing_mistakes.txt

  • Committer: Aaron Bentley
  • Date: 2007-12-20 19:16:02 UTC
  • mto: This revision was merged to the branch mainline in revision 3235.
  • Revision ID: abentley@panoramicfeedback.com-20071220191602-q1p5o3svshujfodd
Add support for hardlinks to TreeTransform

Show diffs side-by-side

added added

removed removed

Lines of Context:
10
10
Dropping the revision history for a project
11
11
-------------------------------------------
12
12
 
13
 
If you accidentally put the wrong tree under version control, simply
 
13
If you accidently put the wrong tree under version control, simply
14
14
delete the ``.bzr`` directory.
15
15
 
16
16
Deregistering a file or directory
17
17
---------------------------------
18
18
 
19
 
If you accidentally register a file using ``add`` that you
 
19
If you accidently register a file using ``add`` that you
20
20
don't want version controlled, you can use the ``remove``
21
21
command to tell Bazaar to forget about it.
22
22
 
29
29
 
30
30
This will complain about the file being modified or unknown.
31
31
If you want to keep the file, use the ``--keep`` option.
32
 
Alternatively, if you want to delete the file, use the ``--force`` option.
 
32
Alternatively, if you want to remove the file, use the ``--force`` option.
33
33
For example::
34
34
 
35
35
  bzr add foo.html
36
36
  (oops - didn't mean that)
37
37
  bzr remove --keep foo.html
38
 
  (foo.html left on disk, but deregistered)
 
38
  (foo.html left on disk)
39
39
 
40
 
On the other hand, the unchanged ``TODO`` file is deregistered and
 
40
On the other hand, the ``TODO`` file is deregistered and
41
41
removed from disk without complaint in this example::
42
42
 
43
43
  bzr add TODO
97
97
chapter, it is worth noting now that ``uncommit`` restores any pending
98
98
merges. (Running ``bzr status`` after ``uncommit`` will show these.)
99
99
``merge`` can also be used to effectively undo just a selected commit
100
 
earlier in history. For more information on ``merge``, see
101
 
`Merging changes <merging_changes.html>`_ in the next chapter and the
102
 
Bazaar User Reference.
 
100
earlier in history. For more information on ``merge``, see `Merging changes`_
 
101
in the next chapter and the Bazaar User Reference.
103
102
 
104
103
Undoing multiple commits
105
104
------------------------
127
126
  Committed revision 20.
128
127
  (release the code)
129
128
  (hmm - bad fix)
130
 
  bzr revert -r 19
 
129
  bzr revert -r 20
131
130
  bzr commit -m "Backout fix for bug #5"
132
131
 
133
 
This will change your entire tree back to the state as of revision 19,
134
 
which is probably only what you want if you haven't made any new commits
135
 
since then. If you have, the ``revert`` would wipe them out as well. In that
136
 
case, you probably want to use `Reverse cherrypicking
137
 
<adv_merging.html#reverse-cherrypicking>`_ instead to
138
 
back out the bad fix.
139
 
 
140
 
Note: As an alternative to using an absolute revision number (like 19), you can
141
 
specify one relative to the tip (-1) using a negative number like this::
142
 
 
143
 
  bzr revert -r -2
144
 
 
145
132
Correcting a tag
146
133
----------------
147
134
 
150
137
 
151
138
  bzr tag 2.0-beta-1
152
139
  (oops, we're not yet ready for that)
153
 
  (make more commits to include more fixes)
154
140
  bzr tag 2.0-beta-1 --force
155
141
 
156
142
Clearing a tag