From 936d5717d1b4afc17b04afbe02ad7aff8770722d Mon Sep 17 00:00:00 2001 From: Bogdano Arendartchuk Date: Tue, 5 Feb 2008 20:51:43 +0000 Subject: Small changes in help messages: - Added URL of the repository system Quickstart - Make the help message of ci clearer - Removed reference to --help-plugins - Added a simple description for repsys in main help - Added short description of interesting subcommands in main help - Updated CHANGES - Reformeatted the 'switch' message to make it easier to read - Improved the help message of 'submit', added reference to the status page - Better help message for rpmlog - Added help message for patchspec - Better help message for markrelease - Added a help message for getsrpm - Added help message for getspec - Better help message for 'create' + changed example URL - Added a clearer help message for co - Added some text explaining 'changed' - Better authoremail help - Clearer message about uncommenting config option - Removed all configuration options that are not needed by one external - Putsrpm is not working, remove from help message - Added another usage example for submit --- CHANGES | 1 + RepSys/commands/authoremail.py | 3 +++ RepSys/commands/changed.py | 2 ++ RepSys/commands/ci.py | 8 +++++--- RepSys/commands/co.py | 6 ++++++ RepSys/commands/create.py | 5 ++++- RepSys/commands/getspec.py | 5 ++++- RepSys/commands/getsrpm.py | 4 ++++ RepSys/commands/markrelease.py | 5 +++++ RepSys/commands/patchspec.py | 2 ++ RepSys/commands/rpmlog.py | 5 ++++- RepSys/commands/submit.py | 9 +++++++++ RepSys/commands/switch.py | 7 ++++--- repsys | 29 +++++++++++++++-------------- repsys.conf | 38 +------------------------------------- 15 files changed, 69 insertions(+), 60 deletions(-) diff --git a/CHANGES b/CHANGES index 849b3ae..d1db357 100644 --- a/CHANGES +++ b/CHANGES @@ -16,6 +16,7 @@ - fixed the use of file:/// URLs when using just the package name - don't give the wrong message "invalid command 'CMD'" when this is not the case +- added more help messages in subcommands * 1.6.19 - added complement for SILENT: CLOG, which hides everything that does not diff --git a/RepSys/commands/authoremail.py b/RepSys/commands/authoremail.py index aee7b58..f5b8b70 100644 --- a/RepSys/commands/authoremail.py +++ b/RepSys/commands/authoremail.py @@ -7,6 +7,9 @@ import getopt HELP = """\ Usage: repsys authoremail [OPTIONS] AUTHOR +Shows the e-mail of an SVN author. It is just a simple interface to access +the [authors] section of repsys.conf. + Options: -h Show this message diff --git a/RepSys/commands/changed.py b/RepSys/commands/changed.py index d3094a8..62b20b6 100644 --- a/RepSys/commands/changed.py +++ b/RepSys/commands/changed.py @@ -8,6 +8,8 @@ import sys HELP = """\ Usage: repsys changed [OPTIONS] URL +Shows if there are pending changes since the last package release. + Options: -a Check all packages in given URL -s Show differences diff --git a/RepSys/commands/ci.py b/RepSys/commands/ci.py index b6a54f6..8d373b5 100644 --- a/RepSys/commands/ci.py +++ b/RepSys/commands/ci.py @@ -5,9 +5,11 @@ from RepSys.rpmutil import commit HELP = """\ Usage: repsys ci [TARGET] -Will commit a change. The difference between an ordinary "svn ci" and -"repsys ci" is that it relocates the working copy to the default repository -in case the option "mirror" is set in repsys.conf. +Will commit recent modifications in the package. + +The difference between an ordinary "svn ci" and "repsys ci" is that it +relocates the working copy to the default repository in case the option +"mirror" is set in repsys.conf. Options: -h Show this message diff --git a/RepSys/commands/co.py b/RepSys/commands/co.py index cadcf56..830b7e7 100644 --- a/RepSys/commands/co.py +++ b/RepSys/commands/co.py @@ -8,12 +8,18 @@ import sys HELP = """\ Usage: repsys co [OPTIONS] URL [LOCALPATH] +Checkout the package source from the Mandriva repository. + +If the 'mirror' option is enabled, the package is obtained from the mirror +repository. + Options: -r REV Revision to checkout -o Do not use the mirror (use official server) -h Show this message Examples: + repsys co pkgname repsys co http://repos/svn/cnc/snapshot/foo repsys co http://repos/svn/cnc/snapshot/foo foo-pkg """ diff --git a/RepSys/commands/create.py b/RepSys/commands/create.py index 56af1ef..a8709f0 100644 --- a/RepSys/commands/create.py +++ b/RepSys/commands/create.py @@ -8,11 +8,14 @@ import sys HELP = """\ Usage: repsys create [OPTIONS] URL +Creates the minimal structure of a package in the repository. + Options: -h Show this message Examples: - repsys create http://repos/svn/cnc/snapshot/newpkg + repsys create newpkg + repsys create svn+ssh://svn.mandriva.com/svn/packages/cooker/newpkg """ def parse_options(): diff --git a/RepSys/commands/getspec.py b/RepSys/commands/getspec.py index 1079a81..5e44074 100644 --- a/RepSys/commands/getspec.py +++ b/RepSys/commands/getspec.py @@ -8,12 +8,15 @@ import sys HELP = """\ Usage: repsys getspec [OPTIONS] REPPKGURL +Prints the .spec file of a given package. + Options: -t DIR Use DIR as target for spec file (default is ".") -h Show this message Examples: - repsys getspec http://repos/svn/cnc/snapshot/foo + repsys getspec pkgname + repsys getspec svn+ssh://svn.mandriva.com/svn/packages/cooker/pkgname """ def parse_options(): diff --git a/RepSys/commands/getsrpm.py b/RepSys/commands/getsrpm.py index d76aca7..f1ebfe1 100644 --- a/RepSys/commands/getsrpm.py +++ b/RepSys/commands/getsrpm.py @@ -16,6 +16,8 @@ import os HELP = """\ Usage: repsys getsrpm [OPTIONS] REPPKGURL +Generates the source RPM (.srpm) file of a given package. + Options: -c Use files in current/ directory (default) -p Use files in pristine/ directory @@ -30,6 +32,8 @@ Options: -h Show this message Examples: + repsys getsrpm python + repsys getsrpm -l python repsys getsrpm http://foo.bar/svn/cnc/snapshot/python repsys getsrpm -p http://foo.bar/svn/cnc/releases/8cl/python repsys getsrpm -r 1001 file:///svn/cnc/snapshot/python diff --git a/RepSys/commands/markrelease.py b/RepSys/commands/markrelease.py index 440775b..1707f39 100644 --- a/RepSys/commands/markrelease.py +++ b/RepSys/commands/markrelease.py @@ -21,6 +21,11 @@ HELP = """\ Usage: repsys markrelease [OPTIONS] REPPKGURL +This subcommand creates a 'tag' for a given revision of a given package. + +The tag will be stored in the directory releases/ inside the package +structure. + Options: -f FILE Try to extract information from given file -r REV Revision which will be used to make the release copy tag diff --git a/RepSys/commands/patchspec.py b/RepSys/commands/patchspec.py index 155ff4f..8330cc3 100644 --- a/RepSys/commands/patchspec.py +++ b/RepSys/commands/patchspec.py @@ -11,6 +11,8 @@ import sys HELP = """\ Usage: repsys patchspec [OPTIONS] REPPKGURL PATCHFILE +It will try to patch a spec file from a given package url. + Options: -l LOG Use LOG as log message -h Show this message diff --git a/RepSys/commands/rpmlog.py b/RepSys/commands/rpmlog.py index 7ea1ac0..5ba5fdd 100644 --- a/RepSys/commands/rpmlog.py +++ b/RepSys/commands/rpmlog.py @@ -12,6 +12,8 @@ import sys HELP = """\ Usage: repsys rpmlog [OPTIONS] REPPKGDIRURL +Prints the RPM changelog of a given package. + Options: -r REV Collect logs from given revision to revision 0 -n NUM Output only last NUM entries @@ -19,7 +21,8 @@ Options: -h Show this message Examples: - repsys rpmlog https://repos/snapshot/python + repsys rpmlog python + repsys rpmlog http://svn.mandriva.com/svn/packages/cooker/python """ def parse_options(): diff --git a/RepSys/commands/submit.py b/RepSys/commands/submit.py index 25d5831..bd6e01c 100644 --- a/RepSys/commands/submit.py +++ b/RepSys/commands/submit.py @@ -20,6 +20,14 @@ Usage: repsys submit [OPTIONS] [URL [REVISION]] Submits the package from URL to the submit host. +The submit host will try to build the package, and upon successful +completion will 'tag' the package and upload it to the official +repositories. + +The status of the submit can visualized at: + +http://kenobi.mandriva.com/bs/output.php + If no URL and revision are specified, the latest changed revision in the package working copy of the current directory will be used. @@ -40,6 +48,7 @@ Examples: repsys submit https://repos/svn/mdv/cooker/foo 14800 repsys submit -r 14800 https://repos/svn/mdv/cooker/foo repsys submit -l https://repos + repsys submit --define section=main/testing -t 2008.0 """ def parse_options(): diff --git a/RepSys/commands/switch.py b/RepSys/commands/switch.py index dcbdd17..5cbe2d7 100644 --- a/RepSys/commands/switch.py +++ b/RepSys/commands/switch.py @@ -5,9 +5,10 @@ from RepSys.rpmutil import switch HELP = """\ Usage: repsys switch [URL] -Relocates the working copy to the base location URL. If URL is not -provided, it will use the option default_parent from repsys.conf as -default, or, if the current working copy is already based in +Relocates the working copy to the base location URL. + +If URL is not provided, it will use the option default_parent from +repsys.conf as default, or, if the current working copy is already based in default_parent, it will use the location from the mirror option from repsys.conf. diff --git a/repsys b/repsys index a243493..9896404 100755 --- a/repsys +++ b/repsys @@ -9,24 +9,25 @@ VERSION="1.6.19" HELP = """\ Usage: repsys COMMAND [COMMAND ARGUMENTS] +Tool to access and manage a package repository structure. + +http://wiki.mandriva.com/en/Development/Packaging/RepositorySystem/Quickstart + Useful commands: - co - ci - sync - submit - create - getspec - getsrpm - rpmlog - changed - authoremail - putsrpm - switch + co checkout a package + ci commit changes + sync add-remove all file changes from the .spec + submit submit a package for build + getspec prints the spec + rpmlog prints the RPM changelog + getsrpm creates the source RPM + create create the structure of a new package + changed shows changes not submitted + authoremail prints the e-mail of a given author + switch relocate to mirror or upstream repository Run "repsys COMMAND --help" for more information. -Run "repsys --help-plugins" for help on loaded plugins. - Written by Gustavo Niemeyer """ diff --git a/repsys.conf b/repsys.conf index 43dd99b..2b119c3 100644 --- a/repsys.conf +++ b/repsys.conf @@ -1,20 +1,10 @@ [global] -verbose = no default_parent = svn+ssh://svn.mandriva.com/svn/packages/cooker -url-map = svn\+ssh://svn\.mandriva\.com/(.*) file:///\1 +## uncomment it in case you don't have a account in the Mandriva cluster: #mirror = http://svn.mandriva.com/svn/packages/cooker/ -#tempdir = /tmp [log] oldurl = svn+ssh://svn.mandriva.com/svn/packages/misc -# controls up to which revision the rpm changelog -# will be constructed (default zero, i.e., oldest -# commit) -revision-offset = 0 -# commit lines containing this string won't be shown in the changelog: -ignore-string = SILENT -# and in case of only allowing a few lines to be visible, use this: -#unignore-string = CLOG [template] path = /usr/share/repsys/default.chlog @@ -23,32 +13,6 @@ path = /usr/share/repsys/default.chlog create-srpm = /usr/share/repsys/create-srpm upload-srpm = /usr/local/bin/youri.devel -[users] -# jsmith = John Smith - [submit] host = kenobi.mandriva.com default = Cooker - -[submit Cooker] -target = /export/home/repsys -allowed = svn+ssh://svn.mandriva.com/svn/packages/cooker -scripts = /usr/share/repsys/rebrand-mdk -## -## rpm-macros refers to the sections containing the macros used for this -## target. The values will be used to build the rpmbuild command line. For -## example: -## -## [macros cooker] -## a = b -## c = %a -## -## will render in the command line: --define "a b" --define "c %a". -## -#rpm-macros = global cooker - -#[macros global] -#distsuffix = mdv - -#[macros cooker] -#mandriva_release = 2007.1 -- cgit v1.2.1