Valery Sizov
387c4b2c21
Backport of multiple_assignees_feature [ci skip]
2017-05-04 17:11:53 +03:00
Douglas Barbosa Alexandre
a6affc66dc
Rename skip_metrics to imported on the importable concern
2017-04-03 15:50:22 -03:00
Douglas Barbosa Alexandre
20486593bd
Skip MR metrics when importing projects from GitHub
2017-04-03 15:50:22 -03:00
Douglas Barbosa Alexandre
336ba94a7b
Fetch GitHub project as a mirror to get all refs at once
2017-04-03 15:50:22 -03:00
Gabriel Mazetto
3c75ee2823
Minor refactor
2017-04-03 12:45:31 +02:00
Douglas Barbosa Alexandre
c8273ba858
Fix BrachFormatter for removed users
2017-04-03 12:45:31 +02:00
Gabriel Mazetto
291bd873d3
One more change to the branch names to preserve metadata
2017-04-03 12:45:31 +02:00
Douglas Barbosa Alexandre
59588ebac0
Prefixes source branch name with short SHA to avoid collision
2017-04-03 12:45:31 +02:00
Gabriel Mazetto
a3e65ef021
Fix GitHub importer for PRs of deleted forked repositories
2017-04-03 12:45:31 +02:00
Gabriel Mazetto
a996880bf7
Using guard clause and added more specs
2017-03-10 21:13:45 +01:00
Gabriel Mazetto
9b53cb6c88
Fix GitHub Import for open PRs from a fork
2017-03-10 21:08:21 +01:00
Gabriel Mazetto
ce35dcbc81
Refactor some code
2017-03-08 19:42:21 +01:00
Gabriel Mazetto
26fa716dd2
Fix name colision when importing GitHub pull requests from forked repositories
2017-03-08 19:42:21 +01:00
Douglas Barbosa Alexandre
ec4b03a4c6
Fix 'Object not found - no match for id (sha)' when importing GitHub PRs
2017-03-07 15:59:07 -03:00
Douwe Maan
56de781a2c
Revert "Enable Style/DotPosition"
...
This reverts commit e00fb2bdc2090e9cabeb1eb35a2672a882cc96e9.
# Conflicts:
# .rubocop.yml
# .rubocop_todo.yml
# lib/gitlab/ci/config/entry/global.rb
# lib/gitlab/ci/config/entry/jobs.rb
# spec/lib/gitlab/ci/config/entry/factory_spec.rb
# spec/lib/gitlab/ci/config/entry/global_spec.rb
# spec/lib/gitlab/ci/config/entry/job_spec.rb
# spec/lib/gitlab/ci/status/build/factory_spec.rb
# spec/lib/gitlab/incoming_email_spec.rb
2017-02-23 09:33:19 -06:00
Douwe Maan
1fe7501b49
Revert "Prefer leading style for Style/DotPosition"
...
This reverts commit cb10b725c8929b8b4460f89c9d96c773af39ba6b.
2017-02-23 09:33:05 -06:00
Douwe Maan
75f5fa997d
Enable Rails/Delegate
2017-02-23 09:32:42 -06:00
Douwe Maan
206953a430
Prefer leading style for Style/DotPosition
2017-02-23 09:32:22 -06:00
Douwe Maan
030baf70d2
Enable Performance/RedundantMerge
2017-02-23 09:31:57 -06:00
Douwe Maan
3dadf306dd
Enable Style/DotPosition
2017-02-23 09:31:56 -06:00
Douglas Barbosa Alexandre
43b1f5e40d
Reuse User#find_by_any_email on UserFormatter#find_by_email
2017-02-20 14:48:12 -03:00
Douglas Barbosa Alexandre
20128693eb
Use leading periods on UserFormatter#find_by_external_uid
2017-02-20 14:48:12 -03:00
Douglas Barbosa Alexandre
7da13fee84
Add a simple cache for Gitlab::GithubImport::Client#user
2017-02-20 14:48:12 -03:00
Douglas Barbosa Alexandre
2d1e0a0811
GitHub Importer - Find users based on their email address
...
The returned email by the GitHub API is the user's publicly visible
email address (or null if the user has not specified a public email
address in their profile)
2017-02-20 14:48:12 -03:00
Robert Speicher
414d695db7
Merge branch 'fix-github-import-MR-wrong-project' into 'security'
...
Fix labels being applied to wrong merge requests on GitHub import
See https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2064
2017-02-15 10:42:56 -05:00
Grzegorz Bizon
632c2939bb
Revert "Merge branch 'revert-9cac0317' into 'master'
"
...
This reverts commit c20934869f , reversing
changes made to 4b7ec44b91 .
2017-01-23 16:35:24 +01:00
Grzegorz Bizon
baeaa97ef4
Revert "Merge branch 'dont-persist-application-settings-in-test-env' into 'master'"
...
This reverts merge request !8573
2017-01-21 22:55:35 +00:00
Rémy Coutable
f6cc29ed83
Don't persist ApplicationSetting in test env
...
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-01-15 01:07:29 -05:00
Rémy Coutable
ab06313c36
Add Project#gitea_import?
...
Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-12-19 17:35:51 +01:00
Rémy Coutable
99ddd1dcbe
Modify GithubImport to support Gitea
...
The reason is that Gitea plan to be GitHub-compatible so it makes sense
to just modify GitHubImport a bit for now, and hopefully we can change
it to GitHubishImport once Gitea is 100%-compatible.
Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-12-19 17:35:51 +01:00
Kim "BKC" Carlbäcker
5d4531db25
Gogs Importer
2016-12-19 17:35:51 +01:00
Douglas Barbosa Alexandre
8ca040d8ae
Fix branch validation for GitHub PR where repo/fork was renamed/deleted
2016-12-01 00:03:12 -02:00
Andrew Smith
3228798b37
Refactor github import to reduce number of API calls
...
Ref #24073
2016-11-18 07:47:00 +10:00
Ahmad Sherif
eaa0303b3d
Cache imported GH labels no matter what
2016-11-04 15:59:53 +02:00
Ahmad Sherif
6a9fb20fe1
Fix applying GitHub-imported labels when importing job is interrupted
...
Closes #24075
2016-11-04 15:59:53 +02:00
Douwe Maan
44cbfeaba8
Merge branch 'adam-fix-labels-find-or-create' into 'master'
...
Pass user instance to Labels::FindOrCreateService or skip_authorization: true
## What does this MR do?
It fixes a bug described in #23694 when `project.owner` was passed to `Labels::FindOrCreateService`. `Labels::FindOrCreateService` expected a user instance and `project.owner` may return a group as well. This MR makes sure that we either pass a user instance or `skip_authorization: true`.
## Are there points in the code the reviewer needs to double check?
- places where we pass `skip_authorization: true`
## Does this MR meet the acceptance criteria?
- Tests
- [x] Added for this feature/bug
- [ ] All builds are passing
- [ ] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html )
- [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides )
- [x] Branch has no merge conflicts with `master` (if it does - rebase it please)
- [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits )
## What are the relevant issue numbers?
Fixes #23694
See merge request !7093
2016-10-28 15:01:59 +00:00
Adam Niedzielski
e2c603696a
Pass user instance to Labels::FindOrCreateService or skip_authorization: true
...
Do not pass project.owner because it may return a group and Labels::FindOrCreateService
throws an error in this case.
Fixes #23694 .
2016-10-28 11:31:45 +02:00
Ahmad Sherif
f68d9261b0
Fix typos
2016-10-28 11:30:20 +02:00
Ahmad Sherif
07275dd79c
Abstract the use of imported[!?] and {current,increment}_page in GitHub importer
2016-10-28 11:30:20 +02:00
Ahmad Sherif
bc6302b942
Use public_send instead of send
2016-10-28 11:30:20 +02:00
Ahmad Sherif
14fbd25d06
Modify GitHub importer to be retryable
2016-10-28 11:30:20 +02:00
Ahmad Sherif
ce38ae8ca1
Fix importing MR comments from GitHub
2016-10-27 15:42:29 +02:00
Ahmad Sherif
4259334fb6
Fix applying labels for GitHub-imported MRs
2016-10-27 15:42:28 +02:00
Douglas Barbosa Alexandre
4f6d1c1d70
Rename Labels::CreateService to Labels::FindOrCreateService
2016-10-19 14:58:28 -02:00
Douglas Barbosa Alexandre
f0ad0ceff5
Fix GitHub importer spec
2016-10-19 14:58:28 -02:00
Douglas Barbosa Alexandre
d009d38ed6
User Labes::CreateService to create labels
2016-10-19 14:58:27 -02:00
Ahmad Sherif
333c02a8c8
Fix broken handling of certain calls in GitHub importer client
...
Closes #22998
2016-10-06 11:14:25 +02:00
Douglas Barbosa Alexandre
b5f9541778
Skip wiki creation when GitHub project has wiki enabled
...
If the GitHub project repository has wiki, we should not create
the default wiki. Otherwise the GitHub importer will fail because
the wiki repository already exist.
This bug was introduced here
https://gitlab.com/gitlab-org/gitlab-ce/commit/892dea67717c0efbd6a28f763
9f34535ec0a8747
2016-10-04 13:06:45 -03:00
Ahmad Sherif
dca1acd6a6
Call after_remove_branch only once after importing all GitHub PRs
2016-09-27 20:45:07 +02:00
Ahmad Sherif
e30bfb809a
Import all GitHub comments after importing issues and PRs
2016-09-27 20:45:07 +02:00