Skip to content

Commit

Permalink
feat: append now accepts --name, --description to supplement the data…
Browse files Browse the repository at this point in the history
…base info
  • Loading branch information
jebrosen committed Sep 2, 2020
1 parent ab7a481 commit 3a9df9d
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion famdb.py
Original file line number Diff line number Diff line change
Expand Up @@ -1622,7 +1622,12 @@ def set_header(val):
args.file.add_family(entry)

db_info = args.file.get_db_info()
db_info["name"] += " (with additions)"

if args.name:
db_info["name"] = args.name
if args.description:
db_info["description"] += "\n" + args.description

db_info["copyright"] += "\n\n" + header

args.file.set_db_info(
Expand Down Expand Up @@ -1695,6 +1700,8 @@ def main():

p_append = subparsers.add_parser("append")
p_append.add_argument("infile", help="the name of the input file to be appended")
p_append.add_argument("--name", help="new name for the database (replaces the existing name)")
p_append.add_argument("--description", help="additional database description (added to the existing description)")
p_append.set_defaults(func=command_append)

args = parser.parse_args()
Expand Down

0 comments on commit 3a9df9d

Please sign in to comment.