Help on --merge option.

This commit is contained in:
Arun Prakash Jana 2016-05-29 12:49:11 +05:30
parent 4ab8b43dd8
commit 3f1a268395
No known key found for this signature in database
GPG Key ID: C0A712ED95043DCB
3 changed files with 19 additions and 15 deletions

View File

@ -110,11 +110,11 @@ Shell completion scripts for Bash, Fish and Zsh can be found in respective subdi
**NOTE:** If you are using `buku` v1.9 or below please refer to the installed man page or program help. **NOTE:** If you are using `buku` v1.9 or below please refer to the installed man page or program help.
usage: buku [-a URL [tags ...]] [-u [N]] [-i path] [-d [N]] usage: buku [-a URL [tags ...]] [-u [N]] [-i file] [-d [N]]
[--url keyword] [--tag [...]] [-t [...]] [-c [...]] [--url keyword] [--tag [...]] [-t [...]] [-c [...]]
[-s keyword [...]] [-S keyword [...]] [--st [...]] [-s keyword [...]] [-S keyword [...]] [--st [...]]
[-k [N]] [-l [N]] [-p [N]] [-f N] [-k [N]] [-l [N]] [-p [N]] [-f N] [-r oldtag [newtag ...]]
[-r oldtag [newtag ...]] [-j] [-o N] [-z] [-h] [-j] [--merge file] [--noprompt] [-o N] [-z] [-h]
A private command-line bookmark manager. Your mini web! A private command-line bookmark manager. Your mini web!
@ -127,7 +127,7 @@ Shell completion scripts for Bash, Fish and Zsh can be found in respective subdi
N is specified without any edit options N is specified without any edit options
-d, --delete [N] delete bookmark at DB index N -d, --delete [N] delete bookmark at DB index N
delete all bookmarks, if no arguments delete all bookmarks, if no arguments
-i, --import path import bookmarks from html file; Firefox, -i, --import file import bookmarks from html file; Firefox,
Google Chrome and IE formats supported Google Chrome and IE formats supported
-h, --help show this information -h, --help show this information
@ -166,6 +166,7 @@ Shell completion scripts for Bash, Fish and Zsh can be found in respective subdi
replace oldtag with newtag everywhere replace oldtag with newtag everywhere
delete oldtag, if no newtag delete oldtag, if no newtag
-j, --json Json formatted output for -p, -s, -S, --st -j, --json Json formatted output for -p, -s, -S, --st
--merge file merge bookmarks from another buku database
--noprompt do not show the prompt, run and exit --noprompt do not show the prompt, run and exit
-o, --open N open bookmark at DB index N in web browser -o, --open N open bookmark at DB index N in web browser
-z, --debug show debug information and additional logs -z, --debug show debug information and additional logs

14
buku
View File

@ -1321,11 +1321,11 @@ if __name__ == '__main__':
argparser = ExtendedArgumentParser( argparser = ExtendedArgumentParser(
description='A private command-line bookmark manager. Your mini web!', description='A private command-line bookmark manager. Your mini web!',
formatter_class=argparse.RawTextHelpFormatter, formatter_class=argparse.RawTextHelpFormatter,
usage='''buku [-a URL [tags ...]] [-u [N]] [-i path] [-d [N]] usage='''buku [-a URL [tags ...]] [-u [N]] [-i file] [-d [N]]
[--url keyword] [--tag [...]] [-t [...]] [-c [...]] [--url keyword] [--tag [...]] [-t [...]] [-c [...]]
[-s keyword [...]] [-S keyword [...]] [--st [...]] [-s keyword [...]] [-S keyword [...]] [--st [...]]
[-k [N]] [-l [N]] [-p [N]] [-f N] [-k [N]] [-l [N]] [-p [N]] [-f N] [-r oldtag [newtag ...]]
[-r oldtag [newtag ...]] [-j] [-o N] [-z] [-h]''', [-j] [--merge file] [--noprompt] [-o N] [-z] [-h]''',
add_help=False add_help=False
) )
@ -1339,13 +1339,13 @@ if __name__ == '__main__':
N is specified without any edit options N is specified without any edit options
-d, --delete [N] delete bookmark at DB index N -d, --delete [N] delete bookmark at DB index N
delete all bookmarks, if no arguments delete all bookmarks, if no arguments
-i, --import path import bookmarks from html file; Firefox, -i, --import file import bookmarks from html file; Firefox,
Google Chrome and IE formats supported Google Chrome and IE formats supported
-h, --help show this information''') -h, --help show this information''')
general_group.add_argument('-a', '--add', nargs='+', dest='addurl', metavar=('URL', 'tags'), help=argparse.SUPPRESS) general_group.add_argument('-a', '--add', nargs='+', dest='addurl', metavar=('URL', 'tags'), help=argparse.SUPPRESS)
general_group.add_argument('-u', '--update', nargs='*', dest='update', action=CustomUpdateAction, metavar=('N', 'URL tags'), help=argparse.SUPPRESS) general_group.add_argument('-u', '--update', nargs='*', dest='update', action=CustomUpdateAction, metavar=('N', 'URL tags'), help=argparse.SUPPRESS)
general_group.add_argument('-d', '--delete', nargs='?', dest='delete', type=int, const=0, metavar='N', help=argparse.SUPPRESS) general_group.add_argument('-d', '--delete', nargs='?', dest='delete', type=int, const=0, metavar='N', help=argparse.SUPPRESS)
general_group.add_argument('-i', '--import', nargs=1, dest='imports', metavar='path', help=argparse.SUPPRESS) general_group.add_argument('-i', '--import', nargs=1, dest='imports', metavar='file', help=argparse.SUPPRESS)
general_group.add_argument('-h', '--help', dest='help', action='store_true', help=argparse.SUPPRESS) general_group.add_argument('-h', '--help', dest='help', action='store_true', help=argparse.SUPPRESS)
# Edit options # Edit options
@ -1396,7 +1396,7 @@ if __name__ == '__main__':
replace oldtag with newtag everywhere replace oldtag with newtag everywhere
delete oldtag, if no newtag delete oldtag, if no newtag
-j, --json Json formatted output for -p, -s, -S, --st -j, --json Json formatted output for -p, -s, -S, --st
--merge merge bookmarks from another database file --merge file merge bookmarks from another buku database
--noprompt do not show the prompt, run and exit --noprompt do not show the prompt, run and exit
-o, --open N open bookmark at DB index N in web browser -o, --open N open bookmark at DB index N in web browser
-z, --debug show debug information and additional logs''') -z, --debug show debug information and additional logs''')
@ -1404,7 +1404,7 @@ if __name__ == '__main__':
power_group.add_argument('-f', '--format', dest='showOpt', type=int, choices=[1, 2], metavar='N', help=argparse.SUPPRESS) power_group.add_argument('-f', '--format', dest='showOpt', type=int, choices=[1, 2], metavar='N', help=argparse.SUPPRESS)
power_group.add_argument('-r', '--replace', nargs='+', dest='replace', metavar=('oldtag', 'newtag'), help=argparse.SUPPRESS) power_group.add_argument('-r', '--replace', nargs='+', dest='replace', metavar=('oldtag', 'newtag'), help=argparse.SUPPRESS)
power_group.add_argument('-j', '--json', dest='jsonOutput', action='store_true', help=argparse.SUPPRESS) power_group.add_argument('-j', '--json', dest='jsonOutput', action='store_true', help=argparse.SUPPRESS)
general_group.add_argument('--merge', nargs=1, dest='merge', metavar='path', help=argparse.SUPPRESS) general_group.add_argument('--merge', nargs=1, dest='merge', metavar='file', help=argparse.SUPPRESS)
power_group.add_argument('--noprompt', dest='noninteractive', action='store_true', help=argparse.SUPPRESS) power_group.add_argument('--noprompt', dest='noninteractive', action='store_true', help=argparse.SUPPRESS)
power_group.add_argument('-o', '--open', dest='openurl', type=int, metavar='N', help=argparse.SUPPRESS) power_group.add_argument('-o', '--open', dest='openurl', type=int, metavar='N', help=argparse.SUPPRESS)
power_group.add_argument('-z', '--debug', dest='debug', action='store_true', help=argparse.SUPPRESS) power_group.add_argument('-z', '--debug', dest='debug', action='store_true', help=argparse.SUPPRESS)

11
buku.1
View File

@ -3,15 +3,15 @@
buku \- A private command-line bookmark manager. Your mini web! buku \- A private command-line bookmark manager. Your mini web!
.SH SYNOPSIS .SH SYNOPSIS
.B buku .B buku
[-a URL [tags ...]] [-u [N]] [-i path] [-d [N]] [-a URL [tags ...]] [-u [N]] [-i file] [-d [N]]
.br .br
[--url keyword] [--tag [...]] [-t [...]] [-c [...]] [--url keyword] [--tag [...]] [-t [...]] [-c [...]]
.br .br
[-s keyword [...]] [-S keyword [...]] [--st [...]] [-s keyword [...]] [-S keyword [...]] [--st [...]]
.br .br
[-k [N]] [-l [N]] [-p [N]] [-f N] [-k [N]] [-l [N]] [-p [N]] [-f N] [-r oldtag [newtag ...]]
.br .br
[-r oldtag [newtag ...]] [-j] [-o N] [-z] [-h] [-j] [--merge file] [--noprompt] [-o N] [-z] [-h]
.SH DESCRIPTION .SH DESCRIPTION
.B buku .B buku
is a command-line tool to save, tag and search bookmarks. is a command-line tool to save, tag and search bookmarks.
@ -61,7 +61,7 @@ in DB. If
.I N .I N
and other options are omitted, all titles are refreshed from the web. Works with update modifiers for the fields url, title, tag and comment. If only N is passed without any edit options, title is fetched and updated (if not empty). and other options are omitted, all titles are refreshed from the web. Works with update modifiers for the fields url, title, tag and comment. If only N is passed without any edit options, title is fetched and updated (if not empty).
.TP .TP
.BI \-i " " \--import " path" .BI \-i " " \--import " file"
Import bookmarks exported from Firefox, Google Chrome or IE in HTML format. Import bookmarks exported from Firefox, Google Chrome or IE in HTML format.
.TP .TP
.BI \-d " " \--delete " [N]" .BI \-d " " \--delete " [N]"
@ -143,6 +143,9 @@ is omitted.
.BI \-j " " \--json .BI \-j " " \--json
Output data formatted as json, works with -p, -s, -S, --st. Output data formatted as json, works with -p, -s, -S, --st.
.TP .TP
.BI \--merge " file"
Merge bookmarks from another Buku database file.
.TP
.BI \--noprompt .BI \--noprompt
Do not show the prompt, run and exit. Do not show the prompt, run and exit.
.TP .TP