{"id":17511735,"url":"https://github.com/claws/gramps2gource","last_synced_at":"2025-04-23T12:56:23.617Z","repository":{"id":12845641,"uuid":"15521314","full_name":"claws/gramps2gource","owner":"claws","description":"Combines Gource and Gramps to produce novel family history visualisations","archived":false,"fork":false,"pushed_at":"2018-10-17T21:13:49.000Z","size":38,"stargazers_count":9,"open_issues_count":0,"forks_count":4,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-24T14:13:53.717Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/claws.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-12-30T05:41:32.000Z","updated_at":"2024-06-17T22:41:20.000Z","dependencies_parsed_at":"2022-08-28T11:41:34.305Z","dependency_job_id":null,"html_url":"https://github.com/claws/gramps2gource","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claws%2Fgramps2gource","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claws%2Fgramps2gource/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claws%2Fgramps2gource/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/claws%2Fgramps2gource/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/claws","download_url":"https://codeload.github.com/claws/gramps2gource/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242052630,"owners_count":20064220,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-20T05:09:46.952Z","updated_at":"2025-03-05T15:30:43.746Z","avatar_url":"https://github.com/claws.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Gramps2Gource\n\nBlurring the line between Genealogy and Software Configuration Management visualisation.\n\n[![Build Status](https://travis-ci.org/claws/gramps2gource.png?branch=master)](https://travis-ci.org/claws/gramps2gource)\n\n## Overview\n\n**Gramps2Gource** combines [Gramps](http://gramps-project.org/) (a Genealogy program written in Python) and [Gource](https://code.google.com/p/gource/) (a software version control visualisation tool for showing  changes over time) to help produce a novel family history visualisation. It parses exported `.gramps` files to produce a Gource custom log file containing the pedigree for a specified person. This custom log file can then be passed to Gource for rendering. See the example video below:\n\n\u003ca href=\"http://www.youtube.com/watch?feature=player_embedded\u0026v=sPtTTv6d0s8\n\" target=\"_blank\"\u003e\u003cimg src=\"http://i1.ytimg.com/vi/sPtTTv6d0s8/mqdefault.jpg\"\nalt=\"Gramps2Gource Example\" border=\"10\" /\u003e\u003c/a\u003e\n\n\nThe Gource custom log format contains the following pipe ('|') delimited fields:\n\n    timestamp - A unix timestamp of when the update occured.\n    username  - The name of the user who made the update.\n    type      - initial for the update type - (A)dded, (M)odified or (D)eleted.\n    file      - Path of the file updated.\n    colour    - A colour for the file in hex (FFFFFF) format. Optional.\n\nGramps2Gource works on Python2.7 and Python3.3.\n\nOne day I may investigate integrating this into Gramps as a plugin where it could access the Gramps database directly instead of via an exported `.gramps` file.\n\nAs always, garbage in garbage out. If your database is not well managed and consistent then your milage may vary.\n\nThis is really just a proof of concept. There is lots of cleanup that could be done and lots that could be added but it does what I wanted.\n\n## Setup\n\n### Install Gource\n\nGource can be installed using:\n\n    $ sudo apt-get install gource\n\nNOTE: Gource versions prior to v0.38 could not handle negative times (times before 1970). This was a real show stopper for displaying family history which is all based in the past. However, since version 0.38 this issue was resolved. In recent versions of Ubuntu the Gource version is v0.40 so this should not be a problem.\n\n### Install Python Dependencies\n\n#### Install Future module\n\nGramps2Gource uses dateutil to help parse complex date descriptions.\n\n    $ [sudo] pip[3] install python-dateutil\n\n#### Install Future module\n\nFor Python2 and Python3 compatibility Gramps2Gource uses the `future` module, hence this must be installed also.\n\n    $ [sudo] pip[3] install future\n\n### Export a gramps file\n\n    1. Open your Gramps family history database\n    2. From the menu choose `Family Trees` then `Export...`\n    3. In the dialog that opens click `Forward`.\n    4. Select `Gramps XML (family tree)` then click forward.\n    5. Click forward again as the defaults are OK.\n    6. Choose a filename then click `Forward`.\n    7. Click Apply.\n\n### Download Gramps2Gource\n\n\tgit clone https://github.com/claws/gramps2gource.git\n\tcd gramps2gource\n\n\n## Using Gramps2Gource\n\nTo generate the custom gource log and display it you need to tell the `gramps2gource.py` script the focus person and the path to the Gramps database file. An output file containing the gource custom log will be saved to a file called `pedigree_\u003cname\u003e.log`.\n\nExample:\n\n    $ python gramps2gource.py --name=\"Amber Marie Smith\" --db=example.gramps --output=pedigree_amber_marie_smith.log\n    $ cat pedigree_amber_marie_smith.log | gource --load-config gource.conf -\n\nThe `gource.conf` effectively builds a command line similar to:\n\n    $ cat pedigree_amber_marie_smith.log | gource -1280x720 --log-format custom --font-size 20 --hide users,dirnames,date --stop-at-end --camera-mode overview --seconds-per-day 1 --disable-bloom --auto-skip-seconds 1 -i 0 -c 3.0 -\n\nThe '-' at the end is important, it instructs Gource to read from standard input.\n\n\n### Calendar Formats\n\nEvent dates can often be stored in different calendar formats. To accomodate\nthis it is possible to implement your own date parser to convert your specific\ncalendar date strings into the necessary datetime object used by Gramps2Gource.\n\nInstead of running `gramps2gource.py` you will need to use something like the\n`custom_date_g2g.py` example. This script accepts the same command line\narguments as the `gramps2gource.py` script.\n\nPrior to running the script you will need to make some code changes to\nimplement and register your specific date handler functions.\n\nFor example, if you have event dates in `French Republican` format (e.g. the\n`cformat` field stored within the gramps date item is `French Republican`) you\nwould create and register a handler with the name `French Republican`. For\nexample:\n\n``` python\n\ndef frech_republican_date_handler(datestring):\n    return magic_datetime_creater(datestring)\n\ngramps.date_processor.register(\n    'French Republican', french_republican_date_handler)\n```\n\nYou need to register the date parser prior to instantiating the\n`Gramps2Gource` object.\n\n\n### Multiple Focus People\n\nMultiple `name` arguments can be specified if you want to show more than one focus person. When multiple names are supplied the output file defaults to `pedigree.log`.\n\nExample:\n\n    $ python gramps2gource.py --name=\"Amber Marie Smith\" --name=\"John Hjalmar Smith\" --db=example.gramps --output=pedigree.log\n    $ cat pedigree.log | gource --load-config gource.conf --hide-root -\n\n\n\n### Record Visualisation\n\nTo record the visualisation to a video file, the following commands may be useful.\n\nh264:\n\n    $ cat ~/path/to/custom_output.log | gource --load-config gource.conf -output-ppm-stream - --output-framerate 30 - | avconv -y -r 30 -f image2pipe -vcodec ppm -i - -b 8192K /path/to/video/output/file.mp4\n\nwebm:\n\n    $ cat ~/path/to/custom_output.log | gource --load-config gource.conf -output-ppm-stream - | avconv -y -r 30 -f image2pipe -vcodec ppm -i - -vcodec libvpx -b 10000K /path/to/video/output/file.webm\n\n[![Analytics](https://ga-beacon.appspot.com/UA-29867375-2/gramps2gource/readme?pixel)](https://github.com/claws/gramps2gource)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclaws%2Fgramps2gource","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fclaws%2Fgramps2gource","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclaws%2Fgramps2gource/lists"}