Skip to content
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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please give credit where credit is due #1

Closed
jpmcgrath opened this issue Jun 20, 2012 · 8 comments
Closed

Please give credit where credit is due #1

jpmcgrath opened this issue Jun 20, 2012 · 8 comments

Comments

@jpmcgrath
Copy link

Hi @siong1987

I was pleased to discover this gem today when playing on the internet. I note that it is clearly derived from my own Shortener gem (https://github.com/jpmcgrath/shortener). I'm really pleased that you were able to put my code to good use, that's the whole point of sharing it.

I see that you have made some good improvements to the code, great stuff!

However, I would really appreciate it if you could replace my name in the copyright notice and mention that your gem is derived from my gem. This is considered polite behaviour in the open source community. Removing my name from the copyright notice in the license file is also specifically prohibited by the license. I don't mind you placing your own name in there as well, you deserve to as you have made significant modifications to your version, but my name should not have been removed.

Cheers,

James.

@siong1987
Copy link
Owner

Do you mind point to the part that the code is derived from your code? To be honest, I don't remember copying your whole branch and making changes based on your code.

4e0d109

And, the above commit looks like I was using some kind of gem generator for it.

Btw, I might refer to your code at some point to get some ideas from. But, I am sure that I didn't change the code based on your branch.

@jpmcgrath
Copy link
Author

Mate, don't be dishonest and do the right thing. It's pretty unrealistic that you would forget doing something like this. You only have to compare the controllers, helpers and models to see that the code was derived from Shortener and pretending otherwise is silly.

I'm not asking for much, I'm sure you'd want others to do the same for you.

@siong1987
Copy link
Owner

Let me say this again. I am not saying that I won't attribute this to you. But, if you could point out the part that I am copying from you, then, I will.

And, I want to say this again. I definitely didn't rewrite this gem from your gem. So, I don't think that changing the license back to you is the thing I would want to do.

@jpmcgrath
Copy link
Author

Ok, how about we look at the shortened_urls_controller.rb:

Mine:
https://github.com/jpmcgrath/shortener/blob/17296a2522b3be4f2b029d2e6efa22594563bd44/app/controllers/shortener/shortened_urls_controller.rb

Yours:
https://github.com/siong1987/mongoid_shortener/blob/4e0d109d8c835175e9f9b86d55826caafe983bf7/app/controllers/mongoid_shortener/shortened_urls_controller.rb

How similar are they? Are the function names the same? Yes. Are the variables the same? Yes. Are the comments the same? YES!

We can now look at the shortened_url.rb model:
Mine:
https://github.com/jpmcgrath/shortener/blob/aad8923184401481af41aff5a3ed7e64e289d8db/app/models/shortener/shortened_url.rb

Yours:
https://github.com/siong1987/mongoid_shortener/blob/4e0d109d8c835175e9f9b86d55826caafe983bf7/app/models/mongoid_shortener/shortened_url.rb

The REGEX constants are the same name and structure, the validations are the same and the functions are largely the same and once again the comments are the same.

There are obvious similarities between both of our shortener_helper.rb files:

https://github.com/jpmcgrath/shortener/blob/17296a2522b3be4f2b029d2e6efa22594563bd44/app/helpers/shortener/shortener_helper.rb

https://github.com/siong1987/mongoid_shortener/blob/4e0d109d8c835175e9f9b86d55826caafe983bf7/app/helpers/mongoid_shortener/shortened_urls_helper.rb

You have changed this file the most, but left the following comment in there: "generate a url from either a url string, or a shortened url object"

Not only is this comment the same comment as I wrote in my file BUT it also doesn't make sense to have it in your method because you raise an exception if the url argument is anything other than a string. The comment says "url string or a shortened url object", but you can't pass a shortened url object to your helper method.

The guts of the Gem are in these three files. The rest of the files are to wrap the whole thing into a rack application.

So, could you please explain how these files contain the same constants, variables, constants and the same comments if you didn't copy and paste those files into your project?

@siong1987
Copy link
Owner

See. That's exactly what I wanted. I already told you that I forgot where I referred the code from. I will update the files accordingly.

@siong1987
Copy link
Owner

1232168

@siong1987
Copy link
Owner

50bfd5c

@jpmcgrath
Copy link
Author

Thanks @siong1987, much appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants