{"action":"created","issue":{"url":"https://api.github.com/repos/bdo/gitpair/issues/16","repository_url":"https://api.github.com/repos/bdo/gitpair","labels_url":"https://api.github.com/repos/bdo/gitpair/issues/16/labels{/name}","comments_url":"https://api.github.com/repos/bdo/gitpair/issues/16/comments","events_url":"https://api.github.com/repos/bdo/gitpair/issues/16/events","html_url":"https://github.com/bdo/gitpair/pull/16","id":264621057,"number":16,"title":"Gitpair executable","user":{"login":"mrozbarry","id":566486,"avatar_url":"https://avatars0.githubusercontent.com/u/566486?v=4","gravatar_id":"","url":"https://api.github.com/users/mrozbarry","html_url":"https://github.com/mrozbarry","followers_url":"https://api.github.com/users/mrozbarry/followers","following_url":"https://api.github.com/users/mrozbarry/following{/other_user}","gists_url":"https://api.github.com/users/mrozbarry/gists{/gist_id}","starred_url":"https://api.github.com/users/mrozbarry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrozbarry/subscriptions","organizations_url":"https://api.github.com/users/mrozbarry/orgs","repos_url":"https://api.github.com/users/mrozbarry/repos","events_url":"https://api.github.com/users/mrozbarry/events{/privacy}","received_events_url":"https://api.github.com/users/mrozbarry/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-10-11T14:59:45Z","updated_at":"2017-10-11T15:20:54Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/bdo/gitpair/pulls/16","html_url":"https://github.com/bdo/gitpair/pull/16","diff_url":"https://github.com/bdo/gitpair/pull/16.diff","patch_url":"https://github.com/bdo/gitpair/pull/16.patch"},"body":"##  ⚠️ 🚨 WARNING ⚠️ 🚨 \r\n\r\nNot in a good spot to merge yet, but I wanted to have a better place for a conversation, since this PR covers multiple pieces, plus you can see the sort of progress/changes I'm making.\r\n\r\n## What\r\n\r\n### In-Progress\r\n\r\n - #4, in progress modularization of code.\r\n   - [ ] Clean up stale code in subcommands/hooks.js\r\n - #1 & #15, support for local .gitpair file\r\n   - See closestPath.js:6\r\n   - Order of checks is closest ancestor path with package.json, or .gitpair, or final fallback is the users home directory.\r\n - #13, allows user to pull down information from public github api.\r\n   - [ ] Should there be support for other services? Thinking maybe bitbucket and gitlab (which may \r\nrequire additional config), and possibly others?\r\n - #5, working on stripping out es6 code so we can probably support node as low as 4?\r\n   - [ ] Thorough testing, and more exact node version number\r\n   - Maybe use something like webpack/rollup/flavour of the week js compiler to compile down to lower node versions?\r\n - #8, gitpair is now a cli app rather than a static script\r\n   - Solves #14, where installing the hook directly is opt-in, and it is possible to run through a husky package script.\r\n   - Solves #10 by removing the package hook on post-install.\r\n\r\n### Planning\r\n\r\n - As per #6, add some unit testing.\r\n - As per #7, after adding unit tests, add travis-ci integrations.\r\n\r\n## GIF\r\n\r\nFor your viewing pleasure...\r\n\r\n\r\n![](https://media3.giphy.com/media/3o7btNhMBytxAM6YBa/giphy.gif)"},"comment":{"url":"https://api.github.com/repos/bdo/gitpair/issues/comments/335847092","html_url":"https://github.com/bdo/gitpair/pull/16#issuecomment-335847092","issue_url":"https://api.github.com/repos/bdo/gitpair/issues/16","id":335847092,"user":{"login":"mrozbarry","id":566486,"avatar_url":"https://avatars0.githubusercontent.com/u/566486?v=4","gravatar_id":"","url":"https://api.github.com/users/mrozbarry","html_url":"https://github.com/mrozbarry","followers_url":"https://api.github.com/users/mrozbarry/followers","following_url":"https://api.github.com/users/mrozbarry/following{/other_user}","gists_url":"https://api.github.com/users/mrozbarry/gists{/gist_id}","starred_url":"https://api.github.com/users/mrozbarry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrozbarry/subscriptions","organizations_url":"https://api.github.com/users/mrozbarry/orgs","repos_url":"https://api.github.com/users/mrozbarry/repos","events_url":"https://api.github.com/users/mrozbarry/events{/privacy}","received_events_url":"https://api.github.com/users/mrozbarry/received_events","type":"User","site_admin":false},"created_at":"2017-10-11T15:20:54Z","updated_at":"2017-10-11T15:20:54Z","author_association":"NONE","body":"@bdo so I have some feedback/questions on the current state of gitpair, which will help me move forward with having a full/complete PR.\r\n\r\n## Swap aliases for initials and tag\r\n\r\nWhat do you think of removing `{ team: [{ aliases: [] }] }` and replacing it with `{ team: [{ initials: \"\", tag: \"\" }] }`? The main thing is I'm not sure how useful it is to have more than one set of initials or multiple twitter-style mention tags for a single person. I'm open to being wrong on this, but even so, I think there is something nice about separating out initials vs tags.  So for example, my original .gitpair could look like:\r\n```json\r\n{ \"team\": [ { \"name\": \"Alex Barry\", \"email\": \"alex@email.com\", \"aliases\": [\"AB\", \"mrozbarry\"] } ] }\r\n```\r\nBut I could be more clear as:\r\n```json\r\n{ \"team\": [ { \"name\": \"Alex Barry\", \"email\": \"alex@email.com\", \"initials\": \"AB\", \"tag\": \"mrozbarry\" } ] }\r\n```\r\nNot super important, though, but just want some feedback from you if this is reasonable or not.\r\n\r\n## Inline adding a team member during a commit\r\n\r\nBuilding a .gitpair file isn't hard, but it's just another thing. A feature I'm in the midst of working on would work like this:\r\n\r\n```json\r\n{\r\n  \"team\": {\r\n    { \"name\": \"Alex Barry\", \"email\": \"alex@email.com\", \"aliases\": [\"AB\", \"mrozbarry\"] }\r\n  }\r\n}\r\n```\r\n\r\n```bash\r\n$ git commit -am \"@mrozbarry @bdo We worked on a thing\"\r\n[GITPAIR] Running hook\r\n\r\nLooks like @bdo isn't in your gitpair team, would you like to add them (Y/n)? Y\r\n? How would you like to import their user data? Github\r\n > Github\r\n | Manual\r\n | Skip \r\n\r\n[GITPAIR] Fetching information from github....\r\n[GITPAIR] ...ok\r\n[GITPAIR] Missing email from bdo\r\n? What is the email address? bdo@email.com\r\n[GITPAIR] Adding new user\r\n{\r\n  \"name\": \"Benoit d'Oncieu\",\r\n  \"email\": \"bdo@email.com\",\r\n  \"aliases\": [\"bdo\"]\r\n}\r\n? Does this look right (Y/n)? Y\r\nUpdating /path/to/project/.gitpair to:\r\n{\r\n  \"team\": {\r\n    { \"name\": \"Alex Barry\", \"email\": \"alex@email.com\", \"aliases\": [\"AB\", \"mrozbarry\"] },\r\n    { \"name\": \"Benoit d'Oncieu\", \"email\": \"bdo@email.com\", \"aliases\": [\"bdo\"] }\r\n  }\r\n}\r\n\r\n[GITPAIR] Reformatting commit...\r\n[GITPAIR] Done\r\n```\r\n\r\nIs that flow too intrusive? There is nothing stopping the developer from adding a new user manually, then re-running the githook\r\n\r\n## Migration path\r\n\r\nDo we need some sort of migration path? May only be relevant if there is some heavy use of gitpair in other projects, and also depending on whether you like this PR, and how you want these features to shape up."}}
{"actor":{"display_login":"mrozbarry"}}