-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Leverage all-stars for author de-dupe and additional usernames #8
Merged
Merged
Changes from 2 commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey hey,
why don't you take the
summary
result here?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, did you want the "long" or "short" summary? Long looks like:
While short looks like:
BTW, did you see this comment about assigning? Are you ok returning all that stuff?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The representation thing is something related to the given reporter in
credits-cli
.We should provide as much data as possible here without cluttering everything. :)
In a perfect world I'd like to have name, email, npm, github, twitter as strings ( or even array - I don't care too much about that one ).
Jup - that's why I am asking for the
summary
call inall-stars
. This will pretty much do the job, without exposing too much data, no?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok I'm confused.
My first approach explicitly added string properties
npm
,github
, andtwitter
to theperson
object. But it was using a fewif
statements. You suggested usingextend
orassign
instead.My second approach used
object-assign
to implicitly overridename
andemail
and add the following properties to theperson
object:npmUser
stringgithubUser
stringtwitter
stringid
stringemails
arraynames
arraynpmUsers
arraygithubUsers
arraytwitters
arraysummary
functiontoString
functionWhich is probably a bit too much.
You mentioned you'd like the
summary
result, which could be represented as one of two strings (instead of a function). I asked which string you'd prefer, and I didn't understand your answer.How many of the properties listed above would you like? Are you suggesting that the
summary()
function inall-stars
return an object (instead of a string) with the following properties?name
stringemail
stringnpm
stringgithub
stringtwitter
stringAnd then merge this with the
person
object viaobject-assign
? Something like this?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm really sorry about the confusion. :(
Using a lot of
if/else
statements in a row doesn't look good in my opinion and is not really extendable. Hopefully you agree there?Aaah I see - here is the confusing coming from. I thought it is returning an object containing strings.
E.g.
This was pretty much what I had in mind, yes.
For all-stars I see 2 requests here ( if you agree ):
What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, I think I can handle that. I will update. 馃樃 Thanks for working this out with me!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
馃懐 馃憤