Commit 8149d7b5 authored by Bob Van Landuyt's avatar Bob Van Landuyt

Merge branch 'jh-remove_html_todolist' into 'master'

Remove HTML todolist functionality

See merge request gitlab-org/gitlab!48020
parents 34eebb0a 8533a7c5
#
# PLEASE DO NOT ADD NEW STRINGS TO THIS FILE.
#
# See https://docs.gitlab.com/ee/development/i18n/externalization.html#html
# for information on how to handle HTML in translations.
#
# This file contains strings that need to be fixed to use the
# updated HTML guidelines. Any strings in this file will no
# longer be able to be translated until they have been updated.
#
# This file (and the functionality around it) will be removed
# once https://gitlab.com/gitlab-org/gitlab/-/issues/217933 is complete.
#
# See https://gitlab.com/gitlab-org/gitlab/-/issues/19485 for more details
# why this change has been made.
#
#
# Strings below are fixed in the source code but the translations are still present in CrowdIn so the
# locale files will fail the linter. They can be deleted after next CrowdIn sync, likely in:
# https://gitlab.com/gitlab-org/gitlab/-/issues/226008
#
"This commit was signed with an <strong>unverified</strong> signature.":
plural_id:
translations:
- "このコミットは<strong>検証されていない</strong> 署名でサインされています。"
- "Этот коммит был подписан <strong>непроверенной</strong> подписью."
- "此提交使用 <strong>未经验证的</strong> 签名进行签名。"
- "Цей коміт підписано <strong>неперевіреним</strong> підписом."
- "Esta commit fue firmado con una firma <strong>no verificada</strong>."
"This commit was signed with a <strong>verified</strong> signature and the committer email is verified to belong to the same user.":
plural_id:
translations:
- "このコミットは <strong>検証済み</strong> の署名でサインされており、このコミッターのメールは同じユーザーのものであることが検証されています。"
- "Это коммит был подписан <strong>верифицированной</strong> подписью и коммитер подтвердил, что адрес почты принадлежит ему."
- "此提交使用 <strong>已验证</strong> 的签名进行签名,并且已验证提交者的电子邮件属于同一用户。"
- "Цей коміт підписано <strong>перевіреним</strong> підписом і адреса електронної пошти комітера гарантовано належить тому самому користувачу."
- "Este commit fue firmado con una firma verificada, y <strong>se ha verificado</strong> que la dirección de correo electrónico del committer y la firma pertenecen al mismo usuario."
"Branch <strong>%{branch_name}</strong> was created. To set up auto deploy, choose a GitLab CI Yaml template and commit your changes. %{link_to_autodeploy_doc}":
plural_id:
translations:
- "分支 <strong>%{branch_name}</strong> 已創建。如需設置自動部署, 請選擇合適的 GitLab CI Yaml 模板併提交更改。%{link_to_autodeploy_doc}"
- "O branch <strong>%{branch_name}</strong> foi criado. Para configurar o deploy automático, selecione um modelo de Yaml do GitLab CI e commit suas mudanças. %{link_to_autodeploy_doc}"
- "<strong>%{branch_name}</strong> ブランチが作成されました。自動デプロイを設定するには、GitLab CI Yaml テンプレートを選択して、変更をコミットしてください。 %{link_to_autodeploy_doc}"
- "La branch <strong>%{branch_name}</strong> è stata creata. Per impostare un rilascio automatico scegli un template CI di Gitlab e committa le tue modifiche %{link_to_autodeploy_doc}"
- "O ramo <strong>%{branch_name}</strong> foi criado. Para configurar a implantação automática, seleciona um modelo de Yaml do GitLab CI e envia as tuas alterações. %{link_to_autodeploy_doc}"
- "Ветка <strong>%{branch_name}</strong> создана. Для настройки автоматического развертывания выберите YAML-шаблон для GitLab CI и зафиксируйте свои изменения. %{link_to_autodeploy_doc}"
- "已创建分支 <strong>%{branch_name}</strong> 。如需设置自动部署, 请选择合适的 GitLab CI Yaml 模板并提交更改。%{link_to_autodeploy_doc}"
- "Гілка <strong>%{branch_name}</strong> створена. Для настройки автоматичного розгортання виберіть GitLab CI Yaml-шаблон і закомітьте зміни. %{link_to_autodeploy_doc}"
- "Клонът <strong>%{branch_name}</strong> беше създаден. За да настроите автоматичното внедряване, изберете Yaml шаблон за GitLab CI и подайте промените си. %{link_to_autodeploy_doc}"
- "Branch <strong>%{branch_name}</strong> wurde erstellt. Um die automatische Bereitstellung einzurichten, wähle eine GitLab CI Yaml Vorlage und committe deine Änderungen. %{link_to_autodeploy_doc}"
- "<strong>%{branch_name}</strong> 브랜치가 생성되었습니다. 자동 배포를 설정하려면 GitLab CI Yaml 템플릿을 선택하고 변경 사항을 적용하십시오. %{link_to_autodeploy_doc}"
- "La branĉo <strong>%{branch_name}</strong> estis kreita. Por agordi aŭtomatan disponigadon, bonvolu elekti Yaml-ŝablonon por GitLab CI kaj enmeti viajn ŝanĝojn. %{link_to_autodeploy_doc}"
- "La branche <strong>%{branch_name}</strong> a été créée. Pour mettre en place le déploiement automatisé, sélectionnez un modèle de fichier YAML pour l’intégration continue (CI) de GitLab, et validez les modifications. %{link_to_autodeploy_doc}"
- "La rama <strong>%{branch_name}</strong> fue creada. Para configurar el auto despliegue, escoge una plantilla Yaml para GitLab CI y envía tus cambios. %{link_to_autodeploy_doc}"
......@@ -5,14 +5,13 @@ module Gitlab
class PoLinter
include Gitlab::Utils::StrongMemoize
attr_reader :po_path, :translation_entries, :metadata_entry, :locale, :html_todolist
attr_reader :po_path, :translation_entries, :metadata_entry, :locale
VARIABLE_REGEX = /%{\w*}|%[a-z]/.freeze
def initialize(po_path:, html_todolist:, locale: I18n.locale.to_s)
def initialize(po_path:, locale: I18n.locale.to_s)
@po_path = po_path
@locale = locale
@html_todolist = html_todolist
end
def errors
......@@ -43,8 +42,7 @@ module Gitlab
@translation_entries = entries.map do |entry_data|
Gitlab::I18n::TranslationEntry.new(
entry_data: entry_data,
nplurals: metadata_entry.expected_forms,
html_allowed: html_todolist.fetch(entry_data[:msgid], false)
nplurals: metadata_entry.expected_forms
)
end
......@@ -97,15 +95,15 @@ module Gitlab
common_message = 'contains < or >. Use variables to include HTML in the string, or the &lt; and &gt; codes ' \
'for the symbols. For more info see: https://docs.gitlab.com/ee/development/i18n/externalization.html#html'
if entry.msgid_contains_potential_html? && !entry.msgid_html_allowed?
if entry.msgid_contains_potential_html?
errors << common_message
end
if entry.plural_id_contains_potential_html? && !entry.plural_id_html_allowed?
if entry.plural_id_contains_potential_html?
errors << 'plural id ' + common_message
end
if entry.translations_contain_potential_html? && !entry.translations_html_allowed?
if entry.translations_contain_potential_html?
errors << 'translation ' + common_message
end
end
......
......@@ -6,12 +6,11 @@ module Gitlab
PERCENT_REGEX = /(?:^|[^%])%(?!{\w*}|[a-z%])/.freeze
ANGLE_BRACKET_REGEX = /[<>]/.freeze
attr_reader :nplurals, :entry_data, :html_allowed
attr_reader :nplurals, :entry_data
def initialize(entry_data:, nplurals:, html_allowed:)
def initialize(entry_data:, nplurals:)
@entry_data = entry_data
@nplurals = nplurals
@html_allowed = html_allowed
end
def msgid
......@@ -97,20 +96,6 @@ module Gitlab
all_translations.any? { |translation| contains_angle_brackets?(translation) }
end
def msgid_html_allowed?
html_allowed.present?
end
def plural_id_html_allowed?
html_allowed.present? && html_allowed['plural_id'] == plural_id
end
def translations_html_allowed?
msgid_html_allowed? && html_allowed['translations'].present? && all_translations.all? do |translation|
html_allowed['translations'].include?(translation)
end
end
private
def contains_angle_brackets?(string)
......
......@@ -65,10 +65,10 @@ namespace :gettext do
linters = files.map do |file|
locale = File.basename(File.dirname(file))
Gitlab::I18n::PoLinter.new(po_path: file, html_todolist: html_todolist, locale: locale)
Gitlab::I18n::PoLinter.new(po_path: file, locale: locale)
end
linters.unshift(Gitlab::I18n::PoLinter.new(po_path: pot_file_path, html_todolist: html_todolist))
linters.unshift(Gitlab::I18n::PoLinter.new(po_path: pot_file_path))
failed_linters = linters.select { |linter| linter.errors.any? }
......
# English translations for gitlab package.
# Copyright (C) 2017 THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the gitlab package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2017.
#
msgid ""
msgstr ""
"Project-Id-Version: gitlab 1.0.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2017-04-12 22:36-0500\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: English\n"
"Language: en\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"\n"
msgid "%d commit"
msgid_plural "%d commits"
msgstr[0] ""
msgstr[1] ""
msgid "%s additional commit has been omitted to prevent performance issues."
msgid_plural "%s additional commits have been omitted to prevent performance issues."
msgstr[0] ""
msgstr[1] ""
msgid "%{commit_author_link} committed %{commit_timeago}"
msgstr ""
msgid "%{number_of_failures} of %{maximum_failures} failures. GitLab will allow access on the next attempt."
msgstr ""
msgid "%{number_of_failures} of %{maximum_failures} failures. GitLab will block access for %{number_of_seconds} seconds."
msgstr ""
msgid "%{number_of_failures} of %{maximum_failures} failures. GitLab will not retry automatically. Reset storage information when the problem is resolved."
msgstr ""
msgid "%{storage_name}: failed storage access attempt on host:"
msgid_plural "%{storage_name}: %{failed_attempts} failed storage access attempts:"
msgstr[0] ""
msgstr[1] ""
msgid "(checkout the %{link} for information on how to install it)."
msgstr ""
msgid "1 pipeline"
msgid_plural "%d pipelines"
msgstr[0] ""
msgstr[1] ""
msgid "About auto deploy"
msgstr ""
msgid "Access to failing storages has been temporarily disabled to allow the mount to recover. Reset storage information after the issue has been resolved to allow access again."
msgstr ""
msgid "Active"
msgstr ""
msgid "Activity"
msgstr ""
msgid "Add Changelog"
msgstr ""
msgid "Add Contribution guide"
msgstr ""
msgid "Add License"
msgstr ""
msgid "Add an SSH key to your profile to pull or push via SSH."
msgstr ""
msgid "Add new directory"
msgstr ""
msgid "Archived project! Repository is read-only"
msgstr ""
msgid "Are you sure you want to delete this pipeline schedule?"
msgstr ""
msgid "Are you sure you want to discard your changes?"
msgstr ""
msgid "Are you sure you want to reset registration token?"
msgstr ""
msgid "Are you sure you want to reset the health check token?"
msgstr ""
msgid "Are you sure?"
msgstr ""
msgid "Attach a file by drag &amp; drop or %{upload_link}"
msgstr ""
msgid "Branch"
msgid_plural "Branches"
msgstr[0] ""
msgstr[1] ""
msgid "Branch <strong>%{branch_name}</strong> was created. To set up auto deploy, choose a GitLab CI Yaml template and commit your changes. %{link_to_autodeploy_doc}"
msgstr ""
msgid "BranchSwitcherPlaceholder|Search branches"
msgstr ""
msgid "BranchSwitcherTitle|Switch branch"
msgstr ""
msgid "Branches"
msgstr ""
msgid "Browse Directory"
msgstr ""
msgid "Browse File"
msgstr ""
msgid "Browse Files"
msgstr ""
msgid "Browse files"
msgstr ""
msgid "ByAuthor|by"
msgstr ""
msgid "CI configuration"
msgstr ""
msgid "Cancel"
msgstr ""
msgid "Cancel edit"
msgstr ""
msgid "ChangeTypeActionLabel|Pick into branch"
msgstr ""
msgid "ChangeTypeActionLabel|Revert in branch"
msgstr ""
msgid "ChangeTypeAction|Cherry-pick"
msgstr ""
msgid "ChangeTypeAction|Revert"
msgstr ""
msgid "Changelog"
msgstr ""
msgid "Charts"
msgstr ""
msgid "Cherry-pick this commit"
msgstr ""
msgid "Cherry-pick this merge request"
msgstr ""
msgid "CiStatusLabel|canceled"
msgstr ""
msgid "CiStatusLabel|created"
msgstr ""
msgid "CiStatusLabel|failed"
msgstr ""
msgid "CiStatusLabel|manual action"
msgstr ""
msgid "CiStatusLabel|passed"
msgstr ""
msgid "CiStatusLabel|passed with warnings"
msgstr ""
msgid "CiStatusLabel|pending"
msgstr ""
msgid "CiStatusLabel|skipped"
msgstr ""
msgid "CiStatusLabel|waiting for manual action"
msgstr ""
msgid "CiStatusText|blocked"
msgstr ""
msgid "CiStatusText|canceled"
msgstr ""
msgid "CiStatusText|created"
msgstr ""
msgid "CiStatusText|failed"
msgstr ""
msgid "CiStatusText|manual"
msgstr ""
msgid "CiStatusText|passed"
msgstr ""
msgid "CiStatusText|pending"
msgstr ""
msgid "CiStatusText|skipped"
msgstr ""
msgid "CiStatus|running"
msgstr ""
msgid "Commit"
msgid_plural "Commits"
msgstr[0] ""
msgstr[1] ""
msgid "Commit duration in minutes for last 30 commits"
msgstr ""
msgid "Commit message"
msgstr ""
msgid "CommitBoxTitle|Commit"
msgstr ""
msgid "CommitMessage|Add %{file_name}"
msgstr ""
msgid "Commits"
msgstr ""
msgid "Commits feed"
msgstr ""
msgid "Commits|History"
msgstr ""
msgid "Committed by"
msgstr ""
msgid "Compare"
msgstr ""
msgid "Contribution guide"
msgstr ""
msgid "Contributors"
msgstr ""
msgid "Copy URL to clipboard"
msgstr ""
msgid "Copy commit SHA to clipboard"
msgstr ""
msgid "Create New Directory"
msgstr ""
msgid "Create a new branch"
msgstr ""
msgid "Create a personal access token on your account to pull or push via %{protocol}."
msgstr ""
msgid "Create directory"
msgstr ""
msgid "Create empty bare repository"
msgstr ""
msgid "Create merge request"
msgstr ""
msgid "Create new..."
msgstr ""
msgid "CreateNewFork|Fork"
msgstr ""
msgid "CreateTag|Tag"
msgstr ""
msgid "CreateTokenToCloneLink|create a personal access token"
msgstr ""
msgid "Cron Timezone"
msgstr ""
msgid "Cron syntax"
msgstr ""
msgid "Custom notification events"
msgstr ""
msgid "Custom notification levels are the same as participating levels. With custom notification levels you will also receive notifications for select events. To find out more, check out %{notification_link}."
msgstr ""
msgid "CycleAnalyticsStage|Code"
msgstr ""
msgid "CycleAnalyticsStage|Issue"
msgstr ""
msgid "CycleAnalyticsStage|Plan"
msgstr ""
msgid "CycleAnalyticsStage|Production"
msgstr ""
msgid "CycleAnalyticsStage|Review"
msgstr ""
msgid "CycleAnalyticsStage|Staging"
msgstr ""
msgid "CycleAnalyticsStage|Test"
msgstr ""
msgid "Define a custom pattern with cron syntax"
msgstr ""
msgid "Delete"
msgstr ""
msgid "Deploy"
msgid_plural "Deploys"
msgstr[0] ""
msgstr[1] ""
msgid "Description"
msgstr ""
msgid "Details"
msgstr ""
msgid "Directory name"
msgstr ""
msgid "Discard changes"
msgstr ""
msgid "Don't show again"
msgstr ""
msgid "Download"
msgstr ""
msgid "Download tar"
msgstr ""
msgid "Download tar.bz2"
msgstr ""
msgid "Download tar.gz"
msgstr ""
msgid "Download zip"
msgstr ""
msgid "DownloadArtifacts|Download"
msgstr ""
msgid "DownloadCommit|Email Patches"
msgstr ""
msgid "DownloadCommit|Plain Diff"
msgstr ""
msgid "DownloadSource|Download"
msgstr ""
msgid "Edit"
msgstr ""
msgid "Edit Pipeline Schedule %{id}"
msgstr ""
msgid "Every day (at 4:00am)"
msgstr ""
msgid "Every month (on the 1st at 4:00am)"
msgstr ""
msgid "Every week (Sundays at 4:00am)"
msgstr ""
msgid "Failed to change the owner"
msgstr ""
msgid "Failed to remove the pipeline schedule"
msgstr ""
msgid "Files"
msgstr ""
msgid "Filter by commit message"
msgstr ""
msgid "Find by path"
msgstr ""
msgid "Find file"
msgstr ""
msgid "FirstPushedBy|First"
msgstr ""
msgid "FirstPushedBy|pushed by"
msgstr ""
msgid "Fork"
msgid_plural "Forks"
msgstr[0] ""
msgstr[1] ""
msgid "ForkedFromProjectPath|Forked from"
msgstr ""
msgid "From issue creation until deploy to production"
msgstr ""
msgid "From merge request merge until deploy to production"
msgstr ""
msgid "Git storage health information has been reset"
msgstr ""
msgid "GitLab Runner section"
msgstr ""
msgid "Go to your fork"
msgstr ""
msgid "GoToYourFork|Fork"
msgstr ""
msgid "Health Check"
msgstr ""
msgid "Health information can be retrieved from the following endpoints. More information is available"
msgstr ""
msgid "HealthCheck|Access token is"
msgstr ""
msgid "HealthCheck|Healthy"
msgstr ""
msgid "HealthCheck|No Health Problems Detected"
msgstr ""
msgid "HealthCheck|Unhealthy"
msgstr ""
msgid "Home"
msgstr ""
msgid "Housekeeping successfully started"
msgstr ""
msgid "Import repository"
msgstr ""
msgid "Install a Runner compatible with GitLab CI"
msgstr ""
msgid "Interval Pattern"
msgstr ""
msgid "Jobs for last month"
msgstr ""
msgid "Jobs for last week"
msgstr ""
msgid "Jobs for last year"
msgstr ""
msgid "LFSStatus|Disabled"
msgstr ""
msgid "LFSStatus|Enabled"
msgstr ""
msgid "Last %d day"
msgid_plural "Last %d days"
msgstr[0] ""
msgstr[1] ""
msgid "Last Pipeline"
msgstr ""
msgid "Last Update"
msgstr ""
msgid "Last commit"
msgstr ""
msgid "Learn more in the"
msgstr ""
msgid "Learn more in the|pipeline schedules documentation"
msgstr ""
msgid "Leave group"
msgstr ""
msgid "Leave project"
msgstr ""
msgid "Limited to showing %d event at most"
msgid_plural "Limited to showing %d events at most"
msgstr[0] ""
msgstr[1] ""
msgid "Median"
msgstr ""
msgid "MissingSSHKeyWarningLink|add an SSH key"
msgstr ""
msgid "More information is available|here"
msgstr ""
msgid "New Issue"
msgid_plural "New Issues"
msgstr[0] ""
msgstr[1] ""
msgid "New Pipeline Schedule"
msgstr ""
msgid "New branch"
msgstr ""
msgid "New directory"
msgstr ""
msgid "New file"
msgstr ""
msgid "New issue"
msgstr ""
msgid "New merge request"
msgstr ""
msgid "New schedule"
msgstr ""
msgid "New snippet"
msgstr ""
msgid "New tag"
msgstr ""
msgid "No repository"
msgstr ""
msgid "No schedules"
msgstr ""
msgid "Not available"
msgstr ""
msgid "Not enough data"
msgstr ""
msgid "Notification events"
msgstr ""
msgid "NotificationEvent|Close issue"
msgstr ""
msgid "NotificationEvent|Close merge request"
msgstr ""
msgid "NotificationEvent|Failed pipeline"
msgstr ""
msgid "NotificationEvent|Merge merge request"
msgstr ""
msgid "NotificationEvent|New issue"
msgstr ""
msgid "NotificationEvent|New merge request"
msgstr ""
msgid "NotificationEvent|New note"
msgstr ""
msgid "NotificationEvent|Reassign issue"
msgstr ""
msgid "NotificationEvent|Reassign merge request"
msgstr ""
msgid "NotificationEvent|Reopen issue"
msgstr ""
msgid "NotificationEvent|Successful pipeline"
msgstr ""
msgid "NotificationLevel|Custom"
msgstr ""
msgid "NotificationLevel|Disabled"
msgstr ""
msgid "NotificationLevel|Global"
msgstr ""
msgid "NotificationLevel|On mention"
msgstr ""
msgid "NotificationLevel|Participate"
msgstr ""
msgid "NotificationLevel|Watch"
msgstr ""
msgid "OfSearchInADropdown|Filter"
msgstr ""
msgid "OpenedNDaysAgo|Opened"
msgstr ""
msgid "Options"
msgstr ""
msgid "Owner"
msgstr ""
msgid "Pipeline"
msgstr ""
msgid "Pipeline Health"
msgstr ""
msgid "Pipeline Schedule"
msgstr ""
msgid "Pipeline Schedules"
msgstr ""
msgid "PipelineCharts|Failed:"
msgstr ""
msgid "PipelineCharts|Overall statistics"
msgstr ""
msgid "PipelineCharts|Success ratio:"
msgstr ""
msgid "PipelineCharts|Successful:"
msgstr ""
msgid "PipelineCharts|Total:"
msgstr ""
msgid "PipelineSchedules|Activated"
msgstr ""
msgid "PipelineSchedules|Active"
msgstr ""
msgid "PipelineSchedules|All"
msgstr ""
msgid "PipelineSchedules|Inactive"
msgstr ""
msgid "PipelineSchedules|Input variable key"
msgstr ""
msgid "PipelineSchedules|Input variable value"
msgstr ""
msgid "PipelineSchedules|Next Run"
msgstr ""
msgid "PipelineSchedules|None"
msgstr ""
msgid "PipelineSchedules|Provide a short description for this pipeline"
msgstr ""
msgid "PipelineSchedules|Remove variable row"
msgstr ""
msgid "PipelineSchedules|Take ownership"
msgstr ""
msgid "PipelineSchedules|Target"
msgstr ""
msgid "PipelineSchedules|Variables"
msgstr ""
msgid "PipelineSheduleIntervalPattern|Custom"
msgstr ""
msgid "Pipelines"
msgstr ""
msgid "Pipelines charts"
msgstr ""
msgid "Pipeline|all"
msgstr ""
msgid "Pipeline|success"
msgstr ""
msgid "Pipeline|with stage"
msgstr ""
msgid "Pipeline|with stages"
msgstr ""
msgid "Project '%{project_name}' queued for deletion."
msgstr ""
msgid "Project '%{project_name}' was successfully created."
msgstr ""
msgid "Project '%{project_name}' was successfully updated."
msgstr ""
msgid "Project '%{project_name}' will be deleted."
msgstr ""
msgid "Project access must be granted explicitly to each user."
msgstr ""
msgid "Project details"
msgstr ""
msgid "Project export could not be deleted."
msgstr ""
msgid "Project export has been deleted."
msgstr ""
msgid "Project export link has expired. Please generate a new export from your project settings."
msgstr ""
msgid "Project export started. A download link will be sent by email."
msgstr ""
msgid "Project home"
msgstr ""
msgid "ProjectFeature|Disabled"
msgstr ""
msgid "ProjectFeature|Everyone with access"
msgstr ""
msgid "ProjectFeature|Only team members"
msgstr ""
msgid "ProjectFileTree|Name"
msgstr ""
msgid "ProjectLastActivity|Never"
msgstr ""
msgid "ProjectLifecycle|Stage"
msgstr ""
msgid "ProjectNetworkGraph|Graph"
msgstr ""
msgid "Read more"
msgstr ""
msgid "Readme"
msgstr ""
msgid "RefSwitcher|Branches"
msgstr ""
msgid "RefSwitcher|Tags"
msgstr ""
msgid "Related Commits"
msgstr ""
msgid "Related Deployed Jobs"
msgstr ""
msgid "Related Issues"
msgstr ""
msgid "Related Jobs"
msgstr ""
msgid "Related Merge Requests"
msgstr ""
msgid "Related Merged Requests"
msgstr ""
msgid "Remind later"
msgstr ""
msgid "Remove project"
msgstr ""
msgid "Repository"
msgstr ""
msgid "Request Access"
msgstr ""
msgid "Reset git storage health information"
msgstr ""
msgid "Reset health check access token"
msgstr ""
msgid "Reset runners registration token"
msgstr ""
msgid "Revert this commit"
msgstr ""
msgid "Revert this merge request"
msgstr ""
msgid "Save pipeline schedule"
msgstr ""
msgid "Schedule a new pipeline"
msgstr ""
msgid "Scheduling Pipelines"
msgstr ""
msgid "Search branches and tags"
msgstr ""
msgid "Select Archive Format"
msgstr ""
msgid "Select a timezone"
msgstr ""
msgid "Select existing branch"
msgstr ""
msgid "Select target branch"
msgstr ""
msgid "Set a password on your account to pull or push via %{protocol}."
msgstr ""
msgid "Set up CI"
msgstr ""
msgid "Set up auto deploy"
msgstr ""
msgid "SetPasswordToCloneLink|set a password"
msgstr ""
msgid "Showing %d event"
msgid_plural "Showing %d events"
msgstr[0] ""
msgstr[1] ""
msgid "Source code"
msgstr ""
msgid "Specify the following URL during the Runner setup:"
msgstr ""
msgid "StarProject|Star"
msgstr ""
msgid "Start a %{new_merge_request} with these changes"
msgstr ""
msgid "Start the Runner!"
msgstr ""
msgid "Switch branch/tag"
msgstr ""
msgid "Tag"
msgid_plural "Tags"
msgstr[0] ""
msgstr[1] ""
msgid "Tags"
msgstr ""
msgid "Target Branch"
msgstr ""
msgid "The coding stage shows the time from the first commit to creating the merge request. The data will automatically be added here once you create your first merge request."
msgstr ""
msgid "The collection of events added to the data gathered for that stage."
msgstr ""
msgid "The fork relationship has been removed."
msgstr ""
msgid "The issue stage shows the time it takes from creating an issue to assigning the issue to a milestone, or add the issue to a list on your Issue Board. Begin creating issues to see data for this stage."
msgstr ""
msgid "The phase of the development lifecycle."
msgstr ""
msgid "The pipelines schedule runs pipelines in the future, repeatedly, for specific branches or tags. Those scheduled pipelines will inherit limited project access based on their associated user."
msgstr ""
msgid "The planning stage shows the time from the previous step to pushing your first commit. This time will be added automatically once you push your first commit."
msgstr ""
msgid "The production stage shows the total time it takes between creating an issue and deploying the code to production. The data will be automatically added once you have completed the full idea to production cycle."
msgstr ""
msgid "The project can be accessed by any logged in user."
msgstr ""
msgid "The project can be accessed without any authentication."
msgstr ""
msgid "The repository for this project does not exist."
msgstr ""
msgid "The review stage shows the time from creating the merge request to merging it. The data will automatically be added after you merge your first merge request."
msgstr ""
msgid "The staging stage shows the time between merging the MR and deploying code to the production environment. The data will be automatically added once you deploy to production for the first time."
msgstr ""
msgid "The testing stage shows the time GitLab CI takes to run every pipeline for the related merge request. The data will automatically be added after your first pipeline finishes running."
msgstr ""
msgid "The time taken by each data entry gathered by that stage."
msgstr ""
msgid "The value lying at the midpoint of a series of observed values. E.g., between 3, 5, 9, the median is 5. Between 3, 5, 7, 8, the median is (5+7)/2 = 6."
msgstr ""
msgid "There are problems accessing Git storage: "
msgstr ""
msgid "This means you can not push code until you create an empty repository or import existing one."
msgstr ""
msgid "Time before an issue gets scheduled"
msgstr ""
msgid "Time before an issue starts implementation"
msgstr ""
msgid "Time between merge request creation and merge/close"
msgstr ""
msgid "Time until first merge request"
msgstr ""
msgid "Timeago|%s days ago"
msgstr ""
msgid "Timeago|%s days remaining"
msgstr ""
msgid "Timeago|%s hours remaining"
msgstr ""
msgid "Timeago|%s minutes ago"
msgstr ""
msgid "Timeago|%s minutes remaining"
msgstr ""
msgid "Timeago|%s months ago"
msgstr ""
msgid "Timeago|%s months remaining"
msgstr ""
msgid "Timeago|%s seconds remaining"
msgstr ""
msgid "Timeago|%s weeks ago"
msgstr ""
msgid "Timeago|%s weeks remaining"
msgstr ""
msgid "Timeago|%s years ago"
msgstr ""
msgid "Timeago|%s years remaining"
msgstr ""
msgid "Timeago|1 day remaining"
msgstr ""
msgid "Timeago|1 hour remaining"
msgstr ""
msgid "Timeago|1 minute remaining"
msgstr ""
msgid "Timeago|1 month remaining"
msgstr ""
msgid "Timeago|1 week remaining"
msgstr ""
msgid "Timeago|1 year remaining"
msgstr ""
msgid "Timeago|Past due"
msgstr ""
msgid "Timeago|a day ago"
msgstr ""
msgid "Timeago|a month ago"
msgstr ""
msgid "Timeago|a week ago"
msgstr ""
msgid "Timeago|in a while"
msgstr ""
msgid "Timeago|a year ago"
msgstr ""
msgid "Timeago|about %s hours ago"
msgstr ""
msgid "Timeago|about a minute ago"
msgstr ""
msgid "Timeago|about an hour ago"
msgstr ""
msgid "Timeago|in %s days"
msgstr ""
msgid "Timeago|in %s hours"
msgstr ""
msgid "Timeago|in %s minutes"
msgstr ""
msgid "Timeago|in %s months"
msgstr ""
msgid "Timeago|in %s seconds"
msgstr ""
msgid "Timeago|in %s weeks"
msgstr ""
msgid "Timeago|in %s years"
msgstr ""
msgid "Timeago|in 1 day"
msgstr ""
msgid "Timeago|in 1 hour"
msgstr ""
msgid "Timeago|in 1 minute"
msgstr ""
msgid "Timeago|in 1 month"
msgstr ""
msgid "Timeago|in 1 week"
msgstr ""
msgid "Timeago|in 1 year"
msgstr ""
msgid "Timeago|less than a minute ago"
msgstr ""
msgid "Time|hr"
msgid_plural "Time|hrs"
msgstr[0] ""
msgstr[1] ""
msgid "Time|min"
msgid_plural "Time|mins"
msgstr[0] ""
msgstr[1] ""
msgid "Time|s"
msgstr ""
msgid "Total Time"
msgstr ""
msgid "Total test time for all commits/merges"
msgstr ""
msgid "Unstar"
msgstr ""
msgid "Upload New File"
msgstr ""
msgid "Upload file"
msgstr ""
msgid "UploadLink|click to upload"
msgstr ""
msgid "Use the following registration token during setup:"
msgstr ""
msgid "Use your global notification setting"
msgstr ""
msgid "View open merge request"
msgstr ""
msgid "VisibilityLevel|Internal"
msgstr ""
msgid "VisibilityLevel|Private"
msgstr ""
msgid "VisibilityLevel|Public"
msgstr ""
msgid "VisibilityLevel|Unknown"
msgstr ""
msgid "Want to see the data? Please ask an administrator for access."
msgstr ""
msgid "We don't have enough data to show this stage."
msgstr ""
msgid "Withdraw Access Request"
msgstr ""
msgid "You are going to remove %{group_name}. Removed groups CANNOT be restored! Are you ABSOLUTELY sure?"
msgstr ""
msgid "You are going to remove %{project_name_with_namespace}. Removed project CANNOT be restored! Are you ABSOLUTELY sure?"
msgstr ""
msgid "You are going to remove the fork relationship to source project %{forked_from_project}. Are you ABSOLUTELY sure?"
msgstr ""
msgid "You are going to transfer %{project_name_with_namespace} to another owner. Are you ABSOLUTELY sure?"
msgstr ""
msgid "You can only add files when you are on a branch"
msgstr ""
msgid "You have reached your project limit"
msgstr ""
msgid "You must sign in to star a project"
msgstr ""
msgid "You need permission."
msgstr ""
msgid "You will not get any notifications via email"
msgstr ""
msgid "You will only receive notifications for the events you choose"
msgstr ""
msgid "You will only receive notifications for threads you have participated in"
msgstr ""
msgid "You will receive notifications for any activity"
msgstr ""
msgid "You will receive notifications only for comments in which you were @mentioned"
msgstr ""
msgid "You won't be able to pull or push project code via %{protocol} until you %{set_password_link} on your account"
msgstr ""
msgid "You won't be able to pull or push project code via SSH until you %{add_ssh_key_link} to your profile"
msgstr ""
msgid "Your name"
msgstr ""
msgid "day"
msgid_plural "days"
msgstr[0] ""
msgstr[1] ""
msgid "new merge request"
msgstr ""
msgid "notification emails"
msgstr ""
msgid "parent"
msgid_plural "parents"
msgstr[0] ""
msgstr[1] ""
......@@ -6,7 +6,7 @@ require 'simple_po_parser'
# Disabling this cop to allow for multi-language examples in comments
# rubocop:disable Style/AsciiComments
RSpec.describe Gitlab::I18n::PoLinter do
let(:linter) { described_class.new(po_path: po_path, html_todolist: {}) }
let(:linter) { described_class.new(po_path: po_path) }
let(:po_path) { 'spec/fixtures/valid.po' }
def fake_translation(msgid:, translation:, plural_id: nil, plurals: [])
......@@ -24,8 +24,7 @@ RSpec.describe Gitlab::I18n::PoLinter do
Gitlab::I18n::TranslationEntry.new(
entry_data: data,
nplurals: plurals.size + 1,
html_allowed: nil
nplurals: plurals.size + 1
)
end
......@@ -160,53 +159,6 @@ RSpec.describe Gitlab::I18n::PoLinter do
]
end
end
context 'when an entry contains html on the todolist' do
subject(:linter) { described_class.new(po_path: po_path, html_todolist: todolist) }
let(:po_path) { 'spec/fixtures/potential_html.po' }
let(:todolist) do
{
'String with a legitimate < use' => {
'plural_id' => 'String with lots of < > uses',
'translations' => [
'Translated string with a legitimate < use',
'Translated string with lots of < > uses'
]
}
}
end
it 'does not present an error' do
message_id = 'String with a legitimate < use'
expect(errors[message_id]).to be_nil
end
end
context 'when an entry on the html todolist has changed' do
subject(:linter) { described_class.new(po_path: po_path, html_todolist: todolist) }
let(:po_path) { 'spec/fixtures/potential_html.po' }
let(:todolist) do
{
'String with a legitimate < use' => {
'plural_id' => 'String with lots of < > uses',
'translations' => [
'Translated string with a different legitimate < use',
'Translated string with lots of < > uses'
]
}
}
end
it 'presents an error for the changed component' do
message_id = 'String with a legitimate < use'
expect(errors[message_id])
.to include a_string_starting_with('translation contains < or >.')
end
end
end
describe '#parse_po' do
......@@ -276,8 +228,7 @@ RSpec.describe Gitlab::I18n::PoLinter do
fake_entry = Gitlab::I18n::TranslationEntry.new(
entry_data: { msgid: 'the singular', msgid_plural: 'the plural', 'msgstr[0]' => 'the singular' },
nplurals: 2,
html_allowed: nil
nplurals: 2
)
errors = []
......
......@@ -6,7 +6,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#singular_translation' do
it 'returns the normal `msgstr` for translations without plural' do
data = { msgid: 'Hello world', msgstr: 'Bonjour monde' }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry.singular_translation).to eq('Bonjour monde')
end
......@@ -18,7 +18,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
'msgstr[0]' => 'Bonjour monde',
'msgstr[1]' => 'Bonjour mondes'
}
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry.singular_translation).to eq('Bonjour monde')
end
......@@ -27,7 +27,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#all_translations' do
it 'returns all translations for singular translations' do
data = { msgid: 'Hello world', msgstr: 'Bonjour monde' }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry.all_translations).to eq(['Bonjour monde'])
end
......@@ -39,7 +39,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
'msgstr[0]' => 'Bonjour monde',
'msgstr[1]' => 'Bonjour mondes'
}
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry.all_translations).to eq(['Bonjour monde', 'Bonjour mondes'])
end
......@@ -52,7 +52,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
msgid_plural: 'Hello worlds',
'msgstr[0]' => 'Bonjour monde'
}
entry = described_class.new(entry_data: data, nplurals: 1, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 1)
expect(entry.plural_translations).to eq(['Bonjour monde'])
end
......@@ -65,7 +65,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
'msgstr[1]' => 'Bonjour mondes',
'msgstr[2]' => 'Bonjour tous les mondes'
}
entry = described_class.new(entry_data: data, nplurals: 3, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 3)
expect(entry.plural_translations).to eq(['Bonjour mondes', 'Bonjour tous les mondes'])
end
......@@ -77,7 +77,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
msgid: 'hello world',
msgstr: 'hello'
}
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry).to have_singular_translation
end
......@@ -89,7 +89,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
"msgstr[0]" => 'hello world',
"msgstr[1]" => 'hello worlds'
}
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry).to have_singular_translation
end
......@@ -100,7 +100,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
msgid_plural: 'hello worlds',
"msgstr[0]" => 'hello worlds'
}
entry = described_class.new(entry_data: data, nplurals: 1, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 1)
expect(entry).not_to have_singular_translation
end
......@@ -109,7 +109,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#msgid_contains_newlines' do
it 'is true when the msgid is an array' do
data = { msgid: %w(hello world) }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry.msgid_has_multiple_lines?).to be_truthy
end
......@@ -118,7 +118,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#plural_id_contains_newlines' do
it 'is true when the msgid is an array' do
data = { msgid_plural: %w(hello world) }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry.plural_id_has_multiple_lines?).to be_truthy
end
......@@ -127,7 +127,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#translations_contain_newlines' do
it 'is true when the msgid is an array' do
data = { msgstr: %w(hello world) }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry.translations_have_multiple_lines?).to be_truthy
end
......@@ -135,7 +135,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#contains_unescaped_chars' do
let(:data) { { msgid: '' } }
let(:entry) { described_class.new(entry_data: data, nplurals: 2, html_allowed: nil) }
let(:entry) { described_class.new(entry_data: data, nplurals: 2) }
it 'is true when the msgid is an array' do
string = '「100%確定」'
......@@ -177,7 +177,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#msgid_contains_unescaped_chars' do
it 'is true when the msgid contains a `%`' do
data = { msgid: '「100%確定」' }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry).to receive(:contains_unescaped_chars?).and_call_original
expect(entry.msgid_contains_unescaped_chars?).to be_truthy
......@@ -187,7 +187,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#plural_id_contains_unescaped_chars' do
it 'is true when the plural msgid contains a `%`' do
data = { msgid_plural: '「100%確定」' }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry).to receive(:contains_unescaped_chars?).and_call_original
expect(entry.plural_id_contains_unescaped_chars?).to be_truthy
......@@ -197,7 +197,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
describe '#translations_contain_unescaped_chars' do
it 'is true when the translation contains a `%`' do
data = { msgstr: '「100%確定」' }
entry = described_class.new(entry_data: data, nplurals: 2, html_allowed: nil)
entry = described_class.new(entry_data: data, nplurals: 2)
expect(entry).to receive(:contains_unescaped_chars?).and_call_original
expect(entry.translations_contain_unescaped_chars?).to be_truthy
......@@ -205,7 +205,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
end
describe '#msgid_contains_potential_html?' do
subject(:entry) { described_class.new(entry_data: data, nplurals: 2, html_allowed: nil) }
subject(:entry) { described_class.new(entry_data: data, nplurals: 2) }
context 'when there are no angle brackets in the msgid' do
let(:data) { { msgid: 'String with no brackets' } }
......@@ -225,7 +225,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
end
describe '#plural_id_contains_potential_html?' do
subject(:entry) { described_class.new(entry_data: data, nplurals: 2, html_allowed: nil) }
subject(:entry) { described_class.new(entry_data: data, nplurals: 2) }
context 'when there are no angle brackets in the plural_id' do
let(:data) { { msgid_plural: 'String with no brackets' } }
......@@ -245,7 +245,7 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
end
describe '#translations_contain_potential_html?' do
subject(:entry) { described_class.new(entry_data: data, nplurals: 2, html_allowed: nil) }
subject(:entry) { described_class.new(entry_data: data, nplurals: 2) }
context 'when there are no angle brackets in the translations' do
let(:data) { { msgstr: 'This string has no angle brackets' } }
......@@ -263,78 +263,4 @@ RSpec.describe Gitlab::I18n::TranslationEntry do
end
end
end
describe '#msgid_html_allowed?' do
subject(:entry) do
described_class.new(entry_data: { msgid: 'String with a <strong>' }, nplurals: 2, html_allowed: html_todo)
end
context 'when the html in the string is in the todolist' do
let(:html_todo) { { 'plural_id' => nil, 'translations' => [] } }
it 'returns true' do
expect(entry.msgid_html_allowed?).to be true
end
end
context 'when the html in the string is not in the todolist' do
let(:html_todo) { nil }
it 'returns false' do
expect(entry.msgid_html_allowed?).to be false
end
end
end
describe '#plural_id_html_allowed?' do
subject(:entry) do
described_class.new(entry_data: { msgid_plural: 'String with many <strong>' }, nplurals: 2, html_allowed: html_todo)
end
context 'when the html in the string is in the todolist' do
let(:html_todo) { { 'plural_id' => 'String with many <strong>', 'translations' => [] } }
it 'returns true' do
expect(entry.plural_id_html_allowed?).to be true
end
end
context 'when the html in the string is not in the todolist' do
let(:html_todo) { { 'plural_id' => 'String with some <strong>', 'translations' => [] } }
it 'returns false' do
expect(entry.plural_id_html_allowed?).to be false
end
end
end
describe '#translations_html_allowed?' do
subject(:entry) do
described_class.new(entry_data: { msgstr: 'String with a <strong>' }, nplurals: 2, html_allowed: html_todo)
end
context 'when the html in the string is in the todolist' do
let(:html_todo) { { 'plural_id' => nil, 'translations' => ['String with a <strong>'] } }
it 'returns true' do
expect(entry.translations_html_allowed?).to be true
end
end
context 'when the html in the string is not in the todolist' do
let(:html_todo) { { 'plural_id' => nil, 'translations' => ['String with a different <strong>'] } }
it 'returns false' do
expect(entry.translations_html_allowed?).to be false
end
end
context 'when the todolist only has the msgid' do
let(:html_todo) { { 'plural_id' => nil, 'translations' => nil } }
it 'returns false' do
expect(entry.translations_html_allowed?).to be false
end
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment