/docs/MyDocs

To get this branch, use:
bzr branch http://darksoft.org/webbzr/docs/MyDocs

« back to all changes in this revision

Viewing changes to SCM/rcs/bzr/bzr.txt

  • Committer: Suren A. Chilingaryan
  • Date: 2017-04-03 02:45:17 UTC
  • Revision ID: csa@suren.me-20170403024517-dwzj0z0k1cmhxm7u
Restructuring, OpenShift, Ansible, Git

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Plugins:
 
2
 bzr plugins                            - list
 
3
 bzr help commands | grep <plugin>      - list supported commands
 
4
 
 
5
 Install to:
 
6
 /usr/lib/python2.4/site-packages/bzrlib/plugins
 
7
 
 
8
Frontends:
 
9
 bzr viz                        - [gtk]
 
10
 bzr qlog                       - [qt, better]
 
11
 
 
12
 olive-gtk
 
13
 
 
14
Initializing:
 
15
 bzr whoami "John Doe <john.doe@gmail.com>"
 
16
 
 
17
Initializing repo:
 
18
 Remote repo:
 
19
    bzr init-repo sftp://dside.dyndns.org/home/csa/.bazaar/adei
 
20
    bzr init sftp://dside.dyndns.org/home/csa/.bazaar/adei/trunk
 
21
 
 
22
 Local directory:
 
23
    bzr init
 
24
    bzr add (adding files)
 
25
 
 
26
  Pushing first revision to remote:
 
27
    bzr push sftp://dside.dyndns.org/home/csa/.bazaar/adei/trunk
 
28
 
 
29
  Binding for automatic updates:
 
30
    bzr bind sftp://dside.dyndns.org/home/csa/.bazaar/adei/trunk/  
 
31
 
 
32
Adding/Removing files:
 
33
 bzr add                        - automatic
 
34
 bzr add --dry-run              - list files which will be added automatically
 
35
 bzr add <file|directory>       - force
 
36
 
 
37
 bzr remove [ --keep | --force ] <file.c>       - force forces physical deletion
 
38
 
 
39
 bzr ignored                    - list of ignored files
 
40
    
 
41
Information on Revisions / ChangeLogs:
 
42
 bzr log --short                - info about current revision
 
43
 bzr log -r 1                   - info on specified revision
 
44
 bzr log -r <1..100|..100|1..>  - info on revision subset
 
45
 bzr log <file>                 - info on specified file
 
46
 
 
47
 bzr log --log-format=gnu       - GNU format
 
48
 
 
49
 bzr annotate <file>            - who changed file
 
50
 bzr cat -r 100 <file>          - print old version of file
 
51
 
 
52
 
 
53
Reviewing Changes:
 
54
 bzr status                     - what is changed
 
55
 bzr diff                       - diffs
 
56
 
 
57
 bzr diff -r 1000..1100         - changes from r1000 to r1100
 
58
 bzr diff -r 1000..             - everything since r1000
 
59
 bzr diff -r tag:version-0-1    - diff with specified tagged revision
 
60
 
 
61
 bzr lessdiff                   - colorized output with less
 
62
 bzr qdiff/gdiff                - QT/GTK
 
63
 
 
64
Commits:
 
65
 bzr commit -m "Message"
 
66
 bzr commit -F <file>           - get commit message from file
 
67
 
 
68
 bzr commit <file.c>            - commit single file
 
69
 bzr commit .                   - commit current directory
 
70
 
 
71
 bzr uncommit                   - cancel last commit / pull, no changes in local dir
 
72
 bzr uncommit -r -3             - uncommit last 3 commits
 
73
 bzr revert [file]              - revert file/tree to last commit
 
74
 bzr revert -r 20               - revert tree to specified revision
 
75
 
 
76
 
 
77
Tagging:
 
78
 bzr tag version-0-1
 
79
 bzr tag 2.0-beta-1 --force     - 'force' could move tag to a new place
 
80
 bzr tag 2.0-beta-4 --delete    - removing tag
 
81
 
 
82
Branching/Checking out:
 
83
 Checkout - if central/parent repository exists.
 
84
 Branch - completely standalone branch, which we will synchronzie with pull
 
85
 Bind/Unbind - converting between this modes
 
86
 
 
87
 Binding to parent branch (synchronous updates)
 
88
    bzr bind sftp://dside.dyndns.org/home/csa/.bazaar/adei/trunk/
 
89
    bzr unbind
 
90
 
 
91
 Getting Sources:
 
92
    bzr branch http://dside.dyndns.org/bzr/adei/trunk/ [dirname]
 
93
    bzr checkout http://dside.dyndns.org/bzr/adei/trunk/ [dirname]
 
94
 Checkout without history:
 
95
    bzr checkout --lightweight http://dside.dyndns.org/bzr/adei/trunk/ [dirname]
 
96
 
 
97
 Updating:
 
98
    bzr update
 
99
 
 
100
 Local commits (not propogating to central server)
 
101
    bzr commit --local
 
102
 
 
103
Merging:
 
104
 bzr merge [URL]                - incorporate changes from another branch
 
105
 bzr conflicts                  - list merge conflicts
 
106
 bzr extmerge [file]            - resolve conflicts using configured tool
 
107
 bzr resolve [file]             - mark [all|single] conflicts resolved
 
108
 
 
109
 Different merge algorithms: criss-cross (look docs)
 
110
 
 
111
 
 
112
 bzr merge -c X foo     - Merge only changes in revision X from branch foo
 
113
 bzr merge -r X foo     - Merge only changes up to revision X from branch foo
 
114
 bzr merge -r X..Y foo  - Merge only changes beetwen revisions X and Y
 
115
                            if X>Y, the specified revisions are reverted
 
116
 
 
117
Rebasing:
 
118
 making it look like the current branch originated from a different point 
 
119
 than it did. The first step identifies the revisions that are in the current 
 
120
 branch that are not in the parent branch. The current branch is then set to 
 
121
 be at the same revision as the target branch, and each revision is replayed 
 
122
 on top of the branch. At the end of the process it will appear as though your 
 
123
 current branch was branched off the current last revision of the target.
 
124
    bzr rebase <URL>
 
125
    bzr rebase-continue         - continue after fixing conflicts
 
126
    bzr rebase-todo             - lists what still should be done
 
127
 
 
128
 
 
129
Push/Pull style coloboration:
 
130
 mirror branch:
 
131
    bzr branch sftp://centralhost/srv/bzr/X-repo/X-trunk
 
132
 per-feature branches from mirror branch:
 
133
    bzr branch X-trunk X-fix
 
134
 
 
135
 X-trunk$ bzr pull [URL]                - synchronizes with master branch
 
136
 X-fix$ bzr merge                       - mergin changes from upstrim
 
137
 X-trunk$ bzr merge ../X-fix
 
138
 X-trunk$ bzr commit -m "Fixed bug #123"
 
139
 X-trunk$ bzr push                      - pushing back to master branch
 
140
 
 
141
 
 
142
 
 
143
 bzr pull                       - gets changes f
 
144
 
 
145
Merge directives:
 
146
 bzr send -o ../fix-123.patch
 
147
 
 
148
Releasing:
 
149
 bzr export /home/csa/releases/adei-0.0.6.tar.bz2
 
150
 
 
151
 
 
152
Colloborative work
 
153
------------------
 
154
    bzr merge sftp://dside.dyndns.org/home/csa/.bazaar/adei/ui/ -r 61
 
155
 
 
156
 Info current tree:
 
157
    bzr branch-history  - which revisions we had
 
158
    bzr missing         - what we are missing in current branch
 
159
    
 
160
 Canceling merge:
 
161
    bzr revert <revision>
 
162
    bzr uncommit <number of revisions>
 
163
    
 
164
Creating Intermediate Repository
 
165
--------------------------------
 
166
    Creating:
 
167
        bzr init-repo sftp://pdv@ipepdvweb.ka.fzk.de/srv/bzr/adei
 
168
        bzr branch http://dside.dyndns.org/bzr/adei/trunk/ sftp://pdv@ipepdvweb.ka.fzk.de/srv/bzr/adei/ui
 
169
        bzr bind sftp://pdv@ipepdvweb.ka.fzk.de/srv/bzr/adei/ui
 
170
 
 
171
    Pushing upstream:
 
172
        bzr push sftp://dside.dyndns.org/home/csa/.bazaar/adei/ui
 
173
 
 
174
    
 
 
b'\\ No newline at end of file'