Commit Graph
1790 Commits
Author SHA1 Message Date
James Lopez d4ab068e8a Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-11 13:23:27 +02:00
James Lopez a86da1b73b Merge branch 'feature/project-export' of gitlab.com:gitlab-org/gitlab-ce into feature/project-import 2016-05-11 13:21:34 +02:00
James Lopez 49e6fc40b9 fix bad refactor 2016-05-11 13:17:49 +02:00
James Lopez df6483c65f Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-10 17:22:28 +02:00
James Lopez 6fa529e981 Merge branches 'feature/project-export' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-import 2016-05-10 17:18:04 +02:00
James Lopez a5d59f075a added better error handling. Also refactored some of the code and fixed a few issues in project_tree_saver 2016-05-10 17:15:20 +02:00
James Lopez 278be18cf0 Merge branch 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-10 12:37:33 +02:00
James Lopez 5b51d13c5e removed method no longer needed 2016-05-10 12:01:10 +02:00
James Lopez d607046df3 fix merge conflicts 2016-05-10 11:56:13 +02:00
James Lopez 6a12ff6345 renaming variable 2016-05-09 18:40:31 +02:00
James Lopez f3a8821217 Merge remote-tracking branch 'gitlab/feature/project-export' into feature/project-export 2016-05-09 18:34:42 +02:00
James Lopez 21be0cae62 fixing merge issues 2016-05-09 18:33:48 +02:00
James Lopez 5dad9f1fcb new line missing 2016-05-09 16:19:07 +00:00
James Lopez 6fe8b5da1f Merge branch 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-09 18:06:20 +02:00
James Lopez 47cd14b560 Merge branch 'feature/project-export' of gitlab.com:gitlab-org/gitlab-ce into feature/project-import 2016-05-09 18:01:06 +02:00
James Lopez 7ff2a51eb2 more refactoring to import export reader 2016-05-09 17:58:43 +02:00
James Lopez 3f87387b6f Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export
# Conflicts:
#	app/models/project.rb
2016-05-09 12:19:33 +02:00
James Lopez 9c639041fe bit more refactoring of import export reader, fixed rubocop warning 2016-05-09 12:15:50 +02:00
James Lopez 3aee167dcc fixed issues after refactor, spec passing 2016-05-09 11:10:12 +02:00
Stan Hu 4be77d0b05 Improve multiple branch push performance by memoizing permission checking
If you attempt to push thousands of branches at once, the 60-second timeout
will occur because GitAccess checking does a lot of work to check if the
user has permission to push to a branch. This changes does two things:

1. Instead of making 1 DB query per branch push, use a memoized list of protected branches to check
2. Memoize what permissions the user has to perform on this project

On a test of 10,000 branch pushes, this prevents gitlab-shell from hitting the 60-second
timeout.

Closes #17225
2016-05-09 01:17:14 -07:00
Stan Hu 21d89d0286 Update SVG sanitizer to conform to SVG 1.1
Use a custom Loofah scrubber since sanitize 2.x transformers are inadequate
to handle case-sensitive SVG attributes. sanitize parses documents as HTML
instead of XML, which causes all SVG attribute names (e.g. viewBox) to be downcased.

* SVG element list: https://www.w3.org/TR/SVG/eltindex.html
* SVG attribute list: https://www.w3.org/TR/SVG/attindex.html

Closes #14555
2016-05-06 23:20:24 -07:00
James Lopez 8ac53eb5d0 started refactoring import export reader - WIP 2016-05-06 17:55:06 +02:00
James Lopez 7750764acd Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-06 15:20:49 +02:00
James Lopez 49cdb778a1 few fixes to import specs and code 2016-05-06 15:18:25 +02:00
James Lopez 4290e9c8dd Merge branches 'feature/project-export' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-import
# Conflicts:
#	lib/gitlab/import_export/import_export.yml
2016-05-06 14:45:15 +02:00
James Lopez b6ab4a3113 missing private keyword 2016-05-06 14:39:57 +02:00
James Lopez ce598b0541 fixed and refactored a few things based on MR feedback 2016-05-06 13:40:02 +02:00
Robert Speicher 4fce876542 Merge branch 'fix/import-url-issues' into 'master'
Fix importer bug when throwing exceptions

Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/15681

See merge request !3941
2016-05-05 22:27:40 +00:00
Yorick Peterse 003671207d Fix passing nil to protected_tag?
Previously this method would directly receive the output of tag_name().
This method could either return a String or nil. In the previous setup
this would somehow magically work but because Rugged::TagCollection#[]
doesn't accept nil values it started to fail.

To work around this the elsif in change_access_check() assigns the
result of tag_name() to a local and then _only_ calls protected_tag?()
if the tag name is not nil. The extra parenthesis are put in place to
ensure that things are parsed correctly, without these the code would be
parsed as follows:

    elsif tag_ref = (tag_name(ref) && protected_tag(tag_ref))

During runtime this would basically resolve to:

    elsif tag_ref = (tag_name(ref) && protected_tag(nil))

This is because when you refer to the variable you're assigning _in_ the
assignment Ruby returns nil instead of raising an error.
2016-05-05 19:46:26 +02:00
Yorick Peterse 93ce229665 Use tag_exists? in GitAccess#protected_tag?
This removes the need for retrieving the entire list of tags just to
check if a specific one exists.
2016-05-05 19:46:26 +02:00
James Lopez 63df9b5785 Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-05 18:13:26 +02:00
James Lopez 9f5dd2de4e handling errors a bit better on import failure 2016-05-05 18:12:24 +02:00
Douglas Barbosa Alexandre 6fbf6b2936 Fix the line code when importing PR review comments from GitHub
Pull Request Review Comments are comments on a portion of the unified
diff.
2016-05-05 10:45:14 -03:00
James Lopez f927e7280e Merge branch 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-05 15:25:21 +02:00
James Lopez 9c60eca87f fix wiki import 2016-05-05 15:23:59 +02:00
James Lopez 99a5d07c92 Merge branch 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-05 14:30:18 +02:00
James Lopez f11920e21d more fixes - restoring repo 2016-05-05 14:21:27 +02:00
James Lopez 4c0f9a54ec Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-05 13:21:04 +02:00
James Lopez 28ba2176dc fix issue restoring repo 2016-05-05 13:19:41 +02:00
James Lopez 65e0d37874 Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-05 12:58:21 +02:00
James Lopez 7204018a36 fix path to bundle 2016-05-05 12:54:12 +02:00
James Lopez 21cfad245c Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-05 12:41:18 +02:00
James Lopez 92f4bde427 use git bundle in import and add wiki repo to import 2016-05-05 12:39:18 +02:00
James Lopez 43488d277e Merge branches 'feature/project-export' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-import 2016-05-05 12:02:36 +02:00
James Lopez 6612ca096a update repo and wiki repo bundler to use git bundle instead of compressing via tar 2016-05-05 12:01:18 +02:00
James Lopez e14d1051d2 fix import feature v2 2016-05-05 11:02:22 +02:00
Rémy Coutable 1a9d505972 Merge branch 'use-rugged-to-create-tag' into 'master'
Use Rugged's TagCollection#create instead of gitlab-shell's Repository#add_tag for better performance

This was originally opened at !1757 by @pcarranza but I changed it to use Rugged instead of gitlab_git, following @DouweM's request.

Once this is merged, https://gitlab.com/gitlab-org/gitlab-shell/merge_requests/26 will be mergeable too.

See merge request !3745
2016-05-04 16:07:13 +00:00
James Lopez 7a531bb116 Merge branches 'feature/project-export-ui-experimental' and 'feature/project-import' of gitlab.com:gitlab-org/gitlab-ce into feature/project-export-ui-experimental 2016-05-04 17:44:15 +02:00
James Lopez a4d242b887 refactored some namespace stuff and fixed project tree restorer spec. also removing controller so that it belongs to the UI MR 2016-05-04 17:42:02 +02:00
Douwe Maan 6a8359f3d3 Merge branch 'pacoguzman/gitlab-ce-15001-since-and-until-operators-api-commits'
# Conflicts:
#	Gemfile.lock
2016-05-04 17:27:47 +02:00