bzr detaillierte einführung

bzr detaillierte einführung

1. Übersicht

Bazaar (bzr) ist ein weiteres Open-Source-DVCS (Distributed Version Control System), das versucht, etwas Neues in die Welt von SCM (Source Code Management) zu bringen. bzr ist eine Ubuntu-Linux-Distributionsfirma, die von Python geschrieben wurde. Einfach als ähnlich wie die Git-Funktion verstanden.

2. Herunterladen

Referenzkette

  • debian:
	sudo apt-get -t lenny-backports install bzr
  • Centos / RHEL
su -c 'rpm -Uvh http://dl.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm'

Then you can use yum to install the bzr package: su -c 'yum install bzr'

3. Verwenden Sie

  • Benutzer erstellen
$ bzr whoami "John Doe <[email protected]>"
$ bzr whoami "[email protected]"
#check
$ bzr whami
  • Erstellen Sie Lager und Filialen
# 创建仓库
[root@db01 /home/chenjiaona/Downloads]# bzr init-repo chenjiaona
Shared repository with trees (format: 2a)
Location:
  shared repository: chenjiaona
# 创建分支
[root@db01 /home/chenjiaona/Downloads]# bzr init chenjiaona/master
Created a repository tree (format: 2a)                                                                                                                                                
Using shared repository: /home/chenjiaona/Downloads/chenjiaona/
# 创建文件
[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# ls
test.txt
[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# bzr commit -m "test"
Committing to: /home/chenjiaona/Downloads/chenjiaona/master/                                                                                                                          
brz: ERROR: No changes to commit. Please 'brz add' the files you want to commit, or use --unchanged to force an empty commit.
(reverse-i-search)`ad': cd /home/chenjiaona/Downlo^Cs/
[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# bzr add .
adding test.txt
[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# bzr commit -m "test"
Committing to: /home/chenjiaona/Downloads/chenjiaona/master/                                                                                                                          
added test.txt
Committed revision 1.
[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# bzr add .
[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# bzr diff
=== modified file 'test.txt'
--- old/test.txt	2021-02-03 03:46:26 +0000
+++ new/test.txt	2021-02-03 03:46:43 +0000
@@ -1,1 +1,2 @@
 aa
+ddd

[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# bzr log
------------------------------------------------------------
revno: 1
committer: [email protected]
branch nick: master
timestamp: Wed 2021-02-03 11:46:26 +0800
message:
  test
  • Parametererklärung
[root@db01 /home/chenjiaona/Downloads/chenjiaona/master]# bzr --help
Breezy 3.0.0dev1 -- a free distributed version-control tool
https://www.breezy-vcs.org/

Basic commands:
  brz init           makes this directory a versioned branch
  brz branch         make a copy of another branch

  brz add            make files or directories versioned
  brz ignore         ignore a file or pattern
  brz mv             move or rename a versioned file

  brz status         summarize changes in working copy
  brz diff           show detailed diffs

  brz merge          pull in changes from another branch
  brz commit         save some or all changes
  brz send           send changes via email

  brz log            show history of changes
  brz check          validate storage

  brz help init      more help on e.g. init command
  brz help commands  list all commands
  brz help topics    list all help topics

4. Referenz

Code1
Code2

Ich denke du magst

Origin blog.csdn.net/jiaona_chen123/article/details/113614058
Empfohlen
Rangfolge