Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-04-15 06:09:11 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-04-15 06:09:11 +0300
commitb71a496c7a3e109f7c85ad7ac453e6f7bf7cda45 (patch)
tree0a76fc00ef860bd369dcaa3f136ee36275eb47f5 /lib/gitlab/wiki_pages.rb
parentc2041156b8b3063d6cf29b324416e8469e588923 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/wiki_pages.rb')
-rw-r--r--lib/gitlab/wiki_pages.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/gitlab/wiki_pages.rb b/lib/gitlab/wiki_pages.rb
new file mode 100644
index 00000000000..47f9aa1117f
--- /dev/null
+++ b/lib/gitlab/wiki_pages.rb
@@ -0,0 +1,15 @@
+# frozen_string_literal: true
+
+module Gitlab
+ module WikiPages
+ # Many common file systems have a limit of 255 bytes for file and
+ # directory names, and while Git and GitLab both support paths exceeding
+ # those limits, the presence of them makes it impossible for users on
+ # those file systems to checkout a wiki repository locally.
+
+ # To avoid this situation, we enforce these limits when editing pages
+ # through the GitLab web interface and API:
+ MAX_TITLE_BYTES = 245 # reserving 10 bytes for the file extension
+ MAX_DIRECTORY_BYTES = 255
+ end
+end