更新升级 专属应用 系统故障 硬件故障 电脑汽车 鸿蒙刷机 鸿蒙开发Linux教程 鸿蒙开发Linux命令
当前位置:HMXT之家 > 鸿蒙开发Linux命令 > Linux svn、suspend、svnlook、SVGAText Mode命令的用法及解释

Linux svn、suspend、svnlook、SVGAText Mode命令的用法及解释

更新时间:2022-01-19 15:31:19浏览次数:371+次

以下为你详细解释svn、suspend、svnlook、SVGAText Mode命令的用法。

\

Linux svn命令的用法及解释

1、Linux svn命令选项

--accept ACTION

    Specify action for automatic conflict resolution. Possible actions are  (postpone, base, mine-full, theirs-full, edit, and launch.

--auto-props

    开启auto-props,覆盖config文件中的enable-auto-props指示。

--change (-c) ARG

    作为引用特定“修改”(也叫做修订版本)的方法,这个选项是“-r ARG-1:ARG”语法上的甜头。

--changelist ARG

    Operate only on members of the changelist named ARG. This option can be used  multiple times to specify sets of changelists.

--cl ARG

    This is an alias for the --changelist option.

--config-dir DIR

    指导Subversion从指定目录而不是默认位置(用户主目录的.subversion)读取配置信息。

--depth ARG

    Limit the scope of an operation to a particular tree depth. ARG is one of  empty, files, immediates, or infinity.

--diff-cmd CMD

    指定用来表示文件区别的外部程序,当svn diff调用时,会使用Subversion的内置区别引擎,默认会提供统一区别输出,如果你希望使用一个外置区别程序,使用--diff-cmd。你可以通过--extensions把选项传递到区别程序。

--diff3-cmd CMD

    指定一个外置程序用来合并文件。

--dry-run

    检验运行一个命令的效果,但没有实际的修改—可以用在磁盘和版本库。

--editor-cmd CMD

    指定一个外部程序来编辑日志信息或是属性值。

--encoding ENC

    告诉Subversion你的提交日志信息是通过提供的字符集编码的,缺省时是你的操作系统的本地编码,如果你的提交信息使用其它编码,你一定要指定这个值。

--extensions (-x) ARGS

    指定一个或多个Subversion传递给提供文件区别的外部区别程序的参数,如果你要传递多个参数,你一定能够要用引号(例如,svn diff --diff-cmd /usr/bin/diff -x "-b -E") 括起所有的参数。这个选项只有在使用--diff-cmd选项时使用。

--file (-F) FILENAME

    为特定子命令使用命名文件的的内容,尽管不同的子命令对这些内容做不同的事情。例如,svn commit使用内容作为提交日志,而svn propset使用它作为属性值。

--force

    Forces a particular command or operation to run. There are some operations  that Subversion will prevent you from doing in normal usage, but you can pass the  force option to tell Subversion “I know what I'm doing as well as the possible  repercussions of doing it, so let me at 'em.” This option is the programmatic  equivalent of doing your own electrical work with the power on—if you don't know  what you're doing, you're likely to get a nasty shock.

--force-log

    将传递给--message(-m)或者--file(-F)的可疑参数指定为有效可接受。缺省情况下,如果选项的参数看起来会成为子命令的目标,Subversion会提出一个错误,例如,你传递一个版本化的文件路径给--file(-F)选项,Subversion会认为出了点错误,认为你将目标对象当成了参数,而你并没有提供其它的—未版本化的文件作为日志信息的文件。为了确认你的意图并且不考虑这类错误,传递--force-log选项给命令来接受它作为日志信息。

--help (-h) or -?)

    If used with one or more subcommands, shows the built-in help text for each.  If used alone, it displays the general client help text.

--ignore-ancestry

    告诉Subversion在计算区别(只依赖于路径内容)时忽略祖先。

--ignore-externals

    告诉Subversion忽略外部定义和外部定义管理的工作拷贝。

--incremental

    打印适合串联的输出格式。

--keep-changelist

    Don't delete the changelist after commit.

--keep-local

    Keep the local copy of a file or directory (used with the svn delete  command).

--limit NUM

    只显示第一个NUM日志信息。

--message (-m) MESSAGE

    Indicates that you will specify either a log message or a lock comment on the  command line, following this option. For example:

    $ svn commit -m "They don't make Sunday."  

--new ARG

    使用ARG作为新的目标(结合svn diff使用)。

--no-auth-cache

    Prevents caching of authentication information (e.g., username and password)  in the Subversion administrative directories.

--no-auto-props

    关闭auto-props,覆盖config文件中的enable-auto-props指示。

--no-diff-deleted

    防止Subversion打印删除文件的区别信息,缺省的行为方式是当你删除了一个文件后运行svn diff打印的区别与删除文件所有的内容得到的结果一样。

--no-ignore

    在状态列表中显示global-ignores配置选项或者是svn:ignore属性忽略的文件。

--no-unlock

    不自动解锁文件(缺省的提交行为是解锁提交列出的所有文件)。

--non-interactive

    In the case of an authentication failure or insufficient credentials,  prevents prompting for credentials (e.g., username or password). This is useful  if you're running Subversion inside of an automated script, and it's more appropriate to have Subversion fail than to prompt for more information.

--non-recursive (-N)

    Deprecated. Stops a subcommand from recursing into subdirectories. Most  subcommands recurse by default, but some subcommands—usually those that have the potential to remove or undo your local modifications—do not.

--notice-ancestry

    在计算区别时关注祖先。

--old ARG

    使用ARG作为旧的目标(结合svn diff使用)。

--parents

    Create and add nonexistent or nonversioned parent subdirectories to the  working copy or repository as part of an operation. This is useful for  automatically creating multiple subdirectories where none currently exist. If  performed on a URL, all the directories will be created in a single commit.

--password PASS

    指出在命令行中提供你的密码—另外,如果它是需要的,Subversion会提示你输入。

--quiet (-q)

    请求客户端在执行操作时只显示重要信息。

--record-only

    Mark revisions as merged (for use with --revision (-r)

--recursive (-R)

    Deprecated. Makes a subcommand recurse into subdirectories. Most subcommands recurse by default.

--reintegrate (-R)

    Used with the svn merge subcommand, merges all of the source URL's changes into the working copy. See “Keeping a Branch in Sync”一节 for details.

--relocate 目的路径[PATH...]

    svn switch子命令中使用,用来修改你的工作拷贝所引用的版本库位置。当版本库的位置修改了,而你有一个工作拷贝,希望继续使用时非常有用。

--remove ARG

    Disassociate ARG from a changelist

--revision (-r) REV

    Indicates that you're going to supply a revision (or range of revisions) for  a particular operation. You can provide revision numbers, keywords, or dates (in  curly braces) as arguments to the revision option. If you wish to offer a range  of revisions, you can provide two revisions separated by a colon. For example:

    $ svn log -r 1729

    $ svn log -r 1729:HEAD

    $ svn log -r 1729:1744

    $ svn log -r {2021-12-04}:{2020-02-17}

    $ svn log -r 1729:{2020-02-17}

--revprop

    操作针对修订版本属性,而不是Subversion文件或目录的属性。这个选项需要你传递-- revision(-r)参数。

--set-depth ARG

    Set the sticky depth on a directory in a working copy to one of empty, files,  immediates, or infinity.

--show-updates (-u)

    Causes the client to display information about which files in your working  copy are out of date. This doesn't actually update any of your files—it just  shows you which files will be updated if you run svn update.

--stop-on-copy

    Causes a Subversion subcommand that traverses the history of a versioned  resource to stop harvesting that historical information when a copy—that is, a  location in history where that resource was copied from another location in the  repository—is encountered.

--strict

    Causes Subversion to use strict semantics, a notion that is rather vague  unless talking about specific subcommands (namely, svn propget).

--targets FILENAME

    Tells Subversion to get the list of files that you wish to operate on from  the filename that you provide instead of listing all the files on the command  line.

--username NAME

    表示你要在命令行提供认证的用户名—否则如果需要,Subversion会提示你这一点。

--use-merge-history (-g)

    Use or display additional information from merge history.

--verbose (-v)

    请求客户端在运行子命令打印尽量多的信息,会导致Subversion打印额外的字段,每个文件的细节信息或者是关于动作的附加信息。

--version

    打印客户端版本信息,这个信息不仅仅包括客户端的版本号,也有所有客户端可以用来访问Subversion版本库的版本库访问模块列表。

--with-all-revprops

    Used with svn log --xml, this option will retrieve and display all revision  properties in the log output.

--with-revprop ARG

    When used with any command that writes to the repository, this sets the  revision property, using the NAME=VALUE format, NAME to VALUE. When used with svn  log --xml, this displays the value of ARG in the log output.

--xml

    使用XML格式打印输出。

2、实例

[root@localhost ~]# svn checkout svn://192.168.1.108/repos/www   #checkout

[root@localhost ~]# svn add test.php        #添加php文件到版本库

[root@localhost ~]# svn add *.php           #添加当前目录下的所有php文件到版本库

[root@localhost ~]# svn commit -m "this is test" test.php  #提交代码到版本库,并且加注释

[root@localhost ~]# svn lock -m "lock test" test.php    #文件加锁

[root@localhost ~]# svn unlock test.php          #解锁

[root@localhost ~]# svn update                   #更新当前目录和所有文件

[root@localhost ~]# svn update -r 20 test.php   #更新版本号为20的文件

[root@localhost ~]# svn status /var/www/        #目录下的文件和子目录的状态,正常状态不显示

[root@localhost ~]# svn delete test.php         #删除文件

[root@localhost ~]# svn move -m "move dir" tpl admin/tpl  #将当前目录下的,tpl文件夹移动到admin目录下

[root@localhost ~]# svn log test.php            #查看test.php这个文件的所有修改记录

[root@localhost ~]# svn info test.php          #查看文件详细信息

[root@localhost ~]# svn diff -r 19:20 test.php    #比较版本19,20之间的差异

[root@localhost ~]# svn merge -r 19:20 test.php   #将两个版本之间的差异合并到当前文件

[root@localhost ~]# svn list /var/www           #显示www目录下的所有属于版本库的文件和目录

[root@localhost ~]# svn mkdir /var/www/admin    #创建纳入版本控制下的新目录

[root@localhost ~]# svn resolved /var/www       #解决版本冲突

Linux suspend命令的用法及解释

Linux suspend命令可以用来暂停shell的执行。

1、用法

suspend [参数,如-f]

2、参数

-f:强制执行

3、实例

[root@localhost ~]# suspend  #暂停shell

[root@localhost ~]# suspend -f  #强制暂停shell

Linux svnlook命令的用法及解释

因为svnlook命令通过直接版本库访问(因此只可以在保存版本库的机器上工作)工作,所以他通过版本库的路径访问,而不是URL。

如果没有指定修订版本或事物,svnlook缺省的是版本库最年轻的(最新的)修订版本。

1、svnlook选项

Options in svnlook are global, just like in svn and svnadmin; however, most  options apply only to one subcommand since the functionality of svnlook is  (intentionally) limited in scope.

--copy-info

Causes svnlook changed to show detailed copy source information.

--no-diff-deleted

Prevents svnlook diff from printing differences for deleted files. The default  behavior when a file is deleted in a transaction/revision is to print the same  differences that you would see if you had left the file but removed all the  content.

--no-diff-added

Prevents svnlook diff from printing differences for added files. The default  behavior when you add a file is to print the same differences that you would see  if you had added the entire contents of an existing (empty) file.

--revision (-r)

指定要进行检查的特定修订版本。

--revprop

操作针对修订版本属性,而不是Subversion文件或目录的属性。这个选项需要你传递--revision(-r)参数。

--transaction (-t)

指定一个希望检查的特定事物ID。

--show-ids

显示文件系统树中每条路径的文件系统节点修订版本ID。

2、实例

[root@localhost ~]# svnlook diff /var/www   #打印修改的文件和属性的区别

[root@localhost ~]# svnlook history /var/www/tpl  #打印路径的版本库历史

[root@localhost ~]# svnlook info -r 40 /var/www  #打印作者、时间戳、日志信息大小和日志信息

[root@localhost ~]# svnlook tree /var/www  #打印版本库的目录树

Linux SVGAText Mode命令的用法及解释

Linux SVGAText Mode命令功能说明:加强文字模式的显示画面。

1、用法

SVGATextMode [-acdfhmnrsv][-t <配置文件>][模式]

2、补充说明

SVGATextMode可用来设置文字模式下的显示画面,包括分辨率,字体和更新频率等。

3、参数

-a:如果新显示模式的屏幕大小与原先不同时,SVGATextMode会执行必要的系统设置。

-c:维持原有的VGA时脉。

-d:执行时会显示详细的信息,供排错时参考。

-f:不要执行配置文件中有关字体载入的指令。

-h:显示帮助。

-m:允许1x1的方式来重设屏幕大小。

-n:仅测试指定的模式。

-r:通知或重设与屏幕大小相关的程序。

-s:显示配置文件中所有可用的模式。

-t<配置文件>:指定配置文件。

-v:SVGATextMode在配置新的显示模式时,预设会先检查垂直与水平的更新更新频率是否在配置文件所指定的范围内,如果不在范围内,则不设置新的显示模式。

[模式]:[模式]参数必须是配置文件中模式的名称。