Skip to content

updated fork feature to use gitlab-shell for v5 of gitlab #3597

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

Merged
merged 3 commits into from
May 3, 2013

Conversation

amacarthur
Copy link
Contributor

Replaces pull request #3382

Dependent upon gitlab-shell pull request: gitlabhq/gitlab-shell#45

This will provide a button on the project page which will create a fork of a project into their own namespace. The fork from/to relationship is recorded in anticipation of gitlab handling cross-repo pull requests.

@amacarthur amacarthur mentioned this pull request Apr 15, 2013
@coveralls
Copy link

Coverage decreased (-11.91%) when pulling ae33fdf on amacarthur:fork-pull-request into 63b78a3 on gitlabhq:master.

View Details

@elestedt
Copy link

Too bad that the build faild :(

@amacarthur
Copy link
Contributor Author

Is there anyway to retry the build? The failure is in an area entirely unrelated to my changeset, and from what I've seen, capybara is prone to intermittent falure.

 1) On a merge request diff with muliple note forms posting a note should be added as discussion

Failure/Error: find('a[data-line-code="342e16cbbd482ac2047dc679b2749d248cc1428f_18_17"]').click

Capybara::Ambiguous:

Ambiguous match, found 2 elements matching css "a[data-line-code=\"342e16cbbd482ac2047dc679b2749d248cc1428f_18_17\"]"

# ./spec/features/notes_on_merge_requests_spec.rb:128:in `block (3 levels) in <top (required)>'

@fbender
Copy link

fbender commented Apr 28, 2013

So if I understand correctly, you cannot merge (PR/MR) forks back into any branch of the original repo. However, I think it is vital for this feature to actually allow to send your work in the forked repo back to the original one. Is this being worked on somewhere else?

@amacarthur
Copy link
Contributor Author

@fbender Yes - this is actively being worked on.

@@ -60,7 +60,8 @@ def project_guest_rules
:read_note,
:write_project,
:write_issue,
:write_note
:write_note,
:fork_project
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

allowing fork project for guest role is bad. Guest role does not have access to source code

@dzaporozhets
Copy link
Contributor

@amacarthur its almost in upstream. Few notes left :)

@amacarthur
Copy link
Contributor Author

Excellent! Thanks @randx

@amacarthur
Copy link
Contributor Author

I hope to update this pull request today. I have encountered a bug that I need to address before this should be merged.

amacarthur added 2 commits May 2, 2013 16:41
When asking to fork a project and a project with the same name
already exists (likely from a previous fork), the recovery from
the fork failure would inadvertantly delete the repo of the
existing destination project.
@coveralls
Copy link

Coverage Status

Coverage decreased (-12.81%) when pulling ec63804 on amacarthur:fork-pull-request into 63b78a3 on gitlabhq:master.

@amacarthur
Copy link
Contributor Author

Travis build failed only when attempting to run with Ruby 2.0.0. The failure is due to a known Ruby 2.0.0 issue. See rails/rails#9417 (comment)

@dzaporozhets
Copy link
Contributor

@amacarthur thank you. Lets merge it :)

dzaporozhets added a commit that referenced this pull request May 3, 2013
updated fork feature to use gitlab-shell for v5 of gitlab
@dzaporozhets dzaporozhets merged commit f40d4e6 into gitlabhq:master May 3, 2013
@ghost ghost assigned dzaporozhets May 3, 2013
@elestedt
Copy link

elestedt commented May 3, 2013

Wonderful. Thanks @amacarthur for all your work on this. And for not giving up 👍

@dzaporozhets
Copy link
Contributor

@amacarthur since

private method `initialize_dup' called for #<Project

for ruby 2.0 we should find a better solution.
We already use 3.2.13 and I'm not sure its rails related (even if true they are not going to provide a release in closest month I guess) so we should fix it.

@dzaporozhets
Copy link
Contributor

@amacarthur Can you please make it work with ruby 2.0 today or should I fix it?

@PEM-FR
Copy link

PEM-FR commented May 3, 2013

This feature is an awesome addition to gitlab! 👍

@amacarthur amacarthur deleted the fork-pull-request branch May 3, 2013 13:48
@amacarthur
Copy link
Contributor Author

@randx Looking into it now.

@amacarthur
Copy link
Contributor Author

Thanks @PEM-FR and @elestedt .

Thanks especially to @randx for being open-minded and accepting a change he was initially unsure of.
GitLab rocks!

@amacarthur
Copy link
Contributor Author

Fix for failure using ruby 2.0:

#3829

@dzaporozhets
Copy link
Contributor

@amacarthur thank you for quick fix :) Also thank you again for good contribution!

@junxy
Copy link

junxy commented May 30, 2013

Suggest fork feature add configurable options, and default project features settings, Just like:
gitlab.yml

    ## Default project features settings
    default_projects_features:
      issues: true
      merge_requests: true
      wiki: true
      wall: false
      snippets: false
      fork: false ##here

Thanks!

rspeicher pushed a commit that referenced this pull request Nov 21, 2015
Award Emoji: fix for merge requests

Closes #3597

See merge request !1865
rspeicher pushed a commit that referenced this pull request Nov 21, 2015
Award Emoji: fix for merge requests

Closes #3597

See merge request !1865
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

7 participants