KDevelop/AuthorIdentities: Difference between revisions
(Created page with "==Definition== "Author identity": metadata about an identity/role taken when writing source code or creating other resources ==Motivation== When it comes to copyright notio...") |
No edit summary |
||
Line 5: | Line 5: | ||
==Motivation== | ==Motivation== | ||
When it comes to copyright notions in files and authorship/committer id in version control systems, the name and the contact information, like email address, | When it comes to copyright notions in files and authorship/committer id in version control systems, the name and the contact information, like email address, can be a few different ones for oneself. E.g. when working in different FLOSS projects, with each email address dedicated to the project, or when working on a FLOSS project both in name of an employer, but also privately in free times. | ||
can be a few different ones for oneself. E.g. when working in different FLOSS projects, with each email address dedicated to the project, or when working on a FLOSS project both in name of an employer, but also privately in free times. | |||
As these data is usually fixed for a given project, and same sets of the data are used in different projects, it would be nice to have this data in a central datastore for reuse and automatic update across projects. Per project the selected data set would be automatically used when the values are needed, like on generation of code or when operating in the version control system. | As these data is usually fixed for a given project, and same sets of the data are used in different projects, it would be nice to have this data in a central datastore for reuse and automatic update across projects. Per project the selected data set would be automatically used when the values are needed, like on generation of code or when operating in the version control system. | ||
Line 21: | Line 20: | ||
==Data Models== | ==Data Models== | ||
Temporary drafts created from currrent user stories, serving as long-term orientation. First implementations would only have properties which are needed for the initial features. | |||
Identity: | Identity: | ||
Line 30: | Line 30: | ||
* copyright owner (if contract work) | * copyright owner (if contract work) | ||
* copyright owner contact data, email/phone/webaddress (if contract work) -> perhaps separate model? | * copyright owner contact data, email/phone/webaddress (if contract work) -> perhaps separate model? | ||
* alias email addresses, older email addresses | * alias email addresses, older email addresses | ||
* alias full name, old full name (marriage, gender change, different details) | * alias full name, old full name (marriage, gender change, different details) | ||
Line 38: | Line 37: | ||
* allows creation/editing/deletion of identities | * allows creation/editing/deletion of identities | ||
* setting the standard identity, preselected for new projects | * setting the standard identity, preselected for new projects | ||
* multiple backends possible, to allow adapting to custom addressbook system/ | * multiple backends possible, to allow adapting to custom addressbook system/LDAP/*, for updating automatically to any changes? | ||
LDAP/*, for updating automatically to any changes? | |||
Line 50: | Line 48: | ||
==User stories== | ==User stories== | ||
Things that might be nice to have support for when it comes to author identities. Meant for collecting idea, not everything will be possible. | |||
=== | ===Do not get in the way=== | ||
working on | As developer working alone on a private project, I do not want to have to deal with any identity stuff, any defaults are fine with me. | ||
===Multiple identities in same system=== | |||
As developer working with the same computer/system on different projects for different customers or different project groups, I want KDevelop to always inject the correct/matching copyright & author information on generating code from file & app templates for different projects/customers, instead of having to manually post-edit the generated code. | |||
=== | ===Multiple identities in same project=== | ||
working on same project with same system both for job and privately, | As developer working on the same project with the same computer system both for job and privately, I want to quickly switch identity data to be used depending on whether I work for job or privately, to mark copyright of contributions accordingly. | ||
=== | ===Pick up identity on import=== | ||
As developer importing a project into KDevelop, I want to have the identity automatically derived from account/server/fetched project and have the option to create a new identity from the found data if there is none, or overwrite with an existing identity. | |||
=== | ===Highlight my contributions in VCS history=== | ||
As developer working on a project with VCS support, I want my easily see my own commits in the vcs history, e.g. by being highlighted. | |||
by | |||
(needs support for multiple identities perhaps, match could be done by name and/or email address (blacklist/whitelist to protect against wrong matches)) | |||
===Update existing identity data=== | |||
As developer working on a project, I want to have assistance when identity properties had been changed (like email address or name) and this should be reflected in all existing copyright/contributor notions of a project, where possible. | |||
Line 79: | Line 78: | ||
project? | project? | ||
on importing, if not matchable to defined identities, ask whether to create new identity in | on importing, if not matchable to defined identities, ask whether to create new identity in system or to overwrite with existing? | ||
system or to overwrite with existing? | |||
==Existing solutions of other products == | ==Existing solutions of other products == | ||
Line 88: | Line 85: | ||
== Available technical features == | == Available technical features == | ||
Currently KDevelop is hard-coded to use whatever is set for the default | Currently KDevelop is hard-coded to use whatever is set for the default profile of KEMailSettings in file templates, the only place which I found to use authorship metadata. | ||
profile of KEMailSettings in file templates, the only place which I found to | KMail seems to be feeding KEMailSettings, but otherwise there might be no data in there. | ||
use authorship metadata. KMail seems to be feeding KEMailSettings, but | |||
otherwise there might be no data in there. | |||
https://lxr.kde.org/source/kde/pim/kidentitymanagement/src/identitymanager.cpp | https://lxr.kde.org/source/kde/pim/kidentitymanagement/src/identitymanager.cpp |
Revision as of 15:08, 6 January 2017
Definition
"Author identity": metadata about an identity/role taken when writing source code or creating other resources
Motivation
When it comes to copyright notions in files and authorship/committer id in version control systems, the name and the contact information, like email address, can be a few different ones for oneself. E.g. when working in different FLOSS projects, with each email address dedicated to the project, or when working on a FLOSS project both in name of an employer, but also privately in free times.
As these data is usually fixed for a given project, and same sets of the data are used in different projects, it would be nice to have this data in a central datastore for reuse and automatic update across projects. Per project the selected data set would be automatically used when the values are needed, like on generation of code or when operating in the version control system.
Initial Plans
Marching plan:
- Collect user stories to gain idea of problem space: what kind of identity data is used when and where, what identity data sources can be used or need to by synced with
- Collect previous/existing attempts/approaches to learn more about solution space
- magic happens
- Profit!
Data Models
Temporary drafts created from currrent user stories, serving as long-term orientation. First implementations would only have properties which are needed for the initial features.
Identity:
- internal id
- display name for identity, to be used in selections
- display picture to be used along/in-place of display names
- full name
- email address
- copyright owner (if contract work)
- copyright owner contact data, email/phone/webaddress (if contract work) -> perhaps separate model?
- alias email addresses, older email addresses
- alias full name, old full name (marriage, gender change, different details)
- account in related project management server (build server, review server, task management server, issue server, ...)
Identity manager:
- allows creation/editing/deletion of identities
- setting the standard identity, preselected for new projects
- multiple backends possible, to allow adapting to custom addressbook system/LDAP/*, for updating automatically to any changes?
Project:
- has at least one identity assigned
- identity is configured on creation, defaults to standard
- active identity queried for name & email address on creation from templates
- vcs commit metadata settings updated on selecting active identity
User stories
Things that might be nice to have support for when it comes to author identities. Meant for collecting idea, not everything will be possible.
Do not get in the way
As developer working alone on a private project, I do not want to have to deal with any identity stuff, any defaults are fine with me.
Multiple identities in same system
As developer working with the same computer/system on different projects for different customers or different project groups, I want KDevelop to always inject the correct/matching copyright & author information on generating code from file & app templates for different projects/customers, instead of having to manually post-edit the generated code.
Multiple identities in same project
As developer working on the same project with the same computer system both for job and privately, I want to quickly switch identity data to be used depending on whether I work for job or privately, to mark copyright of contributions accordingly.
Pick up identity on import
As developer importing a project into KDevelop, I want to have the identity automatically derived from account/server/fetched project and have the option to create a new identity from the found data if there is none, or overwrite with an existing identity.
Highlight my contributions in VCS history
As developer working on a project with VCS support, I want my easily see my own commits in the vcs history, e.g. by being highlighted.
(needs support for multiple identities perhaps, match could be done by name and/or email address (blacklist/whitelist to protect against wrong matches))
Update existing identity data
As developer working on a project, I want to have assistance when identity properties had been changed (like email address or name) and this should be reflected in all existing copyright/contributor notions of a project, where possible.
Challenges
Syncing data with git
git has its own system to store author identity data, which can be edited directly. How to detect any direct changes? How to deal with it e.g. on importing an existing project?
on importing, if not matchable to defined identities, ask whether to create new identity in system or to overwrite with existing?
Existing solutions of other products
?
Available technical features
Currently KDevelop is hard-coded to use whatever is set for the default profile of KEMailSettings in file templates, the only place which I found to use authorship metadata. KMail seems to be feeding KEMailSettings, but otherwise there might be no data in there. https://lxr.kde.org/source/kde/pim/kidentitymanagement/src/identitymanager.cpp