summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLarry Li <larryli@qq.com>2016-03-24 06:21:03 +0800
committerLarry Li <larryli@qq.com>2016-03-24 06:21:03 +0800
commitb0a44cb0c867b2eec84ba8bb4ac303d829848195 (patch)
tree70e71494ecbe50706ba756c54ac3d6e440dcd7ae
parent3192db707183244bb21af382fe709c963ae96348 (diff)
downloadgitlab-ce-b0a44cb0c867b2eec84ba8bb4ac303d829848195.tar.gz
导入上一版本 8.5 汉化v8.6.0.zh0
Signed-off-by: Larry Li <larryli@qq.com>
-rw-r--r--app/assets/javascripts/ci/build.coffee4
-rw-r--r--app/assets/javascripts/copy_to_clipboard.js.coffee2
-rw-r--r--app/assets/javascripts/groups_select.js.coffee2
-rw-r--r--app/assets/javascripts/importer_status.js.coffee4
-rw-r--r--app/assets/javascripts/lib/jquery.timeago.js28
-rw-r--r--app/assets/javascripts/markdown_preview.js.coffee4
-rw-r--r--app/assets/javascripts/merge_request_widget.js.coffee2
-rw-r--r--app/assets/javascripts/milestone.js.coffee8
-rw-r--r--app/assets/javascripts/namespace_select.js.coffee2
-rw-r--r--app/assets/javascripts/project.js.coffee10
-rw-r--r--app/assets/javascripts/project_select.js.coffee4
-rw-r--r--app/assets/javascripts/protected_branches.js.coffee2
-rw-r--r--app/assets/javascripts/stat_graph_contributors.js.coffee6
-rw-r--r--app/assets/javascripts/users_select.js.coffee8
-rw-r--r--app/controllers/admin/appearances_controller.rb8
-rw-r--r--app/controllers/admin/application_settings_controller.rb3
-rw-r--r--app/controllers/admin/applications_controller.rb5
-rw-r--r--app/controllers/admin/broadcast_messages_controller.rb2
-rw-r--r--app/controllers/admin/groups_controller.rb9
-rw-r--r--app/controllers/admin/hooks_controller.rb3
-rw-r--r--app/controllers/admin/keys_controller.rb5
-rw-r--r--app/controllers/admin/services_controller.rb5
-rw-r--r--app/controllers/admin/users_controller.rb27
-rw-r--r--app/controllers/application_controller.rb7
-rw-r--r--app/controllers/ci/lints_controller.rb4
-rw-r--r--app/controllers/groups/group_members_controller.rb12
-rw-r--r--app/controllers/groups_controller.rb2
-rw-r--r--app/controllers/import/google_code_controller.rb13
-rw-r--r--app/controllers/invites_controller.rb21
-rw-r--r--app/controllers/omniauth_callbacks_controller.rb10
-rw-r--r--app/controllers/passwords_controller.rb3
-rw-r--r--app/controllers/profiles/notifications_controller.rb5
-rw-r--r--app/controllers/profiles/passwords_controller.rb11
-rw-r--r--app/controllers/profiles/preferences_controller.rb7
-rw-r--r--app/controllers/profiles/two_factor_auths_controller.rb4
-rw-r--r--app/controllers/profiles_controller.rb7
-rw-r--r--app/controllers/projects/application_controller.rb2
-rw-r--r--app/controllers/projects/blob_controller.rb5
-rw-r--r--app/controllers/projects/forks_controller.rb2
-rw-r--r--app/controllers/projects/hooks_controller.rb7
-rw-r--r--app/controllers/projects/labels_controller.rb2
-rw-r--r--app/controllers/projects/services_controller.rb7
-rw-r--r--app/controllers/projects/wikis_controller.rb11
-rw-r--r--app/controllers/projects_controller.rb12
-rw-r--r--app/controllers/registrations_controller.rb3
-rw-r--r--app/helpers/appearances_helper.rb3
-rw-r--r--app/helpers/application_helper.rb16
-rw-r--r--app/helpers/blob_helper.rb20
-rw-r--r--app/helpers/broadcast_messages_helper.rb6
-rw-r--r--app/helpers/button_helper.rb4
-rw-r--r--app/helpers/ci_status_helper.rb4
-rw-r--r--app/helpers/commits_helper.rb20
-rw-r--r--app/helpers/diff_helper.rb4
-rw-r--r--app/helpers/emails_helper.rb13
-rw-r--r--app/helpers/events_helper.rb5
-rw-r--r--app/helpers/gitlab_markdown_helper.rb31
-rw-r--r--app/helpers/groups_helper.rb7
-rw-r--r--app/helpers/issues_helper.rb3
-rw-r--r--app/helpers/milestones_helper.rb4
-rw-r--r--app/helpers/namespaces_helper.rb4
-rw-r--r--app/helpers/notes_helper.rb7
-rw-r--r--app/helpers/notifications_helper.rb11
-rw-r--r--app/helpers/preferences_helper.rb18
-rw-r--r--app/helpers/projects_helper.rb19
-rw-r--r--app/helpers/search_helper.rb25
-rw-r--r--app/helpers/selects_helper.rb3
-rw-r--r--app/helpers/sorting_helper.rb25
-rw-r--r--app/helpers/time_helper.rb6
-rw-r--r--app/helpers/todos_helper.rb14
-rw-r--r--app/helpers/visibility_level_helper.rb15
-rw-r--r--app/models/concerns/taskable.rb2
-rw-r--r--app/models/issue.rb4
-rw-r--r--app/models/label.rb4
-rw-r--r--app/models/merge_request.rb1
-rw-r--r--app/models/milestone.rb5
-rw-r--r--app/models/notification.rb21
-rw-r--r--app/services/merge_requests/build_service.rb3
-rw-r--r--app/views/abuse_report_mailer/notify.html.haml6
-rw-r--r--app/views/abuse_report_mailer/notify.text.haml4
-rw-r--r--app/views/admin/abuse_reports/_abuse_report.html.haml16
-rw-r--r--app/views/admin/abuse_reports/index.html.haml14
-rw-r--r--app/views/admin/appearances/_form.html.haml26
-rw-r--r--app/views/admin/appearances/preview.html.haml14
-rw-r--r--app/views/admin/appearances/show.html.haml6
-rw-r--r--app/views/admin/application_settings/_form.html.haml16
-rw-r--r--app/views/admin/application_settings/show.html.haml4
-rw-r--r--app/views/admin/applications/_delete_form.html.haml2
-rw-r--r--app/views/admin/applications/_form.html.haml14
-rw-r--r--app/views/admin/applications/edit.html.haml4
-rw-r--r--app/views/admin/applications/index.html.haml16
-rw-r--r--app/views/admin/applications/new.html.haml4
-rw-r--r--app/views/admin/applications/show.html.haml12
-rw-r--r--app/views/admin/background_jobs/show.html.haml14
-rw-r--r--app/views/admin/broadcast_messages/edit.html.haml2
-rw-r--r--app/views/admin/broadcast_messages/index.html.haml19
-rw-r--r--app/views/admin/builds/_build.html.haml4
-rw-r--r--app/views/admin/builds/index.html.haml28
-rw-r--r--app/views/admin/dashboard/index.html.haml46
-rw-r--r--app/views/admin/deploy_keys/index.html.haml16
-rw-r--r--app/views/admin/deploy_keys/new.html.haml16
-rw-r--r--app/views/admin/groups/_form.html.haml10
-rw-r--r--app/views/admin/groups/edit.html.haml4
-rw-r--r--app/views/admin/groups/index.html.haml17
-rw-r--r--app/views/admin/groups/new.html.haml4
-rw-r--r--app/views/admin/groups/show.html.haml15
-rw-r--r--app/views/admin/hooks/index.html.haml23
-rw-r--r--app/views/admin/identities/_form.html.haml6
-rw-r--r--app/views/admin/identities/_identity.html.haml6
-rw-r--r--app/views/admin/identities/edit.html.haml4
-rw-r--r--app/views/admin/identities/index.html.haml10
-rw-r--r--app/views/admin/identities/new.html.haml4
-rw-r--r--app/views/admin/keys/show.html.haml2
-rw-r--r--app/views/admin/labels/_form.html.haml14
-rw-r--r--app/views/admin/labels/edit.html.haml4
-rw-r--r--app/views/admin/labels/index.html.haml8
-rw-r--r--app/views/admin/labels/new.html.haml4
-rw-r--r--app/views/admin/logs/show.html.haml6
-rw-r--r--app/views/admin/projects/index.html.haml28
-rw-r--r--app/views/admin/projects/show.html.haml38
-rw-r--r--app/views/admin/runners/_runner.html.haml24
-rw-r--r--app/views/admin/runners/index.html.haml52
-rw-r--r--app/views/admin/runners/show.html.haml50
-rw-r--r--app/views/admin/services/_form.html.haml4
-rw-r--r--app/views/admin/services/edit.html.haml2
-rw-r--r--app/views/admin/services/index.html.haml14
-rw-r--r--app/views/admin/users/_form.html.haml14
-rw-r--r--app/views/admin/users/_head.html.haml18
-rw-r--r--app/views/admin/users/_profile.html.haml14
-rw-r--r--app/views/admin/users/edit.html.haml4
-rw-r--r--app/views/admin/users/groups.html.haml8
-rw-r--r--app/views/admin/users/index.html.haml4
-rw-r--r--app/views/admin/users/new.html.haml4
-rw-r--r--app/views/admin/users/projects.html.haml16
-rw-r--r--app/views/admin/users/show.html.haml62
-rw-r--r--app/views/ci/errors/show.haml2
-rw-r--r--app/views/ci/lints/_create.html.haml26
-rw-r--r--app/views/ci/lints/show.html.haml6
-rw-r--r--app/views/ci/projects/index.html.haml16
-rw-r--r--app/views/ci/shared/_guide.html.haml14
-rw-r--r--app/views/ci/shared/_no_runners.html.haml4
-rw-r--r--app/views/dashboard/_activity_head.html.haml4
-rw-r--r--app/views/dashboard/_groups_head.html.haml10
-rw-r--r--app/views/dashboard/_snippets_head.html.haml8
-rw-r--r--app/views/dashboard/activity.html.haml6
-rw-r--r--app/views/dashboard/groups/index.html.haml4
-rw-r--r--app/views/dashboard/issues.html.haml8
-rw-r--r--app/views/dashboard/merge_requests.html.haml6
-rw-r--r--app/views/dashboard/milestones/index.html.haml8
-rw-r--r--app/views/dashboard/projects/_zero_authorized_projects.html.haml6
-rw-r--r--app/views/dashboard/projects/index.html.haml6
-rw-r--r--app/views/dashboard/projects/starred.html.haml8
-rw-r--r--app/views/dashboard/snippets/index.html.haml16
-rw-r--r--app/views/dashboard/todos/index.html.haml10
-rw-r--r--app/views/devise/confirmations/new.html.haml6
-rw-r--r--app/views/devise/mailer/confirmation_instructions.html.erb8
-rw-r--r--app/views/devise/mailer/reset_password_instructions.html.erb10
-rw-r--r--app/views/devise/mailer/unlock_instructions.html.haml9
-rw-r--r--app/views/devise/passwords/edit.html.haml10
-rw-r--r--app/views/devise/passwords/new.html.haml6
-rw-r--r--app/views/devise/registrations/edit.html.erb14
-rw-r--r--app/views/devise/registrations/new.html.haml2
-rw-r--r--app/views/devise/sessions/_new_base.html.haml10
-rw-r--r--app/views/devise/sessions/_new_ldap.html.haml8
-rw-r--r--app/views/devise/sessions/new.html.haml4
-rw-r--r--app/views/devise/sessions/two_factor.html.haml8
-rw-r--r--app/views/devise/shared/_links.erb10
-rw-r--r--app/views/devise/shared/_omniauth_box.html.haml2
-rw-r--r--app/views/devise/shared/_sign_in_link.html.haml4
-rw-r--r--app/views/devise/shared/_signin_box.html.haml6
-rw-r--r--app/views/devise/shared/_signup_box.html.haml20
-rw-r--r--app/views/devise/unlocks/new.html.haml6
-rw-r--r--app/views/doorkeeper/applications/edit.html.haml4
-rw-r--r--app/views/doorkeeper/applications/new.html.haml4
-rw-r--r--app/views/doorkeeper/applications/show.html.haml12
-rw-r--r--app/views/doorkeeper/authorizations/error.html.haml2
-rw-r--r--app/views/doorkeeper/authorizations/new.html.haml16
-rw-r--r--app/views/doorkeeper/authorizations/show.html.haml2
-rw-r--r--app/views/doorkeeper/authorized_applications/_delete_form.html.haml2
-rw-r--r--app/views/doorkeeper/authorized_applications/index.html.haml6
-rw-r--r--app/views/email_rejection_mailer/rejection.html.haml2
-rw-r--r--app/views/email_rejection_mailer/rejection.text.haml2
-rw-r--r--app/views/errors/access_denied.html.haml8
-rw-r--r--app/views/errors/encoding.html.haml6
-rw-r--r--app/views/errors/git_not_found.html.haml7
-rw-r--r--app/views/errors/not_found.html.haml6
-rw-r--r--app/views/errors/omniauth_error.html.haml4
-rw-r--r--app/views/events/_event_push.atom.haml6
-rw-r--r--app/views/events/event/_created_project.html.haml2
-rw-r--r--app/views/events/event/_note.html.haml2
-rw-r--r--app/views/events/event/_push.html.haml10
-rw-r--r--app/views/explore/_head.html.haml4
-rw-r--r--app/views/explore/groups/index.html.haml10
-rw-r--r--app/views/explore/projects/_nav.html.haml6
-rw-r--r--app/views/explore/projects/index.html.haml4
-rw-r--r--app/views/explore/projects/starred.html.haml4
-rw-r--r--app/views/explore/projects/trending.html.haml4
-rw-r--r--app/views/explore/snippets/index.html.haml10
-rw-r--r--app/views/groups/edit.html.haml4
-rw-r--r--app/views/groups/group_members/_group_member.html.haml22
-rw-r--r--app/views/groups/group_members/_new_group_member.html.haml12
-rw-r--r--app/views/groups/group_members/index.html.haml14
-rw-r--r--app/views/groups/issues.html.haml12
-rw-r--r--app/views/groups/merge_requests.html.haml12
-rw-r--r--app/views/groups/milestones/_header_title.html.haml2
-rw-r--r--app/views/groups/milestones/index.html.haml12
-rw-r--r--app/views/groups/new.html.haml12
-rw-r--r--app/views/groups/projects.html.haml16
-rw-r--r--app/views/groups/show.html.haml4
-rw-r--r--app/views/help/_shortcuts.html.haml2
-rw-r--r--app/views/help/index.html.haml21
-rw-r--r--app/views/help/ui.html.haml4
-rw-r--r--app/views/import/base/create.js.haml8
-rw-r--r--app/views/import/bitbucket/status.html.haml40
-rw-r--r--app/views/import/fogbugz/new.html.haml19
-rw-r--r--app/views/import/fogbugz/new_user_map.html.haml18
-rw-r--r--app/views/import/fogbugz/status.html.haml28
-rw-r--r--app/views/import/github/status.html.haml22
-rw-r--r--app/views/import/gitlab/status.html.haml22
-rw-r--r--app/views/import/gitorious/status.html.haml22
-rw-r--r--app/views/import/google_code/new.html.haml42
-rw-r--r--app/views/import/google_code/new_user_map.html.haml20
-rw-r--r--app/views/import/google_code/status.html.haml43
-rw-r--r--app/views/invites/show.html.haml23
-rw-r--r--app/views/layouts/_collapse_button.html.haml4
-rw-r--r--app/views/layouts/_page.html.haml6
-rw-r--r--app/views/layouts/admin.html.haml4
-rw-r--r--app/views/layouts/ci/_page.html.haml6
-rw-r--r--app/views/layouts/ci/notify.html.haml2
-rw-r--r--app/views/layouts/dashboard.html.haml4
-rw-r--r--app/views/layouts/devise.html.haml15
-rw-r--r--app/views/layouts/explore.html.haml4
-rw-r--r--app/views/layouts/group_settings.html.haml4
-rw-r--r--app/views/layouts/header/_default.html.haml2
-rw-r--r--app/views/layouts/help.html.haml4
-rw-r--r--app/views/layouts/nav/_admin.html.haml68
-rw-r--r--app/views/layouts/nav/_group_settings.html.haml12
-rw-r--r--app/views/layouts/nav/_project_settings.html.haml8
-rw-r--r--app/views/layouts/profile.html.haml4
-rw-r--r--app/views/layouts/project_settings.html.haml4
-rw-r--r--app/views/layouts/search.html.haml4
-rw-r--r--app/views/layouts/snippets.html.haml2
-rw-r--r--app/views/notify/_reassigned_issuable_email.html.haml8
-rw-r--r--app/views/notify/closed_issue_email.html.haml2
-rw-r--r--app/views/notify/closed_issue_email.text.haml4
-rw-r--r--app/views/notify/closed_merge_request_email.html.haml2
-rw-r--r--app/views/notify/closed_merge_request_email.text.haml8
-rw-r--r--app/views/notify/group_access_granted_email.html.haml2
-rw-r--r--app/views/notify/group_access_granted_email.text.erb2
-rw-r--r--app/views/notify/group_invite_accepted_email.html.haml6
-rw-r--r--app/views/notify/group_invite_accepted_email.text.erb2
-rw-r--r--app/views/notify/group_invite_declined_email.html.haml2
-rw-r--r--app/views/notify/group_invite_declined_email.text.erb2
-rw-r--r--app/views/notify/group_member_invited_email.html.haml13
-rw-r--r--app/views/notify/group_member_invited_email.text.erb6
-rw-r--r--app/views/notify/issue_status_changed_email.html.haml2
-rw-r--r--app/views/notify/issue_status_changed_email.text.erb4
-rw-r--r--app/views/notify/merge_request_status_email.html.haml2
-rw-r--r--app/views/notify/merge_request_status_email.text.haml8
-rw-r--r--app/views/notify/merged_merge_request_email.html.haml2
-rw-r--r--app/views/notify/merged_merge_request_email.text.haml8
-rw-r--r--app/views/notify/new_email_email.html.haml10
-rw-r--r--app/views/notify/new_email_email.text.erb8
-rw-r--r--app/views/notify/new_issue_email.html.haml2
-rw-r--r--app/views/notify/new_issue_email.text.erb8
-rw-r--r--app/views/notify/new_merge_request_email.html.haml2
-rw-r--r--app/views/notify/new_merge_request_email.text.erb6
-rw-r--r--app/views/notify/new_ssh_key_email.html.haml10
-rw-r--r--app/views/notify/new_ssh_key_email.text.erb8
-rw-r--r--app/views/notify/new_user_email.html.haml10
-rw-r--r--app/views/notify/new_user_email.text.erb8
-rw-r--r--app/views/notify/note_commit_email.text.erb4
-rw-r--r--app/views/notify/note_issue_email.text.erb4
-rw-r--r--app/views/notify/note_merge_request_email.html.haml2
-rw-r--r--app/views/notify/note_merge_request_email.text.erb2
-rw-r--r--app/views/notify/project_access_granted_email.html.haml2
-rw-r--r--app/views/notify/project_access_granted_email.text.erb2
-rw-r--r--app/views/notify/project_invite_accepted_email.html.haml6
-rw-r--r--app/views/notify/project_invite_accepted_email.text.erb2
-rw-r--r--app/views/notify/project_invite_declined_email.html.haml4
-rw-r--r--app/views/notify/project_invite_declined_email.text.erb2
-rw-r--r--app/views/notify/project_member_invited_email.html.haml13
-rw-r--r--app/views/notify/project_member_invited_email.text.erb6
-rw-r--r--app/views/notify/project_was_moved_email.html.haml8
-rw-r--r--app/views/notify/project_was_moved_email.text.erb8
-rw-r--r--app/views/notify/repository_push_email.html.haml20
-rw-r--r--app/views/notify/repository_push_email.text.haml18
-rw-r--r--app/views/profiles/keys/_key_details.html.haml10
-rw-r--r--app/views/profiles/keys/show.html.haml2
-rw-r--r--app/views/profiles/notifications/update.js.haml4
-rw-r--r--app/views/profiles/passwords/new.html.haml18
-rw-r--r--app/views/profiles/two_factor_auths/_codes.html.haml10
-rw-r--r--app/views/profiles/two_factor_auths/codes.html.haml4
-rw-r--r--app/views/profiles/two_factor_auths/create.html.haml4
-rw-r--r--app/views/profiles/update_username.js.haml4
-rw-r--r--app/views/projects/_activity.html.haml2
-rw-r--r--app/views/projects/_bitbucket_import_modal.html.haml10
-rw-r--r--app/views/projects/_commit_button.html.haml4
-rw-r--r--app/views/projects/_find_file_link.html.haml6
-rw-r--r--app/views/projects/_github_import_modal.html.haml10
-rw-r--r--app/views/projects/_gitlab_import_modal.html.haml10
-rw-r--r--app/views/projects/_home_panel.html.haml6
-rw-r--r--app/views/projects/_last_commit.html.haml6
-rw-r--r--app/views/projects/_last_push.html.haml11
-rw-r--r--app/views/projects/_md_preview.html.haml10
-rw-r--r--app/views/projects/_readme.html.haml13
-rw-r--r--app/views/projects/_zen.html.haml2
-rw-r--r--app/views/projects/activity.html.haml4
-rw-r--r--app/views/projects/artifacts/browse.html.haml10
-rw-r--r--app/views/projects/blob/_actions.html.haml10
-rw-r--r--app/views/projects/blob/_download.html.haml2
-rw-r--r--app/views/projects/blob/_header_title.html.haml2
-rw-r--r--app/views/projects/blob/_text.html.haml2
-rw-r--r--app/views/projects/blob/_upload.html.haml6
-rw-r--r--app/views/projects/blob/edit.html.haml4
-rw-r--r--app/views/projects/blob/preview.html.haml2
-rw-r--r--app/views/projects/blob/show.html.haml4
-rw-r--r--app/views/projects/branches/_branch.html.haml20
-rw-r--r--app/views/projects/branches/index.html.haml16
-rw-r--r--app/views/projects/branches/new.html.haml14
-rw-r--r--app/views/projects/builds/_header_title.html.haml2
-rw-r--r--app/views/projects/builds/show.html.haml28
-rw-r--r--app/views/projects/buttons/_dropdown.html.haml16
-rw-r--r--app/views/projects/buttons/_fork.html.haml8
-rw-r--r--app/views/projects/buttons/_notifications.html.haml2
-rw-r--r--app/views/projects/buttons/_star.html.haml10
-rw-r--r--app/views/projects/commit/_ci_menu.html.haml4
-rw-r--r--app/views/projects/commit/_commit_box.html.haml18
-rw-r--r--app/views/projects/commit/builds.html.haml2
-rw-r--r--app/views/projects/commit/show.html.haml2
-rw-r--r--app/views/projects/commits/_commit.html.haml3
-rw-r--r--app/views/projects/commits/_commits.html.haml4
-rw-r--r--app/views/projects/commits/_header_title.html.haml2
-rw-r--r--app/views/projects/commits/show.html.haml12
-rw-r--r--app/views/projects/compare/_form.html.haml12
-rw-r--r--app/views/projects/compare/index.html.haml12
-rw-r--r--app/views/projects/compare/show.html.haml8
-rw-r--r--app/views/projects/deploy_keys/_deploy_key.html.haml10
-rw-r--r--app/views/projects/deploy_keys/_form.html.haml13
-rw-r--r--app/views/projects/deploy_keys/index.html.haml28
-rw-r--r--app/views/projects/deploy_keys/new.html.haml4
-rw-r--r--app/views/projects/diffs/_file.html.haml2
-rw-r--r--app/views/projects/diffs/_image.html.haml14
-rw-r--r--app/views/projects/diffs/_parallel_view.html.haml2
-rw-r--r--app/views/projects/diffs/_stats.html.haml12
-rw-r--r--app/views/projects/diffs/_text_file.html.haml4
-rw-r--r--app/views/projects/edit.html.haml48
-rw-r--r--app/views/projects/empty.html.haml4
-rw-r--r--app/views/projects/find_file/show.html.haml6
-rw-r--r--app/views/projects/forks/error.html.haml12
-rw-r--r--app/views/projects/forks/new.html.haml24
-rw-r--r--app/views/projects/graphs/_head.html.haml8
-rw-r--r--app/views/projects/graphs/_header_title.html.haml2
-rw-r--r--app/views/projects/graphs/ci.html.haml4
-rw-r--r--app/views/projects/graphs/ci/_build_times.haml2
-rw-r--r--app/views/projects/graphs/ci/_builds.haml12
-rw-r--r--app/views/projects/graphs/ci/_overall.haml18
-rw-r--r--app/views/projects/graphs/commits.html.haml24
-rw-r--r--app/views/projects/graphs/languages.html.haml4
-rw-r--r--app/views/projects/graphs/show.html.haml8
-rw-r--r--app/views/projects/imports/new.html.haml8
-rw-r--r--app/views/projects/imports/show.html.haml8
-rw-r--r--app/views/projects/issues/_closed_by_box.html.haml4
-rw-r--r--app/views/projects/issues/_header_title.html.haml2
-rw-r--r--app/views/projects/issues/_issue.html.haml10
-rw-r--r--app/views/projects/issues/_issues.html.haml2
-rw-r--r--app/views/projects/issues/_merge_requests.html.haml6
-rw-r--r--app/views/projects/issues/edit.html.haml4
-rw-r--r--app/views/projects/issues/index.html.haml8
-rw-r--r--app/views/projects/issues/new.html.haml4
-rw-r--r--app/views/projects/issues/show.html.haml2
-rw-r--r--app/views/projects/labels/_form.html.haml6
-rw-r--r--app/views/projects/labels/_header_title.html.haml2
-rw-r--r--app/views/projects/labels/edit.html.haml4
-rw-r--r--app/views/projects/labels/index.html.haml10
-rw-r--r--app/views/projects/labels/new.html.haml4
-rw-r--r--app/views/projects/merge_requests/_head.html.haml2
-rw-r--r--app/views/projects/merge_requests/_header_title.html.haml2
-rw-r--r--app/views/projects/merge_requests/_merge_request.html.haml10
-rw-r--r--app/views/projects/merge_requests/_merge_requests.html.haml2
-rw-r--r--app/views/projects/merge_requests/_new_compare.html.haml12
-rw-r--r--app/views/projects/merge_requests/_new_submit.html.haml8
-rw-r--r--app/views/projects/merge_requests/edit.html.haml4
-rw-r--r--app/views/projects/merge_requests/index.html.haml6
-rw-r--r--app/views/projects/merge_requests/invalid.html.haml18
-rw-r--r--app/views/projects/merge_requests/new.html.haml2
-rw-r--r--app/views/projects/merge_requests/show/_commits.html.haml2
-rw-r--r--app/views/projects/merge_requests/show/_how_to_merge.html.haml27
-rw-r--r--app/views/projects/merge_requests/widget/_closed.html.haml8
-rw-r--r--app/views/projects/merge_requests/widget/_heading.html.haml22
-rw-r--r--app/views/projects/merge_requests/widget/_locked.html.haml4
-rw-r--r--app/views/projects/merge_requests/widget/_merged.html.haml20
-rw-r--r--app/views/projects/merge_requests/widget/_merged_buttons.haml2
-rw-r--r--app/views/projects/merge_requests/widget/_open.html.haml4
-rw-r--r--app/views/projects/merge_requests/widget/open/_accept.html.haml16
-rw-r--r--app/views/projects/merge_requests/widget/open/_archived.html.haml4
-rw-r--r--app/views/projects/merge_requests/widget/open/_check.html.haml2
-rw-r--r--app/views/projects/merge_requests/widget/open/_conflicts.html.haml8
-rw-r--r--app/views/projects/merge_requests/widget/open/_merge_when_build_succeeds.html.haml16
-rw-r--r--app/views/projects/merge_requests/widget/open/_missing_branch.html.haml12
-rw-r--r--app/views/projects/merge_requests/widget/open/_not_allowed.html.haml4
-rw-r--r--app/views/projects/merge_requests/widget/open/_nothing.html.haml7
-rw-r--r--app/views/projects/merge_requests/widget/open/_reload.html.haml4
-rw-r--r--app/views/projects/milestones/_form.html.haml28
-rw-r--r--app/views/projects/milestones/_header_title.html.haml2
-rw-r--r--app/views/projects/milestones/edit.html.haml4
-rw-r--r--app/views/projects/milestones/index.html.haml8
-rw-r--r--app/views/projects/milestones/new.html.haml4
-rw-r--r--app/views/projects/milestones/show.html.haml20
-rw-r--r--app/views/projects/network/_head.html.haml2
-rw-r--r--app/views/projects/network/show.html.haml6
-rw-r--r--app/views/projects/new.html.haml30
-rw-r--r--app/views/projects/no_repo.html.haml12
-rw-r--r--app/views/projects/notes/_hints.html.haml4
-rw-r--r--app/views/projects/notes/_note.html.haml4
-rw-r--r--app/views/projects/notes/_notes_with_form.html.haml10
-rw-r--r--app/views/projects/notes/discussions/_active.html.haml8
-rw-r--r--app/views/projects/notes/discussions/_commit.html.haml6
-rw-r--r--app/views/projects/notes/discussions/_outdated.html.haml8
-rw-r--r--app/views/projects/project_members/_group_members.html.haml6
-rw-r--r--app/views/projects/project_members/_header_title.html.haml2
-rw-r--r--app/views/projects/project_members/_new_project_member.html.haml12
-rw-r--r--app/views/projects/project_members/_project_member.html.haml22
-rw-r--r--app/views/projects/project_members/_team.html.haml6
-rw-r--r--app/views/projects/project_members/import.html.haml14
-rw-r--r--app/views/projects/project_members/index.html.haml10
-rw-r--r--app/views/projects/protected_branches/_branches_list.html.haml14
-rw-r--r--app/views/projects/protected_branches/index.html.haml20
-rw-r--r--app/views/projects/releases/edit.html.haml4
-rw-r--r--app/views/projects/repositories/_feed.html.haml2
-rw-r--r--app/views/projects/runners/_runner.html.haml6
-rw-r--r--app/views/projects/runners/_shared_runners.html.haml18
-rw-r--r--app/views/projects/runners/_specific_runners.html.haml18
-rw-r--r--app/views/projects/runners/edit.html.haml16
-rw-r--r--app/views/projects/runners/index.html.haml18
-rw-r--r--app/views/projects/runners/show.html.haml28
-rw-r--r--app/views/projects/services/_form.html.haml6
-rw-r--r--app/views/projects/services/edit.html.haml2
-rw-r--r--app/views/projects/services/index.html.haml14
-rw-r--r--app/views/projects/show.html.haml22
-rw-r--r--app/views/projects/snippets/_actions.html.haml10
-rw-r--r--app/views/projects/snippets/_header_title.html.haml2
-rw-r--r--app/views/projects/snippets/edit.html.haml4
-rw-r--r--app/views/projects/snippets/index.html.haml8
-rw-r--r--app/views/projects/snippets/new.html.haml4
-rw-r--r--app/views/projects/snippets/show.html.haml4
-rw-r--r--app/views/projects/tags/_download.html.haml8
-rw-r--r--app/views/projects/tags/_tag.html.haml6
-rw-r--r--app/views/projects/tags/index.html.haml10
-rw-r--r--app/views/projects/tags/new.html.haml2
-rw-r--r--app/views/projects/tags/show.html.haml14
-rw-r--r--app/views/projects/tree/_spinner.html.haml2
-rw-r--r--app/views/projects/tree/_tree_content.html.haml10
-rw-r--r--app/views/projects/tree/_tree_header.html.haml22
-rw-r--r--app/views/projects/tree/show.html.haml6
-rw-r--r--app/views/projects/triggers/_trigger.html.haml6
-rw-r--r--app/views/projects/triggers/index.html.haml20
-rw-r--r--app/views/projects/variables/show.html.haml22
-rw-r--r--app/views/projects/wikis/_form.html.haml14
-rw-r--r--app/views/projects/wikis/_header_title.html.haml2
-rw-r--r--app/views/projects/wikis/_main_links.html.haml8
-rw-r--r--app/views/projects/wikis/_nav.html.haml8
-rw-r--r--app/views/projects/wikis/_new.html.haml6
-rw-r--r--app/views/projects/wikis/edit.html.haml4
-rw-r--r--app/views/projects/wikis/empty.html.haml6
-rw-r--r--app/views/projects/wikis/git_access.html.haml10
-rw-r--r--app/views/projects/wikis/history.html.haml14
-rw-r--r--app/views/projects/wikis/pages.html.haml4
-rw-r--r--app/views/projects/wikis/show.html.haml8
-rw-r--r--app/views/search/_category.html.haml26
-rw-r--r--app/views/search/_results.html.haml7
-rw-r--r--app/views/search/results/_empty.html.haml3
-rw-r--r--app/views/search/results/_issue.html.haml2
-rw-r--r--app/views/search/results/_merge_request.html.haml4
-rw-r--r--app/views/search/results/_note.html.haml4
-rw-r--r--app/views/search/results/_snippet_blob.html.haml6
-rw-r--r--app/views/search/results/_snippet_title.html.haml4
-rw-r--r--app/views/shared/_choose_group_avatar_button.html.haml6
-rw-r--r--app/views/shared/_commit_message_container.html.haml5
-rw-r--r--app/views/shared/_confirm_modal.html.haml12
-rw-r--r--app/views/shared/_event_filter.html.haml8
-rw-r--r--app/views/shared/_field.html.haml2
-rw-r--r--app/views/shared/_group_form.html.haml14
-rw-r--r--app/views/shared/_import_form.html.haml10
-rw-r--r--app/views/shared/_merge_requests.html.haml2
-rw-r--r--app/views/shared/_milestone_expired.html.haml2
-rw-r--r--app/views/shared/_milestones_filter.html.haml6
-rw-r--r--app/views/shared/_new_commit_form.html.haml4
-rw-r--r--app/views/shared/_no_password.html.haml6
-rw-r--r--app/views/shared/_outdated_browser.html.haml8
-rw-r--r--app/views/shared/_project_limit.html.haml6
-rw-r--r--app/views/shared/_promo.html.haml7
-rw-r--r--app/views/shared/_service_settings.html.haml28
-rw-r--r--app/views/shared/_visibility_level.html.haml2
-rw-r--r--app/views/shared/_visibility_radios.html.haml2
-rw-r--r--app/views/shared/groups/_group.html.haml2
-rw-r--r--app/views/shared/issuable/_nav.html.haml14
-rw-r--r--app/views/shared/issuable/_search_form.html.haml2
-rw-r--r--app/views/shared/issuable/_sidebar.html.haml2
-rw-r--r--app/views/shared/snippets/_blob.html.haml2
-rw-r--r--app/views/shared/snippets/_form.html.haml14
-rw-r--r--app/views/shared/snippets/_header.html.haml4
-rw-r--r--app/views/snippets/_actions.html.haml10
-rw-r--r--app/views/snippets/_snippets.html.haml2
-rw-r--r--app/views/snippets/edit.html.haml4
-rw-r--r--app/views/snippets/index.html.haml6
-rw-r--r--app/views/snippets/new.html.haml4
-rw-r--r--app/views/snippets/show.html.haml4
-rw-r--r--app/views/users/calendar.html.haml2
-rw-r--r--app/views/users/calendar_activities.html.haml2
-rw-r--r--app/views/users/show.atom.builder2
-rw-r--r--app/views/users/show.html.haml2
-rw-r--r--config/application.rb7
-rw-r--r--config/initializers/date_time_formats.rb4
-rw-r--r--config/locales/devise.zh.yml61
-rw-r--r--config/locales/doorkeeper.zh.yml151
-rw-r--r--config/locales/kaminari.zh.yml17
-rw-r--r--config/locales/sherlock.zh.yml37
-rw-r--r--config/locales/zh.yml219
-rw-r--r--lib/gitlab/access.rb17
-rw-r--r--lib/gitlab/themes.rb13
-rw-r--r--lib/gitlab/visibility_level.rb7
-rw-r--r--public/ci/build-canceled.svg2
-rw-r--r--public/ci/build-failed.svg2
-rw-r--r--public/ci/build-pending.svg2
-rw-r--r--public/ci/build-running.svg2
-rw-r--r--public/ci/build-skipped.svg2
-rw-r--r--public/ci/build-success.svg2
-rw-r--r--public/ci/build-unknown.svg2
528 files changed, 2877 insertions, 2324 deletions
diff --git a/app/assets/javascripts/ci/build.coffee b/app/assets/javascripts/ci/build.coffee
index 7afe8bf79e2..e4846e5e454 100644
--- a/app/assets/javascripts/ci/build.coffee
+++ b/app/assets/javascripts/ci/build.coffee
@@ -14,10 +14,10 @@ class CiBuild
state = $(this).data("state")
if "enabled" is state
$(this).data "state", "disabled"
- $(this).text "enable autoscroll"
+ $(this).text "开启自动滚动"
else
$(this).data "state", "enabled"
- $(this).text "disable autoscroll"
+ $(this).text "关闭自动滚动"
#
# Check for new build output if user still watching build page
diff --git a/app/assets/javascripts/copy_to_clipboard.js.coffee b/app/assets/javascripts/copy_to_clipboard.js.coffee
index 24301e01b10..b17a4c80855 100644
--- a/app/assets/javascripts/copy_to_clipboard.js.coffee
+++ b/app/assets/javascripts/copy_to_clipboard.js.coffee
@@ -17,7 +17,7 @@ genericError = (e) ->
else
key = 'Ctrl'
- showTooltip(e.trigger, "Press #{key}-C to copy")
+ showTooltip(e.trigger, "按 #{key}-C 复制")
showTooltip = (target, title) ->
$(target).
diff --git a/app/assets/javascripts/groups_select.js.coffee b/app/assets/javascripts/groups_select.js.coffee
index 1084e2a17d1..ced461cb964 100644
--- a/app/assets/javascripts/groups_select.js.coffee
+++ b/app/assets/javascripts/groups_select.js.coffee
@@ -4,7 +4,7 @@ class @GroupsSelect
skip_ldap = $(select).hasClass('skip_ldap')
$(select).select2
- placeholder: "Search for a group"
+ placeholder: "搜索群组"
multiple: $(select).hasClass('multiselect')
minimumInputLength: 0
query: (query) ->
diff --git a/app/assets/javascripts/importer_status.js.coffee b/app/assets/javascripts/importer_status.js.coffee
index be8d225e73b..82e79fc7889 100644
--- a/app/assets/javascripts/importer_status.js.coffee
+++ b/app/assets/javascripts/importer_status.js.coffee
@@ -26,9 +26,9 @@ class @ImporterStatus
if job.import_status == 'finished'
job_item.removeClass("active").addClass("success")
- status_field.html('<span><i class="fa fa-check"></i> done</span>')
+ status_field.html('<span><i class="fa fa-check"></i> 完成</span>')
else if job.import_status == 'started'
- status_field.html("<i class='fa fa-spinner fa-spin'></i> started")
+ status_field.html("<i class='fa fa-spinner fa-spin'></i> 已开始")
else
status_field.html(job.import_status)
diff --git a/app/assets/javascripts/lib/jquery.timeago.js b/app/assets/javascripts/lib/jquery.timeago.js
index cc17aa7d3d1..3e1fecafc71 100644
--- a/app/assets/javascripts/lib/jquery.timeago.js
+++ b/app/assets/javascripts/lib/jquery.timeago.js
@@ -43,20 +43,20 @@
strings: {
prefixAgo: null,
prefixFromNow: null,
- suffixAgo: "ago",
- suffixFromNow: "from now",
- seconds: "less than a minute",
- minute: "about a minute",
- minutes: "%d minutes",
- hour: "about an hour",
- hours: "about %d hours",
- day: "a day",
- days: "%d days",
- month: "about a month",
- months: "%d months",
- year: "about a year",
- years: "%d years",
- wordSeparator: " ",
+ suffixAgo: "之前",
+ suffixFromNow: null,
+ seconds: "不到 1 分钟",
+ minute: "大约 1 分钟",
+ minutes: " %d 分钟",
+ hour: "大约 1 小时",
+ hours: "大约 %d 小时",
+ day: " 1 天",
+ days: " %d 天",
+ month: "大约 1 个月",
+ months: " %d 个月",
+ year: "大约 1 年",
+ years: " %d 年",
+ wordSeparator: "",
numbers: []
}
},
diff --git a/app/assets/javascripts/markdown_preview.js.coffee b/app/assets/javascripts/markdown_preview.js.coffee
index 2a0b9479445..fcae2454264 100644
--- a/app/assets/javascripts/markdown_preview.js.coffee
+++ b/app/assets/javascripts/markdown_preview.js.coffee
@@ -13,10 +13,10 @@ class @MarkdownPreview
mdText = form.find('textarea.markdown-area').val()
if mdText.trim().length == 0
- preview.text('Nothing to preview.')
+ preview.text('没有预览内容。')
@hideReferencedUsers(form)
else
- preview.text('Loading...')
+ preview.text('正在载入...')
@renderMarkdown mdText, (response) =>
preview.html(response.body)
preview.syntaxHighlight()
diff --git a/app/assets/javascripts/merge_request_widget.js.coffee b/app/assets/javascripts/merge_request_widget.js.coffee
index 738ffc8343b..e7bd6efdd01 100644
--- a/app/assets/javascripts/merge_request_widget.js.coffee
+++ b/app/assets/javascripts/merge_request_widget.js.coffee
@@ -53,7 +53,7 @@ class @MergeRequestWidget
@setMergeButtonClass('btn-danger')
showCiCoverage: (coverage) ->
- text = 'Coverage ' + coverage + '%'
+ text = '覆盖率 ' + coverage + '%'
$('.ci_widget:visible .ci-coverage').text(text)
setMergeButtonClass: (css_class) ->
diff --git a/app/assets/javascripts/milestone.js.coffee b/app/assets/javascripts/milestone.js.coffee
index 0037a3a21c2..c49481691d2 100644
--- a/app/assets/javascripts/milestone.js.coffee
+++ b/app/assets/javascripts/milestone.js.coffee
@@ -15,7 +15,7 @@ class @Milestone
$(li).find('.assignee-icon').html('')
$(li).effect 'highlight'
else
- new Flash("Issue update failed", 'alert')
+ new Flash("更新问题失败", 'alert')
dataType: "json"
@sortIssues: (data) ->
@@ -27,7 +27,7 @@ class @Milestone
data: data
success: (data) ->
if data.saved != true
- new Flash("Issues update failed", 'alert')
+ new Flash("更新问题失败", 'alert')
dataType: "json"
@sortMergeRequests: (data) ->
@@ -39,7 +39,7 @@ class @Milestone
data: data
success: (data) ->
if data.saved != true
- new Flash("MR update failed", 'alert')
+ new Flash("更新合并请求失败", 'alert')
dataType: "json"
@updateMergeRequest: (li, merge_request_url, data) ->
@@ -58,7 +58,7 @@ class @Milestone
$(li).find('.assignee-icon').html('')
$(li).effect 'highlight'
else
- new Flash("Issue update failed", 'alert')
+ new Flash("更新问题失败", 'alert')
dataType: "json"
constructor: ->
diff --git a/app/assets/javascripts/namespace_select.js.coffee b/app/assets/javascripts/namespace_select.js.coffee
index a02c4515ccc..8a7d9822c53 100644
--- a/app/assets/javascripts/namespace_select.js.coffee
+++ b/app/assets/javascripts/namespace_select.js.coffee
@@ -12,7 +12,7 @@ class @NamespaceSelect
$('.ajax-namespace-select').each (i, select) ->
$(select).select2
- placeholder: "Search for namespace"
+ placeholder: "搜索命名空间"
multiple: $(select).hasClass('multiselect')
minimumInputLength: 0
query: (query) ->
diff --git a/app/assets/javascripts/project.js.coffee b/app/assets/javascripts/project.js.coffee
index 76bc4ff42a2..705e1a96476 100644
--- a/app/assets/javascripts/project.js.coffee
+++ b/app/assets/javascripts/project.js.coffee
@@ -42,11 +42,11 @@ class @Project
$('#notification-form').submit()
label = null
switch notification_level
- when 0 then label = ' Disabled '
- when 1 then label = ' Participating '
- when 2 then label = ' Watching '
- when 3 then label = ' Global '
- when 4 then label = ' On Mention '
+ when 0 then label = ' 禁止 '
+ when 1 then label = ' 参与的 '
+ when 2 then label = ' 关注的 '
+ when 3 then label = ' 全局 '
+ when 4 then label = ' 被提及 '
$('#notifications-button').empty().append("<i class='fa fa-bell'></i>" + label + "<i class='fa fa-angle-down'></i>")
$(@).parents('ul').find('li.active').removeClass 'active'
$(@).parent().addClass 'active'
diff --git a/app/assets/javascripts/project_select.js.coffee b/app/assets/javascripts/project_select.js.coffee
index be8ab9b428d..0b1da52b7f1 100644
--- a/app/assets/javascripts/project_select.js.coffee
+++ b/app/assets/javascripts/project_select.js.coffee
@@ -5,8 +5,8 @@ class @ProjectSelect
@includeGroups = $(select).data('include-groups')
@orderBy = $(select).data('order-by') || 'id'
- placeholder = "Search for project"
- placeholder += " or group" if @includeGroups
+ placeholder = "搜索项目"
+ placeholder += "或群组" if @includeGroups
$(select).select2
placeholder: placeholder
diff --git a/app/assets/javascripts/protected_branches.js.coffee b/app/assets/javascripts/protected_branches.js.coffee
index 5753c9d4e72..af2c6a31d62 100644
--- a/app/assets/javascripts/protected_branches.js.coffee
+++ b/app/assets/javascripts/protected_branches.js.coffee
@@ -18,4 +18,4 @@ $ ->
row.closest('tr').effect('highlight')
error: ->
- new Flash("Failed to update branch!", "alert")
+ new Flash("更新分支失败!", "alert")
diff --git a/app/assets/javascripts/stat_graph_contributors.js.coffee b/app/assets/javascripts/stat_graph_contributors.js.coffee
index 3be14cb43dd..9b0bb285448 100644
--- a/app/assets/javascripts/stat_graph_contributors.js.coffee
+++ b/app/assets/javascripts/stat_graph_contributors.js.coffee
@@ -26,7 +26,7 @@ class @ContributorsStatGraph
commits = $('<span/>', {
class: 'graph-author-commits-count'
})
- commits.text(author.commits + " commits")
+ commits.text(author.commits + " 次提交")
$('<span/>').append(commits)
create_author_header: (author) ->
@@ -63,8 +63,8 @@ class @ContributorsStatGraph
@field = field
change_date_header: ->
x_domain = ContributorsGraph.prototype.x_domain
- print_date_format = d3.time.format("%B %e %Y")
- print = print_date_format(x_domain[0]) + " - " + print_date_format(x_domain[1])
+ print_date_format = d3.time.format("%Y-%m-%d")
+ print = print_date_format(x_domain[0]) + " 到 " + print_date_format(x_domain[1])
$("#date_header").text(print)
redraw_author_commit_info: (author) ->
author_list_item = $(@authors[author.author_name].list_item)
diff --git a/app/assets/javascripts/users_select.js.coffee b/app/assets/javascripts/users_select.js.coffee
index 3d6452d2f46..5083ea4a2f1 100644
--- a/app/assets/javascripts/users_select.js.coffee
+++ b/app/assets/javascripts/users_select.js.coffee
@@ -101,7 +101,7 @@ class @UsersSelect
firstUser = $(select).data('first-user')
$(select).select2
- placeholder: "Search for a user"
+ placeholder: "搜索用户"
multiple: $(select).hasClass('multiselect')
minimumInputLength: 0
query: (query) =>
@@ -119,14 +119,14 @@ class @UsersSelect
if showNullUser
nullUser = {
- name: 'Unassigned',
+ name: '未指派',
id: 0
}
data.results.unshift(nullUser)
if showAnyUser
name = showAnyUser
- name = 'Any User' if name == true
+ name = '任何用户' if name == true
anyUser = {
name: name,
id: null
@@ -135,7 +135,7 @@ class @UsersSelect
if showEmailUser && data.results.length == 0 && query.term.match(/^[^@]+@[^@]+$/)
emailUser = {
- name: "Invite \"#{query.term}\"",
+ name: "邀请 \"#{query.term}\"",
username: query.term,
id: query.term
}
diff --git a/app/controllers/admin/appearances_controller.rb b/app/controllers/admin/appearances_controller.rb
index 26cf74e4849..3599860c116 100644
--- a/app/controllers/admin/appearances_controller.rb
+++ b/app/controllers/admin/appearances_controller.rb
@@ -11,7 +11,7 @@ class Admin::AppearancesController < Admin::ApplicationController
@appearance = Appearance.new(appearance_params)
if @appearance.save
- redirect_to admin_appearances_path, notice: 'Appearance was successfully created.'
+ redirect_to admin_appearances_path, notice: '创建外观成功。'
else
render action: 'show'
end
@@ -19,7 +19,7 @@ class Admin::AppearancesController < Admin::ApplicationController
def update
if @appearance.update(appearance_params)
- redirect_to admin_appearances_path, notice: 'Appearance was successfully updated.'
+ redirect_to admin_appearances_path, notice: '更新外观成功。'
else
render action: 'show'
end
@@ -30,14 +30,14 @@ class Admin::AppearancesController < Admin::ApplicationController
@appearance.save
- redirect_to admin_appearances_path, notice: 'Logo was succesfully removed.'
+ redirect_to admin_appearances_path, notice: 'Logo 删除成功。'
end
def header_logos
@appearance.remove_header_logo!
@appearance.save
- redirect_to admin_appearances_path, notice: 'Header logo was succesfully removed.'
+ redirect_to admin_appearances_path, notice: '头部 Logo 删除成功。'
end
private
diff --git a/app/controllers/admin/application_settings_controller.rb b/app/controllers/admin/application_settings_controller.rb
index ed9f6031389..0c244eb80e9 100644
--- a/app/controllers/admin/application_settings_controller.rb
+++ b/app/controllers/admin/application_settings_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Admin::ApplicationSettingsController < Admin::ApplicationController
before_action :set_application_setting
@@ -7,7 +8,7 @@ class Admin::ApplicationSettingsController < Admin::ApplicationController
def update
if @application_setting.update_attributes(application_setting_params)
redirect_to admin_application_settings_path,
- notice: 'Application settings saved successfully'
+ notice: '应用设置保存成功'
else
render :show
end
diff --git a/app/controllers/admin/applications_controller.rb b/app/controllers/admin/applications_controller.rb
index 471d24934a0..7403dd4d9b2 100644
--- a/app/controllers/admin/applications_controller.rb
+++ b/app/controllers/admin/applications_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Admin::ApplicationsController < Admin::ApplicationController
before_action :set_application, only: [:show, :edit, :update, :destroy]
@@ -28,7 +29,7 @@ class Admin::ApplicationsController < Admin::ApplicationController
def update
if @application.update(application_params)
- redirect_to admin_application_path(@application), notice: 'Application was successfully updated.'
+ redirect_to admin_application_path(@application), notice: '应用更新成功。'
else
render :edit
end
@@ -36,7 +37,7 @@ class Admin::ApplicationsController < Admin::ApplicationController
def destroy
@application.destroy
- redirect_to admin_applications_url, notice: 'Application was successfully destroyed.'
+ redirect_to admin_applications_url, notice: '应用销毁成功。'
end
private
diff --git a/app/controllers/admin/broadcast_messages_controller.rb b/app/controllers/admin/broadcast_messages_controller.rb
index fc342924987..3ea90a8d13e 100644
--- a/app/controllers/admin/broadcast_messages_controller.rb
+++ b/app/controllers/admin/broadcast_messages_controller.rb
@@ -13,7 +13,7 @@ class Admin::BroadcastMessagesController < Admin::ApplicationController
@broadcast_message = BroadcastMessage.new(broadcast_message_params)
if @broadcast_message.save
- redirect_to admin_broadcast_messages_path, notice: 'Broadcast Message was successfully created.'
+ redirect_to admin_broadcast_messages_path, notice: '广播信息创建成功。'
else
render :index
end
diff --git a/app/controllers/admin/groups_controller.rb b/app/controllers/admin/groups_controller.rb
index 8e2a981be7c..4dafef43184 100644
--- a/app/controllers/admin/groups_controller.rb
+++ b/app/controllers/admin/groups_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Admin::GroupsController < Admin::ApplicationController
before_action :group, only: [:edit, :show, :update, :destroy, :project_update, :members_update]
@@ -26,7 +27,7 @@ class Admin::GroupsController < Admin::ApplicationController
if @group.save
@group.add_owner(current_user)
- redirect_to [:admin, @group], notice: 'Group was successfully created.'
+ redirect_to [:admin, @group], notice: '群组创建成功。'
else
render "new"
end
@@ -34,7 +35,7 @@ class Admin::GroupsController < Admin::ApplicationController
def update
if @group.update_attributes(group_params)
- redirect_to [:admin, @group], notice: 'Group was successfully updated.'
+ redirect_to [:admin, @group], notice: '群组更新成功。'
else
render "edit"
end
@@ -43,13 +44,13 @@ class Admin::GroupsController < Admin::ApplicationController
def members_update
@group.add_users(params[:user_ids].split(','), params[:access_level], current_user)
- redirect_to [:admin, @group], notice: 'Users were successfully added.'
+ redirect_to [:admin, @group], notice: '用户增加成功。'
end
def destroy
DestroyGroupService.new(@group, current_user).execute
- redirect_to admin_groups_path, notice: 'Group was successfully deleted.'
+ redirect_to admin_groups_path, notice: '群组删除成功。'
end
private
diff --git a/app/controllers/admin/hooks_controller.rb b/app/controllers/admin/hooks_controller.rb
index 0bd19c49d8f..520d122d9e5 100644
--- a/app/controllers/admin/hooks_controller.rb
+++ b/app/controllers/admin/hooks_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Admin::HooksController < Admin::ApplicationController
def index
@hooks = SystemHook.all
@@ -8,7 +9,7 @@ class Admin::HooksController < Admin::ApplicationController
@hook = SystemHook.new(hook_params)
if @hook.save
- redirect_to admin_hooks_path, notice: 'Hook was successfully created.'
+ redirect_to admin_hooks_path, notice: '钩子创建成功。'
else
@hooks = SystemHook.all
render :index
diff --git a/app/controllers/admin/keys_controller.rb b/app/controllers/admin/keys_controller.rb
index cb33fdd9763..c4e3c59a402 100644
--- a/app/controllers/admin/keys_controller.rb
+++ b/app/controllers/admin/keys_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Admin::KeysController < Admin::ApplicationController
before_action :user, only: [:show, :destroy]
@@ -15,9 +16,9 @@ class Admin::KeysController < Admin::ApplicationController
respond_to do |format|
if key.destroy
- format.html { redirect_to [:admin, user], notice: 'User key was successfully removed.' }
+ format.html { redirect_to [:admin, user], notice: '用户密钥删除成功。' }
else
- format.html { redirect_to [:admin, user], alert: 'Failed to remove user key.' }
+ format.html { redirect_to [:admin, user], alert: '用户密钥删除失败。' }
end
end
end
diff --git a/app/controllers/admin/services_controller.rb b/app/controllers/admin/services_controller.rb
index 46133588332..39aefde7f7d 100644
--- a/app/controllers/admin/services_controller.rb
+++ b/app/controllers/admin/services_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Admin::ServicesController < Admin::ApplicationController
before_action :service, only: [:edit, :update]
@@ -8,14 +9,14 @@ class Admin::ServicesController < Admin::ApplicationController
def edit
unless service.present?
redirect_to admin_application_settings_services_path,
- alert: "Service is unknown or it doesn't exist"
+ alert: "服务未知或不存在"
end
end
def update
if service.update_attributes(application_services_params[:service])
redirect_to admin_application_settings_services_path,
- notice: 'Application settings saved successfully'
+ notice: '应用设置保存成功'
else
render :edit
end
diff --git a/app/controllers/admin/users_controller.rb b/app/controllers/admin/users_controller.rb
index 9abf08d0e19..f084c38d248 100644
--- a/app/controllers/admin/users_controller.rb
+++ b/app/controllers/admin/users_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Admin::UsersController < Admin::ApplicationController
before_action :user, except: [:index, :new, :create]
@@ -33,42 +34,42 @@ class Admin::UsersController < Admin::ApplicationController
def block
if user.block
- redirect_back_or_admin_user(notice: "Successfully blocked")
+ redirect_back_or_admin_user(notice: "禁用成功")
else
- redirect_back_or_admin_user(alert: "Error occurred. User was not blocked")
+ redirect_back_or_admin_user(alert: "发生错误。用户未被禁止")
end
end
def unblock
if user.ldap_blocked?
- redirect_back_or_admin_user(alert: "This user cannot be unlocked manually from GitLab")
+ redirect_back_or_admin_user(alert: "此用户无法通过 GitLab 来启用")
elsif user.activate
- redirect_back_or_admin_user(notice: "Successfully unblocked")
+ redirect_back_or_admin_user(notice: "启用成功")
else
- redirect_back_or_admin_user(alert: "Error occurred. User was not unblocked")
+ redirect_back_or_admin_user(alert: "发生错误。用户未被启用")
end
end
def unlock
if user.unlock_access!
- redirect_back_or_admin_user(alert: "Successfully unlocked")
+ redirect_back_or_admin_user(alert: "解除锁定成功")
else
- redirect_back_or_admin_user(alert: "Error occurred. User was not unlocked")
+ redirect_back_or_admin_user(alert: "发生错误。用户未被解除锁定")
end
end
def confirm
if user.confirm
- redirect_back_or_admin_user(notice: "Successfully confirmed")
+ redirect_back_or_admin_user(notice: "确认成功")
else
- redirect_back_or_admin_user(alert: "Error occurred. User was not confirmed")
+ redirect_back_or_admin_user(alert: "发生错误。用户未被确认")
end
end
def disable_two_factor
user.disable_two_factor!
redirect_to admin_user_path(user),
- notice: 'Two-factor Authentication has been disabled for this user'
+ notice: '此用户已禁止两步验证'
end
def create
@@ -85,7 +86,7 @@ class Admin::UsersController < Admin::ApplicationController
respond_to do |format|
if @user.save
- format.html { redirect_to [:admin, @user], notice: 'User was successfully created.' }
+ format.html { redirect_to [:admin, @user], notice: '用户创建成功。' }
format.json { render json: @user, status: :created, location: @user }
else
format.html { render "new" }
@@ -107,7 +108,7 @@ class Admin::UsersController < Admin::ApplicationController
respond_to do |format|
user.skip_reconfirmation!
if user.update_attributes(user_params_with_pass)
- format.html { redirect_to [:admin, user], notice: 'User was successfully updated.' }
+ format.html { redirect_to [:admin, user], notice: '用户更新成功。' }
format.json { head :ok }
else
# restore username to keep form action url.
@@ -134,7 +135,7 @@ class Admin::UsersController < Admin::ApplicationController
user.update_secondary_emails!
respond_to do |format|
- format.html { redirect_back_or_admin_user(notice: "Successfully removed email.") }
+ format.html { redirect_back_or_admin_user(notice: "删除电子邮箱成功。") }
format.js { render nothing: true }
end
end
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb
index 3a0eb96a460..c5f224e855e 100644
--- a/app/controllers/application_controller.rb
+++ b/app/controllers/application_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
require 'gon'
require 'fogbugz'
@@ -90,7 +91,7 @@ class ApplicationController < ActionController::Base
def reject_blocked!
if current_user && current_user.blocked?
sign_out current_user
- flash[:alert] = "Your account is blocked. Retry when an admin has unblocked it."
+ flash[:alert] = "你的账号被禁用。请在管理员启用该账号后重试。"
redirect_to new_user_session_path
end
end
@@ -98,7 +99,7 @@ class ApplicationController < ActionController::Base
def after_sign_in_path_for(resource)
if resource.is_a?(User) && resource.respond_to?(:blocked?) && resource.blocked?
sign_out resource
- flash[:alert] = "Your account is blocked. Retry when an admin has unblocked it."
+ flash[:alert] = "你的账号被禁用。请在管理员启用该账号后重试。"
new_user_session_path
else
stored_location_for(:redirect) || stored_location_for(resource) || root_path
@@ -244,7 +245,7 @@ class ApplicationController < ActionController::Base
def require_email
if current_user && current_user.temp_oauth_email?
- redirect_to profile_path, notice: 'Please complete your profile with email address' and return
+ redirect_to profile_path, notice: '请在个人资料中填写电子邮箱地址' and return
end
end
diff --git a/app/controllers/ci/lints_controller.rb b/app/controllers/ci/lints_controller.rb
index a7af3cb8345..936ff051bf1 100644
--- a/app/controllers/ci/lints_controller.rb
+++ b/app/controllers/ci/lints_controller.rb
@@ -10,7 +10,7 @@ module Ci
if @content.blank?
@status = false
- @error = "Please provide content of .gitlab-ci.yml"
+ @error = "请提供 .gitlab-ci.yml 文件内容"
else
@config_processor = Ci::GitlabCiYamlProcessor.new(@content)
@stages = @config_processor.stages
@@ -21,7 +21,7 @@ module Ci
@error = e.message
@status = false
rescue
- @error = 'Undefined error'
+ @error = '未定义错误'
@status = false
ensure
render :show
diff --git a/app/controllers/groups/group_members_controller.rb b/app/controllers/groups/group_members_controller.rb
index d5ef33888c6..992170b39cd 100644
--- a/app/controllers/groups/group_members_controller.rb
+++ b/app/controllers/groups/group_members_controller.rb
@@ -20,7 +20,7 @@ class Groups::GroupMembersController < Groups::ApplicationController
def create
@group.add_users(params[:user_ids].split(','), params[:access_level], current_user)
- redirect_to group_group_members_path(@group), notice: 'Users were successfully added.'
+ redirect_to group_group_members_path(@group), notice: '用户增加成功。'
end
def update
@@ -39,7 +39,7 @@ class Groups::GroupMembersController < Groups::ApplicationController
@group_member.destroy
respond_to do |format|
- format.html { redirect_to group_group_members_path(@group), notice: 'User was successfully removed from group.' }
+ format.html { redirect_to group_group_members_path(@group), notice: '用户从群组删除成功。' }
format.js { render nothing: true }
end
end
@@ -52,9 +52,9 @@ class Groups::GroupMembersController < Groups::ApplicationController
if @group_member.invite?
@group_member.resend_invite
- redirect_to redirect_path, notice: 'The invitation was successfully resent.'
+ redirect_to redirect_path, notice: '邀请重发成功。'
else
- redirect_to redirect_path, alert: 'The invitation has already been accepted.'
+ redirect_to redirect_path, alert: '邀请已经被接受。'
end
end
@@ -64,10 +64,10 @@ class Groups::GroupMembersController < Groups::ApplicationController
if can?(current_user, :destroy_group_member, @group_member)
@group_member.destroy
- redirect_to(dashboard_groups_path, notice: "You left #{group.name} group.")
+ redirect_to(dashboard_groups_path, notice: "已离开 #{group.name} 群组。")
else
if @group.last_owner?(current_user)
- redirect_to(dashboard_groups_path, alert: "You can not leave #{group.name} group because you're the last owner. Transfer or delete the group.")
+ redirect_to(dashboard_groups_path, alert: "不能离开 #{group.name} 群组,因为你是最后一个群组所有者。请转移或删除群组。")
else
return render_403
end
diff --git a/app/controllers/groups_controller.rb b/app/controllers/groups_controller.rb
index 87efb0a8970..55a80d7643c 100644
--- a/app/controllers/groups_controller.rb
+++ b/app/controllers/groups_controller.rb
@@ -91,7 +91,7 @@ class GroupsController < Groups::ApplicationController
def destroy
DestroyGroupService.new(@group, current_user).execute
- redirect_to root_path, alert: "Group '#{@group.name}' was successfully deleted."
+ redirect_to root_path, alert: "群组 '#{@group.name}' 被成功删除。"
end
protected
diff --git a/app/controllers/import/google_code_controller.rb b/app/controllers/import/google_code_controller.rb
index e0de31f2251..8e004556bef 100644
--- a/app/controllers/import/google_code_controller.rb
+++ b/app/controllers/import/google_code_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Import::GoogleCodeController < Import::BaseController
before_action :verify_google_code_import_enabled
before_action :user_map, only: [:new_user_map, :create_user_map]
@@ -10,18 +11,18 @@ class Import::GoogleCodeController < Import::BaseController
dump_file = params[:dump_file]
unless dump_file.respond_to?(:read)
- return redirect_back_or_default(options: { alert: "You need to upload a Google Takeout archive." })
+ return redirect_back_or_default(options: { alert: "需要上传 Google Takeout 存档。" })
end
begin
dump = JSON.parse(dump_file.read)
rescue
- return redirect_back_or_default(options: { alert: "The uploaded file is not a valid Google Takeout archive." })
+ return redirect_back_or_default(options: { alert: "上传的文件不是有效的 Google Takeout 存档。" })
end
client = Gitlab::GoogleCodeImport::Client.new(dump)
unless client.valid?
- return redirect_back_or_default(options: { alert: "The uploaded file is not a valid Google Takeout archive." })
+ return redirect_back_or_default(options: { alert: "上传的文件不是有效的 Google Takeout 存档。" })
end
session[:google_code_dump] = dump
@@ -44,13 +45,13 @@ class Import::GoogleCodeController < Import::BaseController
begin
user_map = JSON.parse(user_map_json)
rescue
- flash.now[:alert] = "The entered user map is not a valid JSON user map."
+ flash.now[:alert] = "输入的用户映射表不是有效的 JSON 用户映射表。"
render "new_user_map" and return
end
unless user_map.is_a?(Hash) && user_map.all? { |k, v| k.is_a?(String) && v.is_a?(String) }
- flash.now[:alert] = "The entered user map is not a valid JSON user map."
+ flash.now[:alert] = "输入的用户映射表不是有效的 JSON 用户映射表。"
render "new_user_map" and return
end
@@ -62,7 +63,7 @@ class Import::GoogleCodeController < Import::BaseController
session[:google_code_user_map] = user_map
- flash[:notice] = "The user map has been saved. Continue by selecting the projects you want to import."
+ flash[:notice] = "用户映射表已保存。选择要导入的项目后继续。"
redirect_to status_import_google_code_path
end
diff --git a/app/controllers/invites_controller.rb b/app/controllers/invites_controller.rb
index 94bb108c5f5..a214b439b22 100644
--- a/app/controllers/invites_controller.rb
+++ b/app/controllers/invites_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class InvitesController < ApplicationController
before_action :member
skip_before_action :authenticate_user!, only: :decline
@@ -12,9 +13,9 @@ class InvitesController < ApplicationController
if member.accept_invite!(current_user)
label, path = source_info(member.source)
- redirect_to path, notice: "You have been granted #{member.human_access} access to #{label}."
+ redirect_to path, notice: "已接受作为 #{member.human_access} 访问 #{label} 的邀请。"
else
- redirect_back_or_default(options: { alert: "The invitation could not be accepted." })
+ redirect_back_or_default(options: { alert: "此邀请无法被接受。" })
end
end
@@ -29,9 +30,9 @@ class InvitesController < ApplicationController
new_user_session_path
end
- redirect_to path, notice: "You have declined the invitation to join #{label}."
+ redirect_to path, notice: "已拒绝加入 #{label} 的邀请。"
else
- redirect_back_or_default(options: { alert: "The invitation could not be declined." })
+ redirect_back_or_default(options: { alert: "此邀请无法被拒绝。" })
end
end
@@ -53,9 +54,9 @@ class InvitesController < ApplicationController
def authenticate_user!
return if current_user
- notice = "To accept this invitation, sign in"
- notice << " or create an account" if current_application_settings.signup_enabled?
- notice << "."
+ notice = "要接受此邀请,请登入"
+ notice << "或者创建账号" if current_application_settings.signup_enabled?
+ notice << "。"
store_location_for :user, request.fullpath
redirect_to new_user_session_path, notice: notice
@@ -65,14 +66,14 @@ class InvitesController < ApplicationController
case source
when Project
project = member.source
- label = "project #{project.name_with_namespace}"
+ label = "项目 #{project.name_with_namespace}"
path = namespace_project_path(project.namespace, project)
when Group
group = member.source
- label = "group #{group.name}"
+ label = "群组 #{group.name}"
path = group_path(group)
else
- label = "who knows what"
+ label = "谁知道"
path = dashboard_projects_path
end
diff --git a/app/controllers/omniauth_callbacks_controller.rb b/app/controllers/omniauth_callbacks_controller.rb
index 21135f7d607..4f3aa66ff5c 100644
--- a/app/controllers/omniauth_callbacks_controller.rb
+++ b/app/controllers/omniauth_callbacks_controller.rb
@@ -37,7 +37,7 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
sign_in_and_redirect(@user)
end
else
- flash[:alert] = "Access denied for your LDAP account."
+ flash[:alert] = "您的 LDAP 账号被禁止访问。"
redirect_to new_user_session_path
end
end
@@ -49,7 +49,7 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
identity = current_user.identities.find_by(extern_uid: oauth['uid'], provider: :saml)
if identity.nil?
current_user.identities.create(extern_uid: oauth['uid'], provider: :saml)
- redirect_to profile_account_path, notice: 'Authentication method updated'
+ redirect_to profile_account_path, notice: '认证方法已更新'
else
redirect_to after_sign_in_path_for(current_user)
end
@@ -83,7 +83,7 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
# Add new authentication method
current_user.identities.find_or_create_by(extern_uid: oauth['uid'], provider: oauth['provider'])
log_audit_event(current_user, with: oauth['provider'])
- redirect_to profile_account_path, notice: 'Authentication method updated'
+ redirect_to profile_account_path, notice: '认证方法已更新'
else
oauth_user = Gitlab::OAuth::User.new(oauth)
oauth_user.save
@@ -93,10 +93,10 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
end
rescue Gitlab::OAuth::SignupDisabledError
label = Gitlab::OAuth::Provider.label_for(oauth['provider'])
- message = "Signing in using your #{label} account without a pre-existing GitLab account is not allowed."
+ message = "没有绑定 GitLab 账号前是无法使用 #{label} 账号登陆系统。"
if current_application_settings.signup_enabled?
- message << " Create a GitLab account first, and then connect it to your #{label} account."
+ message << " 请先创建一个 GitLab 账号,然后再绑定 #{label} 账号。"
end
flash[:notice] = message
diff --git a/app/controllers/passwords_controller.rb b/app/controllers/passwords_controller.rb
index a8575e037e4..7017a3c95b7 100644
--- a/app/controllers/passwords_controller.rb
+++ b/app/controllers/passwords_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class PasswordsController < Devise::PasswordsController
before_action :resource_from_email, only: [:create]
before_action :prevent_ldap_reset, only: [:create]
@@ -17,7 +18,7 @@ class PasswordsController < Devise::PasswordsController
).first_or_initialize
unless user.reset_password_period_valid?
- flash[:alert] = 'Your password reset token has expired.'
+ flash[:alert] = '使用的密码重置授权已过期。'
redirect_to(new_user_password_url(user_email: user['email']))
end
end
diff --git a/app/controllers/profiles/notifications_controller.rb b/app/controllers/profiles/notifications_controller.rb
index 1fd1d6882df..46d5badc1a3 100644
--- a/app/controllers/profiles/notifications_controller.rb
+++ b/app/controllers/profiles/notifications_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Profiles::NotificationsController < Profiles::ApplicationController
def show
@user = current_user
@@ -24,9 +25,9 @@ class Profiles::NotificationsController < Profiles::ApplicationController
respond_to do |format|
format.html do
if @saved
- flash[:notice] = "Notification settings saved"
+ flash[:notice] = "通知设置已保存"
else
- flash[:alert] = "Failed to save new settings"
+ flash[:alert] = "保存新设置失败"
end
redirect_back_or_default(default: profile_notifications_path)
diff --git a/app/controllers/profiles/passwords_controller.rb b/app/controllers/profiles/passwords_controller.rb
index c780e0983f9..fa40e954f49 100644
--- a/app/controllers/profiles/passwords_controller.rb
+++ b/app/controllers/profiles/passwords_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Profiles::PasswordsController < Profiles::ApplicationController
skip_before_action :check_password_expiration, only: [:new, :create]
@@ -11,7 +12,7 @@ class Profiles::PasswordsController < Profiles::ApplicationController
def create
unless @user.password_automatically_set || @user.valid_password?(user_params[:current_password])
- redirect_to new_profile_password_path, alert: 'You must provide a valid current password'
+ redirect_to new_profile_password_path, alert: '必须提供一个有效的当前密码'
return
end
@@ -26,7 +27,7 @@ class Profiles::PasswordsController < Profiles::ApplicationController
if result
@user.update_attributes(password_expires_at: nil)
- redirect_to root_path, notice: 'Password successfully changed'
+ redirect_to root_path, notice: '密码修改成功'
else
render :new
end
@@ -42,12 +43,12 @@ class Profiles::PasswordsController < Profiles::ApplicationController
password_attributes[:password_automatically_set] = false
unless @user.password_automatically_set || @user.valid_password?(user_params[:current_password])
- redirect_to edit_profile_password_path, alert: 'You must provide a valid current password'
+ redirect_to edit_profile_password_path, alert: '必须提供一个有效的当前密码'
return
end
if @user.update_attributes(password_attributes)
- flash[:notice] = "Password was successfully updated. Please login with it"
+ flash[:notice] = "密码已成功更新。请使用新密码重新登录"
redirect_to new_user_session_path
else
render 'edit'
@@ -56,7 +57,7 @@ class Profiles::PasswordsController < Profiles::ApplicationController
def reset
current_user.send_reset_password_instructions
- redirect_to edit_profile_password_path, notice: 'We sent you an email with reset password instructions'
+ redirect_to edit_profile_password_path, notice: '已发送重置密码操作的电子邮件'
end
private
diff --git a/app/controllers/profiles/preferences_controller.rb b/app/controllers/profiles/preferences_controller.rb
index a9a06ecc808..1559a191ba2 100644
--- a/app/controllers/profiles/preferences_controller.rb
+++ b/app/controllers/profiles/preferences_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Profiles::PreferencesController < Profiles::ApplicationController
before_action :user
@@ -7,13 +8,13 @@ class Profiles::PreferencesController < Profiles::ApplicationController
def update
begin
if @user.update_attributes(preferences_params)
- flash[:notice] = 'Preferences saved.'
+ flash[:notice] = '偏好设置已保存。'
else
- flash[:alert] = 'Failed to save preferences.'
+ flash[:alert] = '保存偏好设置失败。'
end
rescue ArgumentError => e
# Raised when `dashboard` is given an invalid value.
- flash[:alert] = "Failed to save preferences (#{e.message})."
+ flash[:alert] = "保存偏好设置失败(#{e.message})。"
end
respond_to do |format|
diff --git a/app/controllers/profiles/two_factor_auths_controller.rb b/app/controllers/profiles/two_factor_auths_controller.rb
index 8f83fdd02bc..4f58033b659 100644
--- a/app/controllers/profiles/two_factor_auths_controller.rb
+++ b/app/controllers/profiles/two_factor_auths_controller.rb
@@ -14,10 +14,10 @@ class Profiles::TwoFactorAuthsController < Profiles::ApplicationController
if two_factor_authentication_required?
if two_factor_grace_period_expired?
- flash.now[:alert] = 'You must enable Two-factor Authentication for your account.'
+ flash.now[:alert] = '您必须给您的账户启用两步验证。'
else
grace_period_deadline = current_user.otp_grace_period_started_at + two_factor_grace_period.hours
- flash.now[:alert] = "You must enable Two-factor Authentication for your account before #{l(grace_period_deadline)}."
+ flash.now[:alert] = "您必须在 #{l(grace_period_deadline)} 之前给您的账户启用两步验证。"
end
end
diff --git a/app/controllers/profiles_controller.rb b/app/controllers/profiles_controller.rb
index 32fca6b838e..bcf7a296eae 100644
--- a/app/controllers/profiles_controller.rb
+++ b/app/controllers/profiles_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class ProfilesController < Profiles::ApplicationController
include ActionView::Helpers::SanitizeHelper
@@ -12,10 +13,10 @@ class ProfilesController < Profiles::ApplicationController
user_params.except!(:email) if @user.ldap_user?
if @user.update_attributes(user_params)
- flash[:notice] = "Profile was successfully updated"
+ flash[:notice] = "个人资料已成功更新"
else
messages = @user.errors.full_messages.uniq.join('. ')
- flash[:alert] = "Failed to update profile. #{messages}"
+ flash[:alert] = "更新个人资料失败。 #{messages}"
end
respond_to do |format|
@@ -25,7 +26,7 @@ class ProfilesController < Profiles::ApplicationController
def reset_private_token
if current_user.reset_authentication_token!
- flash[:notice] = "Token was successfully updated"
+ flash[:notice] = "令牌已成功更新"
end
redirect_to profile_account_path
diff --git a/app/controllers/projects/application_controller.rb b/app/controllers/projects/application_controller.rb
index 657ee94cfd7..2cdf098cee6 100644
--- a/app/controllers/projects/application_controller.rb
+++ b/app/controllers/projects/application_controller.rb
@@ -75,7 +75,7 @@ class Projects::ApplicationController < ApplicationController
unless @repository.branch_names.include?(@ref)
redirect_to(
namespace_project_tree_path(@project.namespace, @project, @ref),
- notice: "This action is not allowed unless you are on a branch"
+ notice: "除在分支的顶层外不允许本操作"
)
end
end
diff --git a/app/controllers/projects/blob_controller.rb b/app/controllers/projects/blob_controller.rb
index cd8b2911674..75320453ced 100644
--- a/app/controllers/projects/blob_controller.rb
+++ b/app/controllers/projects/blob_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
# Controller for viewing a file's blame
class Projects::BlobController < Projects::ApplicationController
include ExtractsPath
@@ -22,7 +23,7 @@ class Projects::BlobController < Projects::ApplicationController
end
def create
- create_commit(Files::CreateService, success_notice: "The file has been successfully created.",
+ create_commit(Files::CreateService, success_notice: "文件已创建成功。",
success_path: namespace_project_blob_path(@project.namespace, @project, File.join(@target_branch, @file_path)),
failure_view: :new,
failure_path: namespace_project_new_blob_path(@project.namespace, @project, @ref))
@@ -62,7 +63,7 @@ class Projects::BlobController < Projects::ApplicationController
end
def destroy
- create_commit(Files::DeleteService, success_notice: "The file has been successfully deleted.",
+ create_commit(Files::DeleteService, success_notice: "文件已删除成功。",
success_path: namespace_project_tree_path(@project.namespace, @project, @target_branch),
failure_view: :show,
failure_path: namespace_project_blob_path(@project.namespace, @project, @id))
diff --git a/app/controllers/projects/forks_controller.rb b/app/controllers/projects/forks_controller.rb
index a1b8632df98..faab7f19c18 100644
--- a/app/controllers/projects/forks_controller.rb
+++ b/app/controllers/projects/forks_controller.rb
@@ -48,7 +48,7 @@ class Projects::ForksController < Projects::ApplicationController
if continue_params
redirect_to continue_params[:to], notice: continue_params[:notice]
else
- redirect_to namespace_project_path(@forked_project.namespace, @forked_project), notice: "The project '#{@forked_project.name}' was successfully forked."
+ redirect_to namespace_project_path(@forked_project.namespace, @forked_project), notice: "项目 '#{@forked_project.name}' 项目成功。"
end
end
else
diff --git a/app/controllers/projects/hooks_controller.rb b/app/controllers/projects/hooks_controller.rb
index 5fd4f855dec..d781e7679a6 100644
--- a/app/controllers/projects/hooks_controller.rb
+++ b/app/controllers/projects/hooks_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Projects::HooksController < Projects::ApplicationController
# Authorize
before_action :authorize_admin_project!
@@ -28,12 +29,12 @@ class Projects::HooksController < Projects::ApplicationController
status, message = TestHookService.new.execute(hook, current_user)
if status
- flash[:notice] = 'Hook successfully executed.'
+ flash[:notice] = '钩子执行成功。'
else
- flash[:alert] = "Hook execution failed: #{message}"
+ flash[:alert] = "钩子执行失败:#{message}"
end
else
- flash[:alert] = 'Hook execution failed. Ensure the project has commits.'
+ flash[:alert] = '钩子执行失败。确保项目已提交。'
end
redirect_back_or_default(default: { action: 'index' })
diff --git a/app/controllers/projects/labels_controller.rb b/app/controllers/projects/labels_controller.rb
index 5f471d405f5..66f07d7bd09 100644
--- a/app/controllers/projects/labels_controller.rb
+++ b/app/controllers/projects/labels_controller.rb
@@ -65,7 +65,7 @@ class Projects::LabelsController < Projects::ApplicationController
respond_to do |format|
format.html do
redirect_to(namespace_project_labels_path(@project.namespace, @project),
- notice: 'Label was removed')
+ notice: '标记已删除')
end
format.js
end
diff --git a/app/controllers/projects/services_controller.rb b/app/controllers/projects/services_controller.rb
index 8b2577aebe1..42416acd902 100644
--- a/app/controllers/projects/services_controller.rb
+++ b/app/controllers/projects/services_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Projects::ServicesController < Projects::ApplicationController
ALLOWED_PARAMS = [:title, :token, :type, :active, :api_key, :api_url, :api_version, :subdomain,
:room, :recipients, :project_url, :webhook,
@@ -37,7 +38,7 @@ class Projects::ServicesController < Projects::ApplicationController
redirect_to(
edit_namespace_project_service_path(@project.namespace, @project,
@service.to_param, notice:
- 'Successfully updated.')
+ '已更新成功。')
)
else
render 'edit'
@@ -48,9 +49,9 @@ class Projects::ServicesController < Projects::ApplicationController
data = Gitlab::PushDataBuilder.build_sample(project, current_user)
outcome = @service.test(data)
if outcome[:success]
- message = { notice: 'We sent a request to the provided URL' }
+ message = { notice: '已发送请求到提供的链接' }
else
- error_message = "We tried to send a request to the provided URL but an error occurred"
+ error_message = "已发送请求到提供的链接,但收到一个错误回应"
error_message << ": #{outcome[:result]}" if outcome[:result].present?
message = { alert: error_message }
end
diff --git a/app/controllers/projects/wikis_controller.rb b/app/controllers/projects/wikis_controller.rb
index 88fccfed509..ed19ec2aa9f 100644
--- a/app/controllers/projects/wikis_controller.rb
+++ b/app/controllers/projects/wikis_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
require 'project_wiki'
class Projects::WikisController < Projects::ApplicationController
@@ -47,7 +48,7 @@ class Projects::WikisController < Projects::ApplicationController
if @page.update(content, format, message)
redirect_to(
namespace_project_wiki_path(@project.namespace, @project, @page),
- notice: 'Wiki was successfully updated.'
+ notice: '维基更新成功。'
)
else
render 'edit'
@@ -60,7 +61,7 @@ class Projects::WikisController < Projects::ApplicationController
if @page.create(wiki_params)
redirect_to(
namespace_project_wiki_path(@project.namespace, @project, @page),
- notice: 'Wiki was successfully updated.'
+ notice: '维基更新成功。'
)
else
render action: "edit"
@@ -73,7 +74,7 @@ class Projects::WikisController < Projects::ApplicationController
unless @page
redirect_to(
namespace_project_wiki_path(@project.namespace, @project, :home),
- notice: "Page not found"
+ notice: "页面不存在"
)
end
end
@@ -84,7 +85,7 @@ class Projects::WikisController < Projects::ApplicationController
redirect_to(
namespace_project_wiki_path(@project.namespace, @project, :home),
- notice: "Page was successfully deleted"
+ notice: "维基删除成功"
)
end
@@ -99,7 +100,7 @@ class Projects::WikisController < Projects::ApplicationController
# Call #wiki to make sure the Wiki Repo is initialized
@project_wiki.wiki
rescue ProjectWiki::CouldNotCreateWikiError
- flash[:notice] = "Could not create Wiki Repository at this time. Please try again later."
+ flash[:notice] = "现在不能创建维基版本仓库。请稍后重试。"
redirect_to project_path(@project)
return false
end
diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb
index 928817ba811..fb90266476a 100644
--- a/app/controllers/projects_controller.rb
+++ b/app/controllers/projects_controller.rb
@@ -30,7 +30,7 @@ class ProjectsController < Projects::ApplicationController
if @project.saved?
redirect_to(
project_path(@project),
- notice: "Project '#{@project.name}' was successfully created."
+ notice: "项目 '#{@project.name}' 创建成功。"
)
else
render 'new'
@@ -42,11 +42,11 @@ class ProjectsController < Projects::ApplicationController
respond_to do |format|
if status
- flash[:notice] = "Project '#{@project.name}' was successfully updated."
+ flash[:notice] = "项目 '#{@project.name}' 更新成功。"
format.html do
redirect_to(
edit_project_path(@project),
- notice: "Project '#{@project.name}' was successfully updated."
+ notice: "项目 '#{@project.name}' 更新成功。"
)
end
format.js
@@ -72,7 +72,7 @@ class ProjectsController < Projects::ApplicationController
return access_denied! unless can?(current_user, :remove_fork_project, @project)
if @project.unlink_fork
- flash[:notice] = 'The fork relationship has been removed.'
+ flash[:notice] = '派生关系被删除。'
end
end
@@ -93,7 +93,7 @@ class ProjectsController < Projects::ApplicationController
end
if @project.pending_delete?
- flash[:alert] = "Project queued for delete."
+ flash[:alert] = "项目正在排队删除。"
end
respond_to do |format|
@@ -124,7 +124,7 @@ class ProjectsController < Projects::ApplicationController
return access_denied! unless can?(current_user, :remove_project, @project)
::Projects::DestroyService.new(@project, current_user, {}).pending_delete!
- flash[:alert] = "Project '#{@project.name}' will be deleted."
+ flash[:alert] = "项目 '#{@project.name}' 已被删除。"
redirect_to dashboard_projects_path
rescue Projects::DestroyService::DestroyError => ex
diff --git a/app/controllers/registrations_controller.rb b/app/controllers/registrations_controller.rb
index c48175a4c5a..ab0c9f7d8a1 100644
--- a/app/controllers/registrations_controller.rb
+++ b/app/controllers/registrations_controller.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class RegistrationsController < Devise::RegistrationsController
before_action :signup_enabled?
include Recaptcha::Verify
@@ -20,7 +21,7 @@ class RegistrationsController < Devise::RegistrationsController
DeleteUserService.new(current_user).execute(current_user)
respond_to do |format|
- format.html { redirect_to new_user_session_path, notice: "Account successfully removed." }
+ format.html { redirect_to new_user_session_path, notice: "账号删除成功。" }
end
end
diff --git a/app/helpers/appearances_helper.rb b/app/helpers/appearances_helper.rb
index e0abc3a2869..c32f422492f 100644
--- a/app/helpers/appearances_helper.rb
+++ b/app/helpers/appearances_helper.rb
@@ -1,9 +1,10 @@
+#encoding: utf-8
module AppearancesHelper
def brand_title
if brand_item && brand_item.title
brand_item.title
else
- 'GitLab Community Edition'
+ 'GitLab 社区版'
end
end
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index e6ceb213532..e32f94929e5 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
require 'digest/md5'
require 'uri'
@@ -95,24 +96,24 @@ module ApplicationHelper
if project.repo_exists?
time_ago_with_tooltip(project.repository.commit.committed_date)
else
- 'Never'
+ '从未'
end
rescue
- 'Never'
+ '从未'
end
def grouped_options_refs
repository = @project.repository
options = [
- ['Branches', repository.branch_names],
- ['Tags', VersionSorter.rsort(repository.tag_names)]
+ ['分支', repository.branch_names],
+ ['标签', VersionSorter.rsort(repository.tag_names)]
]
# If reference is commit id - we should add it to branch/tag selectbox
if(@ref && !options.flatten.include?(@ref) &&
@ref =~ /\A[0-9a-zA-Z]{6,52}\z/)
- options << ['Commit', [@ref]]
+ options << ['提交', [@ref]]
end
grouped_options_for_select(options, @ref || @project.default_branch)
@@ -292,7 +293,10 @@ module ApplicationHelper
def state_filters_text_for(entity, project)
titles = {
- opened: "Open"
+ opened: "未关闭",
+ closed: "已关闭",
+ merged: "已合并",
+ all: "所有",
}
entity_title = titles[entity] || entity.to_s.humanize
diff --git a/app/helpers/blob_helper.rb b/app/helpers/blob_helper.rb
index 0f77b3b299a..29ca06eb287 100644
--- a/app/helpers/blob_helper.rb
+++ b/app/helpers/blob_helper.rb
@@ -27,9 +27,9 @@ module BlobHelper
link_opts)
if !on_top_of_branch?(project, ref)
- button_tag "Edit", class: "btn btn-default disabled has_tooltip", title: "You can only edit files when you are on a branch", data: { container: 'body' }
+ button_tag "编辑", class: "btn btn-default disabled has_tooltip", title: "你只能在分支上修改编辑文件", data: { container: 'body' }
elsif can_edit_blob?(blob, project, ref)
- link_to "Edit", edit_path, class: 'btn'
+ link_to "编辑", edit_path, class: 'btn'
elsif can?(current_user, :fork_project, project)
continue_params = {
to: edit_path,
@@ -38,7 +38,7 @@ module BlobHelper
}
fork_path = namespace_project_forks_path(project.namespace, project, namespace_key: current_user.namespace.id, continue: continue_params)
- link_to "Edit", fork_path, class: 'btn', method: :post
+ link_to "编辑", fork_path, class: 'btn', method: :post
end
end
@@ -50,9 +50,9 @@ module BlobHelper
return unless blob
if !on_top_of_branch?(project, ref)
- button_tag label, class: "btn btn-#{btn_class} disabled has_tooltip", title: "You can only #{action} files when you are on a branch", data: { container: 'body' }
+ button_tag label, class: "btn btn-#{btn_class} disabled has_tooltip", title: "你只能在分支上#{action}文件", data: { container: 'body' }
elsif blob.lfs_pointer?
- button_tag label, class: "btn btn-#{btn_class} disabled has_tooltip", title: "It is not possible to #{action} files that are stored in LFS using the web interface", data: { container: 'body' }
+ button_tag label, class: "btn btn-#{btn_class} disabled has_tooltip", title: "不能使用网页界面#{action}存储在 LFS 上的文件", data: { container: 'body' }
elsif can_edit_blob?(blob, project, ref)
button_tag label, class: "btn btn-#{btn_class}", 'data-target' => "#modal-#{modal_type}-blob", 'data-toggle' => 'modal'
elsif can?(current_user, :fork_project, project)
@@ -72,7 +72,7 @@ module BlobHelper
project,
ref,
path,
- label: "Replace",
+ label: "替换",
action: "replace",
btn_class: "default",
modal_type: "upload"
@@ -84,7 +84,7 @@ module BlobHelper
project,
ref,
path,
- label: "Delete",
+ label: "删除",
action: "delete",
btn_class: "remove",
modal_type: "remove"
@@ -96,14 +96,14 @@ module BlobHelper
end
def leave_edit_message
- "Leave edit mode?\nAll unsaved changes will be lost."
+ "离开编辑模式?\n所有未保存的修改都会丢失。"
end
def editing_preview_title(filename)
if Gitlab::MarkupHelper.previewable?(filename)
- 'Preview'
+ '预览'
else
- 'Preview Changes'
+ '预览修改'
end
end
diff --git a/app/helpers/broadcast_messages_helper.rb b/app/helpers/broadcast_messages_helper.rb
index 43a29c96bca..7c0ba8fd54f 100644
--- a/app/helpers/broadcast_messages_helper.rb
+++ b/app/helpers/broadcast_messages_helper.rb
@@ -24,11 +24,11 @@ module BroadcastMessagesHelper
def broadcast_message_status(broadcast_message)
if broadcast_message.active?
- 'Active'
+ '当前'
elsif broadcast_message.ended?
- 'Expired'
+ '已过期'
else
- 'Pending'
+ '排队'
end
end
diff --git a/app/helpers/button_helper.rb b/app/helpers/button_helper.rb
index d6c05843743..4fdc319f615 100644
--- a/app/helpers/button_helper.rb
+++ b/app/helpers/button_helper.rb
@@ -35,7 +35,7 @@ module ButtonHelper
clone: project.http_url_to_repo,
container: 'body',
html: 'true',
- title: "Set a password on your account<br>to pull or push via #{protocol}"
+ title: "在账户中设置密码<br>然后再使用 #{protocol} 拉取和推送。"
},
type: :button
end
@@ -51,7 +51,7 @@ module ButtonHelper
clone: project.ssh_url_to_repo,
container: 'body',
html: 'true',
- title: 'Add an SSH key to your profile<br>to pull or push via SSH.'
+ title: '在个人资料中增加 SSH 密钥<br>然后再使用 SSH 拉取和推送。'
},
type: :button
end
diff --git a/app/helpers/ci_status_helper.rb b/app/helpers/ci_status_helper.rb
index 8b1575d5e0c..724146443b8 100644
--- a/app/helpers/ci_status_helper.rb
+++ b/app/helpers/ci_status_helper.rb
@@ -24,9 +24,9 @@ module CiStatusHelper
def ci_label_for_status(status)
if status == 'success'
- 'passed'
+ '通过'
else
- status
+ ci_status_zh(status)
end
end
diff --git a/app/helpers/commits_helper.rb b/app/helpers/commits_helper.rb
index f994c9e6170..b2027c904ac 100644
--- a/app/helpers/commits_helper.rb
+++ b/app/helpers/commits_helper.rb
@@ -1,4 +1,4 @@
-# encoding: utf-8
+#encoding: utf-8
module CommitsHelper
# Returns a link to the commit author. If the author has a matching user and
# is a member of the current @project it will link to the team member page.
@@ -102,14 +102,14 @@ module CommitsHelper
if current_controller?(:projects, :commits)
if @repo.blob_at(commit.id, @path)
return link_to(
- "Browse File »",
+ "浏览文件 »",
namespace_project_blob_path(project.namespace, project,
tree_join(commit.id, @path)),
class: "pull-right"
)
elsif @path.present?
return link_to(
- "Browse Directory »",
+ "浏览目录 »",
namespace_project_tree_path(project.namespace, project,
tree_join(commit.id, @path)),
class: "pull-right"
@@ -117,7 +117,7 @@ module CommitsHelper
end
end
link_to(
- "Browse Files »",
+ "浏览文件 »",
namespace_project_tree_path(project.namespace, project, commit),
class: "pull-right"
)
@@ -126,11 +126,11 @@ module CommitsHelper
def revert_commit_link(commit, continue_to_path, btn_class: nil)
return unless current_user
- tooltip = "Revert this #{revert_commit_type(commit)} in a new merge request"
+ tooltip = "在新的合并请求中恢复此#{revert_commit_type(commit)}"
if can_collaborate_with_project?
content_tag :span, 'data-toggle' => 'modal', 'data-target' => '#modal-revert-commit' do
- link_to 'Revert', '#modal-revert-commit', 'data-toggle' => 'tooltip', 'data-container' => 'body', title: tooltip, class: "btn btn-default btn-grouped btn-#{btn_class}"
+ link_to '恢复', '#modal-revert-commit', 'data-toggle' => 'tooltip', 'data-container' => 'body', title: tooltip, class: "btn btn-default btn-grouped btn-#{btn_class}"
end
elsif can?(current_user, :fork_project, @project)
continue_params = {
@@ -142,15 +142,15 @@ module CommitsHelper
namespace_key: current_user.namespace.id,
continue: continue_params)
- link_to 'Revert', fork_path, class: 'btn btn-grouped btn-close', method: :post, 'data-toggle' => 'tooltip', 'data-container' => 'body', title: tooltip
+ link_to '恢复', fork_path, class: 'btn btn-grouped btn-close', method: :post, 'data-toggle' => 'tooltip', 'data-container' => 'body', title: tooltip
end
end
def revert_commit_type(commit)
if commit.merged_merge_request
- 'merge request'
+ '合并请求'
else
- 'commit'
+ '提交'
end
end
@@ -199,7 +199,7 @@ module CommitsHelper
tree_join(commit_sha, diff.new_path)),
class: 'btn view-file js-view-file'
) do
- raw('View file @') + content_tag(:span, commit_sha[0..6],
+ raw('查看文件 @') + content_tag(:span, commit_sha[0..6],
class: 'commit-short-id')
end
end
diff --git a/app/helpers/diff_helper.rb b/app/helpers/diff_helper.rb
index ff32e834499..6948f097fc8 100644
--- a/app/helpers/diff_helper.rb
+++ b/app/helpers/diff_helper.rb
@@ -67,11 +67,11 @@ module DiffHelper
end
def inline_diff_btn
- diff_btn('Inline', 'inline', diff_view == 'inline')
+ diff_btn('内嵌', 'inline', diff_view == 'inline')
end
def parallel_diff_btn
- diff_btn('Side-by-side', 'parallel', diff_view == 'parallel')
+ diff_btn('并排对比', 'parallel', diff_view == 'parallel')
end
def submodule_link(blob, ref, repository = @repository)
diff --git a/app/helpers/emails_helper.rb b/app/helpers/emails_helper.rb
index 41b5bd7be90..9e1d86ddbef 100644
--- a/app/helpers/emails_helper.rb
+++ b/app/helpers/emails_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module EmailsHelper
# Google Actions
@@ -41,19 +42,19 @@ module EmailsHelper
def password_reset_token_valid_time
valid_hours = Devise.reset_password_within / 60 / 60
if valid_hours >= 24
- unit = 'day'
+ unit = '天'
valid_length = (valid_hours / 24).floor
else
- unit = 'hour'
+ unit = '小时'
valid_length = valid_hours.floor
end
- pluralize(valid_length, unit)
+ pluralize(valid_length, unit, unit)
end
def reset_token_expire_message
- link_tag = link_to('request a new one', new_user_password_url(user_email: @user.email))
- msg = "This link is valid for #{password_reset_token_valid_time}. "
- msg << "After it expires, you can #{link_tag}."
+ link_tag = link_to('申请一个新的', new_user_password_url(user_email: @user.email))
+ msg = "此链接在 #{password_reset_token_valid_time}内有效。"
+ msg << "过期后请#{link_tag}。"
end
end
diff --git a/app/helpers/events_helper.rb b/app/helpers/events_helper.rb
index a67a6b208e2..e127a16a09a 100644
--- a/app/helpers/events_helper.rb
+++ b/app/helpers/events_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module EventsHelper
def link_to_author(event)
author = event.author
@@ -29,7 +30,7 @@ module EventsHelper
link_opts = {
class: "event-filter-link",
id: "#{key}_event_filter",
- title: "Filter by #{tooltip.downcase}",
+ title: "#{tooltip.downcase}过滤",
}
content_tag :li, class: active do
@@ -177,7 +178,7 @@ module EventsHelper
end
else
content_tag :strong do
- "(deleted)"
+ "(已删除)"
end
end
end
diff --git a/app/helpers/gitlab_markdown_helper.rb b/app/helpers/gitlab_markdown_helper.rb
index 2f760af02fd..74da575e064 100644
--- a/app/helpers/gitlab_markdown_helper.rb
+++ b/app/helpers/gitlab_markdown_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
require 'nokogiri'
module GitlabMarkdownHelper
@@ -117,21 +118,21 @@ module GitlabMarkdownHelper
end
MARKDOWN_TIPS = [
- "End a line with two or more spaces for a line-break, or soft-return",
- "Inline code can be denoted by `surrounding it with backticks`",
- "Blocks of code can be denoted by three backticks ``` or four leading spaces",
- "Emoji can be added by :emoji_name:, for example :thumbsup:",
- "Notify other participants using @user_name",
- "Notify a specific group using @group_name",
- "Notify the entire team using @all",
- "Reference an issue using a hash, for example issue #123",
- "Reference a merge request using an exclamation point, for example MR !123",
- "Italicize words or phrases using *asterisks* or _underscores_",
- "Bold words or phrases using **double asterisks** or __double underscores__",
- "Strikethrough words or phrases using ~~two tildes~~",
- "Make a bulleted list using + pluses, - minuses, or * asterisks",
- "Denote blockquotes using > at the beginning of a line",
- "Make a horizontal line using three or more hyphens ---, asterisks ***, or underscores ___"
+ "行中断(软换行)是在行尾使用两个或更多的空格",
+ "可以用 `英文反引号包围` 来内嵌代码",
+ "使用三个 ``` 英文反引号或行首四个空格来声明代码块",
+ "可以使用 :emoji_name: 代码来插入 Emoji 表情,比如 :thumbsup:",
+ "使用 @user_name 通知其他参与者",
+ "使用 @group_name 通知指定的群组",
+ "使用 @all 通知整个团队",
+ "使用英文 # 井号引用指定 id 的问题,比如 #123",
+ "使用英文 ! 感叹号引用指定 id 的合并请求,比如 !123",
+ "使用英文 *星号* or _下划线_ 标记指定的单词或短语为斜体",
+ "使用英文 **双星号** 或 __双下划线__ 标记指定的单词或短语为粗体",
+ "使用英文 ~~双波浪号~~ 标记指定的单词或短语为删除线",
+ "可以在行首使用英文 + 加号、- 减号 或 * 星号标记一个带符号列表",
+ "可以在行首使用英文 > 大于号表示引用",
+ "使用三个或更多的英文 --- 减号、*** 星号或 ___ 下划线来标记一个横线"
].freeze
# Returns a random markdown tip for use as a textarea placeholder
diff --git a/app/helpers/groups_helper.rb b/app/helpers/groups_helper.rb
index b1f0a765bb9..3d563ad74c9 100644
--- a/app/helpers/groups_helper.rb
+++ b/app/helpers/groups_helper.rb
@@ -1,14 +1,15 @@
+#encoding: utf-8
module GroupsHelper
def remove_user_from_group_message(group, member)
if member.user
- "Are you sure you want to remove \"#{member.user.name}\" from \"#{group.name}\"?"
+ "确定要从 \"#{group.name}\" 删除 \"#{member.user.name}\"?"
else
- "Are you sure you want to revoke the invitation for \"#{member.invite_email}\" to join \"#{group.name}\"?"
+ "确定要收回邀请 \"#{member.invite_email}\" 加入到 \"#{group.name}\"?"
end
end
def leave_group_message(group)
- "Are you sure you want to leave \"#{group}\" group?"
+ "确定要离开 \"#{group}\" 群组么?"
end
def should_user_see_group_roles?(user, group)
diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb
index 24b90fef4fe..cd630bb6973 100644
--- a/app/helpers/issues_helper.rb
+++ b/app/helpers/issues_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module IssuesHelper
def issue_css_classes(issue)
classes = "issue"
@@ -10,7 +11,7 @@ module IssuesHelper
# to allow filtering issues by an unassigned User or Milestone
def unassigned_filter
# Milestone uses :title, Issue uses :name
- OpenStruct.new(id: 0, title: 'None (backlog)', name: 'Unassigned')
+ OpenStruct.new(id: 0, title: '无 (积压)', name: '未指派')
end
def url_for_project_issues(project = @project, options = {})
diff --git a/app/helpers/milestones_helper.rb b/app/helpers/milestones_helper.rb
index c9d8787bd19..8f03dae5ff2 100644
--- a/app/helpers/milestones_helper.rb
+++ b/app/helpers/milestones_helper.rb
@@ -56,11 +56,11 @@ module MilestonesHelper
def milestone_remaining_days(milestone)
if milestone.expired?
- content_tag(:strong, 'expired')
+ content_tag(:strong, '已过期')
elsif milestone.due_date
days = milestone.remaining_days
content = content_tag(:strong, days)
- content << " #{'day'.pluralize(days)} remaining"
+ content << "剩余 #{'day'.pluralize(days)}"
end
end
end
diff --git a/app/helpers/namespaces_helper.rb b/app/helpers/namespaces_helper.rb
index faba418c4db..e29cf69345a 100644
--- a/app/helpers/namespaces_helper.rb
+++ b/app/helpers/namespaces_helper.rb
@@ -3,8 +3,8 @@ module NamespacesHelper
groups = current_user.owned_groups + current_user.masters_groups
users = [current_user.namespace]
- group_opts = ["Groups", groups.sort_by(&:human_name).map {|g| [display_path ? g.path : g.human_name, g.id]} ]
- users_opts = [ "Users", users.sort_by(&:human_name).map {|u| [display_path ? u.path : u.human_name, u.id]} ]
+ group_opts = ["群组", groups.sort_by(&:human_name).map {|g| [display_path ? g.path : g.human_name, g.id]} ]
+ users_opts = [ "用户", users.sort_by(&:human_name).map {|u| [display_path ? u.path : u.human_name, u.id]} ]
options = []
options << group_opts
diff --git a/app/helpers/notes_helper.rb b/app/helpers/notes_helper.rb
index 53c543c28c5..e8b9a50c3e2 100644
--- a/app/helpers/notes_helper.rb
+++ b/app/helpers/notes_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module NotesHelper
# Helps to distinguish e.g. commit notes in mr notes list
def note_for_main_target?(note)
@@ -50,7 +51,7 @@ module NotesHelper
button_tag(class: 'btn add-diff-note js-add-diff-note-button',
data: data,
- title: 'Add a comment to this line') do
+ title: '在此行增加注释') do
icon('comment-o')
end
end
@@ -68,9 +69,9 @@ module NotesHelper
}
button_tag class: 'btn btn-nr reply-btn js-discussion-reply-button',
- data: data, title: 'Add a reply' do
+ data: data, title: '增加回复' do
link_text = icon('comment')
- link_text << ' Reply'
+ link_text << ' 回复'
end
end
end
diff --git a/app/helpers/notifications_helper.rb b/app/helpers/notifications_helper.rb
index 499c655d2bf..510e01ecf71 100644
--- a/app/helpers/notifications_helper.rb
+++ b/app/helpers/notifications_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module NotificationsHelper
include IconsHelper
@@ -16,15 +17,15 @@ module NotificationsHelper
def notification_list_item(notification_level, user_membership)
case notification_level
when Notification::N_DISABLED
- update_notification_link(Notification::N_DISABLED, user_membership, 'Disabled', 'microphone-slash')
+ update_notification_link(Notification::N_DISABLED, user_membership, '关闭', 'microphone-slash')
when Notification::N_PARTICIPATING
- update_notification_link(Notification::N_PARTICIPATING, user_membership, 'Participate', 'volume-up')
+ update_notification_link(Notification::N_PARTICIPATING, user_membership, '参与', 'volume-up')
when Notification::N_WATCH
- update_notification_link(Notification::N_WATCH, user_membership, 'Watch', 'eye')
+ update_notification_link(Notification::N_WATCH, user_membership, '关注', 'eye')
when Notification::N_MENTION
- update_notification_link(Notification::N_MENTION, user_membership, 'On mention', 'at')
+ update_notification_link(Notification::N_MENTION, user_membership, '被提及', 'at')
when Notification::N_GLOBAL
- update_notification_link(Notification::N_GLOBAL, user_membership, 'Global', 'globe')
+ update_notification_link(Notification::N_GLOBAL, user_membership, '全局', 'globe')
else
# do nothing
end
diff --git a/app/helpers/preferences_helper.rb b/app/helpers/preferences_helper.rb
index c73cb3028ee..acd70a749fd 100644
--- a/app/helpers/preferences_helper.rb
+++ b/app/helpers/preferences_helper.rb
@@ -2,17 +2,17 @@
module PreferencesHelper
def layout_choices
[
- ['Fixed', :fixed],
- ['Fluid', :fluid]
+ ['固定', :fixed],
+ ['自适应', :fluid]
]
end
# Maps `dashboard` values to more user-friendly option text
DASHBOARD_CHOICES = {
- projects: 'Your Projects (default)',
- stars: 'Starred Projects',
- project_activity: "Your Projects' Activity",
- starred_project_activity: "Starred Projects' Activity"
+ projects: '你的项目 (默认)',
+ stars: '星标项目',
+ project_activity: "你的项目活动",
+ starred_project_activity: "星标项目活动"
}.with_indifferent_access.freeze
# Returns an Array usable by a select field for more user-friendly option text
@@ -33,9 +33,9 @@ module PreferencesHelper
def project_view_choices
[
- ['Readme (default)', :readme],
- ['Activity view', :activity],
- ['Files view', :files]
+ ['Readme (默认)', :readme],
+ ['活动视图', :activity],
+ ['文件视图', :files]
]
end
diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb
index 5473419ef24..a6a7e354ae6 100644
--- a/app/helpers/projects_helper.rb
+++ b/app/helpers/projects_helper.rb
@@ -1,9 +1,10 @@
+#encoding: utf-8
module ProjectsHelper
def remove_from_project_team_message(project, member)
if member.user
- "You are going to remove #{member.user.name} from #{project.name} project team. Are you sure?"
+ "将要从 #{project.name} 项目组删除 #{member.user.name}。确定要继续么?"
else
- "You are going to revoke the invitation for #{member.invite_email} to join #{project.name} project team. Are you sure?"
+ "将要收回邀请 #{member.invite_email} 加入到 #{project.name} 项目组。确定要继续么?"
end
end
@@ -30,7 +31,7 @@ module ProjectsHelper
default_opts = { avatar: true, name: true, size: 16, author_class: 'author', title: ":name" }
opts = default_opts.merge(opts)
- return "(deleted)" unless author
+ return "(已删除)" unless author
author_html = ""
@@ -85,15 +86,15 @@ module ProjectsHelper
end
def remove_project_message(project)
- "You are going to remove #{project.name_with_namespace}.\n Removed project CANNOT be restored!\n Are you ABSOLUTELY sure?"
+ "将要删除 #{project.name_with_namespace} 。\n 删除项目后无法恢复!\n 百分之百确定要继续么?"
end
def transfer_project_message(project)
- "You are going to transfer #{project.name_with_namespace} to another owner. Are you ABSOLUTELY sure?"
+ "将要转移 #{project.name_with_namespace} 给其他人。百分之百确定要继续么?"
end
def remove_fork_project_message(project)
- "You are going to remove the fork relationship to source project #{@project.forked_from_project.name_with_namespace}. Are you ABSOLUTELY sure?"
+ "将要删除从源项目 #{@project.forked_from_project.name_with_namespace} 的派生关系。百分之百确定要继续么?"
end
def project_nav_tabs
@@ -196,7 +197,7 @@ module ProjectsHelper
# In order to prevent 500 error
# when application cannot allocate memory
# to calculate repo size - just show 'Unknown'
- 'unknown'
+ '未知'
end
def default_url_to_repo(project = @project)
@@ -219,7 +220,7 @@ module ProjectsHelper
if project.last_activity_at
time_ago_with_tooltip(project.last_activity_at, placement: 'bottom', html_class: 'last_activity_time_ago')
else
- "Never"
+ "从未"
end
end
@@ -303,7 +304,7 @@ module ProjectsHelper
end
def leave_project_message(project)
- "Are you sure you want to leave \"#{project.name}\" project?"
+ "确认要要离开 \"#{project.name}\" 项目么?"
end
def new_readme_path
diff --git a/app/helpers/search_helper.rb b/app/helpers/search_helper.rb
index 494dad0b41e..bb61fc1d5c1 100644
--- a/app/helpers/search_helper.rb
+++ b/app/helpers/search_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module SearchHelper
def search_autocomplete_opts(term)
return unless current_user
@@ -52,16 +53,16 @@ module SearchHelper
ref = @ref || @project.repository.root_ref
[
- { label: "#{prefix} - Files", url: namespace_project_tree_path(@project.namespace, @project, ref) },
- { label: "#{prefix} - Commits", url: namespace_project_commits_path(@project.namespace, @project, ref) },
- { label: "#{prefix} - Network", url: namespace_project_network_path(@project.namespace, @project, ref) },
- { label: "#{prefix} - Graph", url: namespace_project_graph_path(@project.namespace, @project, ref) },
- { label: "#{prefix} - Issues", url: namespace_project_issues_path(@project.namespace, @project) },
- { label: "#{prefix} - Merge Requests", url: namespace_project_merge_requests_path(@project.namespace, @project) },
- { label: "#{prefix} - Milestones", url: namespace_project_milestones_path(@project.namespace, @project) },
- { label: "#{prefix} - Snippets", url: namespace_project_snippets_path(@project.namespace, @project) },
- { label: "#{prefix} - Members", url: namespace_project_project_members_path(@project.namespace, @project) },
- { label: "#{prefix} - Wiki", url: namespace_project_wikis_path(@project.namespace, @project) },
+ { label: "#{prefix} - 文件", url: namespace_project_tree_path(@project.namespace, @project, ref) },
+ { label: "#{prefix} - 提交", url: namespace_project_commits_path(@project.namespace, @project, ref) },
+ { label: "#{prefix} - 网络", url: namespace_project_network_path(@project.namespace, @project, ref) },
+ { label: "#{prefix} - 图表", url: namespace_project_graph_path(@project.namespace, @project, ref) },
+ { label: "#{prefix} - 问题", url: namespace_project_issues_path(@project.namespace, @project) },
+ { label: "#{prefix} - 合并请求", url: namespace_project_merge_requests_path(@project.namespace, @project) },
+ { label: "#{prefix} - 里程碑", url: namespace_project_milestones_path(@project.namespace, @project) },
+ { label: "#{prefix} - 代码脚本", url: namespace_project_snippets_path(@project.namespace, @project) },
+ { label: "#{prefix} - 成员", url: namespace_project_project_members_path(@project.namespace, @project) },
+ { label: "#{prefix} - 维基", url: namespace_project_wikis_path(@project.namespace, @project) },
]
else
[]
@@ -72,7 +73,7 @@ module SearchHelper
def groups_autocomplete(term, limit = 5)
current_user.authorized_groups.search(term).limit(limit).map do |group|
{
- label: "group: #{search_result_sanitize(group.name)}",
+ label: "群组: #{search_result_sanitize(group.name)}",
url: group_path(group)
}
end
@@ -83,7 +84,7 @@ module SearchHelper
current_user.authorized_projects.search_by_title(term).
sorted_by_stars.non_archived.limit(limit).map do |p|
{
- label: "project: #{search_result_sanitize(p.name_with_namespace)}",
+ label: "项目: #{search_result_sanitize(p.name_with_namespace)}",
url: namespace_project_path(p.namespace, p)
}
end
diff --git a/app/helpers/selects_helper.rb b/app/helpers/selects_helper.rb
index 05386d790ca..cdd1b77ea2b 100644
--- a/app/helpers/selects_helper.rb
+++ b/app/helpers/selects_helper.rb
@@ -1,10 +1,11 @@
+#encoding: utf-8
module SelectsHelper
def users_select_tag(id, opts = {})
css_class = "ajax-users-select "
css_class << "multiselect " if opts[:multiple]
css_class << (opts[:class] || '')
value = opts[:selected] || ''
- placeholder = opts[:placeholder] || 'Search for a user'
+ placeholder = opts[:placeholder] || '选择用户'
null_user = opts[:null_user] || false
any_user = opts[:any_user] || false
diff --git a/app/helpers/sorting_helper.rb b/app/helpers/sorting_helper.rb
index 2f2d2721d6d..550ca5a1eb0 100644
--- a/app/helpers/sorting_helper.rb
+++ b/app/helpers/sorting_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module SortingHelper
def sort_options_hash
{
@@ -27,51 +28,51 @@ module SortingHelper
end
def sort_title_oldest_updated
- 'Oldest updated'
+ '最旧更新的'
end
def sort_title_recently_updated
- 'Last updated'
+ '最近更新的'
end
def sort_title_oldest_created
- 'Oldest created'
+ '最旧创建的'
end
def sort_title_recently_created
- 'Last created'
+ '最近创建的'
end
def sort_title_milestone_soon
- 'Milestone due soon'
+ '最近的里程碑'
end
def sort_title_milestone_later
- 'Milestone due later'
+ '最旧的里程碑'
end
def sort_title_name
- 'Name'
+ '名称'
end
def sort_title_largest_repo
- 'Largest repository'
+ '最大的仓库'
end
def sort_title_recently_signin
- 'Recent sign in'
+ '最近登录'
end
def sort_title_oldest_signin
- 'Oldest sign in'
+ '最旧登录'
end
def sort_title_downvotes
- 'Least popular'
+ '最不受欢迎'
end
def sort_title_upvotes
- 'Most popular'
+ '最受欢迎'
end
def sort_value_oldest_updated
diff --git a/app/helpers/time_helper.rb b/app/helpers/time_helper.rb
index 8142f733e76..7b2eed5c2c5 100644
--- a/app/helpers/time_helper.rb
+++ b/app/helpers/time_helper.rb
@@ -14,14 +14,14 @@ module TimeHelper
seconds = interval_in_seconds - minutes * 60
if minutes >= 1
- "#{pluralize(minutes, "minute")} #{pluralize(seconds, "second")}"
+ "#{pluralize(minutes, "分", "分")} #{pluralize(seconds, "秒", "秒")}"
else
- "#{pluralize(seconds, "second")}"
+ "#{pluralize(seconds, "秒", "秒")}"
end
end
def date_from_to(from, to)
- "#{from.to_s(:short)} - #{to.to_s(:short)}"
+ "#{from.strftime('%m-%d')} - #{to.strftime('%m-%d')}"
end
end
diff --git a/app/helpers/todos_helper.rb b/app/helpers/todos_helper.rb
index edc5686cf08..9d9135ee8ef 100644
--- a/app/helpers/todos_helper.rb
+++ b/app/helpers/todos_helper.rb
@@ -59,9 +59,9 @@ module TodosHelper
def todo_actions_options
actions = [
- OpenStruct.new(id: '', title: 'Any Action'),
- OpenStruct.new(id: Todo::ASSIGNED, title: 'Assigned'),
- OpenStruct.new(id: Todo::MENTIONED, title: 'Mentioned')
+ OpenStruct.new(id: '', title: '任何动作'),
+ OpenStruct.new(id: Todo::ASSIGNED, title: '被指派'),
+ OpenStruct.new(id: Todo::MENTIONED, title: '被提及')
]
options_from_collection_for_select(actions, 'id', 'title', params[:action_id])
@@ -75,16 +75,16 @@ module TodosHelper
OpenStruct.new(id: project.id, title: project.name_with_namespace)
end
- projects.unshift(OpenStruct.new(id: '', title: 'Any Project'))
+ projects.unshift(OpenStruct.new(id: '', title: '任何项目'))
options_from_collection_for_select(projects, 'id', 'title', params[:project_id])
end
def todo_types_options
types = [
- OpenStruct.new(title: 'Any Type', name: ''),
- OpenStruct.new(title: 'Issue', name: 'Issue'),
- OpenStruct.new(title: 'Merge Request', name: 'MergeRequest')
+ OpenStruct.new(title: '任何类型', name: ''),
+ OpenStruct.new(title: '问题', name: 'Issue'),
+ OpenStruct.new(title: '合并请求', name: 'MergeRequest')
]
options_from_collection_for_select(types, 'name', 'title', params[:type])
diff --git a/app/helpers/visibility_level_helper.rb b/app/helpers/visibility_level_helper.rb
index 3a83ae15dd8..0bb3c1e1c0f 100644
--- a/app/helpers/visibility_level_helper.rb
+++ b/app/helpers/visibility_level_helper.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module VisibilityLevelHelper
def visibility_level_color(level)
case level
@@ -29,11 +30,11 @@ module VisibilityLevelHelper
def project_visibility_level_description(level)
case level
when Gitlab::VisibilityLevel::PRIVATE
- "Project access must be granted explicitly to each user."
+ "项目必须明确授权给每个用户访问。"
when Gitlab::VisibilityLevel::INTERNAL
- "The project can be cloned by any logged in user."
+ "项目可以被所有已登录用户克隆。"
when Gitlab::VisibilityLevel::PUBLIC
- "The project can be cloned without any authentication."
+ "项目可以被任何用户克隆。"
end
end
@@ -52,14 +53,14 @@ module VisibilityLevelHelper
case level
when Gitlab::VisibilityLevel::PRIVATE
if snippet.is_a? ProjectSnippet
- "The snippet is visible only to project members."
+ "该代码片段只有项目成员能看到。"
else
- "The snippet is visible only to me."
+ "该代码片段只有自己能看到。"
end
when Gitlab::VisibilityLevel::INTERNAL
- "The snippet is visible to any logged in user."
+ "该代码片段任何已登录用户都可以看到。"
when Gitlab::VisibilityLevel::PUBLIC
- "The snippet can be accessed without any authentication."
+ "该代码片段可以被任何授权的用户访问。"
end
end
diff --git a/app/models/concerns/taskable.rb b/app/models/concerns/taskable.rb
index df2a9e3e84b..01955d2007c 100644
--- a/app/models/concerns/taskable.rb
+++ b/app/models/concerns/taskable.rb
@@ -57,6 +57,6 @@ module Taskable
return '' if description.blank?
sum = tasks.summary
- "#{sum.item_count} tasks (#{sum.complete_count} completed, #{sum.incomplete_count} remaining)"
+ "#{sum.item_count} 个任务(#{sum.complete_count} 个已完成,剩余 #{sum.incomplete_count} 个)"
end
end
diff --git a/app/models/issue.rb b/app/models/issue.rb
index f32db59ac9f..9ba7c66c14a 100644
--- a/app/models/issue.rb
+++ b/app/models/issue.rb
@@ -127,6 +127,10 @@ class Issue < ActiveRecord::Base
project
end
+ def zh_name
+ '问题'
+ end
+
# From all notes on this issue, we'll select the system notes about linked
# merge requests. Of those, the MRs closing `self` are returned.
def closed_by_merge_requests(current_user = nil)
diff --git a/app/models/label.rb b/app/models/label.rb
index f7ffc0b7f36..814945628d0 100644
--- a/app/models/label.rb
+++ b/app/models/label.rb
@@ -19,8 +19,8 @@ class Label < ActiveRecord::Base
# Represents a "No Label" state used for filtering Issues and Merge
# Requests that have no label assigned.
LabelStruct = Struct.new(:title, :name)
- None = LabelStruct.new('No Label', 'No Label')
- Any = LabelStruct.new('Any Label', '')
+ None = LabelStruct.new('无标记', 'No Label')
+ Any = LabelStruct.new('任何标记', '')
DEFAULT_COLOR = '#428BCA'
diff --git a/app/models/merge_request.rb b/app/models/merge_request.rb
index ef48207f956..c527bbcf6ea 100644
--- a/app/models/merge_request.rb
+++ b/app/models/merge_request.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
# == Schema Information
#
# Table name: merge_requests
diff --git a/app/models/milestone.rb b/app/models/milestone.rb
index de7183bf6b4..b8bb94d6366 100644
--- a/app/models/milestone.rb
+++ b/app/models/milestone.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
# == Schema Information
#
# Table name: milestones
@@ -110,9 +111,9 @@ class Milestone < ActiveRecord::Base
def expires_at
if due_date
if due_date.past?
- "expired on #{due_date.to_s(:medium)}"
+ "过期时间 #{due_date.to_s(:medium)}"
else
- "expires on #{due_date.to_s(:medium)}"
+ "过期时间 #{due_date.to_s(:medium)}"
end
end
end
diff --git a/app/models/notification.rb b/app/models/notification.rb
index 171b8df45c2..c643446cec0 100644
--- a/app/models/notification.rb
+++ b/app/models/notification.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
class Notification
#
# Notification levels
@@ -17,11 +18,11 @@ class Notification
def options_with_labels
{
- disabled: N_DISABLED,
- participating: N_PARTICIPATING,
- watch: N_WATCH,
- mention: N_MENTION,
- global: N_GLOBAL
+ 关闭: N_DISABLED,
+ 参与: N_PARTICIPATING,
+ 关注: N_WATCH,
+ 提及: N_MENTION,
+ 全局: N_GLOBAL
}
end
@@ -61,15 +62,15 @@ class Notification
def to_s
case level
when N_DISABLED
- 'Disabled'
+ '关闭'
when N_PARTICIPATING
- 'Participating'
+ '参与'
when N_WATCH
- 'Watching'
+ '关注'
when N_MENTION
- 'On mention'
+ '被提及'
when N_GLOBAL
- 'Global'
+ '全局'
else
# do nothing
end
diff --git a/app/services/merge_requests/build_service.rb b/app/services/merge_requests/build_service.rb
index 6e9152e444e..3dc0d5b42c7 100644
--- a/app/services/merge_requests/build_service.rb
+++ b/app/services/merge_requests/build_service.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module MergeRequests
class BuildService < MergeRequests::BaseService
def execute
@@ -13,7 +14,7 @@ module MergeRequests
if merge_request.target_branch.blank? || merge_request.source_branch.blank?
message =
if params[:source_branch] || params[:target_branch]
- "You must select source and target branch"
+ "必须选择来源和目标分支"
end
return build_failed(merge_request, message)
diff --git a/app/views/abuse_report_mailer/notify.html.haml b/app/views/abuse_report_mailer/notify.html.haml
index 2741eb44357..461196b41f9 100644
--- a/app/views/abuse_report_mailer/notify.html.haml
+++ b/app/views/abuse_report_mailer/notify.html.haml
@@ -1,11 +1,11 @@
%p
#{link_to @abuse_report.user.name, user_url(@abuse_report.user)}
- (@#{@abuse_report.user.username}) was reported for abuse by
+ (@#{@abuse_report.user.username}) 被
#{link_to @abuse_report.reporter.name, user_url(@abuse_report.reporter)}
- (@#{@abuse_report.reporter.username}).
+ (@#{@abuse_report.reporter.username}) 举报为滥用行为。
%blockquote
= @abuse_report.message
%p
- = link_to "View details", admin_abuse_reports_url
+ = link_to "查看明细", admin_abuse_reports_url
diff --git a/app/views/abuse_report_mailer/notify.text.haml b/app/views/abuse_report_mailer/notify.text.haml
index 7dacf857035..3e3d8d20d77 100644
--- a/app/views/abuse_report_mailer/notify.text.haml
+++ b/app/views/abuse_report_mailer/notify.text.haml
@@ -1,5 +1,5 @@
-#{@abuse_report.user.name} (@#{@abuse_report.user.username}) was reported for abuse by #{@abuse_report.reporter.name} (@#{@abuse_report.reporter.username}).
+#{@abuse_report.user.name} (@#{@abuse_report.user.username}) 被 #{@abuse_report.reporter.name} (@#{@abuse_report.reporter.username}) 举报为滥用行为。
\
> #{@abuse_report.message}
\
-View details: #{admin_abuse_reports_url}
+查看明细: #{admin_abuse_reports_url}
diff --git a/app/views/admin/abuse_reports/_abuse_report.html.haml b/app/views/admin/abuse_reports/_abuse_report.html.haml
index 2ab01704b77..b35a007671b 100644
--- a/app/views/admin/abuse_reports/_abuse_report.html.haml
+++ b/app/views/admin/abuse_reports/_abuse_report.html.haml
@@ -5,27 +5,27 @@
- if user
= link_to user.name, [:admin, user]
.light.small
- Joined #{time_ago_with_tooltip(user.created_at)}
+ 加入时间:#{time_ago_with_tooltip(user.created_at)}
- else
- (removed)
+ (已删除)
%td
- if reporter
= link_to reporter.name, [:admin, reporter]
- else
- (removed)
+ (已删除)
.light.small
= time_ago_with_tooltip(abuse_report.created_at)
%td
= markdown(abuse_report.message.squish!, pipeline: :single_line)
%td
- if user
- = link_to 'Remove user & report', admin_abuse_report_path(abuse_report, remove_user: true),
- data: { confirm: "USER #{user.name} WILL BE REMOVED! Are you sure?" }, remote: true, method: :delete, class: "btn btn-xs btn-remove js-remove-tr"
+ = link_to '删除用户和举报', admin_abuse_report_path(abuse_report, remove_user: true),
+ data: { confirm: "确定要删除 #{user.name} 用户么?" }, remote: true, method: :delete, class: "btn btn-xs btn-remove js-remove-tr"
%td
- if user && !user.blocked?
- = link_to 'Block user', block_admin_user_path(user), data: {confirm: 'USER WILL BE BLOCKED! Are you sure?'}, method: :put, class: "btn btn-xs"
+ = link_to '禁用用户', block_admin_user_path(user), data: {confirm: '确定要禁用用户么?'}, method: :put, class: "btn btn-xs"
- else
.btn.btn-xs.disabled
- Already Blocked
- = link_to 'Remove report', [:admin, abuse_report], remote: true, method: :delete, class: "btn btn-xs btn-close js-remove-tr"
+ 已被禁用
+ = link_to '删除举报', [:admin, abuse_report], remote: true, method: :delete, class: "btn btn-xs btn-close js-remove-tr"
diff --git a/app/views/admin/abuse_reports/index.html.haml b/app/views/admin/abuse_reports/index.html.haml
index bc4a9cedb2c..703c3b1a768 100644
--- a/app/views/admin/abuse_reports/index.html.haml
+++ b/app/views/admin/abuse_reports/index.html.haml
@@ -1,17 +1,17 @@
-- page_title "Abuse Reports"
-%h3.page-title Abuse Reports
+- page_title "滥用举报"
+%h3.page-title 滥用举报
%hr
- if @abuse_reports.present?
.table-holder
%table.table
%thead
%tr
- %th User
- %th Reported by
- %th Message
- %th Primary action
+ %th 被举报用户
+ %th 举报人
+ %th 信息
+ %th 操作
%th
= render @abuse_reports
= paginate @abuse_reports
- else
- %h4 There are no abuse reports
+ %h4 没有滥用举报
diff --git a/app/views/admin/appearances/_form.html.haml b/app/views/admin/appearances/_form.html.haml
index 6f325914d14..e1efab88b69 100644
--- a/app/views/admin/appearances/_form.html.haml
+++ b/app/views/admin/appearances/_form.html.haml
@@ -6,17 +6,17 @@
%fieldset.sign-in
%legend
- Sign in/Sign up pages:
+ 登入/注册页面:
.form-group
- = f.label :title, class: 'control-label'
+ = f.label :title, "标题", class: 'control-label'
.col-sm-10
= f.text_field :title, class: "form-control"
.form-group
- = f.label :description, class: 'control-label'
+ = f.label :description, "描述", class: 'control-label'
.col-sm-10
= f.text_area :description, class: "form-control", rows: 10
.hint
- Description parsed with #{link_to "GitLab Flavored Markdown", help_page_path('markdown', 'markdown'), target: '_blank'}.
+ 描述被解析为 #{link_to "GitLab 特色 Markdown", help_page_path('markdown', 'markdown'), target: '_blank'} 格式。
.form-group
= f.label :logo, class: 'control-label'
.col-sm-10
@@ -24,35 +24,35 @@
= image_tag @appearance.logo_url, class: 'appearance-logo-preview'
- if @appearance.persisted?
%br
- = link_to 'Remove logo', logo_admin_appearances_path, data: { confirm: "Logo will be removed. Are you sure?"}, method: :delete, class: "btn btn-remove btn-small remove-logo"
+ = link_to '删除 Logo', logo_admin_appearances_path, data: { confirm: "确定要删除 Logo 么?"}, method: :delete, class: "btn btn-remove btn-small remove-logo"
%hr
= f.hidden_field :logo_cache
= f.file_field :logo, class: ""
.hint
- Maximum file size is 1MB. Pages are optimized for a 640x360 px logo.
+ 文件最大大小为 1MB。页面是按照 640x360 像素 LOGO 设计。
%fieldset.app_logo
%legend
- Navigation bar:
+ 导航条:
.form-group
- = f.label :header_logo, 'Header logo', class: 'control-label'
+ = f.label :header_logo, '头部 Logo', class: 'control-label'
.col-sm-10
- if @appearance.header_logo?
= image_tag @appearance.header_logo_url, class: 'appearance-light-logo-preview'
- if @appearance.persisted?
%br
- = link_to 'Remove header logo', header_logos_admin_appearances_path, data: { confirm: "Header logo will be removed. Are you sure?"}, method: :delete, class: "btn btn-remove btn-small remove-logo"
+ = link_to '删除头部 Logo', header_logos_admin_appearances_path, data: { confirm: "确定要删除头部 Logo 么?"}, method: :delete, class: "btn btn-remove btn-small remove-logo"
%hr
= f.hidden_field :header_logo_cache
= f.file_field :header_logo, class: ""
.hint
- Maximum file size is 1MB. Pages are optimized for a 72x72 px header logo
+ 文件最大大小为 1MB。页面是按照 72x72 像素头部 LOGO 设计。
.form-actions
- = f.submit 'Save', class: 'btn btn-save'
+ = f.submit '保存', class: 'btn btn-save'
- if @appearance.persisted?
- = link_to 'Preview last save', preview_admin_appearances_path, class: 'btn', target: '_blank'
+ = link_to '预览最后保存', preview_admin_appearances_path, class: 'btn', target: '_blank'
- if @appearance.updated_at
%span.pull-right
- Last edit #{time_ago_with_tooltip(@appearance.updated_at)}
+ 最后编辑:#{time_ago_with_tooltip(@appearance.updated_at)}
diff --git a/app/views/admin/appearances/preview.html.haml b/app/views/admin/appearances/preview.html.haml
index dd4a64e80bc..c77dfbeaacb 100644
--- a/app/views/admin/appearances/preview.html.haml
+++ b/app/views/admin/appearances/preview.html.haml
@@ -1,11 +1,11 @@
-- page_title "Preview | Appearance"
+- page_title "预览 | 外观"
%h3.page-title
- Appearance settings - Preview
+ 外观设置 - 预览
%hr
.ui-box
.title
- Sign-in page
+ 登入页面
%div
.login-page
.container
@@ -23,7 +23,7 @@
= brand_text
.col-sm-4
.login-box
- %h3.page-title Sign in
- = text_field_tag :login, nil, class: "form-control top", placeholder: "Username or Email"
- = password_field_tag :password, nil, class: "form-control bottom", placeholder: "Password"
- = button_tag "Sign in", class: "btn-create btn"
+ %h3.page-title 登入
+ = text_field_tag :login, nil, class: "form-control top", placeholder: "用户名或电子邮箱"
+ = password_field_tag :password, nil, class: "form-control bottom", placeholder: "密码"
+ = button_tag "登入", class: "btn-create btn"
diff --git a/app/views/admin/appearances/show.html.haml b/app/views/admin/appearances/show.html.haml
index 089e8e4cb7a..682ccaa35bc 100644
--- a/app/views/admin/appearances/show.html.haml
+++ b/app/views/admin/appearances/show.html.haml
@@ -1,7 +1,7 @@
-- page_title "Appearance"
+- page_title "外观"
%h3.page-title
- Appearance settings
+ 外观设置
%p.light
- You can modify the look and feel of GitLab here
+ 你可以在这里修改 GitLab 的外观效果
= render 'form'
diff --git a/app/views/admin/application_settings/_form.html.haml b/app/views/admin/application_settings/_form.html.haml
index 0350995d03d..4d4d9723b78 100644
--- a/app/views/admin/application_settings/_form.html.haml
+++ b/app/views/admin/application_settings/_form.html.haml
@@ -252,29 +252,29 @@
.checkbox
= f.label :akismet_enabled do
= f.check_box :akismet_enabled
- Enable Akismet
- %span.help-block#akismet_help_block Helps prevent bots from creating issues
+ 开启 Akismet
+ %span.help-block#akismet_help_block 用户阻止机器人创建问题
.form-group
= f.label :akismet_api_key, 'Akismet API Key', class: 'control-label col-sm-2'
.col-sm-10
= f.text_field :akismet_api_key, class: 'form-control'
.help-block
- Generate API key at
+ 在后面的网址生成 API 密钥(API Key):
%a{ href: 'http://www.akismet.com', target: 'blank'} http://www.akismet.com
%fieldset
- %legend Error Reporting and Logging
+ %legend 错误报告和日志
%p
- These settings require a restart to take effect.
+ 这些设置需要重启才能生效。
.form-group
.col-sm-offset-2.col-sm-10
.checkbox
= f.label :sentry_enabled do
= f.check_box :sentry_enabled
- Enable Sentry
+ 开启 Sentry
.help-block
- Sentry is an error reporting and logging tool which is currently not shipped with GitLab, get it here:
+ Sentry 是一个错误报告和日志记录工具。GitLab 当前并未自带此工具,需要在后面的网址下载并安装:
%a{ href: 'https://getsentry.com', target: '_blank' } https://getsentry.com
.form-group
@@ -283,4 +283,4 @@
= f.text_field :sentry_dsn, class: 'form-control'
.form-actions
- = f.submit 'Save', class: 'btn btn-save'
+ = f.submit '保存', class: 'btn btn-save'
diff --git a/app/views/admin/application_settings/show.html.haml b/app/views/admin/application_settings/show.html.haml
index e9c7ca9d5aa..faf58aec9a2 100644
--- a/app/views/admin/application_settings/show.html.haml
+++ b/app/views/admin/application_settings/show.html.haml
@@ -1,4 +1,4 @@
-- page_title "Settings"
-%h3.page-title Settings
+- page_title "设置"
+%h3.page-title 设置
%hr
= render 'form'
diff --git a/app/views/admin/applications/_delete_form.html.haml b/app/views/admin/applications/_delete_form.html.haml
index 3147cbd659f..3a744c0c864 100644
--- a/app/views/admin/applications/_delete_form.html.haml
+++ b/app/views/admin/applications/_delete_form.html.haml
@@ -1,4 +1,4 @@
- submit_btn_css ||= 'btn btn-link btn-remove btn-sm'
= form_tag admin_application_path(application) do
%input{:name => "_method", :type => "hidden", :value => "delete"}/
- = submit_tag 'Destroy', onclick: "return confirm('Are you sure?')", class: submit_btn_css \ No newline at end of file
+ = submit_tag '销毁', onclick: "return confirm('确定要继续么?')", class: submit_btn_css \ No newline at end of file
diff --git a/app/views/admin/applications/_form.html.haml b/app/views/admin/applications/_form.html.haml
index e18f7b499dd..f60a03c2bbc 100644
--- a/app/views/admin/applications/_form.html.haml
+++ b/app/views/admin/applications/_form.html.haml
@@ -5,22 +5,22 @@
- application.errors.full_messages.each do |msg|
%p= msg
= content_tag :div, class: 'form-group' do
- = f.label :name, class: 'col-sm-2 control-label'
+ = f.label :name, "名称", class: 'col-sm-2 control-label'
.col-sm-10
= f.text_field :name, class: 'form-control'
= doorkeeper_errors_for application, :name
= content_tag :div, class: 'form-group' do
- = f.label :redirect_uri, class: 'col-sm-2 control-label'
+ = f.label :redirect_uri, "重定向 URI", class: 'col-sm-2 control-label'
.col-sm-10
= f.text_area :redirect_uri, class: 'form-control'
= doorkeeper_errors_for application, :redirect_uri
%span.help-block
- Use one line per URI
+ 每个 URI 使用一行
- if Doorkeeper.configuration.native_redirect_uri
%span.help-block
- Use
+ 使用
%code= Doorkeeper.configuration.native_redirect_uri
- for local tests
+ 作为本地测试
.form-actions
- = f.submit 'Submit', class: "btn btn-save wide"
- = link_to "Cancel", admin_applications_path, class: "btn btn-default"
+ = f.submit '提交', class: "btn btn-save wide"
+ = link_to "取消", admin_applications_path, class: "btn btn-default"
diff --git a/app/views/admin/applications/edit.html.haml b/app/views/admin/applications/edit.html.haml
index c596866bde2..985418631c0 100644
--- a/app/views/admin/applications/edit.html.haml
+++ b/app/views/admin/applications/edit.html.haml
@@ -1,4 +1,4 @@
-- page_title "Edit", @application.name, "Applications"
-%h3.page-title Edit application
+- page_title "编辑", @application.name, "应用"
+%h3.page-title 编辑应用
- @url = admin_application_path(@application)
= render 'form', application: @application
diff --git a/app/views/admin/applications/index.html.haml b/app/views/admin/applications/index.html.haml
index f8cd98f0ec4..c72133800f2 100644
--- a/app/views/admin/applications/index.html.haml
+++ b/app/views/admin/applications/index.html.haml
@@ -1,16 +1,16 @@
-- page_title "Applications"
+- page_title "应用"
%h3.page-title
- System OAuth applications
+ 系统 OAuth 应用
%p.light
- System OAuth applications don't belong to any user and can only be managed by admins
+ 系统 OAuth 应用不属于特定的用户,只由管理员管理
%hr
-%p= link_to 'New Application', new_admin_application_path, class: 'btn btn-success'
+%p= link_to '新应用', new_admin_application_path, class: 'btn btn-success'
%table.table.table-striped
%thead
%tr
- %th Name
- %th Callback URL
- %th Clients
+ %th 名称
+ %th 回调链接
+ %th 客户端
%th
%th
%tbody.oauth-applications
@@ -19,5 +19,5 @@
%td= link_to application.name, admin_application_path(application)
%td= application.redirect_uri
%td= application.access_tokens.map(&:resource_owner_id).uniq.count
- %td= link_to 'Edit', edit_admin_application_path(application), class: 'btn btn-link'
+ %td= link_to '编辑', edit_admin_application_path(application), class: 'btn btn-link'
%td= render 'delete_form', application: application
diff --git a/app/views/admin/applications/new.html.haml b/app/views/admin/applications/new.html.haml
index 6310d89bd6b..6d9391b43e7 100644
--- a/app/views/admin/applications/new.html.haml
+++ b/app/views/admin/applications/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "New Application"
-%h3.page-title New application
+- page_title "新应用"
+%h3.page-title 新应用
- @url = admin_applications_path
= render 'form', application: @application
diff --git a/app/views/admin/applications/show.html.haml b/app/views/admin/applications/show.html.haml
index 3eb9d61972b..ac94ac7fe2e 100644
--- a/app/views/admin/applications/show.html.haml
+++ b/app/views/admin/applications/show.html.haml
@@ -1,28 +1,28 @@
-- page_title @application.name, "Applications"
+- page_title @application.name, "应用"
%h3.page-title
- Application: #{@application.name}
+ 应用: #{@application.name}
.table-holder
%table.table
%tr
%td
- Application Id
+ 应用 Id
%td
%code#application_id= @application.uid
%tr
%td
- Secret:
+ 密匙:
%td
%code#secret= @application.secret
%tr
%td
- Callback url
+ 回调链接
%td
- @application.redirect_uri.split.each do |uri|
%div
%span.monospace= uri
.form-actions
- = link_to 'Edit', edit_admin_application_path(@application), class: 'btn btn-primary wide pull-left'
+ = link_to '编辑', edit_admin_application_path(@application), class: 'btn btn-primary wide pull-left'
= render 'delete_form', application: @application, submit_btn_css: 'btn btn-danger prepend-left-10'
diff --git a/app/views/admin/background_jobs/show.html.haml b/app/views/admin/background_jobs/show.html.haml
index de5bc050cf0..f2ee1482662 100644
--- a/app/views/admin/background_jobs/show.html.haml
+++ b/app/views/admin/background_jobs/show.html.haml
@@ -1,16 +1,16 @@
-- page_title "Background Jobs"
-%h3.page-title Background Jobs
-%p.light GitLab uses #{link_to "sidekiq", "http://sidekiq.org/"} library for async job processing
+- page_title "后台作业"
+%h3.page-title 后台作业
+%p.light GitLab 使用 #{link_to "sidekiq", "http://sidekiq.org/"} 库同步作业处理
%hr
.panel.panel-default
- .panel-heading Sidekiq running processes
+ .panel-heading Sidekiq 运行进程
.panel-body
- if @sidekiq_processes.empty?
%h4.cred
%i.fa.fa-exclamation-triangle
- There are no running sidekiq processes. Please restart GitLab
+ 没有运行的 sidekiq 进程,请重新启动 GitLab
- else
.table-holder
%table.table
@@ -35,10 +35,10 @@
.clearfix
%p
%i.fa.fa-exclamation-circle
- If '[25 of 25 busy]' is shown, restart GitLab with 'sudo service gitlab reload'.
+ 如果显示 '[25 of 25 busy]' 请使用 'sudo service gitlab reload' 重新启动 GitLab。
%p
%i.fa.fa-exclamation-circle
- If more than one sidekiq process is listed, stop GitLab, kill the remaining sidekiq processes (sudo pkill -u #{gitlab_config.user} -f sidekiq) and restart GitLab.
+ 如果列出超过一个 sidekiq 进程,请停止 GitLab,杀死剩余的 sidekiq 进程 (sudo pkill -u #{Settings.gitlab.user} -f sidekiq),然后重新启动 GitLab。
diff --git a/app/views/admin/broadcast_messages/edit.html.haml b/app/views/admin/broadcast_messages/edit.html.haml
index 45e053eb31d..f5482bd3a89 100644
--- a/app/views/admin/broadcast_messages/edit.html.haml
+++ b/app/views/admin/broadcast_messages/edit.html.haml
@@ -1,3 +1,3 @@
-- page_title "Broadcast Messages"
+- page_title "广播信息"
= render 'form'
diff --git a/app/views/admin/broadcast_messages/index.html.haml b/app/views/admin/broadcast_messages/index.html.haml
index c05538a393c..dd9fe805820 100644
--- a/app/views/admin/broadcast_messages/index.html.haml
+++ b/app/views/admin/broadcast_messages/index.html.haml
@@ -1,10 +1,9 @@
-- page_title "Broadcast Messages"
+- page_title "广播信息"
%h3.page-title
- Broadcast Messages
+ 广播信息
%p.light
- Broadcast messages are displayed for every user and can be used to notify
- users about scheduled maintenance, recent upgrades and more.
+ 广播信息会显示给所有用户,可以用于通知用户系统定期维护、近期计划升级等信息。
= render 'form'
@@ -14,10 +13,10 @@
%table.table
%thead
%tr
- %th Status
- %th Preview
- %th Starts
- %th Ends
+ %th 状态
+ %th 预览
+ %th 开始
+ %th 结束
%th &nbsp;
%tbody
- @broadcast_messages.each do |message|
@@ -31,7 +30,7 @@
%td
= message.ends_at
%td
- = link_to icon('pencil-square-o'), edit_admin_broadcast_message_path(message), title: 'Edit', class: 'btn btn-xs'
- = link_to icon('times'), admin_broadcast_message_path(message), method: :delete, remote: true, title: 'Remove', class: 'js-remove-tr btn btn-xs btn-danger'
+ = link_to icon('pencil-square-o'), edit_admin_broadcast_message_path(message), title: '编辑', class: 'btn btn-xs'
+ = link_to icon('times'), admin_broadcast_message_path(message), method: :delete, remote: true, title: '删除', class: 'js-remove-tr btn btn-xs btn-danger'
= paginate @broadcast_messages, theme: 'gitlab'
diff --git a/app/views/admin/builds/_build.html.haml b/app/views/admin/builds/_build.html.haml
index 588ad767426..6e254a50c2b 100644
--- a/app/views/admin/builds/_build.html.haml
+++ b/app/views/admin/builds/_build.html.haml
@@ -41,9 +41,9 @@
%span.label.label-primary
= tag
- if build.try(:trigger_request)
- %span.label.label-info triggered
+ %span.label.label-info 被触发
- if build.try(:allow_failure)
- %span.label.label-danger allowed to fail
+ %span.label.label-danger 允许失败
%td.duration
- if build.duration
diff --git a/app/views/admin/builds/index.html.haml b/app/views/admin/builds/index.html.haml
index 5931efdefe6..5ee960d2348 100644
--- a/app/views/admin/builds/index.html.haml
+++ b/app/views/admin/builds/index.html.haml
@@ -2,44 +2,44 @@
%ul.nav-links
%li{class: ('active' if @scope.nil?)}
= link_to admin_builds_path do
- All
+ 所有
%span.badge.js-totalbuilds-count= @all_builds.count(:id)
%li{class: ('active' if @scope == 'running')}
= link_to admin_builds_path(scope: :running) do
- Running
+ 正在运行
%span.badge.js-running-count= number_with_delimiter(@all_builds.running_or_pending.count(:id))
%li{class: ('active' if @scope == 'finished')}
= link_to admin_builds_path(scope: :finished) do
- Finished
+ 已结束
%span.badge.js-running-count= number_with_delimiter(@all_builds.finished.count(:id))
.nav-controls
- if @all_builds.running_or_pending.any?
- = link_to 'Cancel all', cancel_all_admin_builds_path, data: { confirm: 'Are you sure?' }, class: 'btn btn-danger', method: :post
+ = link_to '取消所有', cancel_all_admin_builds_path, data: { confirm: '确定要继续么?' }, class: 'btn btn-danger', method: :post
.gray-content-block.second-block
- #{(@scope || 'running').capitalize} builds
+ #{(@scope || 'running').capitalize} 的构建
%ul.content-list
- if @builds.blank?
%li
- .nothing-here-block No builds to show
+ .nothing-here-block 没有构建显示
- else
.table-holder
%table.table.builds
%thead
%tr
- %th Status
- %th Build ID
- %th Project
- %th Commit
- %th Ref
+ %th 状态
+ %th 构建 ID
+ %th 项目
+ %th 提交
+ %th 参考
%th Runner
- %th Name
- %th Duration
- %th Finished at
+ %th 名称
+ %th 运行时间
+ %th 结束时间
%th
- @builds.each do |build|
diff --git a/app/views/admin/dashboard/index.html.haml b/app/views/admin/dashboard/index.html.haml
index 3274ba5377b..23645abab1d 100644
--- a/app/views/admin/dashboard/index.html.haml
+++ b/app/views/admin/dashboard/index.html.haml
@@ -1,46 +1,46 @@
.admin-dashboard
.row
.col-md-4
- %h4 Statistics
+ %h4 统计
%hr
%p
- Forks
+ 派生
%span.light.pull-right
= number_with_delimiter(ForkedProjectLink.count)
%p
- Issues
+ 问题
%span.light.pull-right
= number_with_delimiter(Issue.count)
%p
- Merge Requests
+ 合并请求
%span.light.pull-right
= number_with_delimiter(MergeRequest.count)
%p
- Notes
+ 笔记
%span.light.pull-right
= number_with_delimiter(Note.count)
%p
- Snippets
+ 代码片段
%span.light.pull-right
= number_with_delimiter(Snippet.count)
%p
- SSH Keys
+ SSH 密钥
%span.light.pull-right
= number_with_delimiter(Key.count)
%p
- Milestones
+ 里程碑
%span.light.pull-right
= number_with_delimiter(Milestone.count)
%p
- Active Users
+ 活跃用户
%span.light.pull-right
= number_with_delimiter(User.active.count)
.col-md-4
%h4
- Features
+ 功能
%hr
%p
- Sign up
+ 注册
%span.light.pull-right
= boolean_to_icon signup_enabled?
%p
@@ -48,7 +48,7 @@
%span.light.pull-right
= boolean_to_icon Gitlab.config.ldap.enabled
%p
- Gravatar
+ 头像
%span.light.pull-right
= boolean_to_icon gravatar_enabled?
%p
@@ -56,12 +56,12 @@
%span.light.pull-right
= boolean_to_icon Gitlab.config.omniauth.enabled
%p
- Reply by email
+ 电子邮件回复
%span.light.pull-right
= boolean_to_icon Gitlab::IncomingEmail.enabled?
.col-md-4
%h4
- Components
+ 组件
- if current_application_settings.version_check_enabled
.pull-right
= version_status_badge
@@ -101,32 +101,32 @@
.row
.col-sm-4
.light-well
- %h4 Projects
+ %h4 项目
.data
= link_to admin_namespaces_projects_path do
%h1= number_with_delimiter(Project.count)
%hr
- = link_to('New Project', new_project_path, class: "btn btn-new")
+ = link_to('新项目', new_project_path, class: "btn btn-new")
.col-sm-4
.light-well
- %h4 Users
+ %h4 用户
.data
= link_to admin_users_path do
%h1= number_with_delimiter(User.count)
%hr
- = link_to 'New User', new_admin_user_path, class: "btn btn-new"
+ = link_to '新用户', new_admin_user_path, class: "btn btn-new"
.col-sm-4
.light-well
- %h4 Groups
+ %h4 群组
.data
= link_to admin_groups_path do
%h1= number_with_delimiter(Group.count)
%hr
- = link_to 'New Group', new_admin_group_path, class: "btn btn-new"
+ = link_to '新群组', new_admin_group_path, class: "btn btn-new"
.row.prepend-top-10
.col-md-4
- %h4 Latest projects
+ %h4 最近项目
%hr
- @projects.each do |project|
%p
@@ -135,7 +135,7 @@
#{time_ago_with_tooltip(project.created_at)}
.col-md-4
- %h4 Latest users
+ %h4 最近用户
%hr
- @users.each do |user|
%p
@@ -145,7 +145,7 @@
#{time_ago_with_tooltip(user.created_at)}
.col-md-4
- %h4 Latest groups
+ %h4 最近群组
%hr
- @groups.each do |group|
%p
diff --git a/app/views/admin/deploy_keys/index.html.haml b/app/views/admin/deploy_keys/index.html.haml
index 41c43899978..6bd1ddeb965 100644
--- a/app/views/admin/deploy_keys/index.html.haml
+++ b/app/views/admin/deploy_keys/index.html.haml
@@ -1,17 +1,17 @@
-- page_title "Deploy Keys"
+- page_title "部署密钥"
.panel.panel-default
.panel-heading
- Public deploy keys (#{@deploy_keys.count})
+ 公开的部署密钥 (#{@deploy_keys.count})
.controls
- = link_to 'New Deploy Key', new_admin_deploy_key_path, class: "btn btn-new btn-sm"
+ = link_to '新部署密钥', new_admin_deploy_key_path, class: "btn btn-new btn-sm"
- if @deploy_keys.any?
.table-holder
%table.table
%thead.panel-heading
%tr
- %th Title
- %th Fingerprint
- %th Added at
+ %th 标题
+ %th 指纹
+ %th 增加时间
%th
%tbody
- @deploy_keys.each do |deploy_key|
@@ -22,6 +22,6 @@
%code.key-fingerprint= deploy_key.fingerprint
%td
%span.cgray
- added #{time_ago_with_tooltip(deploy_key.created_at)}
+ 增加时间 #{time_ago_with_tooltip(deploy_key.created_at)}
%td
- = link_to 'Remove', admin_deploy_key_path(deploy_key), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-sm btn-remove delete-key pull-right"
+ = link_to '删除', admin_deploy_key_path(deploy_key), data: { confirm: '确定要继续么?'}, method: :delete, class: "btn btn-sm btn-remove delete-key pull-right"
diff --git a/app/views/admin/deploy_keys/new.html.haml b/app/views/admin/deploy_keys/new.html.haml
index 5b46b3222a9..d052df27bf1 100644
--- a/app/views/admin/deploy_keys/new.html.haml
+++ b/app/views/admin/deploy_keys/new.html.haml
@@ -1,5 +1,5 @@
-- page_title "New Deploy Key"
-%h3.page-title New public deploy key
+- page_title "新部署密钥"
+%h3.page-title 新的公开的部署密钥
%hr
%div
@@ -11,17 +11,17 @@
%li= msg
.form-group
- = f.label :title, class: "control-label"
+ = f.label :title, "标题", class: "control-label"
.col-sm-10= f.text_field :title, class: 'form-control'
.form-group
- = f.label :key, class: "control-label"
+ = f.label :key, "密钥", class: "control-label"
.col-sm-10
%p.light
- Paste a machine public key here. Read more about how to generate it
- = link_to "here", help_page_path("ssh", "README")
+ 在这里粘贴机器公钥。如何生成密钥请点击
+ = link_to "这里", help_page_path("ssh", "README")
= f.text_area :key, class: "form-control thin_area", rows: 5
.form-actions
- = f.submit 'Create', class: "btn-create btn"
- = link_to "Cancel", admin_deploy_keys_path, class: "btn btn-cancel"
+ = f.submit '创建', class: "btn-create btn"
+ = link_to "取消", admin_deploy_keys_path, class: "btn btn-cancel"
diff --git a/app/views/admin/groups/_form.html.haml b/app/views/admin/groups/_form.html.haml
index 7f2b1cd235d..7534b04c7ba 100644
--- a/app/views/admin/groups/_form.html.haml
+++ b/app/views/admin/groups/_form.html.haml
@@ -6,7 +6,7 @@
= render 'shared/group_form', f: f
.form-group.group-description-holder
- = f.label :avatar, "Group avatar", class: 'control-label'
+ = f.label :avatar, "群组头像", class: 'control-label'
.col-sm-10
= render 'shared/choose_group_avatar_button', f: f
@@ -18,10 +18,10 @@
.alert.alert-info
= render 'shared/group_tips'
.form-actions
- = f.submit 'Create group', class: "btn btn-create"
- = link_to 'Cancel', admin_groups_path, class: "btn btn-cancel"
+ = f.submit '创建群组', class: "btn btn-create"
+ = link_to '取消', admin_groups_path, class: "btn btn-cancel"
- else
.form-actions
- = f.submit 'Save changes', class: "btn btn-save"
- = link_to 'Cancel', admin_group_path(@group), class: "btn btn-cancel"
+ = f.submit '保存修改', class: "btn btn-save"
+ = link_to '取消', admin_group_path(@group), class: "btn btn-cancel"
diff --git a/app/views/admin/groups/edit.html.haml b/app/views/admin/groups/edit.html.haml
index eb09a6328ed..26f51d1ce11 100644
--- a/app/views/admin/groups/edit.html.haml
+++ b/app/views/admin/groups/edit.html.haml
@@ -1,4 +1,4 @@
-- page_title "Edit", @group.name, "Groups"
-%h3.page-title Edit group: #{@group.name}
+- page_title "编辑", @group.name, "群组"
+%h3.page-title 编辑群组:#{@group.name}
%hr
= render 'form'
diff --git a/app/views/admin/groups/index.html.haml b/app/views/admin/groups/index.html.haml
index 6bdc885a312..d47460cecb9 100644
--- a/app/views/admin/groups/index.html.haml
+++ b/app/views/admin/groups/index.html.haml
@@ -1,18 +1,17 @@
-- page_title "Groups"
+- page_title "群组"
%h3.page-title
- Groups (#{number_with_delimiter(@groups.total_count)})
- = link_to 'New Group', new_admin_group_path, class: "btn btn-new pull-right"
+ 群组 (#{number_with_delimiter(@groups.total_count)})
+ = link_to '新群组', new_admin_group_path, class: "btn btn-new pull-right"
%p.light
- Group allows you to keep projects organized.
- Use groups for uniting related projects.
+ 群组用于管理有组织的关联项目。
%hr
= form_tag admin_groups_path, method: :get, class: 'form-inline' do
= hidden_field_tag :sort, @sort
.form-group
= text_field_tag :name, params[:name], class: "form-control"
- = button_tag "Search", class: "btn submit btn-primary"
+ = button_tag "搜索", class: "btn submit btn-primary"
.pull-right
.dropdown.inline
@@ -41,8 +40,8 @@
%li
.clearfix
.pull-right.prepend-top-10
- = link_to 'Edit', edit_admin_group_path(group), id: "edit_#{dom_id(group)}", class: "btn btn-sm"
- = link_to 'Destroy', [:admin, group], data: {confirm: "REMOVE #{group.name}? Are you sure?"}, method: :delete, class: "btn btn-sm btn-remove"
+ = link_to '编辑', edit_admin_group_path(group), id: "edit_#{dom_id(group)}", class: "btn btn-sm"
+ = link_to '销毁', [:admin, group], data: {confirm: "确定要删除 #{group.name}?"}, method: :delete, class: "btn btn-sm btn-remove"
%h4
= link_to [:admin, group] do
@@ -60,7 +59,7 @@
= truncate group.description, length: 150
.clearfix
%p.light
- #{pluralize(group.members.size, 'member')}, #{pluralize(group.projects.count, 'project')}
+ #{pluralize(group.members.size, '个用户', '个用户')}, #{pluralize(group.projects.count, '个项目', '个项目')}
= paginate @groups, theme: "gitlab"
diff --git a/app/views/admin/groups/new.html.haml b/app/views/admin/groups/new.html.haml
index c81ee552ac3..86a84a9167a 100644
--- a/app/views/admin/groups/new.html.haml
+++ b/app/views/admin/groups/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "New Group"
-%h3.page-title New group
+- page_title "新群组"
+%h3.page-title 新群组
%hr
= render 'form'
diff --git a/app/views/admin/groups/show.html.haml b/app/views/admin/groups/show.html.haml
index f309e80a39a..1693e3afa63 100644
--- a/app/views/admin/groups/show.html.haml
+++ b/app/views/admin/groups/show.html.haml
@@ -75,11 +75,12 @@
- if can?(current_user, :admin_group_member, @group)
.panel.panel-default
.panel-heading
- Add user(s) to the group:
+ 增加用户到群组:
.panel-body.form-holder
%p.light
- Read more about project permissions
- %strong= link_to "here", help_page_path("permissions", "permissions"), class: "vlink"
+ 关于项目的权限点击
+ %strong= link_to "这里", help_page_path("permissions", "permissions"), class: "vlink"
+ 了解更多信息
= form_tag members_update_admin_group_path(@group), id: "new_project_member", class: "bulk_import", method: :put do
%div
@@ -87,11 +88,11 @@
%div.prepend-top-10
= select_tag :access_level, options_for_select(GroupMember.access_level_roles), class: "project-access-select select2"
%hr
- = button_tag 'Add users to group', class: "btn btn-create"
+ = button_tag '增加用户到群组', class: "btn btn-create"
.panel.panel-default
.panel-heading
%h3.panel-title
- Members
+ 成员
%span.badge
#{@group.group_members.count}
%ul.well-list.group-users-list
@@ -105,11 +106,11 @@
- else
%strong
= member.invite_email
- (invited)
+ (已邀请)
%span.pull-right.light
= member.human_access
- if can?(current_user, :destroy_group_member, member)
- = link_to group_group_member_path(@group, member), data: { confirm: remove_user_from_group_message(@group, member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: 'Remove user from group' do
+ = link_to group_group_member_path(@group, member), data: { confirm: remove_user_from_group_message(@group, member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: '从群组中删除用户' do
%i.fa.fa-minus.fa-inverse
.panel-footer
= paginate @members, param_name: 'members_page', theme: 'gitlab'
diff --git a/app/views/admin/hooks/index.html.haml b/app/views/admin/hooks/index.html.haml
index 53b3cd04c68..322b9989f2e 100644
--- a/app/views/admin/hooks/index.html.haml
+++ b/app/views/admin/hooks/index.html.haml
@@ -1,10 +1,9 @@
-- page_title "System Hooks"
+- page_title "系统钩子"
%h3.page-title
- System hooks
+ 系统钩子
%p.light
- #{link_to "System hooks ", help_page_path("system_hooks", "system_hooks"), class: "vlink"} can be
- used for binding events when GitLab creates a User or Project.
+ #{link_to "系统钩子", help_page_path("system_hooks", "system_hooks"), class: "vlink"}可以绑定例如 Git 版本创建用户或项目的事件。
%hr
@@ -15,31 +14,31 @@
- @hook.errors.full_messages.each do |msg|
%p= msg
.form-group
- = f.label :url, "URL:", class: 'control-label'
+ = f.label :url, "链接:", class: 'control-label'
.col-sm-10
= f.text_field :url, class: "form-control"
.form-group
- = f.label :enable_ssl_verification, "SSL verification", class: 'control-label checkbox'
+ = f.label :enable_ssl_verification, "SSL 验证证书", class: 'control-label checkbox'
.col-sm-10
.checkbox
= f.label :enable_ssl_verification do
= f.check_box :enable_ssl_verification
- %strong Enable SSL verification
+ %strong 启用 SSL 验证证书
.form-actions
- = f.submit "Add System Hook", class: "btn btn-create"
+ = f.submit "增加系统钩子", class: "btn btn-create"
%hr
-if @hooks.any?
.panel.panel-default
.panel-heading
- System hooks (#{@hooks.count})
+ 系统钩子 (#{@hooks.count})
%ul.well-list
- @hooks.each do |hook|
%li
.list-item-name
%strong= hook.url
- %p SSL Verification: #{hook.enable_ssl_verification ? "enabled" : "disabled"}
+ %p SSL 验证证书: #{hook.enable_ssl_verification ? "已启用" : "已禁用"}
.pull-right
- = link_to 'Test Hook', admin_hook_test_path(hook), class: "btn btn-sm"
- = link_to 'Remove', admin_hook_path(hook), data: { confirm: 'Are you sure?' }, method: :delete, class: "btn btn-remove btn-sm"
+ = link_to '测试钩子', admin_hook_test_path(hook), class: "btn btn-sm"
+ = link_to '删除', admin_hook_path(hook), data: { confirm: '确定要继续么?' }, method: :delete, class: "btn btn-remove btn-sm"
diff --git a/app/views/admin/identities/_form.html.haml b/app/views/admin/identities/_form.html.haml
index 3a788558226..b2ef274064d 100644
--- a/app/views/admin/identities/_form.html.haml
+++ b/app/views/admin/identities/_form.html.haml
@@ -6,15 +6,15 @@
%p= msg
.form-group
- = f.label :provider, class: 'control-label'
+ = f.label :provider, "提供者", class: 'control-label'
.col-sm-10
- values = Gitlab::OAuth::Provider.providers.map { |name| ["#{Gitlab::OAuth::Provider.label_for(name)} (#{name})", name] }
= f.select :provider, values, { allow_blank: false }, class: 'form-control'
.form-group
- = f.label :extern_uid, "Identifier", class: 'control-label'
+ = f.label :extern_uid, "身份", class: 'control-label'
.col-sm-10
= f.text_field :extern_uid, class: 'form-control', required: true
.form-actions
- = f.submit 'Save changes', class: "btn btn-save"
+ = f.submit '保存修改', class: "btn btn-save"
diff --git a/app/views/admin/identities/_identity.html.haml b/app/views/admin/identities/_identity.html.haml
index 7362d904b94..9bf0146de6e 100644
--- a/app/views/admin/identities/_identity.html.haml
+++ b/app/views/admin/identities/_identity.html.haml
@@ -5,8 +5,8 @@
= identity.extern_uid
%td
= link_to edit_admin_user_identity_path(@user, identity), class: 'btn btn-xs btn-grouped' do
- Edit
+ 编辑
= link_to [:admin, @user, identity], method: :delete,
class: 'btn btn-xs btn-danger',
- data: { confirm: "Are you sure you want to remove this identity?" } do
- Delete
+ data: { confirm: "确定要删除此身份么?" } do
+ 删除
diff --git a/app/views/admin/identities/edit.html.haml b/app/views/admin/identities/edit.html.haml
index 515d46b0f29..e5747397c8c 100644
--- a/app/views/admin/identities/edit.html.haml
+++ b/app/views/admin/identities/edit.html.haml
@@ -1,6 +1,6 @@
-- page_title "Edit", @identity.provider, "Identities", @user.name, "Users"
+- page_title "编辑", @identity.provider, "身份", @user.name, "用户"
%h3.page-title
- Edit identity for #{@user.name}
+ 编辑 #{@user.name} 的身份
%hr
= render 'form'
diff --git a/app/views/admin/identities/index.html.haml b/app/views/admin/identities/index.html.haml
index 741d111fb7d..c764cf01100 100644
--- a/app/views/admin/identities/index.html.haml
+++ b/app/views/admin/identities/index.html.haml
@@ -1,15 +1,15 @@
-- page_title "Identities", @user.name, "Users"
+- page_title "身份", @user.name, "用户"
= render 'admin/users/head'
-= link_to 'New Identity', new_admin_user_identity_path, class: 'pull-right btn btn-new'
+= link_to '新身份', new_admin_user_identity_path, class: 'pull-right btn btn-new'
- if @identities.present?
.table-holder
%table.table
%thead
%tr
- %th Provider
- %th Identifier
+ %th 提供者
+ %th 身份
%th
= render @identities
- else
- %h4 This user has no identities
+ %h4 此用户没有任何身份
diff --git a/app/views/admin/identities/new.html.haml b/app/views/admin/identities/new.html.haml
index e30bf0ef0ee..64192db74d7 100644
--- a/app/views/admin/identities/new.html.haml
+++ b/app/views/admin/identities/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "New Identity"
-%h3.page-title New identity
+- page_title "新身份"
+%h3.page-title 新身份
%hr
= render 'form'
diff --git a/app/views/admin/keys/show.html.haml b/app/views/admin/keys/show.html.haml
index 9ee77c77398..84403edd2ee 100644
--- a/app/views/admin/keys/show.html.haml
+++ b/app/views/admin/keys/show.html.haml
@@ -1,2 +1,2 @@
-- page_title @key.title, "Keys"
+- page_title @key.title, "密钥"
= render "profiles/keys/key_details", admin: true
diff --git a/app/views/admin/labels/_form.html.haml b/app/views/admin/labels/_form.html.haml
index 8c6b389bf15..49d921725f9 100644
--- a/app/views/admin/labels/_form.html.haml
+++ b/app/views/admin/labels/_form.html.haml
@@ -8,23 +8,23 @@
%br
.form-group
- = f.label :title, class: 'control-label'
+ = f.label :title, "标题", class: 'control-label'
.col-sm-10
= f.text_field :title, class: "form-control", required: true
.form-group
- = f.label :description, class: 'control-label'
+ = f.label :description, "描述", class: 'control-label'
.col-sm-10
= f.text_field :description, class: "form-control js-quick-submit"
.form-group
- = f.label :color, "Background color", class: 'control-label'
+ = f.label :color, "背景颜色", class: 'control-label'
.col-sm-10
.input-group
.input-group-addon.label-color-preview &nbsp;
= f.color_field :color, class: "form-control"
.help-block
- Choose any color.
+ 选择任意颜色。
%br
- Or you can choose one of suggested colors below
+ 或者在下方选择推荐的颜色
.suggest-colors
- suggested_colors.each do |color|
@@ -32,8 +32,8 @@
&nbsp;
.form-actions
- = f.submit 'Save', class: 'btn btn-save js-save-button'
- = link_to "Cancel", admin_labels_path, class: 'btn btn-cancel'
+ = f.submit '保存', class: 'btn btn-save js-save-button'
+ = link_to "取消", admin_labels_path, class: 'btn btn-cancel'
:javascript
new Labels();
diff --git a/app/views/admin/labels/edit.html.haml b/app/views/admin/labels/edit.html.haml
index 309aedceded..7dfff96999b 100644
--- a/app/views/admin/labels/edit.html.haml
+++ b/app/views/admin/labels/edit.html.haml
@@ -1,5 +1,5 @@
-- page_title "Edit", @label.name, "Labels"
+- page_title "编辑", @label.name, "标记"
%h3.page-title
- Edit Label
+ 编辑标记
%hr
= render 'form'
diff --git a/app/views/admin/labels/index.html.haml b/app/views/admin/labels/index.html.haml
index 3c57e3dc174..266a1bf9328 100644
--- a/app/views/admin/labels/index.html.haml
+++ b/app/views/admin/labels/index.html.haml
@@ -1,8 +1,8 @@
-- page_title "Labels"
+- page_title "标记"
= link_to new_admin_label_path, class: "pull-right btn btn-nr btn-new" do
- New label
+ 新标记
%h3.page-title
- Labels
+ 标记
%hr
.labels
@@ -12,5 +12,5 @@
= paginate @labels, theme: 'gitlab'
- else
.light-well
- .nothing-here-block There are no labels yet
+ .nothing-here-block 还没有标记
diff --git a/app/views/admin/labels/new.html.haml b/app/views/admin/labels/new.html.haml
index 0135ad0723d..14c8a954b18 100644
--- a/app/views/admin/labels/new.html.haml
+++ b/app/views/admin/labels/new.html.haml
@@ -1,5 +1,5 @@
-- page_title "New Label"
+- page_title "新标记"
%h3.page-title
- New Label
+ 新标记
%hr
= render 'form'
diff --git a/app/views/admin/logs/show.html.haml b/app/views/admin/logs/show.html.haml
index af9fdeb0734..e1ac4a7b4f8 100644
--- a/app/views/admin/logs/show.html.haml
+++ b/app/views/admin/logs/show.html.haml
@@ -1,4 +1,4 @@
-- page_title "Logs"
+- page_title "日志"
- loggers = [Gitlab::GitLogger, Gitlab::AppLogger,
Gitlab::ProductionLogger, Gitlab::SidekiqLogger]
%ul.nav-links.log-tabs
@@ -7,7 +7,7 @@
= link_to klass::file_name, "##{klass::file_name_noext}",
'data-toggle' => 'tab'
.gray-content-block
- To prevent performance issues admin logs output the last 2000 lines
+ 为了防止性能问题管理日志只输出最后的 2000 行
.tab-content
- loggers.each do |klass|
.tab-pane{ class: (klass == Gitlab::GitLogger ? 'active' : ''),
@@ -19,7 +19,7 @@
.pull-right
= link_to '#', class: 'log-bottom' do
%i.fa.fa-arrow-down
- Scroll down
+ 向下滚动
.file-content.logs
%ol
- klass.read_latest.each do |line|
diff --git a/app/views/admin/projects/index.html.haml b/app/views/admin/projects/index.html.haml
index d39c0f44031..a9b56541b7b 100644
--- a/app/views/admin/projects/index.html.haml
+++ b/app/views/admin/projects/index.html.haml
@@ -1,4 +1,4 @@
-- page_title "Projects"
+- page_title "项目"
= render 'shared/show_aside'
.row.prepend-top-default
@@ -6,30 +6,30 @@
.admin-filter
= form_tag admin_namespaces_projects_path, method: :get, class: '' do
.form-group
- = label_tag :name, 'Name:'
+ = label_tag :name, '名称:'
= text_field_tag :name, params[:name], class: "form-control"
.form-group
- = label_tag :namespace_id, "Namespace"
+ = label_tag :namespace_id, "命名空间"
= namespace_select_tag :namespace_id, selected: params[:namespace_id], class: 'input-large'
.form-group
- %strong Activity
+ %strong 活动
.checkbox
= label_tag :with_push do
= check_box_tag :with_push, 1, params[:with_push]
- %span Projects with push events
+ %span 项目有推送事件
.checkbox
= label_tag :abandoned do
= check_box_tag :abandoned, 1, params[:abandoned]
- %span No activity over 6 month
+ %span 6 个月不再活动
.checkbox
= label_tag :with_archived do
= check_box_tag :with_archived, 1, params[:with_archived]
- %span Show archived projects
+ %span 显示已归档项目
%fieldset
- %strong Visibility level:
+ %strong 可见等级:
.visibility-levels
- Project.visibility_levels.each do |label, level|
.checkbox
@@ -40,13 +40,13 @@
= label
%hr
= hidden_field_tag :sort, params[:sort]
- = button_tag "Search", class: "btn submit btn-primary"
- = link_to "Reset", admin_namespaces_projects_path, class: "btn btn-cancel"
+ = button_tag "搜索", class: "btn submit btn-primary"
+ = link_to "重置", admin_namespaces_projects_path, class: "btn btn-cancel"
%section.col-md-9
.panel.panel-default
.panel-heading
- Projects (#{@projects.total_count})
+ 项目 (#{@projects.total_count})
.controls
.dropdown.inline
%button.dropdown-toggle.btn.btn-sm{type: 'button', 'data-toggle' => 'dropdown'}
@@ -68,7 +68,7 @@
= sort_title_oldest_updated
= link_to admin_namespaces_projects_path(sort: sort_value_largest_repo) do
= sort_title_largest_repo
- = link_to 'New Project', new_project_path, class: "btn btn-sm btn-success"
+ = link_to '新项目', new_project_path, class: "btn btn-sm btn-success"
%ul.well-list
- @projects.each do |project|
%li
@@ -81,8 +81,8 @@
%span.label.label-warning archived
%span.label.label-gray
= repository_size(project)
- = link_to 'Edit', edit_namespace_project_path(project.namespace, project), id: "edit_#{dom_id(project)}", class: "btn btn-sm"
- = link_to 'Destroy', [project.namespace.becomes(Namespace), project], data: { confirm: remove_project_message(project) }, method: :delete, class: "btn btn-sm btn-remove"
+ = link_to '编辑', edit_namespace_project_path(project.namespace, project), id: "edit_#{dom_id(project)}", class: "btn btn-sm"
+ = link_to '销毁', [project.namespace.becomes(Namespace), project], data: { confirm: remove_project_message(project) }, method: :delete, class: "btn btn-sm btn-remove"
- if @projects.blank?
.nothing-here-block 0 projects matches
= paginate @projects, theme: "gitlab"
diff --git a/app/views/admin/projects/show.html.haml b/app/views/admin/projects/show.html.haml
index c638c32a654..2585f957bf7 100644
--- a/app/views/admin/projects/show.html.haml
+++ b/app/views/admin/projects/show.html.haml
@@ -1,42 +1,42 @@
-- page_title @project.name_with_namespace, "Projects"
+- page_title @project.name_with_namespace, "项目"
%h3.page-title
- Project: #{@project.name_with_namespace}
+ 项目:#{@project.name_with_namespace}
= link_to edit_project_path(@project), class: "btn btn-nr pull-right" do
%i.fa.fa-pencil-square-o
- Edit
+ 编辑
%hr
.row
.col-md-6
.panel.panel-default
.panel-heading
- Project info:
+ 项目信息:
%ul.well-list
%li
- %span.light Name:
+ %span.light 名称:
%strong
= link_to @project.name, project_path(@project)
%li
- %span.light Namespace:
+ %span.light 命名空间:
%strong
- if @project.namespace
= link_to @project.namespace.human_name, [:admin, @project.group || @project.owner]
- else
- Global
+ 全局
%li
- %span.light Owned by:
+ %span.light 所有者:
%strong
- if @project.owner
= link_to @project.owner_name, [:admin, @project.owner]
- else
- (deleted)
+ (已删除)
%li
- %span.light Created by:
+ %span.light 创建者:
%strong
- = @project.creator.try(:name) || '(deleted)'
+ = @project.creator.try(:name) || '(已删除)'
%li
- %span.light Created on:
+ %span.light 创建时间:
%strong
= @project.created_at.to_s(:medium)
@@ -83,24 +83,24 @@
.panel.panel-default
.panel-heading
- Transfer project
+ 转移项目
.panel-body
= form_for @project, url: transfer_admin_namespace_project_path(@project.namespace, @project), method: :put, html: { class: 'form-horizontal' } do |f|
.form-group
- = f.label :new_namespace_id, "Namespace", class: 'control-label'
+ = f.label :new_namespace_id, "命名空间", class: 'control-label'
.col-sm-10
= namespace_select_tag :new_namespace_id, selected: params[:namespace_id], class: 'input-large'
.form-group
.col-sm-offset-2.col-sm-10
- = f.submit 'Transfer', class: 'btn btn-primary'
+ = f.submit '转移', class: 'btn btn-primary'
.col-md-6
- if @group
.panel.panel-default
.panel-heading
%strong #{@group.name}
- group members (#{@group.group_members.count})
+ 群组成员 (#{@group.group_members.count})
.pull-right
= link_to admin_group_path(@group), class: 'btn btn-xs' do
%i.fa.fa-pencil-square-o
@@ -112,13 +112,13 @@
.panel.panel-default
.panel-heading
- Project members
+ 项目成员
%small
(#{@project.users.count})
.pull-right
= link_to namespace_project_project_members_path(@project.namespace, @project), class: "btn btn-xs" do
%i.fa.fa-pencil-square-o
- Manage Access
+ 管理权限
%ul.well-list.project_members
- @project_members.each do |project_member|
- user = project_member.user
@@ -133,7 +133,7 @@
(invited)
.pull-right
- if project_member.owner?
- %span.light Owner
+ %span.light 所有者
- else
%span.light= project_member.human_access
= link_to namespace_project_project_member_path(@project.namespace, @project, project_member), data: { confirm: remove_from_project_team_message(@project, project_member)}, method: :delete, remote: true, class: "btn btn-sm btn-remove" do
diff --git a/app/views/admin/runners/_runner.html.haml b/app/views/admin/runners/_runner.html.haml
index 6745e58deca..3344b24afaf 100644
--- a/app/views/admin/runners/_runner.html.haml
+++ b/app/views/admin/runners/_runner.html.haml
@@ -1,11 +1,11 @@
%tr{id: dom_id(runner)}
%td
- if runner.shared?
- %span.label.label-success shared
+ %span.label.label-success 共享的
- else
- %span.label.label-info specific
+ %span.label.label-info 特定的
- unless runner.active?
- %span.label.label-danger paused
+ %span.label.label-danger 暂停的
%td
= link_to admin_runner_path(runner) do
@@ -13,13 +13,13 @@
%td
.runner-description
= runner.description
- %span (#{link_to 'edit', '#', class: 'edit-runner-link'})
+ %span (#{link_to '编辑', '#', class: 'edit-runner-link'})
.runner-description-form.hide
= form_for [:admin, runner], remote: true, html: { class: 'form-inline' } do |f|
.form-group
= f.text_field :description, class: 'form-control'
- = f.submit 'Save', class: 'btn'
- %span (#{link_to 'cancel', '#', class: 'cancel'})
+ = f.submit '保存', class: 'btn'
+ %span (#{link_to '取消', '#', class: 'cancel'})
%td
- if runner.shared?
\-
@@ -33,16 +33,16 @@
= tag
%td
- if runner.contacted_at
- #{time_ago_in_words(runner.contacted_at)} ago
+ #{time_ago_in_words(runner.contacted_at)}之前
- else
- Never
+ 从未
%td
.pull-right
- = link_to 'Edit', admin_runner_path(runner), class: 'btn btn-sm'
+ = link_to '编辑', admin_runner_path(runner), class: 'btn btn-sm'
&nbsp;
- if runner.active?
- = link_to 'Pause', [:pause, :admin, runner], data: { confirm: "Are you sure?" }, method: :get, class: 'btn btn-danger btn-sm'
+ = link_to '暂停', [:pause, :admin, runner], data: { confirm: "确定要继续么?" }, method: :get, class: 'btn btn-danger btn-sm'
- else
- = link_to 'Resume', [:resume, :admin, runner], method: :get, class: 'btn btn-success btn-sm'
- = link_to 'Remove', [:admin, runner], data: { confirm: "Are you sure?" }, method: :delete, class: 'btn btn-danger btn-sm'
+ = link_to '继续', [:resume, :admin, runner], method: :get, class: 'btn btn-success btn-sm'
+ = link_to '删除', [:admin, runner], data: { confirm: "确定要继续么?" }, method: :delete, class: 'btn btn-danger btn-sm'
diff --git a/app/views/admin/runners/index.html.haml b/app/views/admin/runners/index.html.haml
index c407972cd08..61432db43c9 100644
--- a/app/views/admin/runners/index.html.haml
+++ b/app/views/admin/runners/index.html.haml
@@ -1,51 +1,51 @@
%p.lead
%span
- To register a new runner you should enter the following registration token.
- With this token the runner will request a unique runner token and use that for future communication.
- Registration token is
+ 要注册新的 runner 你需要输入后面的注册授权码。
+ Runner 将使用这个唯一授权码来标识自己,并使用它和服务器通信。
+ 注册授权码是
%code{ id: 'runners-token' } #{current_application_settings.runners_registration_token}
.bs-callout.clearfix
.pull-left
%p
- You can reset runners registration token by pressing a button below.
+ 你可以点击下面的按钮重置 runner 的注册授权码。
%p
= button_to reset_runners_token_admin_application_settings_path,
method: :put, class: 'btn btn-default',
- data: { confirm: 'Are you sure you want to reset registration token?' } do
+ data: { confirm: '确定要继续重置注册授权码么?' } do
= icon('refresh')
- Reset runners registration token
+ 重置 runner 注册授权码
.bs-callout
%p
- A 'runner' is a process which runs a build.
- You can setup as many runners as you need.
+ 一个 'runner' 就是一个运行构建的进程。
+ 你可以按照自己的需要设置很多个 runner。
%br
- Runners can be placed on separate users, servers, and even on your local machine.
+ Runners 可以被部署在不同的用户、服务器上,甚至在你本地使用的机器上。
%br
%div
- %span Each runner can be in one of the following states:
+ %span 每个 runner 可以是下列状态之一:
%ul
%li
- %span.label.label-success shared
- \- run builds from all unassigned projects
+ %span.label.label-success 共享的
+ \- 会运行所有未特殊指定项目的构建
%li
- %span.label.label-info specific
- \- run builds from assigned projects
+ %span.label.label-info 特定的
+ \- 只运行被特殊指定到该 runner 的项目的构建
%li
- %span.label.label-danger paused
- \- runner will not receive any new builds
+ %span.label.label-danger 暂停的
+ \- 该 runner 不会接受任何新构建
.append-bottom-20.clearfix
.pull-left
= form_tag admin_runners_path, id: 'runners-search', class: 'form-inline', method: :get do
.form-group
- = search_field_tag :search, params[:search], class: 'form-control', placeholder: 'Runner description or token', spellcheck: false
- = submit_tag 'Search', class: 'btn'
+ = search_field_tag :search, params[:search], class: 'form-control', placeholder: 'Runner 描述或授权码', spellcheck: false
+ = submit_tag '搜索', class: 'btn'
.pull-right.light
- Runners with last contact less than a minute ago: #{@active_runners_cnt}
+ 最后联系时间少于一分钟前的 runner 数量:#{@active_runners_cnt}
%br
@@ -53,13 +53,13 @@
%table.table
%thead
%tr
- %th Type
- %th Runner token
- %th Description
- %th Projects
- %th Builds
- %th Tags
- %th Last contact
+ %th 类型
+ %th Runner 授权码
+ %th 描述
+ %th 项目
+ %th 构建
+ %th 标签
+ %th 最后联系
%th
- @runners.each do |runner|
diff --git a/app/views/admin/runners/show.html.haml b/app/views/admin/runners/show.html.haml
index 8700b4820cd..941d02f8631 100644
--- a/app/views/admin/runners/show.html.haml
+++ b/app/views/admin/runners/show.html.haml
@@ -4,52 +4,52 @@
.pull-right
- if @runner.shared?
%span.runner-state.runner-state-shared
- Shared
+ 共享的
- else
%span.runner-state.runner-state-specific
- Specific
+ 特定的
- if @runner.shared?
.bs-callout.bs-callout-success
- %h4 This runner will process builds from ALL UNASSIGNED projects
+ %h4 此 runner 将会处理所有<b>未指派</b>项目的构建
%p
- If you want runners to build only specific projects, enable them in the table below.
- Keep in mind that this is a one way transition.
+ 如果你想让此 runner 只会处理指派项目的构建,请在下面的表格中启用相关项目的指派。
+ 需要注意的是,此操作只能一次。一旦指定,此 runner 将不能再转为共享的。
- else
.bs-callout.bs-callout-info
- %h4 This runner will process builds only from ASSIGNED projects
- %p You can't make this a shared runner.
+ %h4 此 runner 将只会处理<b>指派</b>项目的构建
+ %p 你不能再将此 runner 转为共享的。
%hr
= form_for @runner, url: admin_runner_path(@runner), html: { class: 'form-horizontal' } do |f|
.form-group
= label_tag :token, class: 'control-label' do
- Token
+ 授权码
.col-sm-10
= f.text_field :token, class: 'form-control', readonly: true
.form-group
= label_tag :description, class: 'control-label' do
- Description
+ 描述
.col-sm-10
= f.text_field :description, class: 'form-control'
.form-group
= label_tag :tag_list, class: 'control-label' do
- Tags
+ 标签列表
.col-sm-10
= f.text_field :tag_list, value: @runner.tag_list.to_s, class: 'form-control'
- .help-block You can setup builds to only use runners with specific tags
+ .help-block 你可以设置构建只使用指定标签的 runner
.form-actions
- = f.submit 'Save', class: 'btn btn-save'
+ = f.submit '保存', class: 'btn btn-save'
.row
.col-md-6
- %h4 Restrict projects for this runner
+ %h4 此 runner 指派的项目
- if @runner.projects.any?
%table.table
%thead
%tr
- %th Assigned projects
+ %th 指派的项目
%th
- @runner.runner_projects.each do |runner_project|
- project = runner_project.project
@@ -60,12 +60,12 @@
= project.name_with_namespace
%td
.pull-right
- = link_to 'Disable', [:admin, project.namespace.becomes(Namespace), project, runner_project], method: :delete, class: 'btn btn-danger btn-xs'
+ = link_to '禁用', [:admin, project.namespace.becomes(Namespace), project, runner_project], method: :delete, class: 'btn btn-danger btn-xs'
%table.table
%thead
%tr
- %th Project
+ %th 项目
%th
%tr
@@ -73,7 +73,7 @@
= form_tag admin_runner_path(@runner), id: 'runner-projects-search', class: 'form-inline', method: :get do
.form-group
= search_field_tag :search, params[:search], class: 'form-control', spellcheck: false
- = submit_tag 'Search', class: 'btn'
+ = submit_tag '搜索', class: 'btn'
%td
- @projects.each do |project|
@@ -84,19 +84,19 @@
.pull-right
= form_for [:admin, project.namespace.becomes(Namespace), project, project.runner_projects.new] do |f|
= f.hidden_field :runner_id, value: @runner.id
- = f.submit 'Enable', class: 'btn btn-xs'
+ = f.submit '启用', class: 'btn btn-xs'
= paginate @projects
.col-md-6
- %h4 Recent builds served by this runner
+ %h4 此 runner 最近完成的构建
%table.table.builds.runner-builds
%thead
%tr
- %th Build
- %th Status
- %th Project
- %th Commit
- %th Finished at
+ %th 构建
+ %th 状态
+ %th 项目
+ %th 提交
+ %th 结束时间
- @builds.each do |build|
- project = build.project
@@ -122,4 +122,4 @@
%td.timestamp
- if build.finished_at
- %span #{time_ago_in_words build.finished_at} ago
+ %span #{time_ago_in_words build.finished_at}之前
diff --git a/app/views/admin/services/_form.html.haml b/app/views/admin/services/_form.html.haml
index cdbfc60f9a4..6a446090bd5 100644
--- a/app/views/admin/services/_form.html.haml
+++ b/app/views/admin/services/_form.html.haml
@@ -1,10 +1,10 @@
%h3.page-title
= @service.title
-%p #{@service.description} template
+%p #{@service.description} 模板
= form_for :service, url: admin_application_settings_service_path, method: :put, html: { class: 'form-horizontal fieldset-form' } do |form|
= render 'shared/service_settings', form: form
.form-actions
- = form.submit 'Save', class: 'btn btn-save'
+ = form.submit '保存', class: 'btn btn-save'
diff --git a/app/views/admin/services/edit.html.haml b/app/views/admin/services/edit.html.haml
index 53d970e33c1..22612e311bb 100644
--- a/app/views/admin/services/edit.html.haml
+++ b/app/views/admin/services/edit.html.haml
@@ -1,2 +1,2 @@
-- page_title @service.title, "Service Templates"
+- page_title @service.title, "服务模板"
= render 'form'
diff --git a/app/views/admin/services/index.html.haml b/app/views/admin/services/index.html.haml
index 6a5986f496a..30b60bf8d3a 100644
--- a/app/views/admin/services/index.html.haml
+++ b/app/views/admin/services/index.html.haml
@@ -1,15 +1,15 @@
-- page_title "Service Templates"
-%h3.page-title Service templates
-%p.light Service template allows you to set default values for project services
+- page_title "服务模板"
+%h3.page-title 服务模板
+%p.light 服务模板可以为项目服务设置默认值
.table-holder
%table.table
%thead
%tr
%th
- %th Service
- %th Description
- %th Last edit
+ %th 服务
+ %th 描述
+ %th 最后编辑
- @services.sort_by(&:title).each do |service|
%tr
%td
@@ -21,4 +21,4 @@
= service.description
%td.light
= time_ago_in_words service.updated_at
- ago
+ 过去
diff --git a/app/views/admin/users/_form.html.haml b/app/views/admin/users/_form.html.haml
index d2527ede995..f4fce7950ef 100644
--- a/app/views/admin/users/_form.html.haml
+++ b/app/views/admin/users/_form.html.haml
@@ -78,19 +78,19 @@
= f.label :skype, class: 'control-label'
.col-sm-10= f.text_field :skype, class: 'form-control'
.form-group
- = f.label :linkedin, class: 'control-label'
+ = f.label :linkedin, "领英", class: 'control-label'
.col-sm-10= f.text_field :linkedin, class: 'form-control'
.form-group
- = f.label :twitter, class: 'control-label'
+ = f.label :twitter, "推特", class: 'control-label'
.col-sm-10= f.text_field :twitter, class: 'form-control'
.form-group
- = f.label :website_url, 'Website', class: 'control-label'
+ = f.label :website_url, "网址", class: 'control-label'
.col-sm-10= f.text_field :website_url, class: 'form-control'
.form-actions
- if @user.new_record?
- = f.submit 'Create user', class: "btn btn-create"
- = link_to 'Cancel', admin_users_path, class: "btn btn-cancel"
+ = f.submit '创建用户', class: "btn btn-create"
+ = link_to '取消', admin_users_path, class: "btn btn-cancel"
- else
- = f.submit 'Save changes', class: "btn btn-save"
- = link_to 'Cancel', admin_user_path(@user), class: "btn btn-cancel"
+ = f.submit '保存修改', class: "btn btn-save"
+ = link_to '取消', admin_user_path(@user), class: "btn btn-cancel"
diff --git a/app/views/admin/users/_head.html.haml b/app/views/admin/users/_head.html.haml
index ce5e21e54cc..deb4d5aa4d3 100644
--- a/app/views/admin/users/_head.html.haml
+++ b/app/views/admin/users/_head.html.haml
@@ -1,26 +1,26 @@
%h3.page-title
= @user.name
- if @user.blocked?
- %span.cred (Blocked)
+ %span.cred (禁用的)
- if @user.admin
- %span.cred (Admin)
+ %span.cred (管理)
.pull-right
- unless @user == current_user || @user.blocked?
- = link_to 'Impersonate', impersonate_admin_user_path(@user), method: :post, class: "btn btn-nr btn-grouped btn-info"
+ = link_to '假冒', impersonate_admin_user_path(@user), method: :post, class: "btn btn-nr btn-grouped btn-info"
= link_to edit_admin_user_path(@user), class: "btn btn-nr btn-grouped" do
%i.fa.fa-pencil-square-o
- Edit
+ 编辑
%hr
%ul.nav-links
= nav_link(path: 'users#show') do
- = link_to "Account", admin_user_path(@user)
+ = link_to "账户", admin_user_path(@user)
= nav_link(path: 'users#groups') do
- = link_to "Groups", groups_admin_user_path(@user)
+ = link_to "群组", groups_admin_user_path(@user)
= nav_link(path: 'users#projects') do
- = link_to "Projects", projects_admin_user_path(@user)
+ = link_to "项目", projects_admin_user_path(@user)
= nav_link(path: 'users#keys') do
- = link_to "SSH keys", keys_admin_user_path(@user)
+ = link_to "SSH 密钥", keys_admin_user_path(@user)
= nav_link(controller: :identities) do
- = link_to "Identities", admin_user_identities_path(@user)
+ = link_to "身份", admin_user_identities_path(@user)
.append-bottom-default
diff --git a/app/views/admin/users/_profile.html.haml b/app/views/admin/users/_profile.html.haml
index 6bc217f84cc..c2502c82dd0 100644
--- a/app/views/admin/users/_profile.html.haml
+++ b/app/views/admin/users/_profile.html.haml
@@ -1,13 +1,13 @@
.panel.panel-default
.panel-heading
- Profile
+ 个人资料
%ul.well-list
%li
- %span.light Member since
+ %span.light 注册时间:
%strong= user.created_at.to_s(:medium)
- unless user.public_email.blank?
%li
- %span.light E-mail:
+ %span.light 电子邮箱:
%strong= link_to user.public_email, "mailto:#{user.public_email}"
- unless user.skype.blank?
%li
@@ -15,17 +15,17 @@
%strong= link_to user.skype, "skype:#{user.skype}"
- unless user.linkedin.blank?
%li
- %span.light LinkedIn:
+ %span.light 领英:
%strong= link_to user.linkedin, "https://www.linkedin.com/in/#{user.linkedin}"
- unless user.twitter.blank?
%li
- %span.light Twitter:
+ %span.light 推特:
%strong= link_to user.twitter, "https://twitter.com/#{user.twitter}"
- unless user.website_url.blank?
%li
- %span.light Website:
+ %span.light 网站:
%strong= link_to user.short_website_url, user.full_website_url
- unless user.location.blank?
%li
- %span.light Location:
+ %span.light 位置:
%strong= user.location
diff --git a/app/views/admin/users/edit.html.haml b/app/views/admin/users/edit.html.haml
index 3b6fd71500d..395e9d30c33 100644
--- a/app/views/admin/users/edit.html.haml
+++ b/app/views/admin/users/edit.html.haml
@@ -1,5 +1,5 @@
-- page_title "Edit", @user.name, "Users"
+- page_title "编辑", @user.name, "用户"
%h3.page-title
- Edit user: #{@user.name}
+ 编辑用户:#{@user.name}
%hr
= render 'form'
diff --git a/app/views/admin/users/groups.html.haml b/app/views/admin/users/groups.html.haml
index dbecb7bbfd6..ac7500ad67c 100644
--- a/app/views/admin/users/groups.html.haml
+++ b/app/views/admin/users/groups.html.haml
@@ -1,9 +1,9 @@
-- page_title "Groups", @user.name, "Users"
+- page_title "群组", @user.name, "用户"
= render 'admin/users/head'
- if @user.group_members.present?
.panel.panel-default
- .panel-heading Groups:
+ .panel-heading 群组:
%ul.well-list
- @user.group_members.each do |group_member|
- group = group_member.group
@@ -13,7 +13,7 @@
.pull-right
%span.light= group_member.human_access
- unless group_member.owner?
- = link_to group_group_member_path(group, group_member), data: { confirm: remove_user_from_group_message(group, group_member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: 'Remove user from group' do
+ = link_to group_group_member_path(group, group_member), data: { confirm: remove_user_from_group_message(group, group_member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: '从群组中删除用户' do
%i.fa.fa-times.fa-inverse
- else
- .nothing-here-block This user has no groups.
+ .nothing-here-block 此用户没有群组。
diff --git a/app/views/admin/users/index.html.haml b/app/views/admin/users/index.html.haml
index 0ee8dc962b9..a52aa324503 100644
--- a/app/views/admin/users/index.html.haml
+++ b/app/views/admin/users/index.html.haml
@@ -59,10 +59,10 @@
= link_to admin_users_path(sort: sort_value_oldest_updated, filter: params[:filter]) do
= sort_title_oldest_updated
- = link_to 'New User', new_admin_user_path, class: "btn btn-new"
+ = link_to '新用户', new_admin_user_path, class: "btn btn-new"
= form_tag admin_users_path, method: :get, class: 'form-inline' do
.form-group
- = search_field_tag :name, params[:name], placeholder: 'Name, email or username', class: 'form-control', spellcheck: false
+ = search_field_tag :name, params[:name], placeholder: '姓名、电子邮箱或用户名', class: 'form-control', spellcheck: false
= hidden_field_tag "filter", params[:filter]
= button_tag class: 'btn btn-primary' do
%i.fa.fa-search
diff --git a/app/views/admin/users/new.html.haml b/app/views/admin/users/new.html.haml
index bfc36ed7373..b313613a7b1 100644
--- a/app/views/admin/users/new.html.haml
+++ b/app/views/admin/users/new.html.haml
@@ -1,5 +1,5 @@
-- page_title "New User"
+- page_title "新用户"
%h3.page-title
- New user
+ 新用户
%hr
= render 'form'
diff --git a/app/views/admin/users/projects.html.haml b/app/views/admin/users/projects.html.haml
index b655b2a15f5..624b9ff5a4e 100644
--- a/app/views/admin/users/projects.html.haml
+++ b/app/views/admin/users/projects.html.haml
@@ -1,27 +1,27 @@
-- page_title "Projects", @user.name, "Users"
+- page_title "项目", @user.name, "用户"
= render 'admin/users/head'
- if @user.groups.any?
.panel.panel-default
- .panel-heading Group projects
+ .panel-heading 群组项目
%ul.well-list
- @user.groups.each do |group|
%li
%strong= group.name
- &ndash; access to
- #{pluralize(group.projects.count, 'project')}
+ &ndash; 访问
+ #{pluralize(group.projects.count, '个项目', '个项目')}
.row
.col-md-6
- if @personal_projects.present?
= render 'admin/users/projects', projects: @personal_projects
- else
- .nothing-here-block This user has no personal projects.
+ .nothing-here-block 此用户没有个人项目。
.col-md-6
.panel.panel-default
- .panel-heading Joined projects (#{@joined_projects.count})
+ .panel-heading 加入的项目 (#{@joined_projects.count})
%ul.well-list
- @joined_projects.sort_by(&:name_with_namespace).each do |project|
- member = project.team.find_member(@user.id)
@@ -33,11 +33,11 @@
- if member
.pull-right
- if member.owner?
- %span.light Owner
+ %span.light 所有者
- else
%span.light= member.human_access
- if member.respond_to? :project
- = link_to namespace_project_project_member_path(project.namespace, project, member), data: { confirm: remove_from_project_team_message(project, member) }, remote: true, method: :delete, class: "btn-xs btn btn-remove", title: 'Remove user from project' do
+ = link_to namespace_project_project_member_path(project.namespace, project, member), data: { confirm: remove_from_project_team_message(project, member) }, remote: true, method: :delete, class: "btn-xs btn btn-remove", title: '从项目中删除用户' do
%i.fa.fa-times
diff --git a/app/views/admin/users/show.html.haml b/app/views/admin/users/show.html.haml
index d37489bebea..c078453c1ef 100644
--- a/app/views/admin/users/show.html.haml
+++ b/app/views/admin/users/show.html.haml
@@ -1,4 +1,4 @@
-- page_title @user.name, "Users"
+- page_title @user.name, "用户"
= render 'admin/users/head'
.row
@@ -10,7 +10,7 @@
%li
= image_tag avatar_icon(@user, 60), class: "avatar s60"
%li
- %span.light Profile page:
+ %span.light 个人资料页面:
%strong
= link_to user_path(@user) do
= @user.username
@@ -119,7 +119,7 @@
- if @user.created_by
%li
- %span.light Created by:
+ %span.light 创建者:
%strong
= link_to @user.created_by.name, [:admin, @user.created_by]
@@ -128,66 +128,66 @@
- unless @user.confirmed?
.panel.panel-info
.panel-heading
- Confirm user
+ 确认用户
.panel-body
- if @user.unconfirmed_email.present?
- email = " (#{@user.unconfirmed_email})"
- %p This user has an unconfirmed email address#{email}. You may force a confirmation.
+ %p 此用户有一个未确认的电子邮箱地址 #{email}。你可以强制确认。
%br
- = link_to 'Confirm user', confirm_admin_user_path(@user), method: :put, class: "btn btn-info", data: { confirm: 'Are you sure?' }
+ = link_to '确认用户', confirm_admin_user_path(@user), method: :put, class: "btn btn-info", data: { confirm: '确认要继续么?' }
- if @user.blocked?
.panel.panel-info
.panel-heading
- This user is blocked
+ 该用户被禁用
.panel-body
- %p Blocking user has the following effects:
+ %p 禁用用户有如下效果:
%ul
- %li User will not be able to login
- %li User will not be able to access git repositories
- %li Personal projects will be left
- %li Owned groups will be left
+ %li 用户无法登录
+ %li 用户无法访问 git 版本仓库
+ %li 个人项目将被移除
+ %li 拥有的群组将被移除
%br
- = link_to 'Unblock user', unblock_admin_user_path(@user), method: :put, class: "btn btn-info", data: { confirm: 'Are you sure?' }
+ = link_to '启用用户', unblock_admin_user_path(@user), method: :put, class: "btn btn-info", data: { confirm: '确认要继续么?' }
- else
.panel.panel-warning
.panel-heading
- Block this user
+ 禁用用户
.panel-body
- %p Blocking user has the following effects:
+ %p 禁用用户有如下效果:
%ul
- %li User will not be able to login
- %li User will not be able to access git repositories
- %li User will be removed from joined projects and groups
- %li Personal projects will be left
- %li Owned groups will be left
+ %li 用户无法登录
+ %li 用户无法访问 git 版本仓库
+ %li 用户将从加入的项目和群组中删除
+ %li 个人项目将被移除
+ %li 拥有的群组将被移除
%br
- = link_to 'Block user', block_admin_user_path(@user), data: { confirm: 'USER WILL BE BLOCKED! Are you sure?' }, method: :put, class: "btn btn-warning"
+ = link_to '禁用用户', block_admin_user_path(@user), data: { confirm: '用户将被禁用!确定要继续么?' }, method: :put, class: "btn btn-warning"
- if @user.access_locked?
.panel.panel-info
.panel-heading
- This account has been locked
+ 此账户已被锁定
.panel-body
- %p This user has been temporarily locked due to excessive number of failed logins. You may manually unlock the account.
+ %p 此用户因为登录失败过多而被临时锁定。可以手动解锁此账户。
%br
- = link_to 'Unlock user', unlock_admin_user_path(@user), method: :put, class: "btn btn-info", data: { confirm: 'Are you sure?' }
+ = link_to '解锁用户', unlock_admin_user_path(@user), method: :put, class: "btn btn-info", data: { confirm: '确定要继续么?' }
.panel.panel-danger
.panel-heading
- Remove user
+ 删除用户
.panel-body
- if @user.can_be_removed?
- %p Deleting a user has the following effects:
+ %p 删除用户有如下效果:
%ul
- %li All user content like authored issues, snippets, comments will be removed
+ %li 所有用户内容,比如:问题、代码片段、注释都将被删除
- rp = @user.personal_projects.count
- unless rp.zero?
- %li #{pluralize rp, 'personal project'} will be removed and cannot be restored
+ %li #{pluralize rp, '个个人项目', '个个人项目'}将被删除并无法恢复
%br
- = link_to 'Remove user', [:admin, @user], data: { confirm: "USER #{@user.name} WILL BE REMOVED! Are you sure?" }, method: :delete, class: "btn btn-remove"
+ = link_to '删除用户', [:admin, @user], data: { confirm: "用户 #{@user.name} 将被删除!确定要继续么?" }, method: :delete, class: "btn btn-remove"
- else
- if @user.solo_owned_groups.present?
%p
- This user is currently an owner in these groups:
+ 此用户当前拥有以下群组:
%strong #{@user.solo_owned_groups.map(&:name).join(', ')}
%p
- You must transfer ownership or delete these groups before you can delete this user.
+ 在删除此用户前,请转移这些群组的所有权或删除之。
diff --git a/app/views/ci/errors/show.haml b/app/views/ci/errors/show.haml
index 2788112c835..5dd495eeb82 100644
--- a/app/views/ci/errors/show.haml
+++ b/app/views/ci/errors/show.haml
@@ -1,2 +1,2 @@
-%h3.error Error
+%h3.error 错误
= @error
diff --git a/app/views/ci/lints/_create.html.haml b/app/views/ci/lints/_create.html.haml
index f7875e68b7e..e59cece7a59 100644
--- a/app/views/ci/lints/_create.html.haml
+++ b/app/views/ci/lints/_create.html.haml
@@ -1,43 +1,43 @@
- if @status
%p
- %b Status:
- syntax is correct
+ %b 状态:
+ 语法正确
%i.fa.fa-ok.correct-syntax
.table-holder
%table.table.table-bordered
%thead
%tr
- %th Parameter
- %th Value
+ %th 参数
+ %th 值
%tbody
- @stages.each do |stage|
- @builds.select { |build| build[:stage] == stage }.each do |build|
%tr
- %td #{stage.capitalize} Job - #{build[:name]}
+ %td #{stage.capitalize} 作业 - #{build[:name]}
%td
%pre
= simple_format build[:commands]
%br
- %b Tag list:
+ %b 标签列表:
= build[:tags]
%br
- %b Refs only:
+ %b 仅供 Refs:
= build[:only] && build[:only].join(", ")
%br
- %b Refs except:
+ %b 排除 Refs:
= build[:except] && build[:except].join(", ")
%br
- %b When:
+ %b 当:
= build[:when]
- if build[:allow_failure]
- %b Allowed to fail
+ %b 允许失败
-else
%p
- %b Status:
- syntax is incorrect
+ %b 状态:
+ 语法错误
%i.fa.fa-remove.incorrect-syntax
- %b Error:
+ %b 错误:
= @error
diff --git a/app/views/ci/lints/show.html.haml b/app/views/ci/lints/show.html.haml
index 0044d779c31..b8660f4d17c 100644
--- a/app/views/ci/lints/show.html.haml
+++ b/app/views/ci/lints/show.html.haml
@@ -1,15 +1,15 @@
-%h2 Check your .gitlab-ci.yml
+%h2 检查你的 .gitlab-ci.yml
%hr
.row
= form_tag ci_lint_path, method: :post do
.form-group
- = label_tag(:content, 'Content of .gitlab-ci.yml', class: 'control-label text-nowrap')
+ = label_tag(:content, '.gitlab-ci.yml 内容', class: 'control-label text-nowrap')
.col-sm-12
= text_area_tag(:content, @content, class: 'form-control span1', rows: 7, require: true)
.col-sm-12
.pull-left.prepend-top-10
- = submit_tag('Validate', class: 'btn btn-success submit-yml')
+ = submit_tag('验证', class: 'btn btn-success submit-yml')
.row.prepend-top-20
.col-sm-12
diff --git a/app/views/ci/projects/index.html.haml b/app/views/ci/projects/index.html.haml
index 9c2290bc4a5..552437cd124 100644
--- a/app/views/ci/projects/index.html.haml
+++ b/app/views/ci/projects/index.html.haml
@@ -1,20 +1,20 @@
.wiki
%h1
- GitLab CI is now integrated in GitLab UI
- %h2 For existing projects
+ GitLab CI 现在已集成到 GitLab 界面
+ %h2 已开启 CI 的项目
%p
- Check the following pages to find the CI status you're looking for:
+ 在下列页面查看相关 CI 状态:
%ul
- %li Projects page - shows CI status for each project.
- %li Project commits page - show CI status for each commit.
+ %li 项目页面 - 显示每个项目的 CI 状态。
+ %li 项目提交页面 - 显示每个提交的 CI 状态。
- %h2 For new projects
+ %h2 新项目
%p
- If you want to enable CI for a new project it is easy as adding
+ 只需简单的在仓库根目录增加
= link_to ".gitlab-ci.yml", "http://doc.gitlab.com/ce/ci/yaml/README.html"
- file to your repository
+ 文件就可以给新项目开启 CI 功能。
diff --git a/app/views/ci/shared/_guide.html.haml b/app/views/ci/shared/_guide.html.haml
index 09e7e653521..8f4fee67bff 100644
--- a/app/views/ci/shared/_guide.html.haml
+++ b/app/views/ci/shared/_guide.html.haml
@@ -1,13 +1,13 @@
.bs-callout.help-callout
- %h4 How to setup CI for this project
+ %h4 如何给此项目设置 CI
%ol
%li
- Add at least one runner to the project.
- Go to #{link_to 'Runners page', runners_path(@project), target: :blank} for instructions.
+ 增加至少一个 runner 给此项目。
+ 转到 #{link_to 'Runners 页面', runners_path(@project), target: :blank}去操作。
%li
- Put the .gitlab-ci.yml in the root of your repository. Examples can be found in
- #{link_to "Configuring project (.gitlab-ci.yml)", "http://doc.gitlab.com/ci/yaml/README.html", target: :blank}.
- You can also test your .gitlab-ci.yml in the #{link_to "Lint", ci_lint_path}
+ 在你的仓库跟目录增加 .gitlab-ci.yml 文件。可以在
+ #{link_to "配置项目 (.gitlab-ci.yml)", "http://doc.gitlab.com/ci/yaml/README.html", target: :blank}中找到示例。
+ 你也可以使用 #{link_to "Lint", ci_lint_path} 工具来测试你的 .gitlab-ci.yml 文件。
%li
- Return to this page and refresh it, it should show a new build.
+ 返回到此页面再刷新,将会显示一个新的构建。
diff --git a/app/views/ci/shared/_no_runners.html.haml b/app/views/ci/shared/_no_runners.html.haml
index f56c37d9b37..89d25bf46af 100644
--- a/app/views/ci/shared/_no_runners.html.haml
+++ b/app/views/ci/shared/_no_runners.html.haml
@@ -1,7 +1,7 @@
.alert.alert-danger
%p
- Now you need Runners to process your builds.
+ 现在需要 Runners 来处理你的构建。
%span
- Checkout the #{link_to 'GitLab Runner section', 'https://about.gitlab.com/gitlab-ci/#gitlab-runner', target: '_blank'} to install it
+ 请参阅 #{link_to 'GitLab Runner 章节', 'https://about.gitlab.com/gitlab-ci/#gitlab-runner', target: '_blank'}来安装。
diff --git a/app/views/dashboard/_activity_head.html.haml b/app/views/dashboard/_activity_head.html.haml
index b78e70ebc1e..fa76520e2a3 100644
--- a/app/views/dashboard/_activity_head.html.haml
+++ b/app/views/dashboard/_activity_head.html.haml
@@ -1,7 +1,7 @@
%ul.nav-links
%li{ class: ("active" unless params[:filter]) }
= link_to activity_dashboard_path, class: 'shortcuts-activity', data: {placement: 'right'} do
- Your Projects
+ 你的项目
%li{ class: ("active" if params[:filter] == 'starred') }
= link_to activity_dashboard_path(filter: 'starred'), data: {placement: 'right'} do
- Starred Projects
+ 星标项目
diff --git a/app/views/dashboard/_groups_head.html.haml b/app/views/dashboard/_groups_head.html.haml
index 3d17f74b709..f5bc1a3af9a 100644
--- a/app/views/dashboard/_groups_head.html.haml
+++ b/app/views/dashboard/_groups_head.html.haml
@@ -1,13 +1,13 @@
.top-area
%ul.nav-links
= nav_link(page: dashboard_groups_path) do
- = link_to dashboard_groups_path, title: 'Your groups' do
- Your Groups
+ = link_to dashboard_groups_path, title: '你的群组' do
+ 你的群组
= nav_link(page: explore_groups_path) do
- = link_to explore_groups_path, title: 'Explore groups' do
- Explore Groups
+ = link_to explore_groups_path, title: '浏览群组' do
+ 浏览群组
- if current_user.can_create_group?
.nav-controls
= link_to new_group_path, class: "btn btn-new" do
= icon('plus')
- New Group
+ 新群组
diff --git a/app/views/dashboard/_snippets_head.html.haml b/app/views/dashboard/_snippets_head.html.haml
index b25e8ea1f0c..36ba18688a9 100644
--- a/app/views/dashboard/_snippets_head.html.haml
+++ b/app/views/dashboard/_snippets_head.html.haml
@@ -1,7 +1,7 @@
%ul.nav-links
= nav_link(page: dashboard_snippets_path, html_options: {class: 'home'}) do
- = link_to dashboard_snippets_path, title: 'Your snippets', data: {placement: 'right'} do
- Your Snippets
+ = link_to dashboard_snippets_path, title: '你的代码片段', data: {placement: 'right'} do
+ 你的代码片段
= nav_link(page: explore_snippets_path) do
- = link_to explore_snippets_path, title: 'Explore snippets', data: {placement: 'right'} do
- Explore Snippets
+ = link_to explore_snippets_path, title: '浏览代码片段', data: {placement: 'right'} do
+ 浏览代码片段
diff --git a/app/views/dashboard/activity.html.haml b/app/views/dashboard/activity.html.haml
index aa57df14c23..a6577803865 100644
--- a/app/views/dashboard/activity.html.haml
+++ b/app/views/dashboard/activity.html.haml
@@ -1,9 +1,9 @@
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, dashboard_projects_url(format: :atom, private_token: current_user.private_token), title: "All activity")
+ = auto_discovery_link_tag(:atom, dashboard_projects_url(format: :atom, private_token: current_user.private_token), title: "所有活动")
-- page_title "Activity"
-- header_title "Activity", activity_dashboard_path
+- page_title "活动"
+- header_title "活动", activity_dashboard_path
= render 'dashboard/activity_head'
diff --git a/app/views/dashboard/groups/index.html.haml b/app/views/dashboard/groups/index.html.haml
index caca91af536..5cd1bd17d79 100644
--- a/app/views/dashboard/groups/index.html.haml
+++ b/app/views/dashboard/groups/index.html.haml
@@ -1,5 +1,5 @@
-- page_title "Groups"
-- header_title "Groups", dashboard_groups_path
+- page_title "群组"
+- header_title "群组", dashboard_groups_path
= render 'dashboard/groups_head'
%ul.content-list
diff --git a/app/views/dashboard/issues.html.haml b/app/views/dashboard/issues.html.haml
index dfa5f80eef8..172d8ec6e02 100644
--- a/app/views/dashboard/issues.html.haml
+++ b/app/views/dashboard/issues.html.haml
@@ -1,8 +1,8 @@
-- page_title "Issues"
-- header_title "Issues", issues_dashboard_path(assignee_id: current_user.id)
+- page_title "问题"
+- header_title "问题", issues_dashboard_path(assignee_id: current_user.id)
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, issues_dashboard_url(format: :atom, private_token: current_user.private_token), title: "#{current_user.name} issues")
+ = auto_discovery_link_tag(:atom, issues_dashboard_url(format: :atom, private_token: current_user.private_token), title: "#{current_user.name} 问题")
.top-area
= render 'shared/issuable/nav', type: :issues
@@ -10,7 +10,7 @@
- if current_user
= link_to issues_dashboard_url(format: :atom, private_token: current_user.private_token), class: 'btn' do
= icon('rss')
- = render 'shared/new_project_item_select', path: 'issues/new', label: "New Issue"
+ = render 'shared/new_project_item_select', path: 'issues/new', label: "新问题"
= render 'shared/issuable/filter', type: :issues
diff --git a/app/views/dashboard/merge_requests.html.haml b/app/views/dashboard/merge_requests.html.haml
index fb016599fef..64b747bb055 100644
--- a/app/views/dashboard/merge_requests.html.haml
+++ b/app/views/dashboard/merge_requests.html.haml
@@ -1,10 +1,10 @@
-- page_title "Merge Requests"
-- header_title "Merge Requests", merge_requests_dashboard_path(assignee_id: current_user.id)
+- page_title "合并请求"
+- header_title "合并请求", merge_requests_dashboard_path(assignee_id: current_user.id)
.top-area
= render 'shared/issuable/nav', type: :merge_requests
.nav-controls
- = render 'shared/new_project_item_select', path: 'merge_requests/new', label: "New Merge Request"
+ = render 'shared/new_project_item_select', path: 'merge_requests/new', label: "新合并请求"
= render 'shared/issuable/filter', type: :merge_requests
diff --git a/app/views/dashboard/milestones/index.html.haml b/app/views/dashboard/milestones/index.html.haml
index 917bfbd47e9..d5c42c3a8f3 100644
--- a/app/views/dashboard/milestones/index.html.haml
+++ b/app/views/dashboard/milestones/index.html.haml
@@ -1,17 +1,17 @@
-- page_title "Milestones"
-- header_title "Milestones", dashboard_milestones_path
+- page_title "里程碑"
+- header_title "里程碑", dashboard_milestones_path
.top-area
= render 'shared/milestones_filter'
.nav-controls
- = render 'shared/new_project_item_select', path: 'milestones/new', label: "New Milestone", include_groups: true
+ = render 'shared/new_project_item_select', path: 'milestones/new', label: "新里程碑", include_groups: true
.milestones
%ul.content-list
- if @milestones.blank?
%li
- .nothing-here-block No milestones to show
+ .nothing-here-block 没有里程碑显示
- else
- @milestones.each do |milestone|
= render 'milestone', milestone: milestone
diff --git a/app/views/dashboard/projects/_zero_authorized_projects.html.haml b/app/views/dashboard/projects/_zero_authorized_projects.html.haml
index d54c7cad7be..33b5b8066bb 100644
--- a/app/views/dashboard/projects/_zero_authorized_projects.html.haml
+++ b/app/views/dashboard/projects/_zero_authorized_projects.html.haml
@@ -28,13 +28,13 @@
%i.fa.fa-users
.dashboard-intro-text
%p.slead
- You can create a group for several dependent projects.
+ 你可以创建一个存放多个相关项目的群组。
%br
- Groups are the best way to manage projects and members.
+ 群组是管理项目和成员的最佳方式。
.link_holder
= link_to new_group_path, class: "btn btn-new" do
%i.fa.fa-plus
- New Group
+ 新群组
-if publicish_project_count > 0
%hr
diff --git a/app/views/dashboard/projects/index.html.haml b/app/views/dashboard/projects/index.html.haml
index 4565e752c1f..c6c52b2d01c 100644
--- a/app/views/dashboard/projects/index.html.haml
+++ b/app/views/dashboard/projects/index.html.haml
@@ -1,9 +1,9 @@
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, dashboard_projects_url(format: :atom, private_token: current_user.private_token), title: "All activity")
+ = auto_discovery_link_tag(:atom, dashboard_projects_url(format: :atom, private_token: current_user.private_token), title: "所有活动")
-- page_title "Projects"
-- header_title "Projects", dashboard_projects_path
+- page_title "项目"
+- header_title "项目", dashboard_projects_path
= render 'dashboard/projects_head'
diff --git a/app/views/dashboard/projects/starred.html.haml b/app/views/dashboard/projects/starred.html.haml
index 70705923d42..770b8bd7b2b 100644
--- a/app/views/dashboard/projects/starred.html.haml
+++ b/app/views/dashboard/projects/starred.html.haml
@@ -1,5 +1,5 @@
-- page_title "Starred Projects"
-- header_title "Projects", dashboard_projects_path
+- page_title "星标项目"
+- header_title "项目", dashboard_projects_path
= render 'dashboard/projects_head'
@@ -9,5 +9,5 @@
- if @projects.any?
= render 'projects'
- else
- %h3 You don't have starred projects yet
- %p.slead Visit project page and press on star icon and it will appear on this page.
+ %h3 你还没有给任何项目加注星标
+ %p.slead 访问项目页面然后按下星标图标即可将项目显示在此页面。
diff --git a/app/views/dashboard/snippets/index.html.haml b/app/views/dashboard/snippets/index.html.haml
index d4e7862981c..c2be2e70692 100644
--- a/app/views/dashboard/snippets/index.html.haml
+++ b/app/views/dashboard/snippets/index.html.haml
@@ -1,36 +1,36 @@
-- page_title "Snippets"
-- header_title "Snippets", dashboard_snippets_path
+- page_title "代码片段"
+- header_title "代码片段", dashboard_snippets_path
= render 'dashboard/snippets_head'
.nav-block
.controls
- = link_to new_snippet_path, class: "btn btn-new", title: "New Snippet" do
+ = link_to new_snippet_path, class: "btn btn-new", title: "新代码片段" do
= icon('plus')
- New Snippet
+ 新代码片段
.nav-links.snippet-scope-menu
%li{ class: ("active" unless params[:scope]) }
= link_to dashboard_snippets_path do
- All
+ 全部
%span.badge
= current_user.snippets.count
%li{ class: ("active" if params[:scope] == "are_private") }
= link_to dashboard_snippets_path(scope: 'are_private') do
- Private
+ 私有
%span.badge
= current_user.snippets.are_private.count
%li{ class: ("active" if params[:scope] == "are_internal") }
= link_to dashboard_snippets_path(scope: 'are_internal') do
- Internal
+ 内部
%span.badge
= current_user.snippets.are_internal.count
%li{ class: ("active" if params[:scope] == "are_public") }
= link_to dashboard_snippets_path(scope: 'are_public') do
- Public
+ 公开
%span.badge
= current_user.snippets.are_public.count
diff --git a/app/views/dashboard/todos/index.html.haml b/app/views/dashboard/todos/index.html.haml
index 623381375a5..f9804101a92 100644
--- a/app/views/dashboard/todos/index.html.haml
+++ b/app/views/dashboard/todos/index.html.haml
@@ -30,18 +30,18 @@
.filter-item.inline
= select_tag('project_id', todo_projects_options,
class: 'select2 trigger-submit', include_blank: true,
- data: {placeholder: 'Project'})
+ data: {placeholder: '项目'})
.filter-item.inline
= users_select_tag(:author_id, selected: params[:author_id],
- placeholder: 'Author', class: 'trigger-submit', any_user: "Any Author", first_user: true, current_user: true)
+ placeholder: '作者', class: 'trigger-submit', any_user: "任何作者", first_user: true, current_user: true)
.filter-item.inline
= select_tag('type', todo_types_options,
class: 'select2 trigger-submit', include_blank: true,
- data: {placeholder: 'Type'})
+ data: {placeholder: '类型'})
.filter-item.inline.actions-filter
= select_tag('action_id', todo_actions_options,
class: 'select2 trigger-submit', include_blank: true,
- data: {placeholder: 'Action'})
+ data: {placeholder: '动作'})
.prepend-top-default
- if @todos.any?
@@ -55,7 +55,7 @@
= render group[1]
= paginate @todos, theme: "gitlab"
- else
- .nothing-here-block You're all done!
+ .nothing-here-block 全部已完成!
:javascript
new UsersSelect();
diff --git a/app/views/devise/confirmations/new.html.haml b/app/views/devise/confirmations/new.html.haml
index 970ba147111..657c70fa63a 100644
--- a/app/views/devise/confirmations/new.html.haml
+++ b/app/views/devise/confirmations/new.html.haml
@@ -1,14 +1,14 @@
.login-box
.login-heading
- %h3 Resend confirmation instructions
+ %h3 重新发送确认邮件
.login-body
= form_for(resource, as: resource_name, url: confirmation_path(resource_name), html: { method: :post }) do |f|
.devise-errors
= devise_error_messages!
.clearfix.append-bottom-20
- = f.email_field :email, placeholder: 'Email', class: "form-control", required: true
+ = f.email_field :email, placeholder: '电子邮箱', class: "form-control", required: true
.clearfix
- = f.submit "Resend confirmation instructions", class: 'btn btn-success'
+ = f.submit "重新发送确认邮件", class: 'btn btn-success'
.clearfix.prepend-top-20
= render 'devise/shared/sign_in_link'
diff --git a/app/views/devise/mailer/confirmation_instructions.html.erb b/app/views/devise/mailer/confirmation_instructions.html.erb
index c6fa8f0ee36..603b26a4109 100644
--- a/app/views/devise/mailer/confirmation_instructions.html.erb
+++ b/app/views/devise/mailer/confirmation_instructions.html.erb
@@ -1,9 +1,9 @@
-<p>Welcome <%= @resource.name %>!</p>
+<p>欢迎 <%= @resource.name %>!</p>
<% if @resource.unconfirmed_email.present? %>
- <p>You can confirm your email (<%= @resource.unconfirmed_email %>) through the link below:</p>
+ <p>你可以通过下面的链接确认你的电子邮箱 (<%= @resource.unconfirmed_email %>):</p>
<% else %>
- <p>You can confirm your account through the link below:</p>
+ <p>你可以通过下面的链接确认你的账号:</p>
<% end %>
-<p><%= link_to 'Confirm your account', confirmation_url(@resource, confirmation_token: @token) %></p>
+<p><%= link_to '确认账号', confirmation_url(@resource, confirmation_token: @token) %></p>
diff --git a/app/views/devise/mailer/reset_password_instructions.html.erb b/app/views/devise/mailer/reset_password_instructions.html.erb
index 23b31da92d8..43b6ecbb0d0 100644
--- a/app/views/devise/mailer/reset_password_instructions.html.erb
+++ b/app/views/devise/mailer/reset_password_instructions.html.erb
@@ -1,8 +1,8 @@
-<p>Hello <%= @resource.email %>!</p>
+<p>你好 <%= @resource.email %>!</p>
-<p>Someone has requested a link to change your password, and you can do this through the link below.</p>
+<p>有人请求修改你的密码,你可以点击下面的链接去操作。</p>
-<p><%= link_to 'Change your password', edit_password_url(@resource, reset_password_token: @token) %></p>
+<p><%= link_to '修改密码', edit_password_url(@resource, reset_password_token: @token) %></p>
-<p>If you didn't request this, please ignore this email.</p>
-<p>Your password won't change until you access the link above and create a new one.</p>
+<p>如果你自己没有请求修改,请忽略本邮件。</p>
+<p>一旦你访问了该链接将会创建新的密码;不访问链接密码不会被修改。</p>
diff --git a/app/views/devise/mailer/unlock_instructions.html.haml b/app/views/devise/mailer/unlock_instructions.html.haml
index 52b327e20c5..39bfb0dd4ff 100644
--- a/app/views/devise/mailer/unlock_instructions.html.haml
+++ b/app/views/devise/mailer/unlock_instructions.html.haml
@@ -1,10 +1,9 @@
%p
-Hello #{@resource.name}!
+你好 #{@resource.name}!
%p
- Your GitLab account has been locked due to an excessive amount of unsuccessful
- sign in attempts. Your account will automatically unlock in
+ 由于账号被试图攻击,你的 GitLab 账号被锁定。你的账号将在
= time_ago_in_words(Devise.unlock_in.from_now)
- or you may click the link below to unlock now.
+ 自动解锁或者点击下面的链接马上解锁你的账号。
-%p= link_to 'Unlock your account', unlock_url(@resource, unlock_token: @token)
+%p= link_to '解锁你的账号', unlock_url(@resource, unlock_token: @token)
diff --git a/app/views/devise/passwords/edit.html.haml b/app/views/devise/passwords/edit.html.haml
index 56048e99c17..cfd9435a20f 100644
--- a/app/views/devise/passwords/edit.html.haml
+++ b/app/views/devise/passwords/edit.html.haml
@@ -1,19 +1,19 @@
.login-box
.login-heading
- %h3 Change your password
+ %h3 修改密码
.login-body
= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f|
.devise-errors
= devise_error_messages!
= f.hidden_field :reset_password_token
%div
- = f.password_field :password, class: "form-control top", placeholder: "New password", required: true
+ = f.password_field :password, class: "form-control top", placeholder: "新密码", required: true
%div
- = f.password_field :password_confirmation, class: "form-control bottom", placeholder: "Confirm new password", required: true
+ = f.password_field :password_confirmation, class: "form-control bottom", placeholder: "确认新密码", required: true
.clearfix
- = f.submit "Change your password", class: "btn btn-primary"
+ = f.submit "修改密码", class: "btn btn-primary"
.clearfix.prepend-top-20
%p
- = link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name)
+ = link_to "没有收到确认邮件?", new_confirmation_path(resource_name)
= render 'devise/shared/sign_in_link'
diff --git a/app/views/devise/passwords/new.html.haml b/app/views/devise/passwords/new.html.haml
index 535e85869e5..dad122b76ca 100644
--- a/app/views/devise/passwords/new.html.haml
+++ b/app/views/devise/passwords/new.html.haml
@@ -1,14 +1,14 @@
.login-box
.login-heading
- %h3 Reset password
+ %h3 重置密码
.login-body
= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :post }) do |f|
.devise-errors
= devise_error_messages!
.clearfix.append-bottom-20
- = f.email_field :email, placeholder: "Email", class: "form-control", required: true, value: params[:user_email], autofocus: true
+ = f.email_field :email, placeholder: "电子邮箱", class: "form-control", required: true, value: params[:user_email], autofocus: true
.clearfix
- = f.submit "Reset password", class: "btn-primary btn"
+ = f.submit "重置密码", class: "btn-primary btn"
.clearfix.prepend-top-20
= render 'devise/shared/sign_in_link'
diff --git a/app/views/devise/registrations/edit.html.erb b/app/views/devise/registrations/edit.html.erb
index f379e71ae5b..a6c8ec06253 100644
--- a/app/views/devise/registrations/edit.html.erb
+++ b/app/views/devise/registrations/edit.html.erb
@@ -1,4 +1,4 @@
-<h2>Edit <%= resource_name.to_s.humanize %></h2>
+<h2>编辑 <%= resource_name.to_s.humanize %></h2>
<%= form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }) do |f| %>
<%= devise_error_messages! %>
@@ -9,20 +9,20 @@
<div><%= f.label :name %><br />
<%= f.text_field :name %></div>
- <div><%= f.label :password %> <i>(leave blank if you don't want to change it)</i><br />
+ <div><%= f.label :password %> <i>(留空表示不修改密码)</i><br />
<%= f.password_field :password %></div>
<div><%= f.label :password_confirmation %><br />
<%= f.password_field :password_confirmation %></div>
- <div><%= f.label :current_password %> <i>(we need your current password to confirm your changes)</i><br />
+ <div><%= f.label :current_password %> <i>(需要输入当前密码确认修改操作)</i><br />
<%= f.password_field :current_password %></div>
-<div><%= f.submit "Update", class: "input_button" %></div>
+<div><%= f.submit "更新", class: "input_button" %></div>
<% end %>
-<h3>Cancel your account</h3>
+<h3>取消账号</h3>
-<p>Unhappy? <%= link_to "Cancel your account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete %>.</p>
+<p>不开心?<%= link_to "取消账号", registration_path(resource_name), data: { confirm: "确定要继续么?" }, method: :delete %>.</p>
-<%= link_to "Back", :back %>
+<%= link_to "返回", :back %>
diff --git a/app/views/devise/registrations/new.html.haml b/app/views/devise/registrations/new.html.haml
index 42cfbbf84f2..adf3bd72c25 100644
--- a/app/views/devise/registrations/new.html.haml
+++ b/app/views/devise/registrations/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "Sign up"
+- page_title "注册"
= render 'devise/shared/signup_box'
= render 'devise/shared/sign_in_link'
diff --git a/app/views/devise/sessions/_new_base.html.haml b/app/views/devise/sessions/_new_base.html.haml
index 9f5520603cd..db2702af21c 100644
--- a/app/views/devise/sessions/_new_base.html.haml
+++ b/app/views/devise/sessions/_new_base.html.haml
@@ -1,12 +1,12 @@
= form_for(resource, as: resource_name, url: session_path(resource_name)) do |f|
- = f.text_field :login, class: "form-control top", placeholder: "Username or Email", autofocus: "autofocus", autocapitalize: "off", autocorrect: "off"
- = f.password_field :password, class: "form-control bottom", placeholder: "Password"
+ = f.text_field :login, class: "form-control top", placeholder: "用户名或电子邮箱", autofocus: "autofocus", autocapitalize: "off", autocorrect: "off"
+ = f.password_field :password, class: "form-control bottom", placeholder: "密码"
- if devise_mapping.rememberable?
.remember-me.checkbox
%label{for: "user_remember_me"}
= f.check_box :remember_me
- %span Remember me
+ %span 记住我
.pull-right
- = link_to "Forgot your password?", new_password_path(resource_name)
+ = link_to "忘记密码?", new_password_path(resource_name)
%div
- = f.submit "Sign in", class: "btn btn-save"
+ = f.submit "登入", class: "btn btn-save"
diff --git a/app/views/devise/sessions/_new_ldap.html.haml b/app/views/devise/sessions/_new_ldap.html.haml
index 689cd6ed665..eac625af542 100644
--- a/app/views/devise/sessions/_new_ldap.html.haml
+++ b/app/views/devise/sessions/_new_ldap.html.haml
@@ -1,9 +1,9 @@
= form_tag(user_omniauth_callback_path(server['provider_name']), id: 'new_ldap_user' ) do
- = text_field_tag :username, nil, {class: "form-control top", placeholder: "#{server['label']} Login", autofocus: "autofocus"}
- = password_field_tag :password, nil, {class: "form-control bottom", placeholder: "Password"}
+ = text_field_tag :username, nil, {class: "form-control top", placeholder: "#{server['label']} 登录", autofocus: "autofocus"}
+ = password_field_tag :password, nil, {class: "form-control bottom", placeholder: "密码"}
- if devise_mapping.rememberable?
.remember-me.checkbox
%label{for: "remember_me"}
= check_box_tag :remember_me, '1', false, id: 'remember_me'
- %span Remember me
- = button_tag "Sign in", class: "btn-save btn"
+ %span 记住我
+ = button_tag "登入", class: "btn-save btn"
diff --git a/app/views/devise/sessions/new.html.haml b/app/views/devise/sessions/new.html.haml
index d65fa60025c..1ba6255215a 100644
--- a/app/views/devise/sessions/new.html.haml
+++ b/app/views/devise/sessions/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "Sign in"
+- page_title "登入"
%div
- if signin_enabled? || ldap_enabled? || crowd_enabled?
= render 'devise/shared/signin_box'
@@ -16,4 +16,4 @@
-# Show a message if none of the mechanisms above are enabled
- if !signin_enabled? && !ldap_enabled? && !(omniauth_enabled? && devise_mapping.omniauthable?)
%div
- No authentication methods configured.
+ 没有配置任何认证方式。
diff --git a/app/views/devise/sessions/two_factor.html.haml b/app/views/devise/sessions/two_factor.html.haml
index 22b2c1a186b..a3f378a273c 100644
--- a/app/views/devise/sessions/two_factor.html.haml
+++ b/app/views/devise/sessions/two_factor.html.haml
@@ -1,10 +1,10 @@
%div
.login-box
.login-heading
- %h3 Two-factor Authentication
+ %h3 两步验证
.login-body
= form_for(resource, as: resource_name, url: session_path(resource_name), method: :post) do |f|
- = f.text_field :otp_attempt, class: 'form-control', placeholder: 'Two-factor authentication code', required: true, autofocus: true
- %p.help-block.hint If you've lost your phone, you may enter one of your recovery codes.
+ = f.text_field :otp_attempt, class: 'form-control', placeholder: '两步验证代码', required: true, autofocus: true
+ %p.help-block.hint 如果丢失了手机,可以输入恢复代码。
.prepend-top-20
- = f.submit "Verify code", class: "btn btn-save"
+ = f.submit "验证代码", class: "btn btn-save"
diff --git a/app/views/devise/shared/_links.erb b/app/views/devise/shared/_links.erb
index 49e99e25c1d..6214f0343d6 100644
--- a/app/views/devise/shared/_links.erb
+++ b/app/views/devise/shared/_links.erb
@@ -1,19 +1,19 @@
<%- if controller_name != 'sessions' %>
- <%= link_to "Sign in", new_session_path(resource_name), class: "btn" %><br />
+ <%= link_to "登录", new_session_path(resource_name), class: "btn" %><br />
<% end -%>
<%- if devise_mapping.registerable? && controller_name != 'registrations' && gitlab_config.signup_enabled %>
- <%= link_to "Sign up", new_registration_path(resource_name) %><br />
+ <%= link_to "注册", new_registration_path(resource_name) %><br />
<% end -%>
<%- if devise_mapping.recoverable? && controller_name != 'passwords' %>
-<%= link_to "Forgot your password?", new_password_path(resource_name), class: "btn" %><br />
+<%= link_to "忘记密码?", new_password_path(resource_name), class: "btn" %><br />
<% end -%>
<%- if devise_mapping.confirmable? && controller_name != 'confirmations' %>
- <%= link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name) %><br />
+ <%= link_to "没有收到确认邮件?", new_confirmation_path(resource_name) %><br />
<% end -%>
<%- if devise_mapping.lockable? && resource_class.unlock_strategy_enabled?(:email) && controller_name != 'unlocks' %>
- <%= link_to "Didn't receive unlock instructions?", new_unlock_path(resource_name) %><br />
+ <%= link_to "没有收到解锁邮件?", new_unlock_path(resource_name) %><br />
<% end -%>
diff --git a/app/views/devise/shared/_omniauth_box.html.haml b/app/views/devise/shared/_omniauth_box.html.haml
index ecf680e7b23..e3ed57b7a3e 100644
--- a/app/views/devise/shared/_omniauth_box.html.haml
+++ b/app/views/devise/shared/_omniauth_box.html.haml
@@ -1,6 +1,6 @@
%p
%span.light
- Sign in with &nbsp;
+ 登入 &nbsp;
- providers = button_based_providers
- providers.each do |provider|
%span.light
diff --git a/app/views/devise/shared/_sign_in_link.html.haml b/app/views/devise/shared/_sign_in_link.html.haml
index fafc4b82f53..3f512bb4757 100644
--- a/app/views/devise/shared/_sign_in_link.html.haml
+++ b/app/views/devise/shared/_sign_in_link.html.haml
@@ -1,5 +1,5 @@
%p
%span.light
- Already have login and password?
+ 已有账号和密码?
%strong
- = link_to "Sign in", new_session_path(resource_name)
+ = link_to "登入", new_session_path(resource_name)
diff --git a/app/views/devise/shared/_signin_box.html.haml b/app/views/devise/shared/_signin_box.html.haml
index 2c15e2c4891..6ec57ae2d3f 100644
--- a/app/views/devise/shared/_signin_box.html.haml
+++ b/app/views/devise/shared/_signin_box.html.haml
@@ -1,10 +1,10 @@
.login-box
- if signup_enabled?
.login-heading
- %h3 Existing user? Sign in
+ %h3 已有账号?登入
- else
.login-heading
- %h3 Sign in
+ %h3 登入
.login-body
- if form_based_providers.any?
%ul.nav-links
@@ -16,7 +16,7 @@
= link_to server['label'], "#tab-#{server['provider_name']}", 'data-toggle' => 'tab'
- if signin_enabled?
%li
- = link_to 'Standard', '#tab-signin', 'data-toggle' => 'tab'
+ = link_to '基本', '#tab-signin', 'data-toggle' => 'tab'
.tab-content
- if crowd_enabled?
%div.tab-pane.active{id: "tab-crowd"}
diff --git a/app/views/devise/shared/_signup_box.html.haml b/app/views/devise/shared/_signup_box.html.haml
index cb93ff2465e..b11d4ce87c5 100644
--- a/app/views/devise/shared/_signup_box.html.haml
+++ b/app/views/devise/shared/_signup_box.html.haml
@@ -1,31 +1,31 @@
.login-box
- if signin_enabled?
.login-heading
- %h3 New user? Create an account
+ %h3 新用户?创建账号
- else
.login-heading
- %h3 Create an account
+ %h3 创建账号
.login-body
- user = params[:user].present? ? params[:user] : {}
= form_for(resource, as: resource_name, url: registration_path(resource_name)) do |f|
.devise-errors
= devise_error_messages!
%div
- = f.text_field :name, class: "form-control top", value: user[:name], placeholder: "Name", required: true
+ = f.text_field :name, class: "form-control top", value: user[:name], placeholder: "姓名", required: true
%div
- = f.text_field :username, class: "form-control middle", value: user[:username], placeholder: "Username", required: true
+ = f.text_field :username, class: "form-control middle", value: user[:username], placeholder: "用户名", required: true
%div
- = f.email_field :email, class: "form-control middle", value: user[:email], placeholder: "Email", required: true
+ = f.email_field :email, class: "form-control middle", value: user[:email], placeholder: "电子邮箱", required: true
.form-group.append-bottom-20#password-strength
- = f.password_field :password, class: "form-control bottom", value: user[:password], id: "user_password_sign_up", placeholder: "Password", required: true
+ = f.password_field :password, class: "form-control bottom", value: user[:password], id: "user_password_sign_up", placeholder: "密码", required: true
%div
- if current_application_settings.recaptcha_enabled
= recaptcha_tags
%div
- = f.submit "Sign up", class: "btn-create btn"
+ = f.submit "注册", class: "btn-create btn"
.clearfix.prepend-top-20
%p
- %span.light Didn't receive a confirmation email?
- = succeed '.' do
- = link_to "Request a new one", new_confirmation_path(resource_name)
+ %span.light 没有收到确认邮件?
+ = succeed '。' do
+ = link_to "请求新的", new_confirmation_path(resource_name)
diff --git a/app/views/devise/unlocks/new.html.haml b/app/views/devise/unlocks/new.html.haml
index 49c087c0646..2cfc4fbcf57 100644
--- a/app/views/devise/unlocks/new.html.haml
+++ b/app/views/devise/unlocks/new.html.haml
@@ -1,14 +1,14 @@
.login-box
.login-heading
- %h3 Resend unlock email
+ %h3 重新发送解锁邮件
.login-body
= form_for(resource, as: resource_name, url: unlock_path(resource_name), html: { method: :post }) do |f|
.devise-errors
= devise_error_messages!
.clearfix.append-bottom-20
- = f.email_field :email, class: 'form-control', placeholder: 'Email', autofocus: 'autofocus', autocapitalize: 'off', autocorrect: 'off'
+ = f.email_field :email, class: 'form-control', placeholder: '电子邮箱', autofocus: 'autofocus', autocapitalize: 'off', autocorrect: 'off'
.clearfix
- = f.submit 'Resend unlock instructions', class: 'btn btn-success'
+ = f.submit '重新发送解锁指令', class: 'btn btn-success'
.clearfix.prepend-top-20
= render 'devise/shared/sign_in_link'
diff --git a/app/views/doorkeeper/applications/edit.html.haml b/app/views/doorkeeper/applications/edit.html.haml
index fb6aa30acee..bdc54e1043c 100644
--- a/app/views/doorkeeper/applications/edit.html.haml
+++ b/app/views/doorkeeper/applications/edit.html.haml
@@ -1,3 +1,3 @@
-- page_title "Edit", @application.name, "Applications"
-%h3.page-title Edit application
+- page_title "编辑", @application.name, "应用"
+%h3.page-title 编辑应用
= render 'form', application: @application
diff --git a/app/views/doorkeeper/applications/new.html.haml b/app/views/doorkeeper/applications/new.html.haml
index fd32a468b45..74dd035ec97 100644
--- a/app/views/doorkeeper/applications/new.html.haml
+++ b/app/views/doorkeeper/applications/new.html.haml
@@ -1,6 +1,6 @@
-- page_title "New Application"
+- page_title "新应用"
-%h3.page-title New Application
+%h3.page-title 新应用
%hr
diff --git a/app/views/doorkeeper/applications/show.html.haml b/app/views/doorkeeper/applications/show.html.haml
index 47442b78d48..d9a64ecfeb5 100644
--- a/app/views/doorkeeper/applications/show.html.haml
+++ b/app/views/doorkeeper/applications/show.html.haml
@@ -1,27 +1,27 @@
-- page_title @application.name, "Applications"
+- page_title @application.name, "应用"
%h3.page-title
- Application: #{@application.name}
+ 应用:#{@application.name}
.table-holder
%table.table
%tr
%td
- Application Id
+ 应用 Id
%td
%code#application_id= @application.uid
%tr
%td
- Secret:
+ 密匙:
%td
%code#secret= @application.secret
%tr
%td
- Callback url
+ 回调链接
%td
- @application.redirect_uri.split.each do |uri|
%div
%span.monospace= uri
.form-actions
- = link_to 'Edit', edit_oauth_application_path(@application), class: 'btn btn-primary wide pull-left'
+ = link_to '编辑', edit_oauth_application_path(@application), class: 'btn btn-primary wide pull-left'
= render 'delete_form', application: @application, submit_btn_css: 'btn btn-danger prepend-left-10'
diff --git a/app/views/doorkeeper/authorizations/error.html.haml b/app/views/doorkeeper/authorizations/error.html.haml
index 7561ec85ed9..b8b0f95f389 100644
--- a/app/views/doorkeeper/authorizations/error.html.haml
+++ b/app/views/doorkeeper/authorizations/error.html.haml
@@ -1,3 +1,3 @@
-%h3.page-title An error has occurred
+%h3.page-title 发生错误
%main{:role => "main"}
%pre= @pre_auth.error_response.body[:error_description] \ No newline at end of file
diff --git a/app/views/doorkeeper/authorizations/new.html.haml b/app/views/doorkeeper/authorizations/new.html.haml
index eae80e5210f..bdba0467fc7 100644
--- a/app/views/doorkeeper/authorizations/new.html.haml
+++ b/app/views/doorkeeper/authorizations/new.html.haml
@@ -1,21 +1,21 @@
-%h3.page-title Authorize required
+%h3.page-title 需要认证
%main{:role => "main"}
%p.h4
- Authorize
+ 允许
%strong.text-info= @pre_auth.client.name
- to use your account?
+ 使用你的账号么?
- if current_user.admin?
.text-warning.prepend-top-20
%p
= icon("exclamation-triangle fw")
- You are an admin, which means granting access to
+ 您是管理员,这意味着
%strong #{@pre_auth.client.name}
- will allow them to interact with GitLab as an admin as well. Proceed with caution.
+ 也一样能以 GitLab 管理员身份进行操作。请谨慎操作。
- if @pre_auth.scopes
#oauth-permissions
- %p This application will be able to:
+ %p 此应用将用于:
%ul.text-info
- @pre_auth.scopes.each do |scope|
%li= t scope, scope: [:doorkeeper, :scopes]
@@ -27,11 +27,11 @@
= hidden_field_tag :state, @pre_auth.state
= hidden_field_tag :response_type, @pre_auth.response_type
= hidden_field_tag :scope, @pre_auth.scope
- = submit_tag "Authorize", class: "btn btn-success wide pull-left"
+ = submit_tag "认证", class: "btn btn-success wide pull-left"
= form_tag oauth_authorization_path, method: :delete do
= hidden_field_tag :client_id, @pre_auth.client.uid
= hidden_field_tag :redirect_uri, @pre_auth.redirect_uri
= hidden_field_tag :state, @pre_auth.state
= hidden_field_tag :response_type, @pre_auth.response_type
= hidden_field_tag :scope, @pre_auth.scope
- = submit_tag "Deny", class: "btn btn-danger prepend-left-10"
+ = submit_tag "拒绝", class: "btn btn-danger prepend-left-10"
diff --git a/app/views/doorkeeper/authorizations/show.html.haml b/app/views/doorkeeper/authorizations/show.html.haml
index 9a402007194..12302a273aa 100644
--- a/app/views/doorkeeper/authorizations/show.html.haml
+++ b/app/views/doorkeeper/authorizations/show.html.haml
@@ -1,3 +1,3 @@
-%h3.page-title Authorization code:
+%h3.page-title 认证代码:
%main{:role => "main"}
%code#authorization_code= params[:code] \ No newline at end of file
diff --git a/app/views/doorkeeper/authorized_applications/_delete_form.html.haml b/app/views/doorkeeper/authorized_applications/_delete_form.html.haml
index bfa95ce79a7..ecb4741ce8f 100644
--- a/app/views/doorkeeper/authorized_applications/_delete_form.html.haml
+++ b/app/views/doorkeeper/authorized_applications/_delete_form.html.haml
@@ -6,4 +6,4 @@
= form_tag path do
%input{:name => "_method", :type => "hidden", :value => "delete"}/
- = submit_tag 'Revoke', onclick: "return confirm('Are you sure?')", class: 'btn btn-link btn-remove btn-sm'
+ = submit_tag '撤销', onclick: "return confirm('确定要继续么?')", class: 'btn btn-link btn-remove btn-sm'
diff --git a/app/views/doorkeeper/authorized_applications/index.html.haml b/app/views/doorkeeper/authorized_applications/index.html.haml
index b184b9c01d4..a4bf444c1ef 100644
--- a/app/views/doorkeeper/authorized_applications/index.html.haml
+++ b/app/views/doorkeeper/authorized_applications/index.html.haml
@@ -1,12 +1,12 @@
%header.page-header
- %h1 Your authorized applications
+ %h1 认证应用
%main{:role => "main"}
.table-holder
%table.table.table-striped
%thead
%tr
- %th Application
- %th Created At
+ %th 应用
+ %th 创建时间
%th
%th
%tbody
diff --git a/app/views/email_rejection_mailer/rejection.html.haml b/app/views/email_rejection_mailer/rejection.html.haml
index 7f7d841fe21..d577d0cc955 100644
--- a/app/views/email_rejection_mailer/rejection.html.haml
+++ b/app/views/email_rejection_mailer/rejection.html.haml
@@ -1,4 +1,4 @@
%p
- Unfortunately, your email message to GitLab could not be processed.
+ 很不幸的告诉你,你发往 GitLab 的邮件无法被处理。
= markdown @reason
diff --git a/app/views/email_rejection_mailer/rejection.text.haml b/app/views/email_rejection_mailer/rejection.text.haml
index 6693e6f90e8..e5e161c8511 100644
--- a/app/views/email_rejection_mailer/rejection.text.haml
+++ b/app/views/email_rejection_mailer/rejection.text.haml
@@ -1,4 +1,4 @@
-Unfortunately, your email message to GitLab could not be processed.
+很不幸的告诉你,你发往 GitLab 的邮件无法被处理。
= @reason
diff --git a/app/views/errors/access_denied.html.haml b/app/views/errors/access_denied.html.haml
index 012e9857642..e01cba8406d 100644
--- a/app/views/errors/access_denied.html.haml
+++ b/app/views/errors/access_denied.html.haml
@@ -1,6 +1,6 @@
-- page_title "Access Denied"
+- page_title "禁止访问"
%h1 403
-%h3 Access Denied
+%h3 禁止访问
%hr
-%p You are not allowed to access this page.
-%p Read more about project permissions #{link_to "here", help_page_path("permissions", "permissions"), class: "vlink"}
+%p 无法访问本页面。
+%p 点击#{link_to "这里", help_page_path("permissions", "permissions"), class: "vlink"}了解更多项目权限内容
diff --git a/app/views/errors/encoding.html.haml b/app/views/errors/encoding.html.haml
index 90cfbebfcc6..7947402d422 100644
--- a/app/views/errors/encoding.html.haml
+++ b/app/views/errors/encoding.html.haml
@@ -1,5 +1,5 @@
-- page_title "Encoding Error"
+- page_title "编码错误"
%h1 500
-%h3 Encoding Error
+%h3 编码错误
%hr
-%p Page can't be loaded because of an encoding error.
+%p 编码发生错误无法载入页面。
diff --git a/app/views/errors/git_not_found.html.haml b/app/views/errors/git_not_found.html.haml
index ff5d4cc1506..fc19f72e00e 100644
--- a/app/views/errors/git_not_found.html.haml
+++ b/app/views/errors/git_not_found.html.haml
@@ -1,7 +1,6 @@
-- page_title "Git Resource Not Found"
+- page_title "Git 资源不存在"
%h1 404
-%h3 Git Resource Not found
+%h3 Git 资源不存在
%hr
%p
- Application can't get access to some branch or commit in your repository. It
- may have been moved.
+ 应用程序无法访问仓库中相应的分支或提交。该内容可能被删除。
diff --git a/app/views/errors/not_found.html.haml b/app/views/errors/not_found.html.haml
index 3756b98ebb2..ee9ed6fd87e 100644
--- a/app/views/errors/not_found.html.haml
+++ b/app/views/errors/not_found.html.haml
@@ -1,5 +1,5 @@
-- page_title "Not Found"
+- page_title "不存在"
%h1 404
-%h3 The resource you were looking for doesn't exist.
+%h3 要找的资源不存在。
%hr
-%p You may have mistyped the address or the page may have moved.
+%p 可能弄错了地址或页面被删除。
diff --git a/app/views/errors/omniauth_error.html.haml b/app/views/errors/omniauth_error.html.haml
index 3e70e98a24c..082970d718a 100644
--- a/app/views/errors/omniauth_error.html.haml
+++ b/app/views/errors/omniauth_error.html.haml
@@ -1,6 +1,6 @@
-- page_title "Auth Error"
+- page_title "认证错误"
%h1 422
-%h3 Sign-in using #{@provider} auth failed
+%h3 使用 #{@provider} 认证登入失败
%hr
%p Sign-in failed because #{@error}.
%p There are couple of steps you can take:
diff --git a/app/views/events/_event_push.atom.haml b/app/views/events/_event_push.atom.haml
index b271b9daff1..eccaf0c0326 100644
--- a/app/views/events/_event_push.atom.haml
+++ b/app/views/events/_event_push.atom.haml
@@ -4,11 +4,11 @@
%strong= commit[:author][:name]
= link_to "(##{truncate_sha(commit[:id])})", namespace_project_commit_path(event.project.namespace, event.project, id: commit[:id])
%i
- at
+ 在
= commit[:timestamp].to_time.to_s(:short)
%blockquote= markdown(escape_once(commit[:message]), pipeline: :atom, project: event.project)
- if event.commits_count > 15
%p
%i
- \... and
- = pluralize(event.commits_count - 15, "more commit")
+ \... 和
+ = pluralize(event.commits_count - 15, "次更多提交", "次更多提交")
diff --git a/app/views/events/event/_created_project.html.haml b/app/views/events/event/_created_project.html.haml
index 8cf36c711b4..e598046bd0c 100644
--- a/app/views/events/event/_created_project.html.haml
+++ b/app/views/events/event/_created_project.html.haml
@@ -13,7 +13,7 @@
.event-note
.md
%p
- Congratulations! Why not share your accomplishment with the world?
+ 恭喜!为什么不把你的成就分享给世界呢?
%a.twitter-share-button{ |
href: "https://twitter.com/share", |
diff --git a/app/views/events/event/_note.html.haml b/app/views/events/event/_note.html.haml
index 830fec0b4ab..609c0cc3856 100644
--- a/app/views/events/event/_note.html.haml
+++ b/app/views/events/event/_note.html.haml
@@ -3,7 +3,7 @@
%span.event_label
= event.action_name
= event_note_title_html(event)
- at
+ 在
- if event.project
= link_to_project event.project
diff --git a/app/views/events/event/_push.html.haml b/app/views/events/event/_push.html.haml
index 235bd46107e..ff61873bec8 100644
--- a/app/views/events/event/_push.html.haml
+++ b/app/views/events/event/_push.html.haml
@@ -21,7 +21,7 @@
- if event.commits_count > 1
%li.commits-stat
- if event.commits_count > 2
- %span ... and #{event.commits_count - 2} more commits.
+ %span ... 和 #{event.commits_count - 2} 次更多提交。
- if event.md_ref?
- from = event.commit_from
@@ -31,14 +31,14 @@
- from_label = from
= link_to namespace_project_compare_path(event.project.namespace, event.project, from: from, to: event.commit_to) do
- Compare #{from_label}...#{truncate_sha(event.commit_to)}
+ 比较 #{from_label}...#{truncate_sha(event.commit_to)}
- if create_mr
%span{"data-user-is" => event.author_id, "data-display" => "inline"}
- or
+ 或
= link_to create_mr_path(event.project.default_branch, event.ref_name, event.project) do
- create a merge request
+ 创建合并请求
- elsif create_mr
%li.commits-stat{"data-user-is" => event.author_id}
= link_to create_mr_path(event.project.default_branch, event.ref_name, event.project) do
- Create Merge Request
+ 创建合并请求
diff --git a/app/views/explore/_head.html.haml b/app/views/explore/_head.html.haml
index d8a57560788..c29570dc4b0 100644
--- a/app/views/explore/_head.html.haml
+++ b/app/views/explore/_head.html.haml
@@ -1,6 +1,6 @@
.explore-title
%h3
- Explore GitLab
+ 浏览 GitLab
%p.lead
- Discover projects, groups and snippets. Share your projects with others
+ 探索发现项目、群组和代码片段。分享你的项目给他人
%br
diff --git a/app/views/explore/groups/index.html.haml b/app/views/explore/groups/index.html.haml
index 8ffca96bb4e..ac43baf12a8 100644
--- a/app/views/explore/groups/index.html.haml
+++ b/app/views/explore/groups/index.html.haml
@@ -1,5 +1,5 @@
-- page_title "Groups"
-- header_title "Groups", dashboard_groups_path
+- page_title "群组"
+- header_title "群组", dashboard_groups_path
- if current_user
= render 'dashboard/groups_head'
@@ -11,9 +11,9 @@
= form_tag explore_groups_path, method: :get, class: 'form-inline form-tiny' do |f|
= hidden_field_tag :sort, @sort
.form-group
- = search_field_tag :search, params[:search], placeholder: "Filter by name", class: "form-control search-text-input", id: "groups_search", spellcheck: false
+ = search_field_tag :search, params[:search], placeholder: "按名称过滤", class: "form-control search-text-input", id: "groups_search", spellcheck: false
.form-group
- = button_tag 'Search', class: "btn btn-default"
+ = button_tag '搜索', class: "btn btn-default"
.pull-right
.dropdown.inline
@@ -39,7 +39,7 @@
- @groups.each do |group|
= render 'shared/groups/group', group: group
- unless @groups.present?
- .nothing-here-block No public groups
+ .nothing-here-block 没有公开群组
= paginate @groups, theme: "gitlab"
diff --git a/app/views/explore/projects/_nav.html.haml b/app/views/explore/projects/_nav.html.haml
index 614b5431779..588b0ae3de7 100644
--- a/app/views/explore/projects/_nav.html.haml
+++ b/app/views/explore/projects/_nav.html.haml
@@ -1,10 +1,10 @@
%ul.nav-links
= nav_link(page: [trending_explore_projects_path, explore_root_path]) do
= link_to trending_explore_projects_path do
- Trending
+ 热门
= nav_link(page: starred_explore_projects_path) do
= link_to starred_explore_projects_path do
- Most stars
+ 最多星标
= nav_link(page: explore_projects_path) do
= link_to explore_projects_path do
- All
+ 全部
diff --git a/app/views/explore/projects/index.html.haml b/app/views/explore/projects/index.html.haml
index 42b50481b9d..2148620092f 100644
--- a/app/views/explore/projects/index.html.haml
+++ b/app/views/explore/projects/index.html.haml
@@ -1,5 +1,5 @@
-- page_title "Projects"
-- header_title "Projects", dashboard_projects_path
+- page_title "项目"
+- header_title "项目", dashboard_projects_path
- if current_user
= render 'dashboard/projects_head'
diff --git a/app/views/explore/projects/starred.html.haml b/app/views/explore/projects/starred.html.haml
index ec461755103..e49c154115f 100644
--- a/app/views/explore/projects/starred.html.haml
+++ b/app/views/explore/projects/starred.html.haml
@@ -1,5 +1,5 @@
-- page_title "Projects"
-- header_title "Projects", dashboard_projects_path
+- page_title "项目"
+- header_title "项目", dashboard_projects_path
- if current_user
= render 'dashboard/projects_head'
diff --git a/app/views/explore/projects/trending.html.haml b/app/views/explore/projects/trending.html.haml
index ec461755103..e49c154115f 100644
--- a/app/views/explore/projects/trending.html.haml
+++ b/app/views/explore/projects/trending.html.haml
@@ -1,5 +1,5 @@
-- page_title "Projects"
-- header_title "Projects", dashboard_projects_path
+- page_title "项目"
+- header_title "项目", dashboard_projects_path
- if current_user
= render 'dashboard/projects_head'
diff --git a/app/views/explore/snippets/index.html.haml b/app/views/explore/snippets/index.html.haml
index 0f100c39ffb..68b287bfdc5 100644
--- a/app/views/explore/snippets/index.html.haml
+++ b/app/views/explore/snippets/index.html.haml
@@ -1,5 +1,5 @@
-- page_title "Snippets"
-- header_title "Snippets", snippets_path
+- page_title "代码片段"
+- header_title "代码片段", snippets_path
- if current_user
= render 'dashboard/snippets_head'
@@ -9,11 +9,11 @@
.gray-content-block
- if current_user
.pull-right
- = link_to new_snippet_path, class: "btn btn-new", title: "New Snippet" do
+ = link_to new_snippet_path, class: "btn btn-new", title: "新代码片段" do
= icon('plus')
- New Snippet
+ 新代码片段
.oneline
- Public snippets created by you and other users are listed here
+ 你和其他用户创建的公开代码片段都会显示在这里
= render 'snippets/snippets'
diff --git a/app/views/groups/edit.html.haml b/app/views/groups/edit.html.haml
index ea5a0358392..0b7177240b3 100644
--- a/app/views/groups/edit.html.haml
+++ b/app/views/groups/edit.html.haml
@@ -1,8 +1,8 @@
-- header_title group_title(@group, "Settings", edit_group_path(@group))
+- header_title group_title(@group, "设置", edit_group_path(@group))
.panel.panel-default.prepend-top-default
.panel-heading
- Group settings
+ 群组设置
.panel-body
= form_for @group, html: { multipart: true, class: "form-horizontal" }, authenticity_token: true do |f|
- if @group.errors.any?
diff --git a/app/views/groups/group_members/_group_member.html.haml b/app/views/groups/group_members/_group_member.html.haml
index 60234be8f83..b457ecf8da0 100644
--- a/app/views/groups/group_members/_group_member.html.haml
+++ b/app/views/groups/group_members/_group_member.html.haml
@@ -10,24 +10,24 @@
= link_to user.name, user_path(user)
%span.cgray= user.username
- if user == current_user
- %span.label.label-success It's you
+ %span.label.label-success 自己
- if user.blocked?
%label.label.label-danger
- %strong Blocked
+ %strong 被禁用
- else
= image_tag avatar_icon(member.invite_email, 24), class: "avatar s24", alt: ''
%strong
= member.invite_email
%span.cgray
- invited
+ 邀请时间
- if member.created_by
- by
+ 由
= link_to member.created_by.name, user_path(member.created_by)
= time_ago_with_tooltip(member.created_at)
- if show_controls && can?(current_user, :admin_group_member, @group)
- = link_to resend_invite_group_group_member_path(@group, member), method: :post, class: "btn-xs btn", title: 'Resend invite' do
- Resend invite
+ = link_to resend_invite_group_group_member_path(@group, member), method: :post, class: "btn-xs btn", title: '重发邀请' do
+ 重发邀请
- if show_roles && should_user_see_group_roles?(current_user, @group)
%span.pull-right
@@ -35,17 +35,17 @@
- if show_controls
- if can?(current_user, :update_group_member, member)
= button_tag class: "btn-xs btn js-toggle-button",
- title: 'Edit access level', type: 'button' do
+ title: '编辑访问等级', type: 'button' do
%i.fa.fa-pencil-square-o
- if can?(current_user, :destroy_group_member, member)
&nbsp;
- if current_user == user
- = link_to leave_group_group_members_path(@group), data: { confirm: leave_group_message(@group.name)}, method: :delete, class: "btn-xs btn btn-remove", title: 'Remove user from group' do
+ = link_to leave_group_group_members_path(@group), data: { confirm: leave_group_message(@group.name)}, method: :delete, class: "btn-xs btn btn-remove", title: '从群组删除用户' do
= icon("sign-out")
- Leave
+ 离开
- else
- = link_to group_group_member_path(@group, member), data: { confirm: remove_user_from_group_message(@group, member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: 'Remove user from group' do
+ = link_to group_group_member_path(@group, member), data: { confirm: remove_user_from_group_message(@group, member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: '从群组删除用户' do
%i.fa.fa-minus.fa-inverse
.edit-member.hide.js-toggle-content
@@ -54,4 +54,4 @@
.prepend-top-10
= f.select :access_level, options_for_select(GroupMember.access_level_roles, member.access_level), {}, class: 'form-control'
.prepend-top-10
- = f.submit 'Save', class: 'btn btn-save btn-sm'
+ = f.submit '保存', class: 'btn btn-save btn-sm'
diff --git a/app/views/groups/group_members/_new_group_member.html.haml b/app/views/groups/group_members/_new_group_member.html.haml
index e7ab4f2409b..56b98baba81 100644
--- a/app/views/groups/group_members/_new_group_member.html.haml
+++ b/app/views/groups/group_members/_new_group_member.html.haml
@@ -1,18 +1,18 @@
= form_for @group_member, url: group_group_members_path(@group), html: { class: 'form-horizontal users-group-form' } do |f|
.form-group
- = f.label :user_ids, "People", class: 'control-label'
+ = f.label :user_ids, "人", class: 'control-label'
.col-sm-10
= users_select_tag(:user_ids, multiple: true, class: 'input-large', scope: :all, email_user: true)
.help-block
- Search for users by name, username, or email, or invite new ones using their email address.
+ 搜索已存在的用户或者使用他们的电子邮箱地址邀请。
.form-group
- = f.label :access_level, "Group Access", class: 'control-label'
+ = f.label :access_level, "群组访问", class: 'control-label'
.col-sm-10
= select_tag :access_level, options_for_select(GroupMember.access_level_roles, @group_member.access_level), class: "project-access-select select2"
.help-block
- Read more about role permissions
- %strong= link_to "here", help_page_path("permissions", "permissions"), class: "vlink"
+ 了解更多角色权限相关请点击
+ %strong= link_to "这里", help_page_path("permissions", "permissions"), class: "vlink"
.form-actions
- = f.submit 'Add users to group', class: "btn btn-create"
+ = f.submit '增加用户到群组', class: "btn btn-create"
diff --git a/app/views/groups/group_members/index.html.haml b/app/views/groups/group_members/index.html.haml
index 6b7fd5746d6..f8bd344d915 100644
--- a/app/views/groups/group_members/index.html.haml
+++ b/app/views/groups/group_members/index.html.haml
@@ -1,29 +1,29 @@
-- page_title "Members"
-- header_title group_title(@group, "Members", group_group_members_path(@group))
+- page_title "成员"
+- header_title group_title(@group, "成员", group_group_members_path(@group))
.group-members-page.prepend-top-default
- if current_user && current_user.can?(:admin_group_member, @group)
.panel.panel-default
.panel-heading
- Add new user to group
+ 增加成员到群组
.panel-body
- if should_user_see_group_roles?(current_user, @group)
%p.light
- Members of group have access to all group projects.
+ 群组成员可以访问所有群组项目。
.new-group-member-holder
= render "new_group_member"
.panel.panel-default
.panel-heading
%strong #{@group.name}
- group members
+ 群组成员
%small
(#{@members.total_count})
.controls
= form_tag group_group_members_path(@group), method: :get, class: 'form-inline member-search-form' do
.form-group
- = search_field_tag :search, params[:search], { placeholder: 'Find existing member by name', class: 'form-control', spellcheck: false }
- = button_tag class: 'btn', title: 'Search' do
+ = search_field_tag :search, params[:search], { placeholder: '使用名字查找已存在的成员', class: 'form-control', spellcheck: false }
+ = button_tag class: 'btn', title: '搜索' do
= icon("search")
%ul.content-list
- @members.each do |member|
diff --git a/app/views/groups/issues.html.haml b/app/views/groups/issues.html.haml
index b0805593fdc..7930fc3cfc5 100644
--- a/app/views/groups/issues.html.haml
+++ b/app/views/groups/issues.html.haml
@@ -1,5 +1,5 @@
-- page_title "Issues"
-- header_title group_title(@group, "Issues", issues_group_path(@group))
+- page_title "问题"
+- header_title group_title(@group, "问题", issues_group_path(@group))
= content_for :meta_tags do
- if current_user
= auto_discovery_link_tag(:atom, issues_group_url(@group, format: :atom, private_token: current_user.private_token), title: "#{@group.name} issues")
@@ -10,16 +10,16 @@
- if current_user
= link_to issues_group_url(@group, format: :atom, private_token: current_user.private_token), class: 'btn' do
= icon('rss')
- = render 'shared/new_project_item_select', path: 'issues/new', label: "New Issue"
+ = render 'shared/new_project_item_select', path: 'issues/new', label: "新问题"
= render 'shared/issuable/filter', type: :issues
.gray-content-block.second-block
- Only issues from
+ 仅
%strong #{@group.name}
- group are listed here.
+ 群组的问题显示在此处。
- if current_user
- To see all issues you should visit #{link_to 'dashboard', issues_dashboard_path} page.
+ 请到#{link_to '仪表盘', issues_dashboard_path}页面访问所有问题。
.prepend-top-default
= render 'shared/issues'
diff --git a/app/views/groups/merge_requests.html.haml b/app/views/groups/merge_requests.html.haml
index e1c9dd931ee..d35f15925be 100644
--- a/app/views/groups/merge_requests.html.haml
+++ b/app/views/groups/merge_requests.html.haml
@@ -1,19 +1,19 @@
-- page_title "Merge Requests"
-- header_title group_title(@group, "Merge Requests", merge_requests_group_path(@group))
+- page_title "合并请求"
+- header_title group_title(@group, "合并请求", merge_requests_group_path(@group))
.top-area
= render 'shared/issuable/nav', type: :merge_requests
.nav-controls
- = render 'shared/new_project_item_select', path: 'merge_requests/new', label: "New Merge Request"
+ = render 'shared/new_project_item_select', path: 'merge_requests/new', label: "新合并请求"
= render 'shared/issuable/filter', type: :merge_requests
.gray-content-block.second-block
- Only merge requests from
+ 仅
%strong #{@group.name}
- group are listed here.
+ 群组的合并请求显示在此处。
- if current_user
- To see all merge requests you should visit #{link_to 'dashboard', merge_requests_dashboard_path} page.
+ 请到#{link_to '仪表盘', merge_requests_dashboard_path}页面访问所有合并请求。
.prepend-top-default
= render 'shared/merge_requests'
diff --git a/app/views/groups/milestones/_header_title.html.haml b/app/views/groups/milestones/_header_title.html.haml
index d7fabf53587..930eabe5a5c 100644
--- a/app/views/groups/milestones/_header_title.html.haml
+++ b/app/views/groups/milestones/_header_title.html.haml
@@ -1 +1 @@
-- header_title group_title(@group, "Milestones", group_milestones_path(@group))
+- header_title group_title(@group, "里程碑", group_milestones_path(@group))
diff --git a/app/views/groups/milestones/index.html.haml b/app/views/groups/milestones/index.html.haml
index ab307708b75..f9d677d9f54 100644
--- a/app/views/groups/milestones/index.html.haml
+++ b/app/views/groups/milestones/index.html.haml
@@ -1,5 +1,5 @@
-- page_title "Milestones"
-- header_title group_title(@group, "Milestones", group_milestones_path(@group))
+- page_title "里程碑"
+- header_title group_title(@group, "里程碑", group_milestones_path(@group))
.top-area
= render 'shared/milestones_filter'
@@ -8,18 +8,18 @@
- if can?(current_user, :admin_milestones, @group)
= link_to new_group_milestone_path(@group), class: "btn btn-new" do
= icon('plus')
- New Milestone
+ 新里程碑
.gray-content-block
- Only milestones from
+ 只有来自
%strong #{@group.name}
- group are listed here.
+ 群组的里程碑显示在这里。
.milestones
%ul.content-list
- if @milestones.blank?
%li
- .nothing-here-block No milestones to show
+ .nothing-here-block 没有里程碑
- else
- @milestones.each do |milestone|
= render 'milestone', milestone: milestone
diff --git a/app/views/groups/new.html.haml b/app/views/groups/new.html.haml
index 30ab8aeba13..828dd877836 100644
--- a/app/views/groups/new.html.haml
+++ b/app/views/groups/new.html.haml
@@ -1,8 +1,8 @@
-- page_title 'New Group'
-- header_title "Groups", dashboard_groups_path
+- page_title '新群组'
+- header_title "群组", dashboard_groups_path
%h3.page-title
- New Group
+ 新群组
%hr
= form_for @group, html: { class: 'group-form form-horizontal' } do |f|
@@ -13,7 +13,7 @@
= render 'shared/group_form', f: f, autofocus: true
.form-group.group-description-holder
- = f.label :avatar, "Group avatar", class: 'control-label'
+ = f.label :avatar, "群组头像", class: 'control-label'
.col-sm-10
= render 'shared/choose_group_avatar_button', f: f
@@ -24,5 +24,5 @@
= render 'shared/group_tips'
.form-actions
- = f.submit 'Create group', class: "btn btn-create", tabindex: 3
- = link_to 'Cancel', dashboard_groups_path, class: 'btn btn-cancel'
+ = f.submit '创建群组', class: "btn btn-create", tabindex: 3
+ = link_to '取消', dashboard_groups_path, class: 'btn btn-cancel'
diff --git a/app/views/groups/projects.html.haml b/app/views/groups/projects.html.haml
index dd75766121e..15818e5a0c4 100644
--- a/app/views/groups/projects.html.haml
+++ b/app/views/groups/projects.html.haml
@@ -1,15 +1,15 @@
-- page_title "Projects"
-- header_title group_title(@group, "Projects", projects_group_path(@group))
+- page_title "项目"
+- header_title group_title(@group, "项目", projects_group_path(@group))
.panel.panel-default.prepend-top-default
.panel-heading
%strong= @group.name
- projects:
+ 项目:
- if can? current_user, :admin_group, @group
.controls
= link_to new_project_path(namespace_id: @group.id), class: "btn btn-sm btn-success" do
= icon('plus')
- New Project
+ 新项目
%ul.well-list
- @projects.each do |project|
%li
@@ -22,10 +22,10 @@
%span.label.label-warning archived
%span.label.label-gray
= repository_size(project)
- = link_to 'Members', namespace_project_project_members_path(project.namespace, project), id: "edit_#{dom_id(project)}", class: "btn btn-sm"
- = link_to 'Edit', edit_namespace_project_path(project.namespace, project), id: "edit_#{dom_id(project)}", class: "btn btn-sm"
- = link_to 'Remove', project, data: { confirm: remove_project_message(project)}, method: :delete, class: "btn btn-sm btn-remove"
+ = link_to '成员', namespace_project_project_members_path(project.namespace, project), id: "edit_#{dom_id(project)}", class: "btn btn-sm"
+ = link_to '编辑', edit_namespace_project_path(project.namespace, project), id: "edit_#{dom_id(project)}", class: "btn btn-sm"
+ = link_to '删除', project, data: { confirm: remove_project_message(project)}, method: :delete, class: "btn btn-sm btn-remove"
- if @projects.blank?
- .nothing-here-block This group has no projects yet
+ .nothing-here-block 该群组还没有项目
= paginate @projects, theme: "gitlab"
diff --git a/app/views/groups/show.html.haml b/app/views/groups/show.html.haml
index 820743dc8dd..cd575e22e9f 100644
--- a/app/views/groups/show.html.haml
+++ b/app/views/groups/show.html.haml
@@ -2,14 +2,14 @@
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, group_url(@group, format: :atom, private_token: current_user.private_token), title: "#{@group.name} activity")
+ = auto_discovery_link_tag(:atom, group_url(@group, format: :atom, private_token: current_user.private_token), title: "#{@group.name} 活动")
.cover-block
.cover-controls
- if @group && can?(current_user, :admin_group, @group)
= link_to icon('pencil'), edit_group_path(@group), class: 'btn'
- if current_user
- = link_to icon('rss'), group_path(@group, { format: :atom, private_token: current_user.private_token }), title: "Feed", class: 'btn rss-btn'
+ = link_to icon('rss'), group_path(@group, { format: :atom, private_token: current_user.private_token }), title: "动态", class: 'btn rss-btn'
.avatar-holder
= link_to group_icon(@group), target: '_blank' do
diff --git a/app/views/help/_shortcuts.html.haml b/app/views/help/_shortcuts.html.haml
index da3c3711cdd..85401681522 100644
--- a/app/views/help/_shortcuts.html.haml
+++ b/app/views/help/_shortcuts.html.haml
@@ -211,7 +211,7 @@
\/
.key
shift k
- %td Scroll to top
+ %td 滚动到顶部
%tr
%td.shortcut
.key
diff --git a/app/views/help/index.html.haml b/app/views/help/index.html.haml
index 57bc91ea5a9..6a5133a2e93 100644
--- a/app/views/help/index.html.haml
+++ b/app/views/help/index.html.haml
@@ -1,13 +1,13 @@
%div
%h1
GitLab
- Community Edition
+ 社区版
- if user_signed_in?
%span= Gitlab::VERSION
%small= Gitlab::REVISION
= version_status_badge
%p.slead
- GitLab is open source software to collaborate on code.
+ GitLab 是用于代码协作的开源软件。
%br
Manage git repositories with fine-grained access controls that keep your code secure.
%br
@@ -17,7 +17,10 @@
%br
Used by more than 100,000 organizations, GitLab is the most popular solution to manage git repositories on-premises.
%br
- Read more about GitLab at #{link_to promo_host, promo_url, target: '_blank'}.
+ 了解 Gitlab 更多内容请访问 #{link_to promo_host, promo_url, target: '_blank'}。
+ %br
+ 需要改进中文翻译,比如将上面的大段英文和下面的文档翻译,请#{link_to '派生 https://gitlab.com/larryli/gitlab 项目', 'https://gitlab.com/larryli/gitlab/fork/new'},
+ 修改文件后提交#{link_to '合并请求', 'https://gitlab.com/larryli/gitlab/merge_requests/new'}。
- if current_application_settings.help_page_text.present?
%hr
= markdown(current_application_settings.help_page_text)
@@ -32,10 +35,10 @@
.col-md-4
.panel.panel-default
.panel-heading
- Quick help
+ 快速帮助
%ul.well-list
- %li= link_to 'See our website for getting help', promo_url + '/getting-help/'
- %li= link_to 'Use the search bar on the top of this page', '#', onclick: 'Shortcuts.focusSearch(event)'
- %li= link_to 'Use shortcuts', '#', onclick: 'Shortcuts.showHelp(event)'
- %li= link_to 'Get a support subscription', 'https://about.gitlab.com/pricing/'
- %li= link_to 'Compare GitLab editions', 'https://about.gitlab.com/features/#compare'
+ %li= link_to '查看我们的网站获取帮助', promo_url + '/getting-help/'
+ %li= link_to '使用页面顶部的搜索功能', '#', onclick: 'Shortcuts.focusSearch(event)'
+ %li= link_to '键盘快捷键', '#', onclick: 'Shortcuts.showHelp(event)'
+ %li= link_to '获取技术支持订阅', 'https://about.gitlab.com/pricing/'
+ %li= link_to '比较 GitLab 版本', 'https://about.gitlab.com/features/#compare'
diff --git a/app/views/help/ui.html.haml b/app/views/help/ui.html.haml
index d084559abc3..c9244770bd0 100644
--- a/app/views/help/ui.html.haml
+++ b/app/views/help/ui.html.haml
@@ -532,8 +532,8 @@
Awesome file
.file-actions
.btn-group
- %a.btn Edit
- %a.btn.btn-danger Remove
+ %a.btn 编辑
+ %a.btn.btn-danger 删除
.file-contenta.code
= render 'shared/file_highlight', blob: blob
diff --git a/app/views/import/base/create.js.haml b/app/views/import/base/create.js.haml
index d8af0295b2d..9c835218dbf 100644
--- a/app/views/import/base/create.js.haml
+++ b/app/views/import/base/create.js.haml
@@ -5,7 +5,7 @@
project_name = "#{@project_name}"
origin_namespace = "#{@target_namespace}"
target_field.empty()
- target_field.append("<p class='alert alert-danger'>This namespace already been taken! Please choose another one</p>")
+ target_field.append("<p class='alert alert-danger'>此命名空间已被使用!请选择其他的</p>")
target_field.append("<input type='text' name='target_namespace' />")
target_field.append("/" + project_name)
target_field.data("project_name", project_name)
@@ -13,7 +13,7 @@
- elsif @access_denied
:plain
job = $("tr#repo_#{@repo_id}")
- job.find(".import-actions").html("<p class='alert alert-danger'>Access denied! Please verify you can add deploy keys to this repository.</p>")
+ job.find(".import-actions").html("<p class='alert alert-danger'>没有访问权限!请确认是否增加了此版本仓库的部署密钥。</p>")
- elsif @project.persisted?
:plain
job = $("tr#repo_#{@repo_id}")
@@ -22,8 +22,8 @@
target_field.empty()
target_field.append('<strong>#{link_to @project.path_with_namespace, namespace_project_path(@project.namespace, @project)}</strong>')
$("table.import-jobs tbody").prepend(job)
- job.addClass("active").find(".import-actions").html("<i class='fa fa-spinner fa-spin'></i> started")
+ job.addClass("active").find(".import-actions").html("<i class='fa fa-spinner fa-spin'></i> 已开始")
- else
:plain
job = $("tr#repo_#{@repo_id}")
- job.find(".import-actions").html("<i class='fa fa-exclamation-circle'> Error saving project: #{escape_javascript(@project.errors.full_messages.join(','))}</i>")
+ job.find(".import-actions").html("<i class='fa fa-exclamation-circle'> 保存项目错误:#{escape_javascript(@project.errors.full_messages.join(','))}</i>")
diff --git a/app/views/import/bitbucket/status.html.haml b/app/views/import/bitbucket/status.html.haml
index aec2e836c9f..bfb46bf6409 100644
--- a/app/views/import/bitbucket/status.html.haml
+++ b/app/views/import/bitbucket/status.html.haml
@@ -1,27 +1,27 @@
-- page_title "Bitbucket import"
-- header_title "Projects", root_path
+- page_title "Bitbucket 导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-bitbucket
- Import projects from Bitbucket
+ 从 Bitbucket 导入项目
- if @repos.any?
%p.light
- Select projects you want to import.
+ 选择要导入的项目。
%hr
%p
- if @incompatible_repos.any?
- = button_tag 'Import all compatible projects', class: "btn btn-success js-import-all"
+ = button_tag '导入所有兼容项目', class: "btn btn-success js-import-all"
- else
- = button_tag 'Import all projects', class: "btn btn-success js-import-all"
+ = button_tag '导入所有项目', class: "btn btn-success js-import-all"
.table-holder
%table.table.import-jobs
%thead
%tr
- %th From Bitbucket
- %th To GitLab
- %th Status
+ %th 从 Bitbucket
+ %th 到 GitLab
+ %th 状态
%tbody
- @already_added_projects.each do |project|
%tr{id: "project_#{project.id}", class: "#{project_status_css_class(project.import_status)}"}
@@ -33,10 +33,10 @@
- if project.import_status == 'finished'
%span
%i.fa.fa-check
- done
+ 完成
- elsif project.import_status == 'started'
%i.fa.fa-spinner.fa-spin
- started
+ 已开始
- else
= project.human_import_status_name
@@ -47,24 +47,24 @@
%td.import-target
= "#{repo["owner"]}/#{repo["slug"]}"
%td.import-actions.job-status
- = button_tag "Import", class: "btn js-add-to-import"
+ = button_tag "导入", class: "btn js-add-to-import"
- @incompatible_repos.each do |repo|
%tr{id: "repo_#{repo["owner"]}___#{repo["slug"]}"}
%td
= link_to "#{repo["owner"]}/#{repo["slug"]}", "https://bitbucket.org/#{repo["owner"]}/#{repo["slug"]}", target: "_blank"
%td.import-target
%td.import-actions-job-status
- = label_tag "Incompatible Project", nil, class: "label label-danger"
+ = label_tag "不兼容项目", nil, class: "label label-danger"
- if @incompatible_repos.any?
%p
- One or more of your Bitbucket projects cannot be imported into GitLab
- directly because they use Subversion or Mercurial for version control,
- rather than Git. Please convert
- = link_to "them to Git,", "https://www.atlassian.com/git/tutorials/migrating-overview"
- and go through the
- = link_to "import flow", status_import_bitbucket_path, "data-no-turbolink" => "true"
- again.
+ 一个或多个 Bitbucket 项目无法直接导入到 GitLab,
+ 因为其使用 Subversion 或 Mercurial 版本控制,
+ 而不是 Git。请转换
+ = link_to "它们为 Git,", "https://www.atlassian.com/git/tutorials/migrating-overview"
+ 然后重新
+ = link_to "导入", status_import_bitbucket_path, "data-no-turbolink" => "true"
+ 。
:javascript
diff --git a/app/views/import/fogbugz/new.html.haml b/app/views/import/fogbugz/new.html.haml
index 5515fad6f48..5c322f38cac 100644
--- a/app/views/import/fogbugz/new.html.haml
+++ b/app/views/import/fogbugz/new.html.haml
@@ -1,26 +1,25 @@
-- page_title "FogBugz Import"
-- header_title "Projects", root_path
+- page_title "FogBugz 导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-bug
- Import projects from FogBugz
+ 从 FogBugz 导入项目
%hr
= form_tag callback_import_fogbugz_path, class: 'form-horizontal' do
%p
- To get started you enter your FogBugz URL and login information below.
- In the next steps, you'll be able to map users and select the projects
- you want to import.
+ 请先在下面填入你的 FogBugz 链接和登录信息。
+ 然后在下一步,你可以映射用户和选择你想要导入的项目。
.form-group
- = label_tag :uri, 'FogBugz URL', class: 'control-label'
+ = label_tag :uri, 'FogBugz 链接', class: 'control-label'
.col-sm-4
= text_field_tag :uri, nil, placeholder: 'https://mycompany.fogbugz.com', class: 'form-control'
.form-group
- = label_tag :email, 'FogBugz Email', class: 'control-label'
+ = label_tag :email, 'FogBugz 电子邮箱', class: 'control-label'
.col-sm-4
= text_field_tag :email, nil, class: 'form-control'
.form-group
- = label_tag :password, 'FogBugz Password', class: 'control-label'
+ = label_tag :password, 'FogBugz 密码', class: 'control-label'
.col-sm-4
= password_field_tag :password, nil, class: 'form-control'
.form-actions
- = submit_tag 'Continue to the next step', class: 'btn btn-create'
+ = submit_tag '继续下一步', class: 'btn btn-create'
diff --git a/app/views/import/fogbugz/new_user_map.html.haml b/app/views/import/fogbugz/new_user_map.html.haml
index 07338736bac..cc920005dc2 100644
--- a/app/views/import/fogbugz/new_user_map.html.haml
+++ b/app/views/import/fogbugz/new_user_map.html.haml
@@ -1,8 +1,8 @@
-- page_title 'User map', 'FogBugz import'
-- header_title "Projects", root_path
+- page_title '用户映射', 'FogBugz 导入'
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-bug
- Import projects from FogBugz
+ 从 FogBugz 导入项目
%hr
= form_tag create_user_map_import_fogbugz_path, class: 'form-horizontal' do
@@ -13,14 +13,14 @@
The user map is a mapping of the FogBugz users that participated on your projects to the way their email address and usernames wil be imported into GitLab. You can change this by populating the table below.
%ul
%li
- %strong Default: Map a FogBugz account ID to a full name
+ %strong 默认:映射 FogBugz 账号 ID 到完整姓名
%p
An empty GitLab User field will add the FogBugz user's full name
(e.g. "By John Smith") in the description of all issues and comments.
It will also associate and/or assign these issues and comments with
the project creator.
%li
- %strong Map a FogBugz account ID to a GitLab user
+ %strong 映射 FogBugz 账号 ID 到 GitLab 用户
%p
Selecting a GitLab user will add a link to the GitLab user in the descriptions
of issues and comments (e.g. "By <a href="#">@johnsmith</a>"). It will also
@@ -31,9 +31,9 @@
%thead
%tr
%th ID
- %th Name
- %th Email
- %th GitLab User
+ %th 名称
+ %th 电子邮箱
+ %th GitLab 用户
%tbody
- @user_map.each do |id, user|
%tr
@@ -45,7 +45,7 @@
scope: :all, email_user: true, selected: user[:gitlab_user])
.form-actions
- = submit_tag 'Continue to the next step', class: 'btn btn-create'
+ = submit_tag '继续下一步', class: 'btn btn-create'
:javascript
new UsersSelect();
diff --git a/app/views/import/fogbugz/status.html.haml b/app/views/import/fogbugz/status.html.haml
index 6ee16c8be4b..cbda3a5d9d3 100644
--- a/app/views/import/fogbugz/status.html.haml
+++ b/app/views/import/fogbugz/status.html.haml
@@ -1,27 +1,27 @@
-- page_title "FogBugz import"
-- header_title "Projects", root_path
+- page_title "FogBugz 导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-bug
- Import projects from FogBugz
+ 从 FogBugz 导入项目
- if @repos.any?
%p.light
- Select projects you want to import.
+ 选择要导入的项目。
%p.light
- Optionally, you can
- = link_to 'customize', new_user_map_import_fogbugz_path
- how FogBugz email addresses and usernames are imported into GitLab.
+ 可选项,可以
+ = link_to '自定义', new_user_map_import_fogbugz_path
+ FogBugz 电子邮箱地址和用户名来导入到 GitLab。
%hr
%p
- = button_tag 'Import all projects', class: 'btn btn-success js-import-all'
+ = button_tag '导入所有项目', class: 'btn btn-success js-import-all'
.table-holder
%table.table.import-jobs
%thead
%tr
- %th From FogBugz
- %th To GitLab
- %th Status
+ %th 从 FogBugz
+ %th 到 GitLab
+ %th 状态
%tbody
- @already_added_projects.each do |project|
%tr{id: "project_#{project.id}", class: "#{project_status_css_class(project.import_status)}"}
@@ -33,10 +33,10 @@
- if project.import_status == 'finished'
%span
%i.fa.fa-check
- done
+ 完成
- elsif project.import_status == 'started'
%i.fa.fa-spinner.fa-spin
- started
+ 已开始
- else
= project.human_import_status_name
@@ -47,7 +47,7 @@
%td.import-target
= "#{current_user.username}/#{repo.name}"
%td.import-actions.job-status
- = button_tag "Import", class: "btn js-add-to-import"
+ = button_tag "导入", class: "btn js-add-to-import"
:javascript
new ImporterStatus("#{jobs_import_fogbugz_path}", "#{import_fogbugz_path}");
diff --git a/app/views/import/github/status.html.haml b/app/views/import/github/status.html.haml
index 1416ee5bd5a..e4daac7593f 100644
--- a/app/views/import/github/status.html.haml
+++ b/app/views/import/github/status.html.haml
@@ -1,22 +1,22 @@
-- page_title "GitHub import"
-- header_title "Projects", root_path
+- page_title "GitHub 导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-github
- Import projects from GitHub
+ 从 GitHub 导入项目
%p.light
- Select projects you want to import.
+ 选择要导入的项目。
%hr
%p
- = button_tag 'Import all projects', class: "btn btn-success js-import-all"
+ = button_tag '导入所有项目', class: "btn btn-success js-import-all"
.table-holder
%table.table.import-jobs
%thead
%tr
- %th From GitHub
- %th To GitLab
- %th Status
+ %th 从 GitHub
+ %th 到 GitLab
+ %th 状态
%tbody
- @already_added_projects.each do |project|
%tr{id: "project_#{project.id}", class: "#{project_status_css_class(project.import_status)}"}
@@ -28,10 +28,10 @@
- if project.import_status == 'finished'
%span
%i.fa.fa-check
- done
+ 完成
- elsif project.import_status == 'started'
%i.fa.fa-spinner.fa-spin
- started
+ 已开始
- else
= project.human_import_status_name
@@ -42,7 +42,7 @@
%td.import-target
= repo.full_name
%td.import-actions.job-status
- = button_tag "Import", class: "btn js-add-to-import"
+ = button_tag "导入", class: "btn js-add-to-import"
:javascript
new ImporterStatus("#{jobs_import_github_path}", "#{import_github_path}");
diff --git a/app/views/import/gitlab/status.html.haml b/app/views/import/gitlab/status.html.haml
index 911a55eb85d..7f193519ae5 100644
--- a/app/views/import/gitlab/status.html.haml
+++ b/app/views/import/gitlab/status.html.haml
@@ -1,22 +1,22 @@
-- page_title "GitLab.com import"
-- header_title "Projects", root_path
+- page_title "GitLab.com 导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-heart
- Import projects from GitLab.com
+ 从 GitLab.com 导入项目
%p.light
- Select projects you want to import.
+ 选择要导入的项目。
%hr
%p
- = button_tag 'Import all projects', class: "btn btn-success js-import-all"
+ = button_tag '导入所有项目', class: "btn btn-success js-import-all"
.table-holder
%table.table.import-jobs
%thead
%tr
- %th From GitLab.com
- %th To this GitLab instance
- %th Status
+ %th 从 GitLab.com
+ %th 到此 GitLab 实例
+ %th 状态
%tbody
- @already_added_projects.each do |project|
%tr{id: "project_#{project.id}", class: "#{project_status_css_class(project.import_status)}"}
@@ -28,10 +28,10 @@
- if project.import_status == 'finished'
%span
%i.fa.fa-check
- done
+ 完成
- elsif project.import_status == 'started'
%i.fa.fa-spinner.fa-spin
- started
+ 已开始
- else
= project.human_import_status_name
@@ -42,7 +42,7 @@
%td.import-target
= repo["path_with_namespace"]
%td.import-actions.job-status
- = button_tag "Import", class: "btn js-add-to-import"
+ = button_tag "导入", class: "btn js-add-to-import"
:javascript
new ImporterStatus("#{jobs_import_gitlab_path}", "#{import_gitlab_path}");
diff --git a/app/views/import/gitorious/status.html.haml b/app/views/import/gitorious/status.html.haml
index 6b0fa1edf8c..62dfd442387 100644
--- a/app/views/import/gitorious/status.html.haml
+++ b/app/views/import/gitorious/status.html.haml
@@ -1,22 +1,22 @@
-- page_title "Gitorious import"
-- header_title "Projects", root_path
+- page_title "Gitorious 导入"
+- header_title "项目", root_path
%h3.page-title
%i.icon-gitorious.icon-gitorious-big
- Import projects from Gitorious.org
+ 从 Gitorious.org 导入项目
%p.light
- Select projects you want to import.
+ 选择要导入的项目。
%hr
%p
- = button_tag 'Import all projects', class: "btn btn-success js-import-all"
+ = button_tag '导入所有项目', class: "btn btn-success js-import-all"
.table-holder
%table.table.import-jobs
%thead
%tr
- %th From Gitorious.org
- %th To GitLab
- %th Status
+ %th 从 Gitorious.org
+ %th 到 GitLab
+ %th 状态
%tbody
- @already_added_projects.each do |project|
%tr{id: "project_#{project.id}", class: "#{project_status_css_class(project.import_status)}"}
@@ -28,10 +28,10 @@
- if project.import_status == 'finished'
%span
%i.fa.fa-check
- done
+ 完成
- elsif project.import_status == 'started'
%i.fa.fa-spinner.fa-spin
- started
+ 已开始
- else
= project.human_import_status_name
@@ -42,7 +42,7 @@
%td.import-target
= repo.full_name
%td.import-actions.job-status
- = button_tag "Import", class: "btn js-add-to-import"
+ = button_tag "导入", class: "btn js-add-to-import"
:javascript
new ImporterStatus("#{jobs_import_gitorious_path}", "#{import_gitorious_path}");
diff --git a/app/views/import/google_code/new.html.haml b/app/views/import/google_code/new.html.haml
index 5d2f149cd5f..e3c9c64e509 100644
--- a/app/views/import/google_code/new.html.haml
+++ b/app/views/import/google_code/new.html.haml
@@ -1,62 +1,62 @@
-- page_title "Google Code import"
-- header_title "Projects", root_path
+- page_title "Google 代码导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-google
- Import projects from Google Code
+ 从 Google 代码导入项目
%hr
= form_tag callback_import_google_code_path, class: 'form-horizontal', multipart: true do
%p
- Follow the steps below to export your Google Code project data.
- In the next step, you'll be able to select the projects you want to import.
+ 按照下面的步骤来导入 Google Code 项目数据。
+ 在下一步,请先选择要导入的项目。
%ol
%li
%p
- Go to
- #{link_to "Google Takeout", "https://www.google.com/settings/takeout", target: "_blank"}.
+ 转到
+ #{link_to "下载数据 (Google Takeout)", "https://www.google.com/settings/takeout", target: "_blank"}.
%li
%p
- Make sure you're logged into the account that owns the projects you'd like to import.
+ 请先确保已登录到要导入项目的账号。
%li
%p
- Click the <strong>Select none</strong> button on the right, since we only need "Google Code Project Hosting".
+ 先在右侧点击<strong>全部不选</strong>按钮,以保证只选择“Google 代码 Project Hosting”选项.
%li
%p
- Scroll down to <strong>Google Code Project Hosting</strong> and enable the switch on the right.
+ 向下滚动到 <strong>Google 代码 Project Hosting</strong>,在右边开启选择。
%li
%p
- Choose <strong>Next</strong> at the bottom of the page.
+ 在页面底部点击<strong>下一步</strong>。
%li
%p
- Leave the "File type" and "Delivery method" options on their default values.
+ “文件类型”与“投放方式”选项保持其默认值即可。
%li
%p
- Choose <strong>Create archive</strong> and wait for archiving to complete.
+ 点击<strong>创建归档文件</strong>,然后等待归档完成。
%li
%p
- Click the <strong>Download</strong> button and wait for downloading to complete.
+ 点击<strong>下载</strong>按钮,然后等待下载完成。
%li
%p
- Find the downloaded ZIP file and decompress it.
+ 找到下载的 ZIP 文件再解压。
%li
%p
- Find the newly extracted <code>Takeout/Google Code Project Hosting/GoogleCodeProjectHosting.json</code> file.
+ 找到新解压出来的 <code>Takeout/Google代码Project Hosting/Google代码ProjectHosting.json</code> 文件。
%li
%p
- Upload <code>GoogleCodeProjectHosting.json</code> here:
+ 上传 <code>Google代码ProjectHosting.json</code> 到这里:
%p
%input{type: "file", name: "dump_file", id: "dump_file"}
%li
%p
- Do you want to customize how Google Code email addresses and usernames are imported into GitLab?
+ 是否想自定义 Google 代码电子邮箱地址和用户名导入到 GitLab?
%p
= label_tag :create_user_map_0 do
= radio_button_tag :create_user_map, 0, true
- No, directly import the existing email addresses and usernames.
+ 否,直接导入到已存在的电子邮箱地址和用户名。
%p
= label_tag :create_user_map_1 do
= radio_button_tag :create_user_map, 1, false
- Yes, let me map Google Code users to full names or GitLab users.
+ 是,映射 Google 代码用户到完整的姓名或 GitLab 用户。
%li
%p
- = submit_tag 'Continue to the next step', class: "btn btn-create"
+ = submit_tag '继续下一步', class: "btn btn-create"
diff --git a/app/views/import/google_code/new_user_map.html.haml b/app/views/import/google_code/new_user_map.html.haml
index 0738b3db1eb..acde47405c5 100644
--- a/app/views/import/google_code/new_user_map.html.haml
+++ b/app/views/import/google_code/new_user_map.html.haml
@@ -1,36 +1,36 @@
-- page_title "User map", "Google Code import"
-- header_title "Projects", root_path
+- page_title "用户映射", "Google 代码导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-google
- Import projects from Google Code
+ 从 Google 代码导入项目
%hr
= form_tag create_user_map_import_google_code_path, class: 'form-horizontal' do
%p
- Customize how Google Code email addresses and usernames are imported into GitLab.
- In the next step, you'll be able to select the projects you want to import.
+ 自定义 Google 代码电子邮箱地址和用户名导入到 GitLab。
+ 下一步,请先选择要导入的项目。
%p
The user map is a JSON document mapping the Google Code users that participated on your projects to the way their email addresses and usernames will be imported into GitLab. You can change this by changing the value on the right hand side of <code>:</code>. Be sure to preserve the surrounding double quotes, other punctuation and the email address or username on the left hand side.
%ul
%li
- %strong Default: Directly import the Google Code email address or username
+ %strong 默认:直接导入 Google 代码电子邮箱地址或用户名
%p
<code>"johnsmith@example.com": "johnsm...@example.com"</code>
will add "By johnsm...@example.com" to all issues and comments originally created by johnsmith@example.com.
The email address or username is masked to ensure the user's privacy.
%li
- %strong Map a Google Code user to a GitLab user
+ %strong 映射 Google 代码用户到 GitLab 用户
%p
<code>"johnsmith@example.com": "@johnsmith"</code>
will add "By <a href="#">@johnsmith</a>" to all issues and comments originally created by johnsmith@example.com,
and will set <a href="#">@johnsmith</a> as the assignee on all issues originally assigned to johnsmith@example.com.
%li
- %strong Map a Google Code user to a full name
+ %strong 映射 Google 代码用户到完整姓名
%p
<code>"johnsmith@example.com": "John Smith"</code>
will add "By John Smith" to all issues and comments originally created by johnsmith@example.com.
%li
- %strong Map a Google Code user to a full email address
+ %strong 映射 Google 代码用户到完整电子邮箱地址
%p
<code>"johnsmith@example.com": "johnsmith@example.com"</code>
will add "By <a href="#">johnsmith@example.com</a>" to all issues and comments originally created by johnsmith@example.com.
@@ -41,4 +41,4 @@
= text_area_tag :user_map, JSON.pretty_generate(@user_map), class: 'form-control', rows: 15
.form-actions
- = submit_tag 'Continue to the next step', class: "btn btn-create"
+ = submit_tag '继续下一步', class: "btn btn-create"
diff --git a/app/views/import/google_code/status.html.haml b/app/views/import/google_code/status.html.haml
index 175ef6921cd..fbdb83d4952 100644
--- a/app/views/import/google_code/status.html.haml
+++ b/app/views/import/google_code/status.html.haml
@@ -1,30 +1,30 @@
-- page_title "Google Code import"
-- header_title "Projects", root_path
+- page_title "Google 代码导入"
+- header_title "项目", root_path
%h3.page-title
%i.fa.fa-google
- Import projects from Google Code
+ 从 Google 代码导入项目
- if @repos.any?
%p.light
- Select projects you want to import.
+ 选择要导入的项目。
%p.light
- Optionally, you can
- = link_to "customize", new_user_map_import_google_code_path
- how Google Code email addresses and usernames are imported into GitLab.
+ 可选项,可以
+ = link_to "自定义", new_user_map_import_google_code_path
+ Google 代码电子邮箱地址和用户名来导入到 GitLab。
%hr
%p
- if @incompatible_repos.any?
- = button_tag 'Import all compatible projects', class: "btn btn-success js-import-all"
+ = button_tag '导入所有兼容项目', class: "btn btn-success js-import-all"
- else
- = button_tag 'Import all projects', class: "btn btn-success js-import-all"
+ = button_tag '导入所有项目', class: "btn btn-success js-import-all"
.table-holder
%table.table.import-jobs
%thead
%tr
- %th From Google Code
- %th To GitLab
- %th Status
+ %th 从 Google 代码
+ %th 到 GitLab
+ %th 状态
%tbody
- @already_added_projects.each do |project|
%tr{id: "project_#{project.id}", class: "#{project_status_css_class(project.import_status)}"}
@@ -36,10 +36,10 @@
- if project.import_status == 'finished'
%span
%i.fa.fa-check
- done
+ 完成
- elsif project.import_status == 'started'
%i.fa.fa-spinner.fa-spin
- started
+ 已开始
- else
= project.human_import_status_name
@@ -50,23 +50,22 @@
%td.import-target
= "#{current_user.username}/#{repo.name}"
%td.import-actions.job-status
- = button_tag "Import", class: "btn js-add-to-import"
+ = button_tag "导入", class: "btn js-add-to-import"
- @incompatible_repos.each do |repo|
%tr{id: "repo_#{repo.id}"}
%td
= link_to repo.name, "https://code.google.com/p/#{repo.name}", target: "_blank"
%td.import-target
%td.import-actions-job-status
- = label_tag "Incompatible Project", nil, class: "label label-danger"
+ = label_tag "不兼容项目", nil, class: "label label-danger"
- if @incompatible_repos.any?
%p
- One or more of your Google Code projects cannot be imported into GitLab
- directly because they use Subversion or Mercurial for version control,
- rather than Git. Please convert them to Git on Google Code, and go
- through the
- = link_to "import flow", new_import_google_code_path
- again.
+ 因为有些项目使用 Subversion(svn) 或 Mercurial(hg) 版本控制
+ 而不是 Git,所以无法导入到 GitLab。
+ 请在 Google 代码上通过
+ = link_to "导入工作流", new_import_google_code_path
+ 将其转换成 Git 后再试。
:javascript
new ImporterStatus("#{jobs_import_google_code_path}", "#{import_google_code_path}");
diff --git a/app/views/invites/show.html.haml b/app/views/invites/show.html.haml
index 2fd4859c1c6..66d799d39c7 100644
--- a/app/views/invites/show.html.haml
+++ b/app/views/invites/show.html.haml
@@ -1,30 +1,29 @@
-- page_title "Invitation"
-%h3.page-title Invitation
+- page_title "邀请"
+%h3.page-title 邀请
%p
- You have been invited
+ 你被
- if inviter = @member.created_by
- by
= link_to inviter.name, user_url(inviter)
- to join
+ 邀请加入
- case @member.source
- when Project
- project = @member.source
- project
+ 项目
%strong
= link_to project.name_with_namespace, namespace_project_url(project.namespace, project)
- when Group
- group = @member.source
- group
+ 群组
%strong
= link_to group.name, group_url(group)
- as #{@member.human_access}.
+ ,身份是 #{@member.human_access}。
- if @member.source.users.include?(current_user)
%p
- However, you are already a member of this #{@member.source.is_a?(Group) ? "group" : "project"}.
- Sign in using a different account to accept the invitation.
+ 注意,你已经是该#{@member.source.is_a?(Group) ? "群组" : "项目"}的成员。
+ 请使用另一个账号登入再接受邀请。
- else
.actions
- = link_to "Accept invitation", accept_invite_url(@token), method: :post, class: "btn btn-success"
- = link_to "Decline", decline_invite_url(@token), method: :post, class: "btn btn-danger prepend-left-10"
+ = link_to "接受邀请", accept_invite_url(@token), method: :post, class: "btn btn-success"
+ = link_to "拒绝", decline_invite_url(@token), method: :post, class: "btn btn-danger prepend-left-10"
diff --git a/app/views/layouts/_collapse_button.html.haml b/app/views/layouts/_collapse_button.html.haml
index 2ed51d87ca1..60308026da5 100644
--- a/app/views/layouts/_collapse_button.html.haml
+++ b/app/views/layouts/_collapse_button.html.haml
@@ -1,4 +1,4 @@
- if nav_menu_collapsed?
- = link_to icon('angle-right'), '#', class: 'toggle-nav-collapse', title: "Open/Close"
+ = link_to icon('angle-right'), '#', class: 'toggle-nav-collapse', title: "打开/关闭"
- else
- = link_to icon('angle-left'), '#', class: 'toggle-nav-collapse', title: "Open/Close"
+ = link_to icon('angle-left'), '#', class: 'toggle-nav-collapse', title: "打开/关闭"
diff --git a/app/views/layouts/_page.html.haml b/app/views/layouts/_page.html.haml
index c799e9c588d..b880f5a3df0 100644
--- a/app/views/layouts/_page.html.haml
+++ b/app/views/layouts/_page.html.haml
@@ -4,7 +4,7 @@
.header-logo
%a#logo
= brand_header_logo
- = link_to root_path, class: 'gitlab-text-container-link', title: 'Dashboard', id: 'js-shortcuts-home' do
+ = link_to root_path, class: 'gitlab-text-container-link', title: '仪表盘', id: 'js-shortcuts-home' do
.gitlab-text-container
%h3 GitLab
@@ -18,8 +18,8 @@
.collapse-nav
= render partial: 'layouts/collapse_button'
- if current_user
- = link_to current_user, class: 'sidebar-user', title: "Profile" do
- = image_tag avatar_icon(current_user, 60), alt: 'Profile', class: 'avatar avatar s36'
+ = link_to current_user, class: 'sidebar-user', title: "个人资料" do
+ = image_tag avatar_icon(current_user, 60), alt: '个人资料', class: 'avatar avatar s36'
.username
= current_user.username
.content-wrapper
diff --git a/app/views/layouts/admin.html.haml b/app/views/layouts/admin.html.haml
index 6591c52bdbd..6a6a1051134 100644
--- a/app/views/layouts/admin.html.haml
+++ b/app/views/layouts/admin.html.haml
@@ -1,5 +1,5 @@
-- page_title "Admin Area"
-- header_title "Admin Area", admin_root_path
+- page_title "管理区域"
+- header_title "管理区域", admin_root_path
- sidebar "admin"
= render template: "layouts/application"
diff --git a/app/views/layouts/ci/_page.html.haml b/app/views/layouts/ci/_page.html.haml
index a13241bebee..01864446baa 100644
--- a/app/views/layouts/ci/_page.html.haml
+++ b/app/views/layouts/ci/_page.html.haml
@@ -4,7 +4,7 @@
.header-logo
%a#logo
= brand_header_logo
- = link_to root_path, class: 'gitlab-text-container-link', title: 'Dashboard', id: 'js-shortcuts-home' do
+ = link_to root_path, class: 'gitlab-text-container-link', title: '仪表盘', id: 'js-shortcuts-home' do
.gitlab-text-container
%h3 GitLab
@@ -15,8 +15,8 @@
.collapse-nav
= render partial: 'layouts/collapse_button'
- if current_user
- = link_to current_user, class: 'sidebar-user', title: "Profile" do
- = image_tag avatar_icon(current_user, 60), alt: 'Profile', class: 'avatar avatar s36'
+ = link_to current_user, class: 'sidebar-user', title: "个人资料" do
+ = image_tag avatar_icon(current_user, 60), alt: '个人资料', class: 'avatar avatar s36'
.username
= current_user.username
.content-wrapper
diff --git a/app/views/layouts/ci/notify.html.haml b/app/views/layouts/ci/notify.html.haml
index 270b206df5e..4cea6278583 100644
--- a/app/views/layouts/ci/notify.html.haml
+++ b/app/views/layouts/ci/notify.html.haml
@@ -16,4 +16,4 @@
%td{align: "left", style: "margin: 0; padding: 10px;"}
%p{style: "font-size:small;color:#777"}
- if @project
- You're receiving this notification because you are the one who triggered a build on the #{@project.name} project.
+ 你接收到此通知是因为你的 #{@project.name} 项目触发的构建。
diff --git a/app/views/layouts/dashboard.html.haml b/app/views/layouts/dashboard.html.haml
index cb96bcc2cf4..2e74821082e 100644
--- a/app/views/layouts/dashboard.html.haml
+++ b/app/views/layouts/dashboard.html.haml
@@ -1,5 +1,5 @@
-- page_title "Dashboard"
-- header_title "Dashboard", root_path unless header_title
+- page_title "仪表盘"
+- header_title "仪表盘", root_path unless header_title
- sidebar "dashboard"
= render template: "layouts/application"
diff --git a/app/views/layouts/devise.html.haml b/app/views/layouts/devise.html.haml
index f08cb0a5428..7e5f18abf79 100644
--- a/app/views/layouts/devise.html.haml
+++ b/app/views/layouts/devise.html.haml
@@ -17,12 +17,12 @@
= brand_image
= brand_text
- else
- %h3 Open source software to collaborate on code
+ %h3 用于代码协作的开源软件
%p
- Manage git repositories with fine grained access controls that keep your code secure.
- Perform code reviews and enhance collaboration with merge requests.
- Each project can also have an issue tracker and a wiki.
+ 细粒度访问控制管理 git 仓库以保证代码安全。
+ 使用合并请求进行代码审查并加强团体合作。
+ 每个项目均有自己的问题跟踪和维基页面。
- if extra_sign_in_text.present?
= markdown(extra_sign_in_text)
@@ -30,6 +30,7 @@
%hr
.container
.footer-links
- = link_to "Explore", explore_root_path
- = link_to "Help", help_path
- = link_to "About GitLab", "https://about.gitlab.com/"
+ = link_to "浏览", explore_root_path
+ = link_to "帮助", help_path
+ = link_to "关于 GitLab", "https://about.gitlab.com/"
+ = link_to "中文", "https://gitlab.com/larryli/gitlab/"
diff --git a/app/views/layouts/explore.html.haml b/app/views/layouts/explore.html.haml
index df65792be73..d97c45b1064 100644
--- a/app/views/layouts/explore.html.haml
+++ b/app/views/layouts/explore.html.haml
@@ -1,5 +1,5 @@
-- page_title "Explore"
+- page_title "浏览"
- unless current_user
- - header_title "Explore GitLab", explore_root_path
+ - header_title "浏览 GitLab", explore_root_path
= render template: "layouts/application"
diff --git a/app/views/layouts/group_settings.html.haml b/app/views/layouts/group_settings.html.haml
index a1a1fc2f858..dcad09af362 100644
--- a/app/views/layouts/group_settings.html.haml
+++ b/app/views/layouts/group_settings.html.haml
@@ -1,5 +1,5 @@
-- page_title "Settings"
-- header_title group_title(@group, "Settings", edit_group_path(@group))
+- page_title "设置"
+- header_title group_title(@group, "设置", edit_group_path(@group))
- sidebar "group_settings"
= render template: "layouts/group"
diff --git a/app/views/layouts/header/_default.html.haml b/app/views/layouts/header/_default.html.haml
index bfa5937cf3f..0b1f5e034e1 100644
--- a/app/views/layouts/header/_default.html.haml
+++ b/app/views/layouts/header/_default.html.haml
@@ -2,7 +2,7 @@
%div{ class: fluid_layout ? "container-fluid" : "container-fluid" }
.header-content
%button.navbar-toggle{type: 'button'}
- %span.sr-only Toggle navigation
+ %span.sr-only 切换导航条
= icon('bars')
.navbar-collapse.collapse
diff --git a/app/views/layouts/help.html.haml b/app/views/layouts/help.html.haml
index 224b24befbe..b1e983b218c 100644
--- a/app/views/layouts/help.html.haml
+++ b/app/views/layouts/help.html.haml
@@ -1,4 +1,4 @@
-- page_title "Help"
-- header_title "Help", help_path
+- page_title "帮助"
+- header_title "帮助", help_path
= render template: "layouts/application"
diff --git a/app/views/layouts/nav/_admin.html.haml b/app/views/layouts/nav/_admin.html.haml
index 280a1b93729..0f206268641 100644
--- a/app/views/layouts/nav/_admin.html.haml
+++ b/app/views/layouts/nav/_admin.html.haml
@@ -1,29 +1,29 @@
%ul.nav.nav-sidebar
= nav_link(controller: :dashboard, html_options: {class: 'home'}) do
- = link_to admin_root_path, title: 'Overview' do
+ = link_to admin_root_path, title: '概览' do
= icon('dashboard fw')
%span
- Overview
+ 概览
= nav_link(controller: [:admin, :projects]) do
- = link_to admin_namespaces_projects_path, title: 'Projects' do
+ = link_to admin_namespaces_projects_path, title: '项目' do
= icon('cube fw')
%span
- Projects
+ 项目
= nav_link(controller: :users) do
- = link_to admin_users_path, title: 'Users' do
+ = link_to admin_users_path, title: '用户' do
= icon('user fw')
%span
- Users
+ 用户
= nav_link(controller: :groups) do
- = link_to admin_groups_path, title: 'Groups' do
+ = link_to admin_groups_path, title: '群组' do
= icon('group fw')
%span
- Groups
+ 群组
= nav_link(controller: :deploy_keys) do
- = link_to admin_deploy_keys_path, title: 'Deploy Keys' do
+ = link_to admin_deploy_keys_path, title: '部署密钥' do
= icon('key fw')
%span
- Deploy Keys
+ 部署密钥
= nav_link path: ['runners#index', 'runners#show'] do
= link_to admin_runners_path, title: 'Runners' do
= icon('cog fw')
@@ -31,72 +31,72 @@
Runners
%span.count= number_with_delimiter(Ci::Runner.count(:all))
= nav_link path: 'builds#index' do
- = link_to admin_builds_path, title: 'Builds' do
+ = link_to admin_builds_path, title: '构建' do
= icon('link fw')
%span
- Builds
+ 构建
%span.count= number_with_delimiter(Ci::Build.count(:all))
= nav_link(controller: :logs) do
- = link_to admin_logs_path, title: 'Logs' do
+ = link_to admin_logs_path, title: '日志' do
= icon('file-text fw')
%span
- Logs
+ 日志
= nav_link(controller: :broadcast_messages) do
- = link_to admin_broadcast_messages_path, title: 'Messages' do
+ = link_to admin_broadcast_messages_path, title: '信息' do
= icon('bullhorn fw')
%span
- Messages
+ 信息
= nav_link(controller: :hooks) do
- = link_to admin_hooks_path, title: 'Hooks' do
+ = link_to admin_hooks_path, title: '钩子' do
= icon('external-link fw')
%span
- Hooks
+ 钩子
= nav_link(controller: :background_jobs) do
- = link_to admin_background_jobs_path, title: 'Background Jobs' do
+ = link_to admin_background_jobs_path, title: '后台作业' do
= icon('cog fw')
%span
- Background Jobs
+ 后台作业
= nav_link(controller: :appearances) do
- = link_to admin_appearances_path, title: 'Appearances' do
+ = link_to admin_appearances_path, title: '外观' do
= icon('image')
%span
- Appearance
+ 外观
= nav_link(controller: :applications) do
- = link_to admin_applications_path, title: 'Applications' do
+ = link_to admin_applications_path, title: '应用' do
= icon('cloud fw')
%span
- Applications
+ 应用
= nav_link(controller: :services) do
- = link_to admin_application_settings_services_path, title: 'Service Templates' do
+ = link_to admin_application_settings_services_path, title: '服务模板' do
= icon('copy fw')
%span
- Service Templates
+ 服务模板
= nav_link(controller: :labels) do
- = link_to admin_labels_path, title: 'Labels' do
+ = link_to admin_labels_path, title: '标记' do
= icon('tags fw')
%span
- Labels
+ 标记
= nav_link(controller: :abuse_reports) do
- = link_to admin_abuse_reports_path, title: "Abuse Reports" do
+ = link_to admin_abuse_reports_path, title: "滥用举报" do
= icon('exclamation-circle fw')
%span
- Abuse Reports
+ 滥用举报
%span.count= number_with_delimiter(AbuseReport.count(:all))
- if askimet_enabled?
= nav_link(controller: :spam_logs) do
- = link_to admin_spam_logs_path, title: "Spam Logs" do
+ = link_to admin_spam_logs_path, title: "Spam 日志" do
= icon('exclamation-triangle fw')
%span
- Spam Logs
+ Spam 日志
%span.count= number_with_delimiter(SpamLog.count(:all))
= nav_link(controller: :application_settings, html_options: { class: 'separate-item'}) do
- = link_to admin_application_settings_path, title: 'Settings' do
+ = link_to admin_application_settings_path, title: '设置' do
= icon('cogs fw')
%span
- Settings
+ 设置
diff --git a/app/views/layouts/nav/_group_settings.html.haml b/app/views/layouts/nav/_group_settings.html.haml
index 56a92fe9103..f75264759e8 100644
--- a/app/views/layouts/nav/_group_settings.html.haml
+++ b/app/views/layouts/nav/_group_settings.html.haml
@@ -1,20 +1,20 @@
%ul.nav.nav-sidebar
= nav_link do
- = link_to group_path(@group), title: 'Go to group', class: 'back-link' do
+ = link_to group_path(@group), title: '转到群组', class: 'back-link' do
= icon('caret-square-o-left fw')
%span
- Go to group
+ 转到群组
%li.separate-item
%ul.sidebar-subnav
= nav_link(path: 'groups#edit') do
- = link_to edit_group_path(@group), title: 'Group Settings' do
+ = link_to edit_group_path(@group), title: '群组设置' do
= icon ('pencil-square-o fw')
%span
- Group Settings
+ 群组设置
= nav_link(path: 'groups#projects') do
- = link_to projects_group_path(@group), title: 'Projects' do
+ = link_to projects_group_path(@group), title: '项目' do
= icon('folder fw')
%span
- Projects
+ 项目
diff --git a/app/views/layouts/nav/_project_settings.html.haml b/app/views/layouts/nav/_project_settings.html.haml
index dc3050f02e5..2ebea4ae51d 100644
--- a/app/views/layouts/nav/_project_settings.html.haml
+++ b/app/views/layouts/nav/_project_settings.html.haml
@@ -47,12 +47,12 @@
%span
Runners
= nav_link(controller: :variables) do
- = link_to namespace_project_variables_path(@project.namespace, @project), title: 'Variables' do
+ = link_to namespace_project_variables_path(@project.namespace, @project), title: '变量' do
= icon('code fw')
%span
- Variables
+ 变量
= nav_link path: 'triggers#index' do
- = link_to namespace_project_triggers_path(@project.namespace, @project), title: 'Triggers' do
+ = link_to namespace_project_triggers_path(@project.namespace, @project), title: '触发器' do
= icon('retweet fw')
%span
- Triggers
+ 触发器
diff --git a/app/views/layouts/profile.html.haml b/app/views/layouts/profile.html.haml
index dfa6cc5702e..35b9131e933 100644
--- a/app/views/layouts/profile.html.haml
+++ b/app/views/layouts/profile.html.haml
@@ -1,5 +1,5 @@
-- page_title "Profile Settings"
-- header_title "Profile Settings", profile_path unless header_title
+- page_title "个人资料设置"
+- header_title "个人资料设置", profile_path unless header_title
- sidebar "profile"
= render template: "layouts/application"
diff --git a/app/views/layouts/project_settings.html.haml b/app/views/layouts/project_settings.html.haml
index 59ce38f67bb..2a62e828d38 100644
--- a/app/views/layouts/project_settings.html.haml
+++ b/app/views/layouts/project_settings.html.haml
@@ -1,5 +1,5 @@
-- page_title "Settings"
-- header_title project_title(@project, "Settings", edit_project_path(@project))
+- page_title "设置"
+- header_title project_title(@project, "设置", edit_project_path(@project))
- sidebar "project_settings"
= render template: "layouts/project"
diff --git a/app/views/layouts/search.html.haml b/app/views/layouts/search.html.haml
index fd4c7ad21a7..772ecf6e191 100644
--- a/app/views/layouts/search.html.haml
+++ b/app/views/layouts/search.html.haml
@@ -1,4 +1,4 @@
-- page_title "Search"
-- header_title "Search", search_path
+- page_title "搜索"
+- header_title "搜索", search_path
= render template: "layouts/application"
diff --git a/app/views/layouts/snippets.html.haml b/app/views/layouts/snippets.html.haml
index 02ca3ee7a28..65805809be1 100644
--- a/app/views/layouts/snippets.html.haml
+++ b/app/views/layouts/snippets.html.haml
@@ -1,3 +1,3 @@
-- header_title "Snippets", snippets_path
+- header_title "代码片段", snippets_path
= render template: "layouts/application"
diff --git a/app/views/notify/_reassigned_issuable_email.html.haml b/app/views/notify/_reassigned_issuable_email.html.haml
index 56d81b2ed2e..6c917fefaa3 100644
--- a/app/views/notify/_reassigned_issuable_email.html.haml
+++ b/app/views/notify/_reassigned_issuable_email.html.haml
@@ -1,10 +1,10 @@
%p
- Assignee changed
+ 改变指派
- if @previous_assignee
- from
+ 从
%strong #{@previous_assignee.name}
- to
+ 到
- if issuable.assignee_id
%strong #{issuable.assignee_name}
- else
- %strong Unassigned
+ %strong 未指派
diff --git a/app/views/notify/closed_issue_email.html.haml b/app/views/notify/closed_issue_email.html.haml
index 56c18cd83cd..c681f20151f 100644
--- a/app/views/notify/closed_issue_email.html.haml
+++ b/app/views/notify/closed_issue_email.html.haml
@@ -1,2 +1,2 @@
%p
- = "Issue was closed by #{@updated_by.name}"
+ = "#{@updated_by.name} 关闭了问题"
diff --git a/app/views/notify/closed_issue_email.text.haml b/app/views/notify/closed_issue_email.text.haml
index ac703b31edd..e35bca5c62e 100644
--- a/app/views/notify/closed_issue_email.text.haml
+++ b/app/views/notify/closed_issue_email.text.haml
@@ -1,3 +1,3 @@
-= "Issue was closed by #{@updated_by.name}"
+= "#{@updated_by.name} 关闭了问题"
-Issue ##{@issue.iid}: #{namespace_project_issue_url(@issue.project.namespace, @issue.project, @issue)}
+问题 ##{@issue.iid}: #{namespace_project_issue_url(@issue.project.namespace, @issue.project, @issue)}
diff --git a/app/views/notify/closed_merge_request_email.html.haml b/app/views/notify/closed_merge_request_email.html.haml
index 574e8bfef24..463f55c3cf4 100644
--- a/app/views/notify/closed_merge_request_email.html.haml
+++ b/app/views/notify/closed_merge_request_email.html.haml
@@ -1,2 +1,2 @@
%p
- = "Merge Request ##{@merge_request.iid} was closed by #{@updated_by.name}"
+ = "#{@updated_by.name} 关闭了合并请求 ##{@merge_request.iid}"
diff --git a/app/views/notify/closed_merge_request_email.text.haml b/app/views/notify/closed_merge_request_email.text.haml
index 59db86b08bc..0d95bd046f6 100644
--- a/app/views/notify/closed_merge_request_email.text.haml
+++ b/app/views/notify/closed_merge_request_email.text.haml
@@ -1,8 +1,8 @@
-= "Merge Request ##{@merge_request.iid} was closed by #{@updated_by.name}"
+= "#{@updated_by.name} 关闭了合并请求 ##{@merge_request.iid}"
-Merge Request url: #{namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request)}
+合并请求链接: #{namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request)}
= merge_path_description(@merge_request, 'to')
-Author: #{@merge_request.author_name}
-Assignee: #{@merge_request.assignee_name}
+作者: #{@merge_request.author_name}
+指派给: #{@merge_request.assignee_name}
diff --git a/app/views/notify/group_access_granted_email.html.haml b/app/views/notify/group_access_granted_email.html.haml
index f1916d624b6..aed847d6730 100644
--- a/app/views/notify/group_access_granted_email.html.haml
+++ b/app/views/notify/group_access_granted_email.html.haml
@@ -1,4 +1,4 @@
%p
- = "You have been granted #{@group_member.human_access} access to group"
+ = "你被授权为 #{@group_member.human_access} 身份访问群组"
= link_to group_url(@group) do
= @group.name
diff --git a/app/views/notify/group_access_granted_email.text.erb b/app/views/notify/group_access_granted_email.text.erb
index ef9617bfc16..ed1b715496a 100644
--- a/app/views/notify/group_access_granted_email.text.erb
+++ b/app/views/notify/group_access_granted_email.text.erb
@@ -1,4 +1,4 @@
-You have been granted <%= @group_member.human_access %> access to group <%= @group.name %>
+你被授权为 <%= @group_member.human_access %> 身份访问群组 <%= @group.name %>
<%= url_for(group_url(@group)) %>
diff --git a/app/views/notify/group_invite_accepted_email.html.haml b/app/views/notify/group_invite_accepted_email.html.haml
index 55efad384a7..bc0ff13ad55 100644
--- a/app/views/notify/group_invite_accepted_email.html.haml
+++ b/app/views/notify/group_invite_accepted_email.html.haml
@@ -1,6 +1,6 @@
%p
- #{@group_member.invite_email}, now known as
+ #{@group_member.invite_email},现在以
#{link_to @group_member.user.name, user_url(@group_member.user)},
- has accepted your invitation to join group
- #{link_to @group.name, group_url(@group)}.
+ 账号接受邀请加入群组
+ #{link_to @group.name, group_url(@group)}。
diff --git a/app/views/notify/group_invite_accepted_email.text.erb b/app/views/notify/group_invite_accepted_email.text.erb
index f8b70f7a5a6..979042ed72b 100644
--- a/app/views/notify/group_invite_accepted_email.text.erb
+++ b/app/views/notify/group_invite_accepted_email.text.erb
@@ -1,3 +1,3 @@
-<%= @group_member.invite_email %>, now known as <%= @group_member.user.name %>, has accepted your invitation to join group <%= @group.name %>.
+<%= @group_member.invite_email %>,现在以 <%= @group_member.user.name %>, 账号接受邀请加入群组 <%= @group.name %>。
<%= group_url(@group) %>
diff --git a/app/views/notify/group_invite_declined_email.html.haml b/app/views/notify/group_invite_declined_email.html.haml
index f9525d84fac..5bb8f6da2dc 100644
--- a/app/views/notify/group_invite_declined_email.html.haml
+++ b/app/views/notify/group_invite_declined_email.html.haml
@@ -1,5 +1,5 @@
%p
#{@invite_email}
- has declined your invitation to join group
+ 拒绝接受邀请加入到群组
#{link_to @group.name, group_url(@group)}.
diff --git a/app/views/notify/group_invite_declined_email.text.erb b/app/views/notify/group_invite_declined_email.text.erb
index 6c19a288d15..58fa9904757 100644
--- a/app/views/notify/group_invite_declined_email.text.erb
+++ b/app/views/notify/group_invite_declined_email.text.erb
@@ -1,3 +1,3 @@
-<%= @invite_email %> has declined your invitation to join group <%= @group.name %>.
+<%= @invite_email %> 拒绝接受邀请加入到群组 <%= @group.name %>.
<%= group_url(@group) %>
diff --git a/app/views/notify/group_member_invited_email.html.haml b/app/views/notify/group_member_invited_email.html.haml
index 163e88bfea3..8e6e57083db 100644
--- a/app/views/notify/group_member_invited_email.html.haml
+++ b/app/views/notify/group_member_invited_email.html.haml
@@ -1,14 +1,13 @@
%p
- You have been invited
+ 你被
- if inviter = @group_member.created_by
- by
= link_to inviter.name, user_url(inviter)
- to join group
+ 邀请加入群组
= link_to @group.name, group_url(@group)
- as #{@group_member.human_access}.
+ 身份是 #{@group_member.human_access}。
%p
- = link_to 'Accept invitation', invite_url(@token)
- or
- = link_to 'decline', decline_invite_url(@token)
+ = link_to '接受邀请', invite_url(@token)
+ 或者
+ = link_to '拒绝', decline_invite_url(@token)
diff --git a/app/views/notify/group_member_invited_email.text.erb b/app/views/notify/group_member_invited_email.text.erb
index 28ce4819b14..ab86c9cb7a9 100644
--- a/app/views/notify/group_member_invited_email.text.erb
+++ b/app/views/notify/group_member_invited_email.text.erb
@@ -1,4 +1,4 @@
-You have been invited <%= "by #{@group_member.created_by.name} " if @group_member.created_by %>to join group <%= @group.name %> as <%= @group_member.human_access %>.
+你被<%= " #{@group_member.created_by.name} " if @group_member.created_by %>邀请加入群组<%= @group.name %> 身份是 <%= @group_member.human_access %>。
-Accept invitation: <%= invite_url(@token) %>
-Decline invitation: <%= decline_invite_url(@token) %>
+接受邀请: <%= invite_url(@token) %>
+拒绝邀请: <%= decline_invite_url(@token) %>
diff --git a/app/views/notify/issue_status_changed_email.html.haml b/app/views/notify/issue_status_changed_email.html.haml
index 482c884a9db..91a87b250ac 100644
--- a/app/views/notify/issue_status_changed_email.html.haml
+++ b/app/views/notify/issue_status_changed_email.html.haml
@@ -1,2 +1,2 @@
%p
- = "Issue was #{@issue_status} by #{@updated_by.name}"
+ = "问题被 #{@updated_by.name} 更新为 #{@issue_status}"
diff --git a/app/views/notify/issue_status_changed_email.text.erb b/app/views/notify/issue_status_changed_email.text.erb
index e6ab3fcde77..def14511b67 100644
--- a/app/views/notify/issue_status_changed_email.text.erb
+++ b/app/views/notify/issue_status_changed_email.text.erb
@@ -1,4 +1,4 @@
-Issue was <%= @issue_status %> by <%= @updated_by.name %>
+问题被 <%= @updated_by.name %> 更新为 <%= @issue_status %>
-Issue <%= @issue.iid %>: <%= url_for(namespace_project_issue_url(@issue.project.namespace, @issue.project, @issue)) %>
+问题 <%= @issue.iid %>: <%= url_for(namespace_project_issue_url(@issue.project.namespace, @issue.project, @issue)) %>
diff --git a/app/views/notify/merge_request_status_email.html.haml b/app/views/notify/merge_request_status_email.html.haml
index c9bf04f514e..77d48a8cba2 100644
--- a/app/views/notify/merge_request_status_email.html.haml
+++ b/app/views/notify/merge_request_status_email.html.haml
@@ -1,2 +1,2 @@
%p
- = "Merge Request ##{@merge_request.iid} was #{@mr_status} by #{@updated_by.name}"
+ = "合并请求 ##{@merge_request.iid} 被 #{@updated_by.name} 更新为 #{@mr_status}"
diff --git a/app/views/notify/merge_request_status_email.text.haml b/app/views/notify/merge_request_status_email.text.haml
index b96dd0fd8ab..b7db2b5da58 100644
--- a/app/views/notify/merge_request_status_email.text.haml
+++ b/app/views/notify/merge_request_status_email.text.haml
@@ -1,8 +1,8 @@
-= "Merge Request ##{@merge_request.iid} was #{@mr_status} by #{@updated_by.name}"
+= "合并请求 ##{@merge_request.iid} 被 #{@updated_by.name} 更新为 #{@mr_status}"
-Merge Request url: #{namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request)}
+合并请求链接: #{namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request)}
= merge_path_description(@merge_request, 'to')
-Author: #{@merge_request.author_name}
-Assignee: #{@merge_request.assignee_name}
+作者: #{@merge_request.author_name}
+指派给: #{@merge_request.assignee_name}
diff --git a/app/views/notify/merged_merge_request_email.html.haml b/app/views/notify/merged_merge_request_email.html.haml
index 6762fae7f64..2e7e7c3d7df 100644
--- a/app/views/notify/merged_merge_request_email.html.haml
+++ b/app/views/notify/merged_merge_request_email.html.haml
@@ -1,2 +1,2 @@
%p
- = "Merge Request ##{@merge_request.iid} was merged"
+ = "合并请求 ##{@merge_request.iid} 已被合并"
diff --git a/app/views/notify/merged_merge_request_email.text.haml b/app/views/notify/merged_merge_request_email.text.haml
index 34dbc60e19b..0524e42b717 100644
--- a/app/views/notify/merged_merge_request_email.text.haml
+++ b/app/views/notify/merged_merge_request_email.text.haml
@@ -1,8 +1,8 @@
-= "Merge Request ##{@merge_request.iid} was merged"
+= "合并请求 ##{@merge_request.iid} 已被合并"
-Merge Request url: #{namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request)}
+合并请求链接: #{namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request)}
= merge_path_description(@merge_request, 'to')
-Author: #{@merge_request.author_name}
-Assignee: #{@merge_request.assignee_name}
+作者: #{@merge_request.author_name}
+指派给: #{@merge_request.assignee_name}
diff --git a/app/views/notify/new_email_email.html.haml b/app/views/notify/new_email_email.html.haml
index 4a0448a573c..b6b77aefa38 100644
--- a/app/views/notify/new_email_email.html.haml
+++ b/app/views/notify/new_email_email.html.haml
@@ -1,10 +1,10 @@
%p
- Hi #{@user.name}!
+ 你好 #{@user.name}!
%p
- A new email was added to your account:
+ 你的账号增加了一个新的电子邮箱:
%p
- email:
+ 电子邮箱:
%code= @email.email
%p
- If this email was added in error, you can remove it here:
- = link_to "Emails", profile_emails_url
+ 如果错误增加该电子邮箱,可以在这里删除它:
+ = link_to "电子邮箱", profile_emails_url
diff --git a/app/views/notify/new_email_email.text.erb b/app/views/notify/new_email_email.text.erb
index 51cba99ad0d..4ef99246b9a 100644
--- a/app/views/notify/new_email_email.text.erb
+++ b/app/views/notify/new_email_email.text.erb
@@ -1,7 +1,7 @@
-Hi <%= @user.name %>!
+你好 <%= @user.name %>!
-A new email was added to your account:
+你的账号增加了一个新的电子邮箱:
-email.................. <%= @email.email %>
+电子邮箱.................. <%= @email.email %>
-If this email was added in error, you can remove it here: <%= profile_emails_url %>
+如果错误增加该电子邮箱,可以在这里删除它:<%= profile_emails_url %>
diff --git a/app/views/notify/new_issue_email.html.haml b/app/views/notify/new_issue_email.html.haml
index ad3ab2525bb..4875ad65902 100644
--- a/app/views/notify/new_issue_email.html.haml
+++ b/app/views/notify/new_issue_email.html.haml
@@ -6,4 +6,4 @@
- if @issue.assignee_id.present?
%p
- Assignee: #{@issue.assignee_name}
+ 指派给: #{@issue.assignee_name}
diff --git a/app/views/notify/new_issue_email.text.erb b/app/views/notify/new_issue_email.text.erb
index fc64c98038b..7997379a753 100644
--- a/app/views/notify/new_issue_email.text.erb
+++ b/app/views/notify/new_issue_email.text.erb
@@ -1,5 +1,5 @@
-New Issue was created.
+新问题被创建。
-Issue <%= @issue.iid %>: <%= url_for(namespace_project_issue_url(@issue.project.namespace, @issue.project, @issue)) %>
-Author: <%= @issue.author_name %>
-Assignee: <%= @issue.assignee_name %>
+问题 <%= @issue.iid %>: <%= url_for(namespace_project_issue_url(@issue.project.namespace, @issue.project, @issue)) %>
+作者: <%= @issue.author_name %>
+指派给: <%= @issue.assignee_name %>
diff --git a/app/views/notify/new_merge_request_email.html.haml b/app/views/notify/new_merge_request_email.html.haml
index 23423e7d981..fc895af4de6 100644
--- a/app/views/notify/new_merge_request_email.html.haml
+++ b/app/views/notify/new_merge_request_email.html.haml
@@ -6,7 +6,7 @@
- if @merge_request.assignee_id.present?
%p
- Assignee: #{@merge_request.author_name} &rarr; #{@merge_request.assignee_name}
+ 指派给: #{@merge_request.author_name} &rarr; #{@merge_request.assignee_name}
-if @merge_request.description
= markdown(@merge_request.description, pipeline: :email)
diff --git a/app/views/notify/new_merge_request_email.text.erb b/app/views/notify/new_merge_request_email.text.erb
index bdcca6e4ab7..4b0bf74d7c6 100644
--- a/app/views/notify/new_merge_request_email.text.erb
+++ b/app/views/notify/new_merge_request_email.text.erb
@@ -1,8 +1,8 @@
-New Merge Request #<%= @merge_request.iid %>
+新的合并请求 #<%= @merge_request.iid %>
<%= url_for(namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request)) %>
<%= merge_path_description(@merge_request, 'to') %>
-Author: <%= @merge_request.author_name %>
-Assignee: <%= @merge_request.assignee_name %>
+作者: <%= @merge_request.author_name %>
+指派给: <%= @merge_request.assignee_name %>
diff --git a/app/views/notify/new_ssh_key_email.html.haml b/app/views/notify/new_ssh_key_email.html.haml
index 63b0cbbd205..25b7ac27202 100644
--- a/app/views/notify/new_ssh_key_email.html.haml
+++ b/app/views/notify/new_ssh_key_email.html.haml
@@ -1,10 +1,10 @@
%p
- Hi #{@user.name}!
+ 你好 #{@user.name}!
%p
- A new public key was added to your account:
+ 你的账号增加了一个新的公钥:
%p
- title:
+ 标题:
%code= @key.title
%p
- If this key was added in error, you can remove it under
- = link_to "SSH Keys", profile_keys_url
+ 如果错误增加该 SSH 密钥,可以在这里删除它:
+ = link_to "SSH 密钥", profile_keys_url
diff --git a/app/views/notify/new_ssh_key_email.text.erb b/app/views/notify/new_ssh_key_email.text.erb
index 05b551c89a0..e5963ae62b1 100644
--- a/app/views/notify/new_ssh_key_email.text.erb
+++ b/app/views/notify/new_ssh_key_email.text.erb
@@ -1,7 +1,7 @@
-Hi <%= @user.name %>!
+你好 <%= @user.name %>!
-A new public key was added to your account:
+你的账号增加了一个新的公钥:
-Title: <%= @key.title %>
+标题: <%= @key.title %>
-If this key was added in error, you can remove it at <%= profile_keys_url %>
+如果错误增加该 SSH 密钥,可以在这里删除它: <%= profile_keys_url %>
diff --git a/app/views/notify/new_user_email.html.haml b/app/views/notify/new_user_email.html.haml
index 6b9b42dcf37..7f9a487770b 100644
--- a/app/views/notify/new_user_email.html.haml
+++ b/app/views/notify/new_user_email.html.haml
@@ -1,16 +1,16 @@
%p
- Hi #{@user['name']}!
+ 你好 #{@user['name']}!
%p
- if Gitlab.config.gitlab.signup_enabled
- Your account has been created successfully.
+ 你的账号创建成功。
- else
- The Administrator created an account for you. Now you are a member of the company GitLab application.
+ 管理员创建了你的账号。现在你已是 GitLab 应用的成员。
%p
- login..........................................
+ 账号..........................................
%code= @user['email']
- if @user.created_by_id
%p
- = link_to "Click here to set your password", edit_password_url(@user, reset_password_token: @token)
+ = link_to "点击这里设置你的密码", edit_password_url(@user, reset_password_token: @token)
%p
= raw reset_token_expire_message
diff --git a/app/views/notify/new_user_email.text.erb b/app/views/notify/new_user_email.text.erb
index dd9b71e3b84..375f12132c3 100644
--- a/app/views/notify/new_user_email.text.erb
+++ b/app/views/notify/new_user_email.text.erb
@@ -1,10 +1,10 @@
-Hi <%= @user.name %>!
+你好 <%= @user.name %>!
-The Administrator created an account for you. Now you are a member of the company GitLab application.
+管理员创建了你的账号。现在你已是 GitLab 应用的成员。
-login.................. <%= @user.email %>
+账号.................. <%= @user.email %>
<% if @user.created_by_id %>
- <%= link_to "Click here to set your password", edit_password_url(@user, :reset_password_token => @token) %>
+ <%= link_to "点击这里设置你的密码", edit_password_url(@user, :reset_password_token => @token) %>
<%= reset_token_expire_message %>
<% end %>
diff --git a/app/views/notify/note_commit_email.text.erb b/app/views/notify/note_commit_email.text.erb
index aaeaf5fdf73..69789362648 100644
--- a/app/views/notify/note_commit_email.text.erb
+++ b/app/views/notify/note_commit_email.text.erb
@@ -1,9 +1,9 @@
-New comment for Commit <%= @commit.short_id %>
+提交 <%= @commit.short_id %> 有了新评论
<%= url_for(namespace_project_commit_url(@note.project.namespace, @note.project, id: @commit.id, anchor: "note_#{@note.id}")) %>
-Author: <%= @note.author_name %>
+作者: <%= @note.author_name %>
<%= @note.note %>
diff --git a/app/views/notify/note_issue_email.text.erb b/app/views/notify/note_issue_email.text.erb
index e33cbcd70f2..21069e30958 100644
--- a/app/views/notify/note_issue_email.text.erb
+++ b/app/views/notify/note_issue_email.text.erb
@@ -1,9 +1,9 @@
-New comment for Issue <%= @issue.iid %>
+问题 <%= @issue.iid %> 有了新评论
<%= url_for(namespace_project_issue_url(@issue.project.namespace, @issue.project, @issue, anchor: "note_#{@note.id}")) %>
-Author: <%= @note.author_name %>
+作者: <%= @note.author_name %>
<%= @note.note %>
diff --git a/app/views/notify/note_merge_request_email.html.haml b/app/views/notify/note_merge_request_email.html.haml
index 65f0e4c4068..fe0c8604257 100644
--- a/app/views/notify/note_merge_request_email.html.haml
+++ b/app/views/notify/note_merge_request_email.html.haml
@@ -1,6 +1,6 @@
- if @note.diff_file_name
%p.details
- New comment on diff for
+ 差异评论
= link_to @note.diff_file_name, @target_url
\:
diff --git a/app/views/notify/note_merge_request_email.text.erb b/app/views/notify/note_merge_request_email.text.erb
index 1d1411992a6..77071f86912 100644
--- a/app/views/notify/note_merge_request_email.text.erb
+++ b/app/views/notify/note_merge_request_email.text.erb
@@ -1,4 +1,4 @@
-New comment for Merge Request <%= @merge_request.iid %>
+合并请求 <%= @merge_request.iid %> 有了新评论
<%= url_for(namespace_project_merge_request_url(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request, anchor: "note_#{@note.id}")) %>
diff --git a/app/views/notify/project_access_granted_email.html.haml b/app/views/notify/project_access_granted_email.html.haml
index dfc30a2d360..49cf9f48c23 100644
--- a/app/views/notify/project_access_granted_email.html.haml
+++ b/app/views/notify/project_access_granted_email.html.haml
@@ -1,5 +1,5 @@
%p
- = "You have been granted #{@project_member.human_access} access to project"
+ = "你被授权为 #{@project_member.human_access} 身份访问项目"
%p
= link_to namespace_project_url(@project.namespace, @project) do
= @project.name_with_namespace
diff --git a/app/views/notify/project_access_granted_email.text.erb b/app/views/notify/project_access_granted_email.text.erb
index 68eb1611ba7..7f63b1c3a6c 100644
--- a/app/views/notify/project_access_granted_email.text.erb
+++ b/app/views/notify/project_access_granted_email.text.erb
@@ -1,4 +1,4 @@
-You have been granted <%= @project_member.human_access %> access to project <%= @project.name_with_namespace %>
+你被授权为 <%= @project_member.human_access %> 身份访问项目 <%= @project.name_with_namespace %>
<%= url_for(namespace_project_url(@project.namespace, @project)) %>
diff --git a/app/views/notify/project_invite_accepted_email.html.haml b/app/views/notify/project_invite_accepted_email.html.haml
index 7e58d30b10a..ae214e816d2 100644
--- a/app/views/notify/project_invite_accepted_email.html.haml
+++ b/app/views/notify/project_invite_accepted_email.html.haml
@@ -1,6 +1,6 @@
%p
- #{@project_member.invite_email}, now known as
+ #{@project_member.invite_email},现在以
#{link_to @project_member.user.name, user_url(@project_member.user)},
- has accepted your invitation to join project
- #{link_to @project.name_with_namespace, namespace_project_url(@project.namespace, @project)}.
+ 账户接受邀请加入项目
+ #{link_to @project.name_with_namespace, namespace_project_url(@project.namespace, @project)}。
diff --git a/app/views/notify/project_invite_accepted_email.text.erb b/app/views/notify/project_invite_accepted_email.text.erb
index fcbe752114d..50215516dd3 100644
--- a/app/views/notify/project_invite_accepted_email.text.erb
+++ b/app/views/notify/project_invite_accepted_email.text.erb
@@ -1,3 +1,3 @@
-<%= @project_member.invite_email %>, now known as <%= @project_member.user.name %>, has accepted your invitation to join project <%= @project.name_with_namespace %>.
+<%= @project_member.invite_email %>,现在以 <%= @project_member.user.name %>, 账户接受邀请加入项目 <%= @project.name_with_namespace %>。
<%= namespace_project_url(@project.namespace, @project) %>
diff --git a/app/views/notify/project_invite_declined_email.html.haml b/app/views/notify/project_invite_declined_email.html.haml
index c2d7e6f6e3a..733844d8be4 100644
--- a/app/views/notify/project_invite_declined_email.html.haml
+++ b/app/views/notify/project_invite_declined_email.html.haml
@@ -1,5 +1,5 @@
%p
#{@invite_email}
- has declined your invitation to join project
- #{link_to @project.name_with_namespace, namespace_project_url(@project.namespace, @project)}.
+ 拒绝接受邀请加入项目
+ #{link_to @project.name_with_namespace, namespace_project_url(@project.namespace, @project)}。
diff --git a/app/views/notify/project_invite_declined_email.text.erb b/app/views/notify/project_invite_declined_email.text.erb
index 484687fa51c..f65dd952d7f 100644
--- a/app/views/notify/project_invite_declined_email.text.erb
+++ b/app/views/notify/project_invite_declined_email.text.erb
@@ -1,3 +1,3 @@
-<%= @invite_email %> has declined your invitation to join project <%= @project.name_with_namespace %>.
+<%= @invite_email %> 拒绝接受邀请加入项目 <%= @project.name_with_namespace %>。
<%= namespace_project_url(@project.namespace, @project) %>
diff --git a/app/views/notify/project_member_invited_email.html.haml b/app/views/notify/project_member_invited_email.html.haml
index 79eb89616de..2a5cffbadfe 100644
--- a/app/views/notify/project_member_invited_email.html.haml
+++ b/app/views/notify/project_member_invited_email.html.haml
@@ -1,13 +1,12 @@
%p
- You have been invited
+ 你被
- if inviter = @project_member.created_by
- by
= link_to inviter.name, user_url(inviter)
- to join project
+ 邀请加入项目
= link_to @project.name_with_namespace, namespace_project_url(@project.namespace, @project)
- as #{@project_member.human_access}.
+ 身份是 #{@project_member.human_access}。
%p
- = link_to 'Accept invitation', invite_url(@token)
- or
- = link_to 'decline', decline_invite_url(@token)
+ = link_to '接受邀请', invite_url(@token)
+ 或者
+ = link_to '拒绝', decline_invite_url(@token)
diff --git a/app/views/notify/project_member_invited_email.text.erb b/app/views/notify/project_member_invited_email.text.erb
index e0706272115..d5676746631 100644
--- a/app/views/notify/project_member_invited_email.text.erb
+++ b/app/views/notify/project_member_invited_email.text.erb
@@ -1,4 +1,4 @@
-You have been invited <%= "by #{@project_member.created_by.name} " if @project_member.created_by %>to join project <%= @project.name_with_namespace %> as <%= @project_member.human_access %>.
+你被<%= " #{@project_member.created_by.name} " if @project_member.created_by %>邀请加入到项目 <%= @project.name_with_namespace %> 身份是 <%= @project_member.human_access %>。
-Accept invitation: <%= invite_url(@token) %>
-Decline invitation: <%= decline_invite_url(@token) %>
+接受邀请: <%= invite_url(@token) %>
+拒绝邀请: <%= decline_invite_url(@token) %>
diff --git a/app/views/notify/project_was_moved_email.html.haml b/app/views/notify/project_was_moved_email.html.haml
index 87b3ff7f0b3..bda3b6a1fa5 100644
--- a/app/views/notify/project_was_moved_email.html.haml
+++ b/app/views/notify/project_was_moved_email.html.haml
@@ -1,15 +1,15 @@
%p
- Project #{@old_path_with_namespace} was moved to another location
+ 项目 #{@old_path_with_namespace} 被转移到另一个地址
%p
- The project is now located under
+ 项目现在定位到
= link_to namespace_project_url(@project.namespace, @project) do
= @project.name_with_namespace
%p
- To update the remote url in your local repository run (for ssh):
+ 要更新本地仓库的远程地址请运行 (ssh):
%p{ style: "background: #f5f5f5; padding:10px; border:1px solid #ddd" }
git remote set-url origin #{@project.ssh_url_to_repo}
%p
- or for http(s):
+ 或 http(s):
%p{ style: "background: #f5f5f5; padding:10px; border:1px solid #ddd" }
git remote set-url origin #{@project.http_url_to_repo}
%br
diff --git a/app/views/notify/project_was_moved_email.text.erb b/app/views/notify/project_was_moved_email.text.erb
index b2c5f71e465..e1e47766550 100644
--- a/app/views/notify/project_was_moved_email.text.erb
+++ b/app/views/notify/project_was_moved_email.text.erb
@@ -1,10 +1,10 @@
-Project <%= @old_path_with_namespace %> was moved to another location
+项目 <%= @old_path_with_namespace %> 被转移到另一个地址
-The project is now located under
+项目现在定位到
<%= namespace_project_url(@project.namespace, @project) %>
-To update the remote url in your local repository run (for ssh):
+要更新本地仓库的远程地址请运行 (ssh):
git remote set-url origin <%= @project.ssh_url_to_repo %>
-or for http(s):
+或 http(s):
git remote set-url origin <%= @project.http_url_to_repo %>
diff --git a/app/views/notify/repository_push_email.html.haml b/app/views/notify/repository_push_email.html.haml
index f2e405b14fd..b597d0f97b5 100644
--- a/app/views/notify/repository_push_email.html.haml
+++ b/app/views/notify/repository_push_email.html.haml
@@ -1,27 +1,27 @@
%h3
#{@message.author_name} #{@message.action_name} #{@message.ref_type} #{@message.ref_name}
- at #{link_to(@message.project_name_with_namespace, namespace_project_url(@message.project_namespace, @message.project))}
+ 在 #{link_to(@message.project_name_with_namespace, namespace_project_url(@message.project_namespace, @message.project))}
- if @message.compare
- if @message.reverse_compare?
%p
- %strong WARNING:
- The push did not contain any new commits, but force pushed to delete the commits and changes below.
+ %strong 警告:
+ 此推送不包含任何提交,但强制推送会删除下面的提交和变更。
%h4
- = @message.reverse_compare? ? "Deleted commits:" : "Commits:"
+ = @message.reverse_compare? ? "删除的提交:" : "提交:"
%ul
- @message.commits.each do |commit|
%li
%strong #{link_to(commit.short_id, namespace_project_commit_url(@message.project_namespace, @message.project, commit))}
%div
- %span by #{commit.author_name}
- %i at #{commit.committed_date.to_s(:iso8601)}
+ %span 由 #{commit.author_name}
+ %i 在 #{commit.committed_date.to_s(:iso8601)}
%pre.commit-message
= commit.safe_message
- %h4 #{pluralize @message.diffs_count, "changed file"}:
+ %h4 #{pluralize @message.diffs_count, "个修改的文件", "个修改的文件"}:
%ul
- @message.diffs.each_with_index do |diff, i|
@@ -43,14 +43,14 @@
= diff.new_path
- unless @message.disable_diffs?
- %h4 Changes:
+ %h4 变更:
- @message.diffs.each_with_index do |diff, i|
%li{id: "diff-#{i}"}
%a{href: @message.target_url + "#diff-#{i}"}
- if diff.deleted_file
%strong
= diff.old_path
- deleted
+ 已删除
- elsif diff.renamed_file
%strong
= diff.old_path
@@ -65,4 +65,4 @@
%br
- if @message.compare_timeout
- %h5 Huge diff. To prevent performance issues changes are hidden
+ %h5 巨大差异。因为性能原因隐藏问题变更
diff --git a/app/views/notify/repository_push_email.text.haml b/app/views/notify/repository_push_email.text.haml
index 53869e36b28..8b9817ac724 100644
--- a/app/views/notify/repository_push_email.text.haml
+++ b/app/views/notify/repository_push_email.text.haml
@@ -1,19 +1,19 @@
-#{@message.author_name} #{@message.action_name} #{@message.ref_type} #{@message.ref_name} at #{@message.project_name_with_namespace}
+#{@message.author_name} #{@message.action_name} #{@message.ref_type} #{@message.ref_name} 在 #{@message.project_name_with_namespace}
- if @message.compare
\
\
- if @message.reverse_compare?
- WARNING: The push did not contain any new commits, but force pushed to delete the commits and changes below.
+ 警告:此推送不包含任何提交,但强制推送会删除下面的提交和变更。
\
\
- = @message.reverse_compare? ? "Deleted commits:" : "Commits:"
+ = @message.reverse_compare? ? "删除的提交:" : "提交:"
- @message.commits.each do |commit|
- #{commit.short_id} by #{commit.author_name} at #{commit.committed_date.to_s(:iso8601)}
+ #{commit.short_id} by #{commit.author_name} 在 #{commit.committed_date.to_s(:iso8601)}
#{commit.safe_message}
\- - - - -
\
\
- #{pluralize @message.diffs_count, "changed file"}:
+ #{pluralize @message.diffs_count, "个修改的文件", "个修改的文件"}:
\
- @message.diffs.each do |diff|
- if diff.deleted_file
@@ -27,12 +27,12 @@
- unless @message.disable_diffs?
\
\
- Changes:
+ 变更:
- @message.diffs.each do |diff|
\
\=====================================
- if diff.deleted_file
- #{diff.old_path} deleted
+ #{diff.old_path} 已删除
- elsif diff.renamed_file
#{diff.old_path} → #{diff.new_path}
- else
@@ -42,8 +42,8 @@
- if @message.compare_timeout
\
\
- Huge diff. To prevent performance issues it was hidden
+ 巨大差异。因为性能原因隐藏问题变更
- if @message.target_url
\
\
- View it on GitLab: #{@message.target_url}
+ 在 GitLab 上查看: #{@message.target_url}
diff --git a/app/views/profiles/keys/_key_details.html.haml b/app/views/profiles/keys/_key_details.html.haml
index dd7615400dc..41be50f806c 100644
--- a/app/views/profiles/keys/_key_details.html.haml
+++ b/app/views/profiles/keys/_key_details.html.haml
@@ -3,21 +3,21 @@
.col-md-4
.panel.panel-default
.panel-heading
- SSH Key
+ SSH 密钥
%ul.well-list
%li
- %span.light Title:
+ %span.light 标题:
%strong= @key.title
%li
- %span.light Created on:
+ %span.light 创建时间:
%strong= @key.created_at.to_s(:medium)
.col-md-8
%p
- %span.light Fingerprint:
+ %span.light 指纹:
%code.key-fingerprint= @key.fingerprint
%pre.well-pre
= @key.key
.col-md-12
.pull-right
- = link_to 'Remove', path_to_key(@key, is_admin), data: {confirm: 'Are you sure?'}, method: :delete, class: "btn btn-remove delete-key"
+ = link_to '删除', path_to_key(@key, is_admin), data: {confirm: '确定要继续?'}, method: :delete, class: "btn btn-remove delete-key"
diff --git a/app/views/profiles/keys/show.html.haml b/app/views/profiles/keys/show.html.haml
index 89f6f01581a..459aa294674 100644
--- a/app/views/profiles/keys/show.html.haml
+++ b/app/views/profiles/keys/show.html.haml
@@ -1,2 +1,2 @@
-- page_title @key.title, "SSH Keys"
+- page_title @key.title, "SSH 密钥"
= render "key_details"
diff --git a/app/views/profiles/notifications/update.js.haml b/app/views/profiles/notifications/update.js.haml
index 84c6ab25599..0ce57b2d36b 100644
--- a/app/views/profiles/notifications/update.js.haml
+++ b/app/views/profiles/notifications/update.js.haml
@@ -1,6 +1,6 @@
- if @saved
:plain
- new Flash("Notification settings saved", "notice")
+ new Flash("通知设置已保存", "notice")
- else
:plain
- new Flash("Failed to save new settings", "alert")
+ new Flash("保存新设置失败", "alert")
diff --git a/app/views/profiles/passwords/new.html.haml b/app/views/profiles/passwords/new.html.haml
index d165f758c81..d0719e678b9 100644
--- a/app/views/profiles/passwords/new.html.haml
+++ b/app/views/profiles/passwords/new.html.haml
@@ -1,12 +1,12 @@
-- page_title "New Password"
-- header_title "New Password"
-%h3.page-title Setup new password
+- page_title "新密码"
+- header_title "新密码"
+%h3.page-title 设置新密码
%hr
= form_for @user, url: profile_password_path, method: :post, html: { class: 'form-horizontal '} do |f|
%p.slead
- Please set a new password before proceeding.
+ 请立即设置一个新密码。
%br
- After a successful password update you will be redirected to login screen.
+ 密码被成功修改后将会重定向到登录页面。
-if @user.errors.any?
.alert.alert-danger
%ul
@@ -15,14 +15,14 @@
- unless @user.password_automatically_set?
.form-group
- = f.label :current_password, class: 'control-label'
+ = f.label :current_password, '当前密码', class: 'control-label'
.col-sm-10= f.password_field :current_password, required: true, class: 'form-control'
.form-group
- = f.label :password, class: 'control-label'
+ = f.label :password, '密码', class: 'control-label'
.col-sm-10= f.password_field :password, required: true, class: 'form-control'
.form-group
- = f.label :password_confirmation, class: 'control-label'
+ = f.label :password_confirmation, '确认密码', class: 'control-label'
.col-sm-10
= f.password_field :password_confirmation, required: true, class: 'form-control'
.form-actions
- = f.submit 'Set new password', class: "btn btn-create"
+ = f.submit '设置新密码', class: "btn btn-create"
diff --git a/app/views/profiles/two_factor_auths/_codes.html.haml b/app/views/profiles/two_factor_auths/_codes.html.haml
index 43b58be7f98..002c246d8bb 100644
--- a/app/views/profiles/two_factor_auths/_codes.html.haml
+++ b/app/views/profiles/two_factor_auths/_codes.html.haml
@@ -1,8 +1,8 @@
%p.slead
- Should you ever lose your phone, each of these recovery codes can be used one
- time each to regain access to your account. Please save them in a safe place, or you
- %b will
- lose access to your account.
+ 如果丢失了手机,可以使用下面的恢复代码重新访问你的账户。
+ 请将其保存到安全的地方,否则你
+ %b 将
+ 会无法访问你的账户。
.codes.well
%ul
@@ -10,4 +10,4 @@
%li
%span.monospace= code
-= link_to 'Proceed', profile_account_path, class: 'btn btn-success'
+= link_to '继续', profile_account_path, class: 'btn btn-success'
diff --git a/app/views/profiles/two_factor_auths/codes.html.haml b/app/views/profiles/two_factor_auths/codes.html.haml
index addf356697a..2fd3c92aafa 100644
--- a/app/views/profiles/two_factor_auths/codes.html.haml
+++ b/app/views/profiles/two_factor_auths/codes.html.haml
@@ -1,5 +1,5 @@
-- page_title 'Recovery Codes', 'Two-factor Authentication'
+- page_title '恢复代码', '两步验证'
-%h3.page-title Two-factor Authentication Recovery codes
+%h3.page-title 两步验证恢复代码
%hr
= render 'codes'
diff --git a/app/views/profiles/two_factor_auths/create.html.haml b/app/views/profiles/two_factor_auths/create.html.haml
index e330aadac13..d1131307502 100644
--- a/app/views/profiles/two_factor_auths/create.html.haml
+++ b/app/views/profiles/two_factor_auths/create.html.haml
@@ -1,6 +1,6 @@
-- page_title 'Two-factor Authentication', 'Account'
+- page_title '两步验证', '账号'
.alert.alert-success
- Congratulations! You have enabled Two-factor Authentication!
+ 恭喜!已启用两步验证!
= render 'codes'
diff --git a/app/views/profiles/update_username.js.haml b/app/views/profiles/update_username.js.haml
index 249680bcab6..f1cd8d22526 100644
--- a/app/views/profiles/update_username.js.haml
+++ b/app/views/profiles/update_username.js.haml
@@ -1,6 +1,6 @@
- if @user.valid?
:plain
- new Flash("Username sucessfully changed", "notice")
+ new Flash("账号已成功修改", "notice")
- else
:plain
- new Flash("Username change failed - #{@user.errors.full_messages.first}", "alert")
+ new Flash("账号修改失败 - #{@user.errors.full_messages.first}", "alert")
diff --git a/app/views/projects/_activity.html.haml b/app/views/projects/_activity.html.haml
index 961b61d2e76..aa901c9edf0 100644
--- a/app/views/projects/_activity.html.haml
+++ b/app/views/projects/_activity.html.haml
@@ -1,7 +1,7 @@
.nav-block.activity-filter-block
- if current_user
.controls
- = link_to namespace_project_path(@project.namespace, @project, format: :atom, private_token: current_user.private_token), title: "Feed", class: 'btn rss-btn' do
+ = link_to namespace_project_path(@project.namespace, @project, format: :atom, private_token: current_user.private_token), title: "动态", class: 'btn rss-btn' do
%i.fa.fa-rss
= render 'shared/event_filter'
diff --git a/app/views/projects/_bitbucket_import_modal.html.haml b/app/views/projects/_bitbucket_import_modal.html.haml
index 2987f6b5b22..f3af5a60496 100644
--- a/app/views/projects/_bitbucket_import_modal.html.haml
+++ b/app/views/projects/_bitbucket_import_modal.html.haml
@@ -3,11 +3,11 @@
.modal-content
.modal-header
%a.close{href: "#", "data-dismiss" => "modal"} ×
- %h3 Import projects from Bitbucket
+ %h3 从 Bitbucket 导入项目
.modal-body
- To enable importing projects from Bitbucket,
+ 要开启从 Bitbucket 导入项目,
- if current_user.admin?
- as administrator you need to configure
+ 作为管理员你需要配置
- else
- ask your GitLab administrator to configure
- == #{link_to 'OAuth integration', help_page_path("integration", "bitbucket")}.
+ 请求你的 GitLab 管理员去配置
+ == #{link_to 'OAuth 集成', help_page_path("integration", "bitbucket")}.
diff --git a/app/views/projects/_commit_button.html.haml b/app/views/projects/_commit_button.html.haml
index 640612ca433..395e8a6917c 100644
--- a/app/views/projects/_commit_button.html.haml
+++ b/app/views/projects/_commit_button.html.haml
@@ -1,6 +1,6 @@
.form-actions
- = button_tag 'Commit Changes', class: 'btn commit-btn js-commit-button btn-create'
- = link_to 'Cancel', cancel_path,
+ = button_tag '提交修改', class: 'btn commit-btn js-commit-button btn-create'
+ = link_to '取消', cancel_path,
class: 'btn btn-cancel', data: {confirm: leave_edit_message}
- unless can?(current_user, :push_code, @project)
diff --git a/app/views/projects/_find_file_link.html.haml b/app/views/projects/_find_file_link.html.haml
index 08e2fc48be7..dbb33090670 100644
--- a/app/views/projects/_find_file_link.html.haml
+++ b/app/views/projects/_find_file_link.html.haml
@@ -1,3 +1,3 @@
-= link_to namespace_project_find_file_path(@project.namespace, @project, @ref), class: 'btn btn-grouped shortcuts-find-file', rel: 'nofollow' do
- = icon('search')
- %span Find File
+= link_to namespace_project_find_file_path(@project.namespace, @project, @ref), class: 'btn btn-grouped shortcuts-find-file', rel: 'nofollow' do
+ = icon('search')
+ %span Find File
diff --git a/app/views/projects/_github_import_modal.html.haml b/app/views/projects/_github_import_modal.html.haml
index 46ad1559356..5da2b284dcc 100644
--- a/app/views/projects/_github_import_modal.html.haml
+++ b/app/views/projects/_github_import_modal.html.haml
@@ -3,11 +3,11 @@
.modal-content
.modal-header
%a.close{href: "#", "data-dismiss" => "modal"} ×
- %h3 Import projects from GitHub
+ %h3 从 GitHub 导入项目
.modal-body
- To enable importing projects from GitHub,
+ 要开启从 GitHub 导入项目,
- if current_user.admin?
- as administrator you need to configure
+ 作为管理员你需要配置
- else
- ask your Gitlab administrator to configure
- == #{link_to 'OAuth integration', help_page_path("integration", "github")}.
+ 请求你的 GitLab 管理员去配置
+ == #{link_to 'OAuth 集成', help_page_path("integration", "github")}.
diff --git a/app/views/projects/_gitlab_import_modal.html.haml b/app/views/projects/_gitlab_import_modal.html.haml
index 377cf0187b8..bbc42d06c38 100644
--- a/app/views/projects/_gitlab_import_modal.html.haml
+++ b/app/views/projects/_gitlab_import_modal.html.haml
@@ -3,11 +3,11 @@
.modal-content
.modal-header
%a.close{href: "#", "data-dismiss" => "modal"} ×
- %h3 Import projects from GitLab.com
+ %h3 从 GitLab.com 导入项目
.modal-body
- To enable importing projects from GitLab.com,
+ 要开启从 GitLab.com 导入项目,
- if current_user.admin?
- as administrator you need to configure
+ 作为管理员你需要配置
- else
- ask your GitLab administrator to configure
- == #{link_to 'OAuth integration', help_page_path("integration", "gitlab")}.
+ 请求你的 GitLab 管理员去配置
+ == #{link_to 'OAuth 集成', help_page_path("integration", "gitlab")}.
diff --git a/app/views/projects/_home_panel.html.haml b/app/views/projects/_home_panel.html.haml
index 514cbfa339d..d240508b64f 100644
--- a/app/views/projects/_home_panel.html.haml
+++ b/app/views/projects/_home_panel.html.haml
@@ -33,12 +33,12 @@
- if can_edit
%li
= link_to edit_project_path(@project) do
- Edit Project
+ 编辑项目
- if access
%li
= link_to leave_namespace_project_project_members_path(@project.namespace, @project),
- data: { confirm: leave_project_message(@project) }, method: :delete, title: 'Leave project' do
- Leave Project
+ data: { confirm: leave_project_message(@project) }, method: :delete, title: '离开项目' do
+ 离开项目
.project-repo-buttons
.split-one.count-buttons
diff --git a/app/views/projects/_last_commit.html.haml b/app/views/projects/_last_commit.html.haml
index 386d72e7787..7e794a38bc4 100644
--- a/app/views/projects/_last_commit.html.haml
+++ b/app/views/projects/_last_commit.html.haml
@@ -6,7 +6,7 @@
= ci_status_label(ci_commit)
= link_to commit.short_id, namespace_project_commit_path(project.namespace, project, commit), class: "commit_short_id"
- = link_to_gfm commit.title, namespace_project_commit_path(project.namespace, project, commit), class: "commit-row-message"
- &middot;
- #{time_ago_with_tooltip(commit.committed_date, skip_js: true)} by
= commit_author_link(commit, avatar: true, size: 24)
+ 在 #{time_ago_with_tooltip(commit.committed_date, skip_js: true)}提交了
+ &middot;
+ = link_to_gfm commit.title, namespace_project_commit_path(project.namespace, project, commit), class: "commit-row-message"
diff --git a/app/views/projects/_last_push.html.haml b/app/views/projects/_last_push.html.haml
index f0a3e416db7..9cd8bd88306 100644
--- a/app/views/projects/_last_push.html.haml
+++ b/app/views/projects/_last_push.html.haml
@@ -4,12 +4,13 @@
.gray-content-block.top-block.clear-block.hidden-xs
.event-last-push
.event-last-push-text
- %span You pushed to
+ 在
+ #{time_ago_with_tooltip(event.created_at)}
+ %span 推送到
= link_to namespace_project_commits_path(event.project.namespace, event.project, event.ref_name) do
%strong= event.ref_name
- branch
- #{time_ago_with_tooltip(event.created_at)}
+ 分支
.pull-right
- = link_to new_mr_path_from_push_event(event), title: "New Merge Request", class: "btn btn-info btn-sm" do
- Create Merge Request
+ = link_to new_mr_path_from_push_event(event), title: "新合并请求", class: "btn btn-info btn-sm" do
+ 创建合并请求
diff --git a/app/views/projects/_md_preview.html.haml b/app/views/projects/_md_preview.html.haml
index 1fb37ef6621..9cac4d7b26a 100644
--- a/app/views/projects/_md_preview.html.haml
+++ b/app/views/projects/_md_preview.html.haml
@@ -3,10 +3,10 @@
%ul.nav-links
%li.active
%a.js-md-write-button(href="#md-write-holder" tabindex="-1")
- Write
+ 编写
%li
%a.js-md-preview-button(href="#md-preview-holder" tabindex="-1")
- Preview
+ 预览
%div
.md-write-holder
@@ -18,8 +18,8 @@
%div.referenced-users.hide
%span
= icon('exclamation-triangle')
- You are about to add
+ 你添加了
%strong
%span.js-referenced-users-count 0
- people
- to the discussion. Proceed with caution.
+ 人
+ 到此讨论。请谨慎行事。
diff --git a/app/views/projects/_readme.html.haml b/app/views/projects/_readme.html.haml
index d1191928d4f..0ab802fa282 100644
--- a/app/views/projects/_readme.html.haml
+++ b/app/views/projects/_readme.html.haml
@@ -9,14 +9,13 @@
- else
.gray-content-block.second-block.center
%h3.page-title
- This project does not have README yet
+ 此项目还未有 README 文件
- if can?(current_user, :push_code, @project)
%p
- A
%code README
- file contains information about other files in a repository and is commonly
- distributed with computer software, forming part of its documentation.
+ 文件包含有版本仓库中其他文件的信息,
+ 也在电脑软件中作为格式化文档的一部分普遍存在。
%p
- We recommend you to
- = link_to "add README", new_readme_path, class: 'underlined-link'
- file to the repository and GitLab will render it here instead of this message.
+ 建议
+ = link_to "增加 README", new_readme_path, class: 'underlined-link'
+ 文件到版本仓库,GitLab 将会载入其内容显示在这里,以替换掉此信息。
diff --git a/app/views/projects/_zen.html.haml b/app/views/projects/_zen.html.haml
index e701253d7de..0f0ae451444 100644
--- a/app/views/projects/_zen.html.haml
+++ b/app/views/projects/_zen.html.haml
@@ -7,6 +7,6 @@
= text_area_tag attr, nil, class: classes
%a.js-zen-enter(tabindex="-1" href="#")
= icon('expand')
- Edit in fullscreen
+ 全屏编辑
%a.js-zen-leave(tabindex="-1" href="#")
= icon('compress')
diff --git a/app/views/projects/activity.html.haml b/app/views/projects/activity.html.haml
index 69fa4ad37c4..1595f9a68d8 100644
--- a/app/views/projects/activity.html.haml
+++ b/app/views/projects/activity.html.haml
@@ -1,5 +1,5 @@
-- page_title "Activity"
-- header_title project_title(@project, "Activity", activity_project_path(@project))
+- page_title "活动"
+- header_title project_title(@project, "活动", activity_project_path(@project))
= render 'projects/last_push'
diff --git a/app/views/projects/artifacts/browse.html.haml b/app/views/projects/artifacts/browse.html.haml
index 84034c8bf16..563bde47ed9 100644
--- a/app/views/projects/artifacts/browse.html.haml
+++ b/app/views/projects/artifacts/browse.html.haml
@@ -1,4 +1,4 @@
-- page_title 'Artifacts', "#{@build.name} (##{@build.id})", 'Builds'
+- page_title '附件', "#{@build.name} (##{@build.id})", '构建'
= render 'projects/builds/header_title'
.top-block.gray-content-block.clearfix
@@ -6,17 +6,17 @@
= link_to download_namespace_project_build_artifacts_path(@project.namespace, @project, @build),
class: 'btn btn-default download' do
= icon('download')
- Download artifacts archive
+ 下载附件打包
.tree-holder
%div.tree-content-holder
%table.table.tree-table
%thead
%tr
- %th Name
- %th Size
+ %th 名称
+ %th 大小
= render partial: 'tree_directory', collection: @entry.directories(parent: true), as: :directory
= render partial: 'tree_file', collection: @entry.files, as: :file
- if @entry.empty?
- .center Empty
+ .center 空
diff --git a/app/views/projects/blob/_actions.html.haml b/app/views/projects/blob/_actions.html.haml
index cdac50f7a8d..bba3cd7274c 100644
--- a/app/views/projects/blob/_actions.html.haml
+++ b/app/views/projects/blob/_actions.html.haml
@@ -1,17 +1,17 @@
.btn-group.tree-btn-group
- = link_to 'Raw', namespace_project_raw_path(@project.namespace, @project, @id),
+ = link_to '原文件', namespace_project_raw_path(@project.namespace, @project, @id),
class: 'btn btn-sm', target: '_blank'
-# only show normal/blame view links for text files
- if blob_text_viewable?(@blob)
- if current_page? namespace_project_blame_path(@project.namespace, @project, @id)
- = link_to 'Normal View', namespace_project_blob_path(@project.namespace, @project, @id),
+ = link_to '普通视图', namespace_project_blob_path(@project.namespace, @project, @id),
class: 'btn btn-sm'
- else
- = link_to 'Blame', namespace_project_blame_path(@project.namespace, @project, @id),
+ = link_to '审查', namespace_project_blame_path(@project.namespace, @project, @id),
class: 'btn btn-sm' unless @blob.empty?
- = link_to 'History', namespace_project_commits_path(@project.namespace, @project, @id),
+ = link_to '历史', namespace_project_commits_path(@project.namespace, @project, @id),
class: 'btn btn-sm'
- = link_to 'Permalink', namespace_project_blob_path(@project.namespace, @project,
+ = link_to '永久链接', namespace_project_blob_path(@project.namespace, @project,
tree_join(@commit.sha, @path)), class: 'btn btn-sm'
- if current_user
diff --git a/app/views/projects/blob/_download.html.haml b/app/views/projects/blob/_download.html.haml
index 7908fcae3de..5cf08bd4f62 100644
--- a/app/views/projects/blob/_download.html.haml
+++ b/app/views/projects/blob/_download.html.haml
@@ -4,4 +4,4 @@
%h1.light
%i.fa.fa-download
%h4
- Download (#{number_to_human_size blob_size(blob)})
+ 下载 (#{number_to_human_size blob_size(blob)})
diff --git a/app/views/projects/blob/_header_title.html.haml b/app/views/projects/blob/_header_title.html.haml
index 78c5ef20a5f..eb679f6bb53 100644
--- a/app/views/projects/blob/_header_title.html.haml
+++ b/app/views/projects/blob/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Files", project_files_path(@project))
+- header_title project_title(@project, "文件", project_files_path(@project))
diff --git a/app/views/projects/blob/_text.html.haml b/app/views/projects/blob/_text.html.haml
index d09cd73558c..8fba36f646d 100644
--- a/app/views/projects/blob/_text.html.haml
+++ b/app/views/projects/blob/_text.html.haml
@@ -7,4 +7,4 @@
= render 'shared/file_highlight', blob: blob
- else
.file-content.code
- .nothing-here-block Empty file
+ .nothing-here-block 空文件
diff --git a/app/views/projects/blob/_upload.html.haml b/app/views/projects/blob/_upload.html.haml
index b1f50eb5f34..72dd4a88c42 100644
--- a/app/views/projects/blob/_upload.html.haml
+++ b/app/views/projects/blob/_upload.html.haml
@@ -9,8 +9,8 @@
.dropzone
.dropzone-previews.blob-upload-dropzone-previews
%p.dz-message.light
- Attach a file by drag &amp; drop or
- = link_to 'click to upload', '#', class: "markdown-selector"
+ 拖放文件到此处或者
+ = link_to '点击上传', '#', class: "markdown-selector"
%br
.dropzone-alerts{class: "alert alert-danger data", style: "display:none"}
@@ -18,7 +18,7 @@
.form-actions
= button_tag button_title, class: 'btn btn-small btn-create btn-upload-file', id: 'submit-all'
- = link_to "Cancel", '#', class: "btn btn-cancel", "data-dismiss" => "modal"
+ = link_to "取消", '#', class: "btn btn-cancel", "data-dismiss" => "modal"
- unless can?(current_user, :push_code, @project)
.inline.prepend-left-10
diff --git a/app/views/projects/blob/edit.html.haml b/app/views/projects/blob/edit.html.haml
index effcce5a1c4..70d8009eb2b 100644
--- a/app/views/projects/blob/edit.html.haml
+++ b/app/views/projects/blob/edit.html.haml
@@ -1,4 +1,4 @@
-- page_title "Edit", @blob.path, @ref
+- page_title "编辑", @blob.path, @ref
= render "header_title"
.file-editor
@@ -6,7 +6,7 @@
%li.active
= link_to '#editor' do
= icon('edit')
- Edit File
+ 编辑文件
%li
= link_to '#preview', 'data-preview-url' => namespace_project_preview_blob_path(@project.namespace, @project, @id) do
diff --git a/app/views/projects/blob/preview.html.haml b/app/views/projects/blob/preview.html.haml
index 541dc96c45f..c7f1c9f8c61 100644
--- a/app/views/projects/blob/preview.html.haml
+++ b/app/views/projects/blob/preview.html.haml
@@ -22,4 +22,4 @@
%td.new_line.diff-line-num
%td.line_content{class: "#{line.type}"}= diff_line_content(line.text)
- else
- .nothing-here-block No changes.
+ .nothing-here-block 没有修改。
diff --git a/app/views/projects/blob/show.html.haml b/app/views/projects/blob/show.html.haml
index 6988039b6c7..7439c3b5126 100644
--- a/app/views/projects/blob/show.html.haml
+++ b/app/views/projects/blob/show.html.haml
@@ -9,5 +9,5 @@
- if can_edit_blob?(@blob)
= render 'projects/blob/remove'
- - title = "Replace #{@blob.name}"
- = render 'projects/blob/upload', title: title, placeholder: title, button_title: 'Replace file', form_path: namespace_project_update_blob_path(@project.namespace, @project, @id), method: :put
+ - title = "替换 #{@blob.name}"
+ = render 'projects/blob/upload', title: title, placeholder: title, button_title: '替换文件', form_path: namespace_project_update_blob_path(@project.namespace, @project, @id), method: :put
diff --git a/app/views/projects/branches/_branch.html.haml b/app/views/projects/branches/_branch.html.haml
index 76a823d3828..fadb13c3616 100644
--- a/app/views/projects/branches/_branch.html.haml
+++ b/app/views/projects/branches/_branch.html.haml
@@ -9,32 +9,32 @@
%span.item-title.str-truncated= branch.name
&nbsp;
- if branch.name == @repository.root_ref
- %span.label.label-primary default
+ %span.label.label-primary 默认
- elsif @repository.merged_to_root_ref? branch.name
- %span.label.label-info.has_tooltip(title="Merged into #{@repository.root_ref}")
- merged
+ %span.label.label-info.has_tooltip(title="合并到 #{@repository.root_ref}")
+ 已合并的
- if @project.protected_branch? branch.name
%span.label.label-success
%i.fa.fa-lock
- protected
+ 保护的
.controls.hidden-xs
- if create_mr_button?(@repository.root_ref, branch.name)
= link_to create_mr_path(@repository.root_ref, branch.name), class: 'btn btn-grouped btn-xs' do
= icon('plus')
- Merge Request
+ 合并请求
- if branch.name != @repository.root_ref
- = link_to namespace_project_compare_index_path(@project.namespace, @project, from: @repository.root_ref, to: branch.name), class: 'btn btn-grouped btn-xs', method: :post, title: "Compare" do
+ = link_to namespace_project_compare_index_path(@project.namespace, @project, from: @repository.root_ref, to: branch.name), class: 'btn btn-grouped btn-xs', method: :post, title: "比较" do
= icon("exchange")
- Compare
+ 比较
- if can_remove_branch?(@project, branch.name)
- = link_to namespace_project_branch_path(@project.namespace, @project, branch.name), class: 'btn btn-grouped btn-xs btn-remove remove-row has_tooltip', title: "Delete branch", method: :delete, data: { confirm: "Deleting the '#{branch.name}' branch cannot be undone. Are you sure?", container: 'body' }, remote: true do
+ = link_to namespace_project_branch_path(@project.namespace, @project, branch.name), class: 'btn btn-grouped btn-xs btn-remove remove-row has_tooltip', title: "删除分支", method: :delete, data: { confirm: "删除 '#{branch.name}' 分支无法恢复。确定要继续么?", container: 'body' }, remote: true do
= icon("trash-o")
- if branch.name != @repository.root_ref
- .divergence-graph{ title: "#{number_commits_ahead} commits ahead, #{number_commits_behind} commits behind #{@repository.root_ref}" }
+ .divergence-graph{ title: "比 #{@repository.root_ref} 超前 #{number_commits_ahead} 次提交,落后 #{number_commits_behind} 次提交" }
.graph-side
.bar.bar-behind{ style: "width: #{number_commits_behind * bar_graph_width_factor}%" }
%span.count.count-behind= number_commits_behind
@@ -48,4 +48,4 @@
= render 'projects/branches/commit', commit: commit, project: @project
- else
%p
- Cant find HEAD commit for this branch
+ 无法在本分支找到 HEAD 提交
diff --git a/app/views/projects/branches/index.html.haml b/app/views/projects/branches/index.html.haml
index 7afea5a5049..32a24f53460 100644
--- a/app/views/projects/branches/index.html.haml
+++ b/app/views/projects/branches/index.html.haml
@@ -1,4 +1,4 @@
-- page_title "Branches"
+- page_title "分支"
= render "projects/commits/header_title"
= render "projects/commits/head"
.gray-content-block
@@ -6,26 +6,28 @@
- if can? current_user, :push_code, @project
= link_to new_namespace_project_branch_path(@project.namespace, @project), class: 'btn btn-create' do
= icon('plus')
- New branch
+ 新分支
&nbsp;
.dropdown.inline
%button.dropdown-toggle.btn{type: 'button', 'data-toggle' => 'dropdown'}
%span.light
- - if @sort.present?
- = @sort.humanize
+ - if params[:sort] == 'recently_updated'
+ = sort_title_recently_updated
+ - elsif params[:sort] == 'last_updated'
+ = sort_title_oldest_updated
- else
- Name
+ 名称
%b.caret
%ul.dropdown-menu
%li
= link_to namespace_project_branches_path(sort: nil) do
- Name
+ 名称
= link_to namespace_project_branches_path(sort: 'recently_updated') do
= sort_title_recently_updated
= link_to namespace_project_branches_path(sort: 'last_updated') do
= sort_title_oldest_updated
.oneline
- Protected branches can be managed in project settings
+ 在项目设置中保护的分支无法被合并
- unless @branches.empty?
%ul.content-list.all-branches
- @branches.each do |branch|
diff --git a/app/views/projects/branches/new.html.haml b/app/views/projects/branches/new.html.haml
index c659af6338c..c1023709afb 100644
--- a/app/views/projects/branches/new.html.haml
+++ b/app/views/projects/branches/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "New Branch"
+- page_title "新分支"
= render "projects/commits/header_title"
- if @error
@@ -6,23 +6,23 @@
%button{ type: "button", class: "close", "data-dismiss" => "alert"} &times;
= @error
%h3.page-title
- New Branch
+ 新分支
%hr
= form_tag namespace_project_branches_path, method: :post, id: "new-branch-form", class: "form-horizontal js-create-branch-form js-requires-input" do
.form-group
- = label_tag :branch_name, nil, class: 'control-label'
+ = label_tag :branch_name, '分支名称', class: 'control-label'
.col-sm-10
= text_field_tag :branch_name, params[:branch_name], required: true, tabindex: 1, autofocus: true, class: 'form-control js-branch-name'
.help-block.text-danger.js-branch-name-error
.form-group
- = label_tag :ref, 'Create from', class: 'control-label'
+ = label_tag :ref, '创建自', class: 'control-label'
.col-sm-10
= text_field_tag :ref, params[:ref] || @project.default_branch, required: true, tabindex: 2, class: 'form-control'
- .help-block Existing branch name, tag, or commit SHA
+ .help-block 已存在的分支名、标签或提交 SHA
.form-actions
- = button_tag 'Create branch', class: 'btn btn-create', tabindex: 3
- = link_to 'Cancel', namespace_project_branches_path(@project.namespace, @project), class: 'btn btn-cancel'
+ = button_tag '创建分支', class: 'btn btn-create', tabindex: 3
+ = link_to '取消', namespace_project_branches_path(@project.namespace, @project), class: 'btn btn-cancel'
:javascript
var availableRefs = #{@project.repository.ref_names.to_json};
diff --git a/app/views/projects/builds/_header_title.html.haml b/app/views/projects/builds/_header_title.html.haml
index 082dab1f5b0..d89c1b6c087 100644
--- a/app/views/projects/builds/_header_title.html.haml
+++ b/app/views/projects/builds/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Builds", project_builds_path(@project))
+- header_title project_title(@project, "构建", project_builds_path(@project))
diff --git a/app/views/projects/builds/show.html.haml b/app/views/projects/builds/show.html.haml
index b02aee3db21..2f85e363c9d 100644
--- a/app/views/projects/builds/show.html.haml
+++ b/app/views/projects/builds/show.html.haml
@@ -29,10 +29,10 @@
- if @build.retried?
%li.active
%a
- Build ##{@build.id}
+ 构建 ##{@build.id}
&middot;
%i.fa.fa-warning
- This build was retried.
+ 此构建已重试。
.gray-content-block.middle-block
.build-head
@@ -80,7 +80,7 @@
- if @build.erased?
.erased.alert.alert-warning
- erased_by = "by #{link_to @build.erased_by.name, user_path(@build.erased_by)}" if @build.erased_by
- Build has been erased #{erased_by.html_safe} #{time_ago_with_tooltip(@build.erased_at)}
+ 构建被 #{erased_by.html_safe} 在 #{time_ago_with_tooltip(@build.erased_at)}删除
- else
%pre.trace#build-trace
%code.bash
@@ -154,15 +154,15 @@
- if @build.trigger_request
.build-widget
%h4.title
- Trigger
+ 触发
%p
- %span.attr-name Token:
+ %span.attr-name 授权码:
#{@build.trigger_request.trigger.short_token}
- if @build.trigger_request.variables
%p
- %span.attr-name Variables:
+ %span.attr-name 变量:
%code
- @build.trigger_request.variables.each do |key, value|
@@ -170,32 +170,32 @@
.build-widget
%h4.title
- Commit
+ 提交
.pull-right
%small
= link_to @build.commit.short_sha, ci_status_path(@build.commit), class: "monospace"
%p
- %span.attr-name Branch:
+ %span.attr-name 分支:
= link_to @build.ref, namespace_project_commits_path(@project.namespace, @project, @build.ref)
%p
- %span.attr-name Author:
+ %span.attr-name 作者:
#{@build.commit.git_author_name}
%p
- %span.attr-name Message:
+ %span.attr-name 信息:
#{@build.commit.git_commit_message}
- if @build.tags.any?
.build-widget
%h4.title
- Tags
+ 标签
- @build.tag_list.each do |tag|
%span.label.label-primary
= tag
- if @builds.present?
.build-widget
- %h4.title #{pluralize(@builds.count(:id), "other build")} for
- = succeed ":" do
+ %h4.title 此提交还有 #{pluralize(@builds.count(:id), "次其他构建", "次其他构建")}
+ = succeed ":" do
= link_to @build.commit.short_sha, ci_status_path(@build.commit), class: "monospace"
%table.table.builds
- @builds.each_with_index do |build, i|
@@ -209,7 +209,7 @@
- else
%span ##{build.id}
- %td.status= build.status
+ %td.status= ci_status_zh(build.status)
:javascript
diff --git a/app/views/projects/buttons/_dropdown.html.haml b/app/views/projects/buttons/_dropdown.html.haml
index e7c85edff96..c4d4e640e52 100644
--- a/app/views/projects/buttons/_dropdown.html.haml
+++ b/app/views/projects/buttons/_dropdown.html.haml
@@ -7,39 +7,39 @@
%li
= link_to url_for_new_issue(@project, only_path: true) do
= icon('exclamation-circle fw')
- New issue
+ 新问题
- merge_project = can?(current_user, :create_merge_request, @project) ? @project : (current_user && current_user.fork_of(@project))
- if merge_project
%li
= link_to new_namespace_project_merge_request_path(merge_project.namespace, merge_project) do
= icon('tasks fw')
- New merge request
+ 新合并请求
- if can?(current_user, :create_snippet, @project)
%li
= link_to new_namespace_project_snippet_path(@project.namespace, @project) do
= icon('file-text-o fw')
- New snippet
+ 新代码片段
- if can?(current_user, :push_code, @project)
%li.divider
%li
= link_to namespace_project_new_blob_path(@project.namespace, @project, @project.default_branch || 'master') do
= icon('file fw')
- New file
+ 新文件
%li
= link_to new_namespace_project_branch_path(@project.namespace, @project) do
= icon('code-fork fw')
- New branch
+ 新分支
%li
= link_to new_namespace_project_tag_path(@project.namespace, @project) do
= icon('tags fw')
- New tag
+ 新标签
- elsif current_user && current_user.already_forked?(@project)
%li.divider
%li
= link_to namespace_project_new_blob_path(@project.namespace, @project, @project.default_branch || 'master') do
= icon('file fw')
- New file
+ 新文件
- elsif can?(current_user, :fork_project, @project)
%li.divider
%li
@@ -50,4 +50,4 @@
continue: continue_params)
= link_to fork_path, method: :post do
= icon('file fw')
- New file
+ 新文件
diff --git a/app/views/projects/buttons/_fork.html.haml b/app/views/projects/buttons/_fork.html.haml
index 133531887a2..9fe85f6eb9c 100644
--- a/app/views/projects/buttons/_fork.html.haml
+++ b/app/views/projects/buttons/_fork.html.haml
@@ -1,17 +1,17 @@
- unless @project.empty_repo?
- if current_user && can?(current_user, :fork_project, @project)
- if current_user.already_forked?(@project) && current_user.manageable_namespaces.size < 2
- = link_to namespace_project_path(current_user, current_user.fork_of(@project)), title: 'Go to your fork', class: 'btn has_tooltip' do
+ = link_to namespace_project_path(current_user, current_user.fork_of(@project)), title: '转到我的派生', class: 'btn has_tooltip' do
= icon('code-fork fw')
- Fork
+ 派生
%div.count-with-arrow
%span.arrow
%span.count
= @project.forks_count
- else
- = link_to new_namespace_project_fork_path(@project.namespace, @project), title: "Fork project", class: 'btn has_tooltip' do
+ = link_to new_namespace_project_fork_path(@project.namespace, @project), title: "派生项目", class: 'btn has_tooltip' do
= icon('code-fork fw')
- Fork
+ 派生
%div.count-with-arrow
%span.arrow
%span.count
diff --git a/app/views/projects/buttons/_notifications.html.haml b/app/views/projects/buttons/_notifications.html.haml
index 3e83ec3912f..df9ff3fdd69 100644
--- a/app/views/projects/buttons/_notifications.html.haml
+++ b/app/views/projects/buttons/_notifications.html.haml
@@ -14,7 +14,7 @@
= notification_list_item(level, @membership)
- when GroupMember
- .btn.disabled.notifications-btn.has_tooltip{title: "To change the notification level, you need to be a member of the project itself, not only its group."}
+ .btn.disabled.notifications-btn.has_tooltip{title: "要修改通知等级,需要你是项目成员,而不仅仅是群组成员。"}
= icon('bell')
= notification_label(@membership)
= icon('angle-down')
diff --git a/app/views/projects/buttons/_star.html.haml b/app/views/projects/buttons/_star.html.haml
index 21ba426aaa1..cb55903d4ab 100644
--- a/app/views/projects/buttons/_star.html.haml
+++ b/app/views/projects/buttons/_star.html.haml
@@ -1,20 +1,20 @@
- if current_user
- = link_to toggle_star_namespace_project_path(@project.namespace, @project), class: 'btn star-btn toggle-star has_tooltip', method: :post, remote: true, title: "Star project" do
+ = link_to toggle_star_namespace_project_path(@project.namespace, @project), class: 'btn star-btn toggle-star has_tooltip', method: :post, remote: true, title: "星标项目" do
- if current_user.starred?(@project)
= icon('star fw')
- %span.starred Unstar
+ %span.starred 取消星标
- else
= icon('star-o fw')
- %span Star
+ %span 星标
%div.count-with-arrow
%span.arrow
%span.count.star-count
= @project.star_count
- else
- = link_to new_user_session_path, class: 'btn has_tooltip star-btn', title: 'You must sign in to star a project' do
+ = link_to new_user_session_path, class: 'btn has_tooltip star-btn', title: '必须登入后才能给项目加注星标' do
= icon('star fw')
- Star
+ 星标
%div.count-with-arrow
%span.arrow
%span.count
diff --git a/app/views/projects/commit/_ci_menu.html.haml b/app/views/projects/commit/_ci_menu.html.haml
index ea33aa472a6..c95869bb99a 100644
--- a/app/views/projects/commit/_ci_menu.html.haml
+++ b/app/views/projects/commit/_ci_menu.html.haml
@@ -1,9 +1,9 @@
%ul.nav-links.no-top.no-bottom.commit-ci-menu
= nav_link(path: 'commit#show') do
= link_to namespace_project_commit_path(@project.namespace, @project, @commit.id) do
- Changes
+ 变更
%span.badge= @diffs.count
= nav_link(path: 'commit#builds') do
= link_to builds_namespace_project_commit_path(@project.namespace, @project, @commit.id) do
- Builds
+ 构建
%span.badge= @statuses.count
diff --git a/app/views/projects/commit/_commit_box.html.haml b/app/views/projects/commit/_commit_box.html.haml
index 71995fcc487..d0d2a45c716 100644
--- a/app/views/projects/commit/_commit_box.html.haml
+++ b/app/views/projects/commit/_commit_box.html.haml
@@ -7,38 +7,38 @@
.pull-left.btn-group
%a.btn.btn-grouped.dropdown-toggle{ data: {toggle: :dropdown} }
%i.fa.fa-download
- Download as
+ 下载为
%span.caret
%ul.dropdown-menu
- unless @commit.parents.length > 1
- %li= link_to "Email Patches", namespace_project_commit_path(@project.namespace, @project, @commit, format: :patch)
- %li= link_to "Plain Diff", namespace_project_commit_path(@project.namespace, @project, @commit, format: :diff)
+ %li= link_to "电子邮件补丁", namespace_project_commit_path(@project.namespace, @project, @commit, format: :patch)
+ %li= link_to "差异文件", namespace_project_commit_path(@project.namespace, @project, @commit, format: :diff)
= link_to namespace_project_tree_path(@project.namespace, @project, @commit), class: "btn btn-grouped" do
= icon('files-o')
- Browse Files
+ 浏览文件
- unless @commit.has_been_reverted?(current_user)
= revert_commit_link(@commit, namespace_project_commit_path(@project.namespace, @project, @commit.id))
%div
%p
- %span.light Commit
+ %span.light 提交
= link_to @commit.id, namespace_project_commit_path(@project.namespace, @project, @commit), class: "monospace"
= clipboard_button(clipboard_text: @commit.id)
.commit-info-row
- %span.light Authored by
+ %span.light 作者
%strong
= commit_author_link(@commit, avatar: true, size: 24)
#{time_ago_with_tooltip(@commit.authored_date)}
- if @commit.different_committer?
.commit-info-row
- %span.light Committed by
+ %span.light 提交者
%strong
= commit_committer_link(@commit, avatar: true, size: 24)
#{time_ago_with_tooltip(@commit.committed_date)}
.commit-info-row
- %span.cgray= pluralize(@commit.parents.count, "parent")
+ %span.cgray= pluralize(@commit.parents.count, "个父辈", "个父辈")
- @commit.parents.each do |parent|
= link_to parent.short_id, namespace_project_commit_path(@project.namespace, @project, parent), class: "monospace"
@@ -46,7 +46,7 @@
.pull-right
= link_to ci_status_path(@ci_commit), class: "ci-status ci-#{@ci_commit.status}" do
= ci_status_icon(@ci_commit)
- build:
+ 构建:
= ci_status_label(@ci_commit)
.commit-info-row.branches
diff --git a/app/views/projects/commit/builds.html.haml b/app/views/projects/commit/builds.html.haml
index 7118a4846c6..0675340128d 100644
--- a/app/views/projects/commit/builds.html.haml
+++ b/app/views/projects/commit/builds.html.haml
@@ -1,4 +1,4 @@
-- page_title "Builds", "#{@commit.title} (#{@commit.short_id})", "Commits"
+- page_title "构建", "#{@commit.title} (#{@commit.short_id})", "提交"
= render "projects/commits/header_title"
.prepend-top-default
= render "commit_box"
diff --git a/app/views/projects/commit/show.html.haml b/app/views/projects/commit/show.html.haml
index 21e186120c3..2ea19b63d6a 100644
--- a/app/views/projects/commit/show.html.haml
+++ b/app/views/projects/commit/show.html.haml
@@ -1,4 +1,4 @@
-- page_title "#{@commit.title} (#{@commit.short_id})", "Commits"
+- page_title "#{@commit.title} (#{@commit.short_id})", "提交"
- page_description @commit.description
= render "projects/commits/header_title"
diff --git a/app/views/projects/commits/_commit.html.haml b/app/views/projects/commits/_commit.html.haml
index 7f2903589a9..4dfccf6f43d 100644
--- a/app/views/projects/commits/_commit.html.haml
+++ b/app/views/projects/commits/_commit.html.haml
@@ -36,7 +36,8 @@
.commit-row-info
= commit_author_link(commit, avatar: true, size: 24)
- authored
+ 在
.committed_ago
#{time_ago_with_tooltip(commit.committed_date, skip_js: true)} &nbsp;
+ 创建
= link_to_browse_code(project, commit)
diff --git a/app/views/projects/commits/_commits.html.haml b/app/views/projects/commits/_commits.html.haml
index a7e3c2478c2..9f09ca78261 100644
--- a/app/views/projects/commits/_commits.html.haml
+++ b/app/views/projects/commits/_commits.html.haml
@@ -8,9 +8,9 @@
.col-md-2.hidden-xs.hidden-sm
%h5.commits-row-date
%i.fa.fa-calendar
- %span= day.strftime('%d %b, %Y')
+ %span= day.strftime('%Y-%m-%d')
.light
- = pluralize(commits.count, 'commit')
+ = pluralize(commits.count, '次提交', '次提交')
.col-md-10.col-sm-12
%ul.bordered-list
= render commits, project: project
diff --git a/app/views/projects/commits/_header_title.html.haml b/app/views/projects/commits/_header_title.html.haml
index e4385893dd9..7a7596d577a 100644
--- a/app/views/projects/commits/_header_title.html.haml
+++ b/app/views/projects/commits/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Commits", project_commits_path(@project))
+- header_title project_title(@project, "提交", project_commits_path(@project))
diff --git a/app/views/projects/commits/show.html.haml b/app/views/projects/commits/show.html.haml
index c52cf25d40a..be98af6db99 100644
--- a/app/views/projects/commits/show.html.haml
+++ b/app/views/projects/commits/show.html.haml
@@ -1,8 +1,8 @@
-- page_title "Commits", @ref
+- page_title "提交", @ref
= render "header_title"
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, namespace_project_commits_url(@project.namespace, @project, @ref, format: :atom, private_token: current_user.private_token), title: "#{@project.name}:#{@ref} commits")
+ = auto_discovery_link_tag(:atom, namespace_project_commits_url(@project.namespace, @project, @ref, format: :atom, private_token: current_user.private_token), title: "#{@project.name}:#{@ref} 提交")
= render "head"
@@ -13,20 +13,20 @@
.block-controls.hidden-xs.hidden-sm
- if @merge_request.present?
.control
- = link_to "View Open Merge Request", namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'btn'
+ = link_to "查看未关闭的合并请求", namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'btn'
- elsif create_mr_button?(@repository.root_ref, @ref)
.control
= link_to create_mr_path(@repository.root_ref, @ref), class: 'btn btn-success' do
= icon('plus')
- Create Merge Request
+ 创建合并请求
.control
= form_tag(namespace_project_commits_path(@project.namespace, @project, @id), method: :get, class: 'pull-left commits-search-form') do
- = search_field_tag :search, params[:search], { placeholder: 'Filter by commit message', id: 'commits-search', class: 'form-control search-text-input', spellcheck: false }
+ = search_field_tag :search, params[:search], { placeholder: '按提交信息过滤', id: 'commits-search', class: 'form-control search-text-input', spellcheck: false }
- if current_user && current_user.private_token
.control
- = link_to namespace_project_commits_path(@project.namespace, @project, @ref, {format: :atom, private_token: current_user.private_token}), title: "Commits Feed", class: 'btn' do
+ = link_to namespace_project_commits_path(@project.namespace, @project, @ref, {format: :atom, private_token: current_user.private_token}), title: "提交动态", class: 'btn' do
= icon("rss")
diff --git a/app/views/projects/compare/_form.html.haml b/app/views/projects/compare/_form.html.haml
index 4ab81f3635c..342ee3d093b 100644
--- a/app/views/projects/compare/_form.html.haml
+++ b/app/views/projects/compare/_form.html.haml
@@ -1,24 +1,24 @@
= form_tag namespace_project_compare_index_path(@project.namespace, @project), method: :post, class: 'form-inline js-requires-input' do
.clearfix
- if params[:to] && params[:from]
- = link_to 'switch', {from: params[:to], to: params[:from]}, {class: 'commits-compare-switch has_tooltip', title: 'Switch base of comparison'}
+ = link_to '切换', {from: params[:to], to: params[:from]}, {class: 'commits-compare-switch has_tooltip', title: '切换比较基准'}
.form-group
.input-group.inline-input-group
- %span.input-group-addon from
+ %span.input-group-addon 从
= text_field_tag :from, params[:from], class: "form-control", required: true
= "..."
.form-group
.input-group.inline-input-group
- %span.input-group-addon to
+ %span.input-group-addon 到
= text_field_tag :to, params[:to], class: "form-control", required: true
&nbsp;
- = button_tag "Compare", class: "btn btn-create commits-compare-btn"
+ = button_tag "比较", class: "btn btn-create commits-compare-btn"
- if @merge_request.present?
- = link_to "View Open Merge Request", namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'prepend-left-10 btn'
+ = link_to "查看未关闭的合并请求", namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'prepend-left-10 btn'
- elsif create_mr_button?
= link_to create_mr_path, class: 'prepend-left-10 btn' do
= icon("plus")
- Create Merge Request
+ 创建合并请求
:javascript
var availableTags = #{@project.repository.ref_names.to_json};
diff --git a/app/views/projects/compare/index.html.haml b/app/views/projects/compare/index.html.haml
index 02be5a2d07f..5454cdada95 100644
--- a/app/views/projects/compare/index.html.haml
+++ b/app/views/projects/compare/index.html.haml
@@ -1,17 +1,17 @@
-- page_title "Compare"
+- page_title "比较"
= render "projects/commits/header_title"
= render "projects/commits/head"
.gray-content-block
- Compare branches, tags or commit ranges.
+ 比较分支、标签或提交范围。
%br
- Fill input field with commit id like
+ 填写诸如
%code.label-branch 4eedf23
- or branch/tag name like
+ 这样的提交 ID 或
%code.label-branch master
- and press compare button for the commits list and a code diff.
+ 这种分支/标签名,然后点击比较按钮获取提交列表和代码差异。
%br
- Changes are shown <b>from</b> the version in the first field <b>to</b> the version in the second field.
+ 显示<b>从</b>第一个版本<b>到</b>第二个版本的差异。
.prepend-top-20
= render "form"
diff --git a/app/views/projects/compare/show.html.haml b/app/views/projects/compare/show.html.haml
index da731f28bb6..fdf9625e0ab 100644
--- a/app/views/projects/compare/show.html.haml
+++ b/app/views/projects/compare/show.html.haml
@@ -14,12 +14,12 @@
.light-well.prepend-top-default
.center
%h4
- There isn't anything to compare.
+ 没有内容需要比较。
%p.slead
- if params[:to] == params[:from]
%span.label-branch #{params[:from]}
- and
+ 与
%span.label-branch #{params[:to]}
- are the same.
+ 内容一致。
- else
- You'll need to use different branch names to get a valid comparison.
+ 需要选择不同的分支用于比较。
diff --git a/app/views/projects/deploy_keys/_deploy_key.html.haml b/app/views/projects/deploy_keys/_deploy_key.html.haml
index 8d66bae8cdf..c494ced0b4d 100644
--- a/app/views/projects/deploy_keys/_deploy_key.html.haml
+++ b/app/views/projects/deploy_keys/_deploy_key.html.haml
@@ -3,14 +3,14 @@
- if @available_keys.include?(deploy_key)
= link_to enable_namespace_project_deploy_key_path(@project.namespace, @project, deploy_key), class: 'btn btn-sm', method: :put do
= icon('plus')
- Enable
+ 启用
- else
- if deploy_key.destroyed_when_orphaned? && deploy_key.almost_orphaned?
- = link_to 'Remove', disable_namespace_project_deploy_key_path(@project.namespace, @project, deploy_key), data: { confirm: 'You are going to remove deploy key. Are you sure?'}, method: :put, class: "btn btn-remove delete-key btn-sm pull-right"
+ = link_to '删除', disable_namespace_project_deploy_key_path(@project.namespace, @project, deploy_key), data: { confirm: '确定要删除部署密钥么?'}, method: :put, class: "btn btn-remove delete-key btn-sm pull-right"
- else
= link_to disable_namespace_project_deploy_key_path(@project.namespace, @project, deploy_key), class: 'btn btn-sm', method: :put do
= icon('power-off')
- Disable
+ 禁用
= icon('key')
%strong= deploy_key.title
@@ -20,7 +20,7 @@
%p.light.prepend-top-10
- if deploy_key.public?
%span.label.label-info.deploy-project-label
- Public deploy key
+ 公开的部署密钥
- deploy_key.projects.each do |project|
- if can?(current_user, :read_project, project)
@@ -29,4 +29,4 @@
= project.name_with_namespace
%small.pull-right
- Created #{time_ago_with_tooltip(deploy_key.created_at)}
+ 创建时间 #{time_ago_with_tooltip(deploy_key.created_at)}
diff --git a/app/views/projects/deploy_keys/_form.html.haml b/app/views/projects/deploy_keys/_form.html.haml
index 5e182af2669..fa36bfb6ac8 100644
--- a/app/views/projects/deploy_keys/_form.html.haml
+++ b/app/views/projects/deploy_keys/_form.html.haml
@@ -7,16 +7,17 @@
%li= msg
.form-group
- = f.label :title, class: "control-label"
+ = f.label :title, '标题', class: "control-label"
.col-sm-10= f.text_field :title, class: 'form-control', autofocus: true, required: true
.form-group
- = f.label :key, class: "control-label"
+ = f.label :key, '公钥', class: "control-label"
.col-sm-10
%p.light
- Paste a machine public key here. Read more about how to generate it
- = link_to "here", help_page_path("ssh", "README")
+ 在这里粘贴机器 SSH 公钥。如何生成请点击
+ = link_to "这里", help_page_path("ssh", "README")
+ 了解更多
= f.text_area :key, class: "form-control thin_area", rows: 5, required: true
.form-actions
- = f.submit 'Create Deploy Key', class: "btn-create btn"
- = link_to "Cancel", namespace_project_deploy_keys_path(@project.namespace, @project), class: "btn btn-cancel"
+ = f.submit '创建部署密钥', class: "btn-create btn"
+ = link_to "取消", namespace_project_deploy_keys_path(@project.namespace, @project), class: "btn btn-cancel"
diff --git a/app/views/projects/deploy_keys/index.html.haml b/app/views/projects/deploy_keys/index.html.haml
index 8e24c778b7c..44f7a37a459 100644
--- a/app/views/projects/deploy_keys/index.html.haml
+++ b/app/views/projects/deploy_keys/index.html.haml
@@ -1,43 +1,43 @@
-- page_title "Deploy Keys"
+- page_title "部署密钥"
%h3.page-title
- Deploy keys allow read-only access to the repository
+ 使用部署密钥只读访问存储库
- = link_to new_namespace_project_deploy_key_path(@project.namespace, @project), class: "btn btn-new pull-right", title: "New Deploy Key" do
+ = link_to new_namespace_project_deploy_key_path(@project.namespace, @project), class: "btn btn-new pull-right", title: "新部署密钥" do
%i.fa.fa-plus
- New Deploy Key
+ 新部署密钥
%p.light
- Deploy keys can be used for CI, staging or production servers.
- You can create a deploy key or add an existing one
+ 部署密钥用于 CI 集成、预发布和产品服务器获取版本仓库的代码。
+ 请创建一个新的或增加已存在的 SSH 密钥
%hr.clearfix
.row
.col-md-6.enabled-keys
%h5
- %strong.cgreen Enabled deploy keys
- for this project
+ 本项目
+ %strong.cgreen 已启用的部署密钥
%ul.bordered-list
= render @enabled_keys
- if @enabled_keys.blank?
.light-well
- .nothing-here-block Create a #{link_to 'new deploy key', new_namespace_project_deploy_key_path(@project.namespace, @project)} or add an existing one
+ .nothing-here-block 创建#{link_to '新部署密钥', new_namespace_project_deploy_key_path(@project.namespace, @project)}或增加已存在的
.col-md-6.available-keys
- # If there are available public deploy keys but no available project deploy keys, only public deploy keys are shown.
- if @available_project_keys.any? || @available_public_keys.blank?
%h5
- %strong Deploy keys
- from projects you have access to
+ 可用的
+ %strong 部署密钥
%ul.bordered-list
= render @available_project_keys
- if @available_project_keys.blank?
.light-well
- .nothing-here-block Deploy keys from projects you have access to will be displayed here
+ .nothing-here-block 本项目可用的部署密钥
- if @available_public_keys.any?
%h5
- %strong Public deploy keys
- available to any project
+ 所有项目可用的
+ %strong 公开部署密钥
%ul.bordered-list
= render @available_public_keys
diff --git a/app/views/projects/deploy_keys/new.html.haml b/app/views/projects/deploy_keys/new.html.haml
index 01fab3008a7..91d9785f419 100644
--- a/app/views/projects/deploy_keys/new.html.haml
+++ b/app/views/projects/deploy_keys/new.html.haml
@@ -1,5 +1,5 @@
-- page_title "New Deploy Key"
-%h3.page-title New Deploy Key
+- page_title "新部署密钥"
+%h3.page-title 新部署密钥
%hr
= render 'form'
diff --git a/app/views/projects/diffs/_file.html.haml b/app/views/projects/diffs/_file.html.haml
index 3898bb202c5..fa53fc429f5 100644
--- a/app/views/projects/diffs/_file.html.haml
+++ b/app/views/projects/diffs/_file.html.haml
@@ -28,7 +28,7 @@
.file-actions.hidden-xs
- if blob_text_viewable?(blob)
- = link_to '#', class: 'js-toggle-diff-comments btn active has_tooltip', title: "Toggle comments for this file" do
+ = link_to '#', class: 'js-toggle-diff-comments btn active has_tooltip', title: "切换此文件的评论显示" do
= icon('comments')
\
diff --git a/app/views/projects/diffs/_image.html.haml b/app/views/projects/diffs/_image.html.haml
index 8367112a9cb..752defbad3f 100644
--- a/app/views/projects/diffs/_image.html.haml
+++ b/app/views/projects/diffs/_image.html.haml
@@ -18,10 +18,10 @@
%p.image-info.hide
%span.meta-filesize= "#{number_to_human_size old_file.size}"
|
- %b W:
+ %b 宽:
%span.meta-width
|
- %b H:
+ %b 高:
%span.meta-height
%span.wrap
.frame.added
@@ -30,10 +30,10 @@
%p.image-info.hide
%span.meta-filesize= "#{number_to_human_size file.size}"
|
- %b W:
+ %b 宽:
%span.meta-width
|
- %b H:
+ %b 高:
%span.meta-height
%div.swipe.view.hide
@@ -62,6 +62,6 @@
.view-modes.hide
%ul.view-modes-menu
- %li.two-up{data: {mode: 'two-up'}} 2-up
- %li.swipe{data: {mode: 'swipe'}} Swipe
- %li.onion-skin{data: {mode: 'onion-skin'}} Onion skin
+ %li.two-up{data: {mode: 'two-up'}} 两方对比
+ %li.swipe{data: {mode: 'swipe'}} 交换覆盖
+ %li.onion-skin{data: {mode: 'onion-skin'}} 透明覆盖
diff --git a/app/views/projects/diffs/_parallel_view.html.haml b/app/views/projects/diffs/_parallel_view.html.haml
index d7c49068745..27aef50cbfb 100644
--- a/app/views/projects/diffs/_parallel_view.html.haml
+++ b/app/views/projects/diffs/_parallel_view.html.haml
@@ -40,4 +40,4 @@
- if diff_file.diff.diff.blank? && diff_file.mode_changed?
.file-mode-changed
- File mode changed
+ 文件模式已改变
diff --git a/app/views/projects/diffs/_stats.html.haml b/app/views/projects/diffs/_stats.html.haml
index ea2a3e01277..9a816f9eef6 100644
--- a/app/views/projects/diffs/_stats.html.haml
+++ b/app/views/projects/diffs/_stats.html.haml
@@ -1,12 +1,12 @@
.js-toggle-container
.commit-stat-summary
- Showing
+ 正在显示
= link_to '#', class: 'js-toggle-button' do
- %strong #{pluralize(diff_files.count, "changed file")}
- with
- %strong.cgreen #{diff_files.sum(&:added_lines)} additions
- and
- %strong.cred #{diff_files.sum(&:removed_lines)} deletions
+ %strong #{pluralize(diff_files.count, "个修改的文件", "个修改的文件")}
+ 包含
+ %strong.cgreen #{diff_files.sum(&:added_lines)} 行增加
+ 和
+ %strong.cred #{diff_files.sum(&:removed_lines)} 行删除
.file-stats.js-toggle-content.hide
%ul
- diff_files.each_with_index do |diff_file, i|
diff --git a/app/views/projects/diffs/_text_file.html.haml b/app/views/projects/diffs/_text_file.html.haml
index e7169d7b599..861b7d9b66e 100644
--- a/app/views/projects/diffs/_text_file.html.haml
+++ b/app/views/projects/diffs/_text_file.html.haml
@@ -1,7 +1,7 @@
- too_big = diff_file.diff_lines.count > Commit::DIFF_SAFE_LINES
- if too_big
.suppressed-container
- %a.show-suppressed-diff.js-show-suppressed-diff Changes suppressed. Click to show.
+ %a.show-suppressed-diff.js-show-suppressed-diff 修改有限制。点击显示。
%table.text-file.code.js-syntax-highlight{ class: too_big ? 'hide' : '' }
@@ -23,4 +23,4 @@
- if diff_file.diff.blank? && diff_file.mode_changed?
.file-mode-changed
- File mode changed
+ 文件模式已改变
diff --git a/app/views/projects/edit.html.haml b/app/views/projects/edit.html.haml
index 6d872cd0b21..d237384cee6 100644
--- a/app/views/projects/edit.html.haml
+++ b/app/views/projects/edit.html.haml
@@ -189,69 +189,69 @@
#{URI.join(root_url, @project.namespace.path)}/
= f.text_field :path, class: 'form-control'
%ul
- %li Be careful. Renaming a project's repository can have unintended side effects.
- %li You will need to update your local repositories to point to the new location.
+ %li 请小心。重命名项目仓库可能有意想不到的副作用。
+ %li 需要更新本地版本仓库指向新位置。
.form-actions
- = f.submit 'Rename project', class: "btn btn-warning"
+ = f.submit '重命名项目', class: "btn btn-warning"
- if can?(current_user, :change_namespace, @project)
.panel.panel-default.panel.panel-danger
- .panel-heading Transfer project
+ .panel-heading 转移项目
.errors-holder
.panel-body
= form_for([@project.namespace.becomes(Namespace), @project], url: transfer_namespace_project_path(@project.namespace, @project), method: :put, remote: true, html: { class: 'transfer-project form-horizontal' }) do |f|
.form-group
= label_tag :new_namespace_id, nil, class: 'control-label' do
- %span Namespace
+ %span 命名空间
.col-sm-9
.form-group
- = select_tag :new_namespace_id, namespaces_options(@project.namespace_id), { prompt: 'Choose a project namespace', class: 'select2' }
+ = select_tag :new_namespace_id, namespaces_options(@project.namespace_id), { prompt: '选择项目命名空间', class: 'select2' }
%ul
- %li Be careful. Changing the project's namespace can have unintended side effects.
- %li You can only transfer the project to namespaces you manage.
- %li You will need to update your local repositories to point to the new location.
+ %li 请注意:更改项目的命名空间可能有意想不到的副作用。
+ %li 只能将项目转移到能管理到的命名空间。
+ %li 需要更新本地版本仓库指向新位置。
.form-actions
- = f.submit 'Transfer project', class: "btn btn-remove js-confirm-danger", data: { "confirm-danger-message" => transfer_project_message(@project) }
+ = f.submit '转移项目', class: "btn btn-remove js-confirm-danger", data: { "confirm-danger-message" => transfer_project_message(@project) }
- else
- .nothing-here-block Only the project owner can transfer a project
+ .nothing-here-block 只有项目所有者才能转移项目。
- if @project.forked?
- if can?(current_user, :remove_fork_project, @project)
= form_for([@project.namespace.becomes(Namespace), @project], url: remove_fork_namespace_project_path(@project.namespace, @project), method: :delete, remote: true, html: { class: 'transfer-project form-horizontal' }) do |f|
.panel.panel-default.panel.panel-danger
- .panel-heading Remove fork relationship
+ .panel-heading 删除派生关系
.panel-body
%p
- This will remove the fork relationship to source project
- #{link_to @project.forked_from_project.name_with_namespace, project_path(@project.forked_from_project)}.
+ 将删除从源项目
+ #{link_to @project.forked_from_project.name_with_namespace, project_path(@project.forked_from_project)} 的派生关系。
%br
- %strong Once removed, the fork relationship cannot be restored and you will no longer be able to send merge requests to the source.
+ %strong 一旦删除,派生关系无法恢复;也将无法在提交合并请求到源项目。
.form-actions
- = button_to 'Remove fork relationship', '#', class: "btn btn-remove js-confirm-danger", data: { "confirm-danger-message" => remove_fork_project_message(@project) }
+ = button_to '删除派生关系', '#', class: "btn btn-remove js-confirm-danger", data: { "confirm-danger-message" => remove_fork_project_message(@project) }
- else
- .nothing-here-block Only the project owner can remove the fork relationship.
+ .nothing-here-block 只有项目所有者才能删除派生关系。
- if can?(current_user, :remove_project, @project)
.panel.panel-default.panel.panel-danger
- .panel-heading Remove project
+ .panel-heading 删除项目
.panel-body
= form_tag(namespace_project_path(@project.namespace, @project), method: :delete, class: 'form-horizontal') do
%p
- Removing the project will delete its repository and all related resources including issues, merge requests etc.
+ 删除项目将删除其版本仓库及所有相关资源,包括问题,合并请求等。
%br
- %strong Removed projects cannot be restored!
+ %strong 删除项目无法恢复!
.form-actions
- = button_to 'Remove project', '#', class: "btn btn-remove js-confirm-danger", data: { "confirm-danger-message" => remove_project_message(@project) }
+ = button_to '删除项目', '#', class: "btn btn-remove js-confirm-danger", data: { "confirm-danger-message" => remove_project_message(@project) }
- else
- .nothing-here-block Only the project owner can remove a project.
+ .nothing-here-block 只有项目所有者才能删除项目。
.save-project-loader.hide
.center
%h2
%i.fa.fa-spinner.fa-spin
- Saving project.
- %p Please wait a moment, this page will automatically refresh when ready.
+ 正在保存项目。
+ %p 请稍等片刻,页面会在准备好后自动刷新。
= render 'shared/confirm_modal', phrase: @project.path
diff --git a/app/views/projects/empty.html.haml b/app/views/projects/empty.html.haml
index 6ad7b05155a..1ce0a9e3018 100644
--- a/app/views/projects/empty.html.haml
+++ b/app/views/projects/empty.html.haml
@@ -44,7 +44,7 @@
git push -u origin master
%fieldset
- %h5 Existing folder or Git repository
+ %h5 已存在的文件夹或 Git 仓库
%pre.light-well
:preserve
cd existing_folder
@@ -56,4 +56,4 @@
- if can? current_user, :remove_project, @project
.prepend-top-20
- = link_to 'Remove project', [@project.namespace.becomes(Namespace), @project], data: { confirm: remove_project_message(@project)}, method: :delete, class: "btn btn-remove pull-right"
+ = link_to '删除项目', [@project.namespace.becomes(Namespace), @project], data: { confirm: remove_project_message(@project)}, method: :delete, class: "btn btn-remove pull-right"
diff --git a/app/views/projects/find_file/show.html.haml b/app/views/projects/find_file/show.html.haml
index 905f6bbbd48..1a6537e68bf 100644
--- a/app/views/projects/find_file/show.html.haml
+++ b/app/views/projects/find_file/show.html.haml
@@ -1,5 +1,5 @@
-- page_title "Find File", @ref
-- header_title project_title(@project, "Files", project_files_path(@project))
+- page_title "查找文件", @ref
+- header_title project_title(@project, "文件", project_files_path(@project))
.file-finder-holder.tree-holder.clearfix
.gray-content-block.top-block
@@ -10,7 +10,7 @@
= link_to namespace_project_tree_path(@project.namespace, @project, @ref) do
= @project.path
%li.file-finder
- %input#file_find.form-control.file-finder-input{type: "text", placeholder: 'Find by path', autocomplete: 'off'}
+ %input#file_find.form-control.file-finder-input{type: "text", placeholder: '按路径查找文件', autocomplete: 'off'}
%div.tree-content-holder
.table-holder
diff --git a/app/views/projects/forks/error.html.haml b/app/views/projects/forks/error.html.haml
index 3d0ab5b85d6..d9b61ee20ba 100644
--- a/app/views/projects/forks/error.html.haml
+++ b/app/views/projects/forks/error.html.haml
@@ -1,13 +1,13 @@
-- page_title "Fork project"
+- page_title "派生项目"
- if @forked_project && !@forked_project.saved?
.alert.alert-danger.alert-block
%h4
%i.fa.fa-code-fork
- Fork Error!
+ 派生错误!
%p
- You tried to fork
+ 试图派生
= link_to_project @project
- but it failed for the following reason:
+ 出现错误,原因如下:
- if @forked_project && @forked_project.errors.any?
@@ -16,6 +16,6 @@
= @forked_project.errors.full_messages.first
%p
- = link_to new_namespace_project_fork_path(@project.namespace, @project), title: "Fork", class: "btn" do
+ = link_to new_namespace_project_fork_path(@project.namespace, @project), title: "派生", class: "btn" do
%i.fa.fa-code-fork
- Try to Fork again
+ 重试派生
diff --git a/app/views/projects/forks/new.html.haml b/app/views/projects/forks/new.html.haml
index edabc2d3b44..087c9a925fe 100644
--- a/app/views/projects/forks/new.html.haml
+++ b/app/views/projects/forks/new.html.haml
@@ -1,8 +1,8 @@
-- page_title "Fork project"
+- page_title "派生项目"
- if @namespaces.present?
- %h3.page-title Fork project
+ %h3.page-title 派生项目
%p.lead
- Click to fork the project to a user or group
+ 点击派生项目到用户或群组
%hr
.fork-namespaces
@@ -12,34 +12,34 @@
.col-md-2.col-sm-3
- if fork = namespace.find_fork_of(@project)
.fork-thumbnail
- = link_to project_path(fork), title: "Visit project fork", class: 'has_tooltip' do
+ = link_to project_path(fork), title: "查看项目派生", class: 'has_tooltip' do
= image_tag namespace_icon(namespace, 100)
.caption
%strong
= namespace.human_name
%div.text-primary
- Already forked
+ 已派生
- else
.fork-thumbnail
- = link_to namespace_project_forks_path(@project.namespace, @project, namespace_key: namespace.id), title: "Fork here", method: "POST", class: 'has_tooltip' do
+ = link_to namespace_project_forks_path(@project.namespace, @project, namespace_key: namespace.id), title: "派生", method: "POST", class: 'has_tooltip' do
= image_tag namespace_icon(namespace, 100)
.caption
%strong
= namespace.human_name
%p.light
- Fork is a copy of a project repository.
+ 派生是创建项目仓库的副本。
%br
- Forking a repository allows you to do changes without affecting the original project.
+ 派生的仓库允许你在不影响原有项目的情况下修改新内容。
- else
- %h3 No available namespaces to fork the project
+ %h3 没有可用的命名空间来派生项目
%p.slead
- You must have permission to create a project in a namespace before forking.
+ 在派生之前,你必须拥有在命名空间中创建项目的权限。
.save-project-loader.hide
.center
%h2
%i.fa.fa-spinner.fa-spin
- Forking repository
- %p Please wait a moment, this page will automatically refresh when ready.
+ 正在派生仓库
+ %p 请稍后,本页面将在准备好后自动刷新。
diff --git a/app/views/projects/graphs/_head.html.haml b/app/views/projects/graphs/_head.html.haml
index 79a56647c53..dbe539cb326 100644
--- a/app/views/projects/graphs/_head.html.haml
+++ b/app/views/projects/graphs/_head.html.haml
@@ -1,11 +1,11 @@
%ul.nav-links
= nav_link(action: :show) do
- = link_to 'Contributors', namespace_project_graph_path
+ = link_to '贡献者', namespace_project_graph_path
= nav_link(action: :commits) do
- = link_to 'Commits', commits_namespace_project_graph_path
+ = link_to '提交', commits_namespace_project_graph_path
= nav_link(action: :languages) do
- = link_to 'Languages', languages_namespace_project_graph_path
+ = link_to '语言', languages_namespace_project_graph_path
- if @project.builds_enabled?
= nav_link(action: :ci) do
= link_to ci_namespace_project_graph_path do
- Continuous Integration
+ 持续集成
diff --git a/app/views/projects/graphs/_header_title.html.haml b/app/views/projects/graphs/_header_title.html.haml
index 1e2f61cd22b..1ddcad6e94a 100644
--- a/app/views/projects/graphs/_header_title.html.haml
+++ b/app/views/projects/graphs/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Graphs", namespace_project_graph_path(@project.namespace, @project, current_ref))
+- header_title project_title(@project, "图表", namespace_project_graph_path(@project.namespace, @project, current_ref))
diff --git a/app/views/projects/graphs/ci.html.haml b/app/views/projects/graphs/ci.html.haml
index 6fa77cc10c6..f02bb120113 100644
--- a/app/views/projects/graphs/ci.html.haml
+++ b/app/views/projects/graphs/ci.html.haml
@@ -1,9 +1,9 @@
-- page_title "Continuous Integration", "Graphs"
+- page_title "持续集成", "图表"
= render "header_title"
= render 'head'
.gray-content-block.append-bottom-default
.oneline
- A collection of graphs for Continuous Integration
+ 持续集成图表集合
#charts.ci-charts
.row
diff --git a/app/views/projects/graphs/ci/_build_times.haml b/app/views/projects/graphs/ci/_build_times.haml
index c58223fd39e..fd9b7010821 100644
--- a/app/views/projects/graphs/ci/_build_times.haml
+++ b/app/views/projects/graphs/ci/_build_times.haml
@@ -1,6 +1,6 @@
%div
%p.light
- Commit duration in minutes for last 30 commits
+ 最后 30 次提交的运行时间(分钟)
%canvas#build_timesChart{height: 200}
diff --git a/app/views/projects/graphs/ci/_builds.haml b/app/views/projects/graphs/ci/_builds.haml
index 8fca07114fa..a8fd0b9ee8b 100644
--- a/app/views/projects/graphs/ci/_builds.haml
+++ b/app/views/projects/graphs/ci/_builds.haml
@@ -1,29 +1,29 @@
-%h4 Build charts
+%h4 构建图表
%p
&nbsp;
%span.cgreen
= icon("circle")
- success
+ 成功
&nbsp;
%span.cgray
= icon("circle")
- all
+ 所有
.prepend-top-default
%p.light
- Builds for last week
+ 上周构建图表
(#{date_from_to(Date.today - 7.days, Date.today)})
%canvas#weekChart{height: 200}
.prepend-top-default
%p.light
- Builds for last month
+ 上月构建图表
(#{date_from_to(Date.today - 30.days, Date.today)})
%canvas#monthChart{height: 200}
.prepend-top-default
%p.light
- Builds for last year
+ 去年构建图表
%canvas#yearChart.padded{height: 250}
- [:week, :month, :year].each do |scope|
diff --git a/app/views/projects/graphs/ci/_overall.haml b/app/views/projects/graphs/ci/_overall.haml
index 4b12e5f2da1..373c3d81011 100644
--- a/app/views/projects/graphs/ci/_overall.haml
+++ b/app/views/projects/graphs/ci/_overall.haml
@@ -1,19 +1,19 @@
-%h4 Overall stats
+%h4 整体统计
%ul
%li
- Total:
- %strong= pluralize @project.builds.count(:all), 'build'
+ 合计:
+ %strong= pluralize @project.builds.count(:all), '次构建', '次构建'
%li
- Successful:
- %strong= pluralize @project.builds.success.count(:all), 'build'
+ 成功:
+ %strong= pluralize @project.builds.success.count(:all), '次构建', '次构建'
%li
- Failed:
- %strong= pluralize @project.builds.failed.count(:all), 'build'
+ 失败:
+ %strong= pluralize @project.builds.failed.count(:all), '次构建', '次构建'
%li
- Success ratio:
+ 成功率:
%strong
#{success_ratio(@project.builds.success, @project.builds.failed)}%
%li
- Commits covered:
+ 提交覆盖:
%strong
= @project.ci_commits.count(:all)
diff --git a/app/views/projects/graphs/commits.html.haml b/app/views/projects/graphs/commits.html.haml
index fc465ab273b..55cec0e7dc5 100644
--- a/app/views/projects/graphs/commits.html.haml
+++ b/app/views/projects/graphs/commits.html.haml
@@ -1,4 +1,4 @@
-- page_title "Commits", "Graphs"
+- page_title "提交", "图表"
= render "header_title"
= render 'head'
@@ -9,9 +9,9 @@
= commits_breadcrumbs
%p.lead
- Commit statistics for
+ 提交统计
%strong #{@ref}
- #{@commits_graph.start_date.strftime('%b %d')} - #{@commits_graph.end_date.strftime('%b %d')}
+ #{@commits_graph.start_date.strftime('%m-%d')} - #{@commits_graph.end_date.strftime('%m-%d')}
.row
.col-md-6
@@ -19,34 +19,34 @@
%li
%p.lead
%strong #{@commits_graph.commits.size}
- commits during
+ 次提交花费
%strong #{@commits_graph.duration}
- days
+ 天
%li
%p.lead
- Average
+ 平均每天
%strong #{@commits_graph.commit_per_day}
- commits per day
+ 次提交
%li
%p.lead
- Contributed by
+ 贡献者
%strong #{@commits_graph.authors}
- authors
+ 人
.col-md-6
%div
%p.slead
- Commits per day of month
+ 每月按天提交数
%canvas#month-chart
.row
.col-md-6
%div
%p.slead
- Commits per day hour (UTC)
+ 每天按小时提交数 (UTC)
%canvas#hour-chart
.col-md-6
%div
%p.slead
- Commits per weekday
+ 每周按天提交数
%canvas#weekday-chart
:javascript
diff --git a/app/views/projects/graphs/languages.html.haml b/app/views/projects/graphs/languages.html.haml
index a7fab5b6d72..020c04ff4a1 100644
--- a/app/views/projects/graphs/languages.html.haml
+++ b/app/views/projects/graphs/languages.html.haml
@@ -1,10 +1,10 @@
-- page_title "Languages", "Graphs"
+- page_title "语言", "图表"
= render "header_title"
= render 'head'
.gray-content-block.append-bottom-default
.oneline
- Programming languages used in this repository
+ 此仓库使用的编程语言
.row
.col-md-8
diff --git a/app/views/projects/graphs/show.html.haml b/app/views/projects/graphs/show.html.haml
index 882e7d6b6ee..aa77eef25fe 100644
--- a/app/views/projects/graphs/show.html.haml
+++ b/app/views/projects/graphs/show.html.haml
@@ -1,4 +1,4 @@
-- page_title "Contributors", "Graphs"
+- page_title "贡献者统计", "图表"
= render "header_title"
= render 'head'
@@ -12,14 +12,14 @@
.center
%h3.page-title
%i.fa.fa-spinner.fa-spin
- Building repository graph.
- %p.slead Please wait a moment, this page will automatically refresh when ready.
+ 正在构建版本库图表。
+ %p.slead 请稍候,成功后会自动刷新页面。
.stat-graph.hide
.header.clearfix
%h3#date_header.page-title
%p.light
- Commits to #{@ref}, excluding merge commits. Limited by 6,000 commits
+ 提交到 #{@ref},排除合并提交。限制为 6,000 次提交。
%input#brush_change{:type => "hidden"}
.graphs
#contributors-master
diff --git a/app/views/projects/imports/new.html.haml b/app/views/projects/imports/new.html.haml
index 6027fb23360..12f47535928 100644
--- a/app/views/projects/imports/new.html.haml
+++ b/app/views/projects/imports/new.html.haml
@@ -1,12 +1,12 @@
-- page_title "Import repository"
+- page_title "导入仓库"
%h3.page-title
- Import repository
+ 导入仓库
%hr
- if @project.import_failed?
.panel.panel-danger
- .panel-heading The repository could not be imported.
+ .panel-heading 版本仓库无法被导入。
.panel-body
%pre
:preserve
@@ -16,4 +16,4 @@
= render "shared/import_form", f: f
.form-actions
- = f.submit 'Start import', class: "btn btn-create", tabindex: 4
+ = f.submit '开始导入', class: "btn btn-create", tabindex: 4
diff --git a/app/views/projects/imports/show.html.haml b/app/views/projects/imports/show.html.haml
index c0d1ce0d120..ad37e177030 100644
--- a/app/views/projects/imports/show.html.haml
+++ b/app/views/projects/imports/show.html.haml
@@ -1,14 +1,14 @@
-- page_title "Import in progress"
+- page_title "正在导入"
.save-project-loader
.center
%h2
%i.fa.fa-spinner.fa-spin
- if @project.forked?
- Forking in progress.
+ 正在派生。
- else
- Import in progress.
+ 正在导入。
- unless @project.forked?
%p.monospace git clone --bare #{@project.safe_import_url}
- %p Please wait while we import the repository for you. Refresh at will.
+ %p 请稍候,正在导入仓库。将自动刷新。
:javascript
new ProjectImport();
diff --git a/app/views/projects/issues/_closed_by_box.html.haml b/app/views/projects/issues/_closed_by_box.html.haml
index 38469ed4774..f5b7a9e25f2 100644
--- a/app/views/projects/issues/_closed_by_box.html.haml
+++ b/app/views/projects/issues/_closed_by_box.html.haml
@@ -1,4 +1,2 @@
.issue-closed-by-widget.second-block
- - pluralized_mr_this = merge_request_count > 1 ? "these" : "this"
- - pluralized_mr_is = merge_request_count > 1 ? "are" : "is"
- When #{pluralized_mr_this} merge #{"request".pluralize(merge_request_count)} #{pluralized_mr_is} accepted, this issue will be closed automatically.
+ 当合并请求被接受后,此问题将会被自动关闭。
diff --git a/app/views/projects/issues/_header_title.html.haml b/app/views/projects/issues/_header_title.html.haml
index 99f03549c44..257d1aefae2 100644
--- a/app/views/projects/issues/_header_title.html.haml
+++ b/app/views/projects/issues/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Issues", namespace_project_issues_path(@project.namespace, @project))
+- header_title project_title(@project, "问题", namespace_project_issues_path(@project.namespace, @project))
diff --git a/app/views/projects/issues/_issue.html.haml b/app/views/projects/issues/_issue.html.haml
index 00e1a3d8069..906b9acd3df 100644
--- a/app/views/projects/issues/_issue.html.haml
+++ b/app/views/projects/issues/_issue.html.haml
@@ -10,11 +10,11 @@
%ul.controls.light
- if issue.closed?
%li
- CLOSED
+ 已关闭
- if issue.assignee
%li
- = link_to_member(@project, issue.assignee, name: false, title: "Assigned to :name")
+ = link_to_member(@project, issue.assignee, name: false, title: "指派给 :name")
- upvotes, downvotes = issue.upvotes, issue.downvotes
- if upvotes > 0
@@ -41,8 +41,8 @@
.issue-info
#{issue.to_reference} &middot;
- opened #{time_ago_with_tooltip(issue.created_at, placement: 'bottom')}
- by #{link_to_member(@project, issue.author, avatar: false)}
+ #{link_to_member(@project, issue.author, avatar: false)}
+ 在 #{time_ago_with_tooltip(issue.created_at, placement: 'bottom')} 开启
- if issue.milestone
&nbsp;
= link_to namespace_project_issues_path(issue.project.namespace, issue.project, milestone_title: issue.milestone.title) do
@@ -58,4 +58,4 @@
= issue.task_status
.pull-right.issue-updated-at
- %span updated #{time_ago_with_tooltip(issue.updated_at, placement: 'bottom', html_class: 'issue_update_ago')}
+ %span #{time_ago_with_tooltip(issue.updated_at, placement: 'bottom', html_class: 'issue_update_ago')}更新
diff --git a/app/views/projects/issues/_issues.html.haml b/app/views/projects/issues/_issues.html.haml
index f34f3c05737..db57f515caf 100644
--- a/app/views/projects/issues/_issues.html.haml
+++ b/app/views/projects/issues/_issues.html.haml
@@ -2,7 +2,7 @@
= render @issues
- if @issues.blank?
%li
- .nothing-here-block No issues to show
+ .nothing-here-block 没有问题
- if @issues.present?
= paginate @issues, theme: "gitlab"
diff --git a/app/views/projects/issues/_merge_requests.html.haml b/app/views/projects/issues/_merge_requests.html.haml
index d6b38b327ff..f767ce3f86a 100644
--- a/app/views/projects/issues/_merge_requests.html.haml
+++ b/app/views/projects/issues/_merge_requests.html.haml
@@ -16,13 +16,13 @@
%strong
= link_to_gfm merge_request.title, merge_request_path(merge_request), class: "row_title"
- unless @issue.project.id == merge_request.target_project.id
- in
+ 在
- project = merge_request.target_project
= link_to project.name_with_namespace, namespace_project_path(project.namespace, project)
%span.merge-request-status.prepend-left-10
- if merge_request.merged?
- MERGED
+ 已合并
- elsif merge_request.closed?
- CLOSED
+ 已关闭
- if @closed_by_merge_requests.present?
= render partial: 'projects/issues/closed_by_box', locals: {merge_request_count: @merge_requests.count}
diff --git a/app/views/projects/issues/edit.html.haml b/app/views/projects/issues/edit.html.haml
index 20216297d25..72eaceefaff 100644
--- a/app/views/projects/issues/edit.html.haml
+++ b/app/views/projects/issues/edit.html.haml
@@ -1,8 +1,8 @@
-- page_title "Edit", "#{@issue.title} (##{@issue.iid})", "Issues"
+- page_title "编辑", "#{@issue.title} (##{@issue.iid})", "问题"
= render "header_title"
%h3.page-title
- Edit Issue ##{@issue.iid}
+ 编辑问题 ##{@issue.iid}
%hr
= render "form"
diff --git a/app/views/projects/issues/index.html.haml b/app/views/projects/issues/index.html.haml
index fde9304c0f8..ba7f7cb1a56 100644
--- a/app/views/projects/issues/index.html.haml
+++ b/app/views/projects/issues/index.html.haml
@@ -1,9 +1,9 @@
-- page_title "Issues"
+- page_title "问题"
= render "header_title"
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, namespace_project_issues_url(@project.namespace, @project, :atom, private_token: current_user.private_token), title: "#{@project.name} issues")
+ = auto_discovery_link_tag(:atom, namespace_project_issues_url(@project.namespace, @project, :atom, private_token: current_user.private_token), title: "#{@project.name} 问题")
.top-area
= render 'shared/issuable/nav', type: :issues
@@ -13,9 +13,9 @@
= icon('rss')
= render 'shared/issuable/search_form', path: namespace_project_issues_path(@project.namespace, @project)
- if can? current_user, :create_issue, @project
- = link_to new_namespace_project_issue_path(@project.namespace, @project, issue: { assignee_id: @issuable_finder.assignee.try(:id), milestone_id: @issuable_finder.milestones.try(:first).try(:id) }), class: "btn btn-new", title: "New Issue", id: "new_issue_link" do
+ = link_to new_namespace_project_issue_path(@project.namespace, @project, issue: { assignee_id: @issuable_finder.assignee.try(:id), milestone_id: @issuable_finder.milestones.try(:first).try(:id) }), class: "btn btn-new", title: "新问题", id: "new_issue_link" do
= icon('plus')
- New Issue
+ 新问题
= render 'shared/issuable/filter', type: :issues
diff --git a/app/views/projects/issues/new.html.haml b/app/views/projects/issues/new.html.haml
index b317a0c1cf4..cee9a064a89 100644
--- a/app/views/projects/issues/new.html.haml
+++ b/app/views/projects/issues/new.html.haml
@@ -1,8 +1,8 @@
-- page_title "New Issue"
+- page_title "新问题"
= render "header_title"
%h3.page-title
- New Issue
+ 新问题
%hr
= render "form"
diff --git a/app/views/projects/issues/show.html.haml b/app/views/projects/issues/show.html.haml
index 6fa059cbe68..2bcfdaaf4da 100644
--- a/app/views/projects/issues/show.html.haml
+++ b/app/views/projects/issues/show.html.haml
@@ -1,4 +1,4 @@
-- page_title "#{@issue.title} (##{@issue.iid})", "Issues"
+- page_title "#{@issue.title} (##{@issue.iid})", "问题"
- page_description @issue.description
- page_card_attributes @issue.card_attributes
diff --git a/app/views/projects/labels/_form.html.haml b/app/views/projects/labels/_form.html.haml
index be7a0bb5628..dc6e8243ca4 100644
--- a/app/views/projects/labels/_form.html.haml
+++ b/app/views/projects/labels/_form.html.haml
@@ -33,7 +33,7 @@
.form-actions
- if @label.persisted?
- = f.submit 'Save changes', class: 'btn btn-save js-save-button'
+ = f.submit '保存修改', class: 'btn btn-save js-save-button'
- else
- = f.submit 'Create Label', class: 'btn btn-create js-save-button'
- = link_to "Cancel", namespace_project_labels_path(@project.namespace, @project), class: 'btn btn-cancel'
+ = f.submit '创建标记', class: 'btn btn-create js-save-button'
+ = link_to "取消", namespace_project_labels_path(@project.namespace, @project), class: 'btn btn-cancel'
diff --git a/app/views/projects/labels/_header_title.html.haml b/app/views/projects/labels/_header_title.html.haml
index abe28da483b..683a9eff415 100644
--- a/app/views/projects/labels/_header_title.html.haml
+++ b/app/views/projects/labels/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Labels", namespace_project_labels_path(@project.namespace, @project))
+- header_title project_title(@project, "标记", namespace_project_labels_path(@project.namespace, @project))
diff --git a/app/views/projects/labels/edit.html.haml b/app/views/projects/labels/edit.html.haml
index 675a805e12f..c64d69871c3 100644
--- a/app/views/projects/labels/edit.html.haml
+++ b/app/views/projects/labels/edit.html.haml
@@ -1,7 +1,7 @@
-- page_title "Edit", @label.name, "Labels"
+- page_title "编辑", @label.name, "标记"
= render "header_title"
%h3.page-title
- Edit Label
+ 编辑标记
%hr
= render 'form'
diff --git a/app/views/projects/labels/index.html.haml b/app/views/projects/labels/index.html.haml
index cc41130a9dc..168920917b1 100644
--- a/app/views/projects/labels/index.html.haml
+++ b/app/views/projects/labels/index.html.haml
@@ -1,14 +1,14 @@
-- page_title "Labels"
+- page_title "标记"
= render "header_title"
.top-area
.nav-text
- Labels can be applied to issues and merge requests.
+ 标记可应用于问题和合并请求。
.nav-controls
- if can? current_user, :admin_label, @project
= link_to new_namespace_project_label_path(@project.namespace, @project), class: "btn btn-new" do
= icon('plus')
- New label
+ 新标记
.labels
- if @labels.present?
@@ -18,6 +18,6 @@
- else
.nothing-here-block
- if can? current_user, :admin_label, @project
- Create first label or #{link_to 'generate', generate_namespace_project_labels_path(@project.namespace, @project), method: :post} default set of labels
+ 创建第一个标记或者#{link_to '生成', generate_namespace_project_labels_path(@project.namespace, @project), method: :post}默认标记组
- else
- No labels created
+ 没有标记被创建
diff --git a/app/views/projects/labels/new.html.haml b/app/views/projects/labels/new.html.haml
index e20fd7d6891..481f6e49d19 100644
--- a/app/views/projects/labels/new.html.haml
+++ b/app/views/projects/labels/new.html.haml
@@ -1,7 +1,7 @@
-- page_title "New Label"
+- page_title "新标记"
= render "header_title"
%h3.page-title
- New Label
+ 新标记
%hr
= render 'form'
diff --git a/app/views/projects/merge_requests/_head.html.haml b/app/views/projects/merge_requests/_head.html.haml
index 19e4dab874b..e18af67b683 100644
--- a/app/views/projects/merge_requests/_head.html.haml
+++ b/app/views/projects/merge_requests/_head.html.haml
@@ -1,5 +1,5 @@
.top-tabs
= link_to namespace_project_merge_requests_path(@project.namespace, @project), class: "tab #{'active' if current_page?(namespace_project_merge_requests_path(@project.namespace, @project)) }" do
%span
- Merge Requests
+ 合并请求
diff --git a/app/views/projects/merge_requests/_header_title.html.haml b/app/views/projects/merge_requests/_header_title.html.haml
index 669a9b06bdf..2397ed6bd2d 100644
--- a/app/views/projects/merge_requests/_header_title.html.haml
+++ b/app/views/projects/merge_requests/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Merge Requests", namespace_project_merge_requests_path(@project.namespace, @project))
+- header_title project_title(@project, "合并请求", namespace_project_merge_requests_path(@project.namespace, @project))
diff --git a/app/views/projects/merge_requests/_merge_request.html.haml b/app/views/projects/merge_requests/_merge_request.html.haml
index 18cf3f14f0b..bcfec88c3a6 100644
--- a/app/views/projects/merge_requests/_merge_request.html.haml
+++ b/app/views/projects/merge_requests/_merge_request.html.haml
@@ -5,11 +5,11 @@
%ul.controls.light
- if merge_request.merged?
%li
- MERGED
+ 已合并
- elsif merge_request.closed?
%li
= icon('ban')
- CLOSED
+ 已关闭
- if merge_request.ci_commit
%li
@@ -17,12 +17,12 @@
- if merge_request.open? && merge_request.broken?
%li
- = link_to merge_request_path(merge_request), class: "has_tooltip", title: "Cannot be merged automatically", data: { container: 'body' } do
+ = link_to merge_request_path(merge_request), class: "has_tooltip", title: "无法被自动合并", data: { container: 'body' } do
= icon('exclamation-triangle')
- if merge_request.assignee
%li
- = link_to_member(merge_request.source_project, merge_request.assignee, name: false, title: "Assigned to :name")
+ = link_to_member(merge_request.source_project, merge_request.assignee, name: false, title: "指派给 :name")
- upvotes, downvotes = merge_request.upvotes, merge_request.downvotes
- if upvotes > 0
@@ -71,4 +71,4 @@
= merge_request.task_status
.pull-right.hidden-xs
- %span updated #{time_ago_with_tooltip(merge_request.updated_at, placement: 'bottom', html_class: 'merge_request_updated_ago')}
+ %span #{time_ago_with_tooltip(merge_request.updated_at, placement: 'bottom', html_class: 'merge_request_updated_ago')}更新
diff --git a/app/views/projects/merge_requests/_merge_requests.html.haml b/app/views/projects/merge_requests/_merge_requests.html.haml
index 5473fa19166..5c1f5484976 100644
--- a/app/views/projects/merge_requests/_merge_requests.html.haml
+++ b/app/views/projects/merge_requests/_merge_requests.html.haml
@@ -2,7 +2,7 @@
= render @merge_requests
- if @merge_requests.blank?
%li
- .nothing-here-block No merge requests to show
+ .nothing-here-block 没有合并请求
- if @merge_requests.present?
= paginate @merge_requests, theme: "gitlab"
diff --git a/app/views/projects/merge_requests/_new_compare.html.haml b/app/views/projects/merge_requests/_new_compare.html.haml
index 01dc7519bee..74572b9b370 100644
--- a/app/views/projects/merge_requests/_new_compare.html.haml
+++ b/app/views/projects/merge_requests/_new_compare.html.haml
@@ -1,5 +1,5 @@
%h3.page-title
- New Merge Request
+ 新合并请求
= form_for [@project.namespace.becomes(Namespace), @project, @merge_request], url: new_namespace_project_merge_request_path(@project.namespace, @project), method: :get, html: { class: "merge-request-form form-inline js-requires-input" } do |f|
.hide.alert.alert-danger.mr-compare-errors
@@ -7,23 +7,23 @@
.col-md-6
.panel.panel-default
.panel-heading
- %strong Source branch
+ %strong 来源分支
.panel-body
= f.select(:source_project_id, [[@merge_request.source_project_path,@merge_request.source_project.id]] , {}, { class: 'source_project select2 span3', disabled: @merge_request.persisted?, required: true })
&nbsp;
- = f.select(:source_branch, @merge_request.source_branches, { include_blank: true }, { class: 'source_branch select2 span2', required: true, data: { placeholder: "Select source branch" } })
+ = f.select(:source_branch, @merge_request.source_branches, { include_blank: true }, { class: 'source_branch select2 span2', required: true, data: { placeholder: "选择来源分支" } })
.panel-footer
.mr_source_commit
.col-md-6
.panel.panel-default
.panel-heading
- %strong Target branch
+ %strong 目标分支
.panel-body
- projects = @project.forked_from_project.nil? ? [@project] : [@project, @project.forked_from_project]
= f.select(:target_project_id, options_from_collection_for_select(projects, 'id', 'path_with_namespace', f.object.target_project_id), {}, { class: 'target_project select2 span3', disabled: @merge_request.persisted?, required: true })
&nbsp;
- = f.select(:target_branch, @merge_request.target_branches, { include_blank: true }, { class: 'target_branch select2 span2', required: true, data: { placeholder: "Select target branch" } })
+ = f.select(:target_branch, @merge_request.target_branches, { include_blank: true }, { class: 'target_branch select2 span2', required: true, data: { placeholder: "选择目标分支" } })
.panel-footer
.mr_target_commit
@@ -76,7 +76,7 @@
:javascript
$(".merge-request-form").on('submit', function () {
if ($("#merge_request_source_branch").val() === "" || $('#merge_request_target_branch').val() === "") {
- $(".mr-compare-errors").html("You must select source and target branch to proceed");
+ $(".mr-compare-errors").html("必须选择来源和目标分支去处理");
$(".mr-compare-errors").fadeIn();
event.preventDefault();
return;
diff --git a/app/views/projects/merge_requests/_new_submit.html.haml b/app/views/projects/merge_requests/_new_submit.html.haml
index 9e59f7df71b..4fad7e9f6fd 100644
--- a/app/views/projects/merge_requests/_new_submit.html.haml
+++ b/app/views/projects/merge_requests/_new_submit.html.haml
@@ -1,14 +1,14 @@
%h3.page-title
- New Merge Request
+ 新合并请求
%p.slead
- source_title, target_title = format_mr_branch_names(@merge_request)
- From
+ 从
%strong.label-branch #{source_title}
- %span into
+ %span 合并到
%strong.label-branch #{target_title}
%span.pull-right
- = link_to 'Change branches', mr_change_branches_path(@merge_request)
+ = link_to '改变分支', mr_change_branches_path(@merge_request)
%hr
= form_for [@project.namespace.becomes(Namespace), @project, @merge_request], html: { class: 'merge-request-form form-horizontal gfm-form js-requires-input' } do |f|
= render 'shared/issuable/form', f: f, issuable: @merge_request
diff --git a/app/views/projects/merge_requests/edit.html.haml b/app/views/projects/merge_requests/edit.html.haml
index fc62bb5bce9..5377cc65836 100644
--- a/app/views/projects/merge_requests/edit.html.haml
+++ b/app/views/projects/merge_requests/edit.html.haml
@@ -1,7 +1,7 @@
-- page_title "Edit", "#{@merge_request.title} (##{@merge_request.iid})", "Merge Requests"
+- page_title "编辑", "#{@merge_request.title} (##{@merge_request.iid})", "合并请求"
= render "header_title"
%h3.page-title
- Edit Merge Request ##{@merge_request.iid}
+ 编辑合并请求 ##{@merge_request.iid}
%hr
= render 'form'
diff --git a/app/views/projects/merge_requests/index.html.haml b/app/views/projects/merge_requests/index.html.haml
index e56a44e0a79..c4bff00892f 100644
--- a/app/views/projects/merge_requests/index.html.haml
+++ b/app/views/projects/merge_requests/index.html.haml
@@ -1,4 +1,4 @@
-- page_title "Merge Requests"
+- page_title "合并请求"
= render "header_title"
= render 'projects/last_push'
@@ -10,9 +10,9 @@
- merge_project = can?(current_user, :create_merge_request, @project) ? @project : (current_user && current_user.fork_of(@project))
- if merge_project
- = link_to new_namespace_project_merge_request_path(merge_project.namespace, merge_project), class: "btn btn-new", title: "New Merge Request" do
+ = link_to new_namespace_project_merge_request_path(merge_project.namespace, merge_project), class: "btn btn-new", title: "新合并请求" do
= icon('plus')
- New Merge Request
+ 新合并请求
= render 'shared/issuable/filter', type: :merge_requests
diff --git a/app/views/projects/merge_requests/invalid.html.haml b/app/views/projects/merge_requests/invalid.html.haml
index fc03ee73a3d..a9cf26c83d5 100644
--- a/app/views/projects/merge_requests/invalid.html.haml
+++ b/app/views/projects/merge_requests/invalid.html.haml
@@ -1,4 +1,4 @@
-- page_title "#{@merge_request.title} (##{@merge_request.iid})", "Merge Requests"
+- page_title "#{@merge_request.title} (##{@merge_request.iid})", "合并请求"
= render "header_title"
.merge-request
@@ -7,20 +7,20 @@
.alert.alert-danger
%p
- We cannot render this merge request properly because
+ 我们不能展示此合并请求,是因为
- if @merge_request.for_fork? && !@merge_request.source_project
- fork project was removed
+ 派生项目被删除
- elsif !@merge_request.source_branch_exists?
- %span.label.label-inverse= @merge_request.source_branch
- does not exist in
%span.label.label-info= @merge_request.source_project_path
+ 中不存在
+ %span.label.label-inverse= @merge_request.source_branch
- elsif !@merge_request.target_branch_exists?
- %span.label.label-inverse= @merge_request.target_branch
- does not exist in
%span.label.label-info= @merge_request.target_project_path
+ 中不存在
+ %span.label.label-inverse= @merge_request.target_branch
- else
- of internal error
+ 存在内部错误
%strong
- Please close Merge Request or change branches with existing one
+ 请关闭此合并请求或者修改为存在的分支
diff --git a/app/views/projects/merge_requests/new.html.haml b/app/views/projects/merge_requests/new.html.haml
index d259968030e..a7973637078 100644
--- a/app/views/projects/merge_requests/new.html.haml
+++ b/app/views/projects/merge_requests/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "New Merge Request"
+- page_title "新合并请求"
= render "header_title"
- if @merge_request.can_be_created && !params[:change_branches]
diff --git a/app/views/projects/merge_requests/show/_commits.html.haml b/app/views/projects/merge_requests/show/_commits.html.haml
index a8f09f855d4..5c73c53045a 100644
--- a/app/views/projects/merge_requests/show/_commits.html.haml
+++ b/app/views/projects/merge_requests/show/_commits.html.haml
@@ -1,5 +1,5 @@
.content-block.oneline-block
= icon("sort-amount-desc")
- Most recent commits displayed first
+ 首先显示最近提交
= render "projects/commits/commits", project: @merge_request.project
diff --git a/app/views/projects/merge_requests/show/_how_to_merge.html.haml b/app/views/projects/merge_requests/show/_how_to_merge.html.haml
index 0dbd159298e..ce5adf837b4 100644
--- a/app/views/projects/merge_requests/show/_how_to_merge.html.haml
+++ b/app/views/projects/merge_requests/show/_how_to_merge.html.haml
@@ -3,11 +3,11 @@
.modal-content
.modal-header
%a.close{href: "#", "data-dismiss" => "modal"} ×
- %h3 Check out, review, and merge locally
+ %h3 检出,在本地审查和合并
.modal-body
%p
- %strong Step 1.
- Fetch and check out the branch for this merge request
+ %strong 第 1 步.
+ 获取并检出此合并请求的分支
= clipboard_button(clipboard_target: 'pre#merge-info-1')
%pre.dark#merge-info-1
- if @merge_request.for_fork?
@@ -19,12 +19,12 @@
git fetch origin
git checkout -b #{h @merge_request.source_branch} origin/#{h @merge_request.source_branch}
%p
- %strong Step 2.
- Review the changes locally
+ %strong 第 2 步.
+ 本地审查变更
%p
- %strong Step 3.
- Merge the branch and fix any conflicts that come up
+ %strong 第 3 步.
+ 合并分支并修复出现的任何冲突
= clipboard_button(clipboard_target: 'pre#merge-info-3')
%pre.dark#merge-info-3
- if @merge_request.for_fork?
@@ -36,19 +36,20 @@
git checkout #{h @merge_request.target_branch}
git merge --no-ff #{h @merge_request.source_branch}
%p
- %strong Step 4.
- Push the result of the merge to GitLab
+ %strong 第 4 步.
+ 推送合并的结果到 GitLab
= clipboard_button(clipboard_target: 'pre#merge-info-4')
%pre.dark#merge-info-4
:preserve
git push origin #{h @merge_request.target_branch}
- unless @merge_request.can_be_merged_by?(current_user)
%p
- Note that pushing to GitLab requires write access to this repository.
+ 请注意推送到 GitLab 需要有此仓库的写权限。
%p
- %strong Tip:
- You can also checkout merge requests locally by
- %a{href: 'https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/workflow/merge_requests.md#checkout-merge-requests-locally', target: '_blank'} following these guidelines
+ %strong 提示:
+ 你可以使用
+ %a{href: 'https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/workflow/merge_requests.md#checkout-merge-requests-locally', target: '_blank'} 此指南
+ 在本地检出合并请求
:javascript
$(function(){
diff --git a/app/views/projects/merge_requests/widget/_closed.html.haml b/app/views/projects/merge_requests/widget/_closed.html.haml
index f3cc0e7e8a1..9d399d1c932 100644
--- a/app/views/projects/merge_requests/widget/_closed.html.haml
+++ b/app/views/projects/merge_requests/widget/_closed.html.haml
@@ -2,11 +2,11 @@
= render 'projects/merge_requests/widget/heading'
.mr-widget-body
%h4
- Closed
+ 已关闭
- if @merge_request.closed_event
- by #{link_to_member(@project, @merge_request.closed_event.author, avatar: true)}
+ 由 #{link_to_member(@project, @merge_request.closed_event.author, avatar: true)}
#{time_ago_with_tooltip(@merge_request.closed_event.created_at)}
%p
- = succeed '.' do
- The changes were not merged into
+ = succeed '。' do
+ 变更未合并到
%span.label-branch= @merge_request.target_branch
diff --git a/app/views/projects/merge_requests/widget/_heading.html.haml b/app/views/projects/merge_requests/widget/_heading.html.haml
index b05ab869215..355150e812b 100644
--- a/app/views/projects/merge_requests/widget/_heading.html.haml
+++ b/app/views/projects/merge_requests/widget/_heading.html.haml
@@ -3,13 +3,13 @@
.ci_widget{class: "ci-#{@ci_commit.status}"}
= ci_status_icon(@ci_commit)
%span
- Build
+ 构建
= ci_status_label(@ci_commit)
- for
- = succeed "." do
+ :
+ = succeed "。" do
= link_to @ci_commit.short_sha, namespace_project_commit_path(@merge_request.source_project.namespace, @merge_request.source_project, @ci_commit.sha), class: "monospace"
%span.ci-coverage
- = link_to "View details", builds_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: "js-show-tab", data: {action: 'builds'}
+ = link_to "查看构建明细", builds_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: "js-show-tab", data: {action: 'builds'}
- elsif @merge_request.has_ci?
- # Compatibility with old CI integrations (ex jenkins) when you request status from CI server via AJAX
@@ -19,27 +19,27 @@
.ci_widget{class: "ci-#{status}", style: "display:none"}
= ci_icon_for_status(status)
%span
- CI build
+ CI 构建
= ci_label_for_status(status)
- for
+ :
- commit = @merge_request.last_commit
- = succeed "." do
+ = succeed "。" do
= link_to commit.short_id, namespace_project_commit_path(@merge_request.source_project.namespace, @merge_request.source_project, commit), class: "monospace"
%span.ci-coverage
- if details_path = ci_build_details_path(@merge_request)
- = link_to "View details", details_path, :"data-no-turbolink" => "data-no-turbolink"
+ = link_to "查看明细", details_path, :"data-no-turbolink" => "data-no-turbolink"
.ci_widget
= icon("spinner spin")
- Checking CI status for #{@merge_request.last_commit_short_sha}&hellip;
+ 正在检查 #{@merge_request.last_commit_short_sha} 的构建状态&hellip;
.ci_widget.ci-not_found{style: "display:none"}
= icon("times-circle")
- Could not find CI status for #{@merge_request.last_commit_short_sha}.
+ 在 CI 服务器上无法找到 #{@merge_request.last_commit_short_sha} 的提交。
.ci_widget.ci-error{style: "display:none"}
= icon("times-circle")
- Could not connect to the CI server. Please check your settings and try again.
+ 无法连接到 CI 服务器。请检查相关设置并重试。
:javascript
$(function() {
diff --git a/app/views/projects/merge_requests/widget/_locked.html.haml b/app/views/projects/merge_requests/widget/_locked.html.haml
index 78d0783cba0..8afbe93f4ae 100644
--- a/app/views/projects/merge_requests/widget/_locked.html.haml
+++ b/app/views/projects/merge_requests/widget/_locked.html.haml
@@ -3,7 +3,7 @@
.mr-widget-body
%h4
= icon("spinner spin")
- Merge in progress&hellip;
+ 正在合并&hellip;
%p
- This merge request is in the process of being merged, during which time it is locked and cannot be closed.
+ 正在合并中。合并时此请求被锁定且不能被关闭。
diff --git a/app/views/projects/merge_requests/widget/_merged.html.haml b/app/views/projects/merge_requests/widget/_merged.html.haml
index 3abae9f0bf6..b137fe11831 100644
--- a/app/views/projects/merge_requests/widget/_merged.html.haml
+++ b/app/views/projects/merge_requests/widget/_merged.html.haml
@@ -2,32 +2,32 @@
= render 'projects/merge_requests/widget/heading'
.mr-widget-body
%h4
- Merged
+ 已合并
- if @merge_request.merge_event
- by #{link_to_member(@project, @merge_request.merge_event.author, avatar: true)}
+ 提交者:#{link_to_member(@project, @merge_request.merge_event.author, avatar: true)}
#{time_ago_with_tooltip(@merge_request.merge_event.created_at)}
%div
- if !@merge_request.source_branch_exists? || (params[:delete_source] == 'true')
%p
- The changes were merged into
- #{link_to @merge_request.target_branch, namespace_project_commits_path(@project.namespace, @project, @merge_request.target_branch), class: "label-branch"}.
- The source branch has been removed.
+ 变更已合并到
+ #{link_to @merge_request.target_branch, namespace_project_commits_path(@project.namespace, @project, @merge_request.target_branch), class: "label-branch"},
+ 来源分支已被删除。
= render 'projects/merge_requests/widget/merged_buttons'
- elsif @merge_request.can_remove_source_branch?(current_user)
.remove_source_branch_widget
%p
- The changes were merged into
- #{link_to @merge_request.target_branch, namespace_project_commits_path(@project.namespace, @project, @merge_request.target_branch), class: "label-branch"}.
- You can remove the source branch now.
+ 变更已合并到
+ #{link_to @merge_request.target_branch, namespace_project_commits_path(@project.namespace, @project, @merge_request.target_branch), class: "label-branch"},
+ 你现在可以删除来源分支。
= render 'projects/merge_requests/widget/merged_buttons', source_branch_exists: true
.remove_source_branch_widget.failed.hide
%p
- Failed to remove source branch '#{@merge_request.source_branch}'.
+ 删除来源分支 '#{@merge_request.source_branch}' 失败。
.remove_source_branch_in_progress.hide
%p
= icon('spinner spin')
- Removing source branch '#{@merge_request.source_branch}'. Please wait, this page will be automatically reloaded.
+ 正在删除来源分支 '#{@merge_request.source_branch}'。请稍候,页面将会被自动重载。
:javascript
$('.remove_source_branch').on('click', function() {
diff --git a/app/views/projects/merge_requests/widget/_merged_buttons.haml b/app/views/projects/merge_requests/widget/_merged_buttons.haml
index 85a3a6ba9e2..586aa2a167e 100644
--- a/app/views/projects/merge_requests/widget/_merged_buttons.haml
+++ b/app/views/projects/merge_requests/widget/_merged_buttons.haml
@@ -6,6 +6,6 @@
- if source_branch_exists
= link_to namespace_project_branch_path(@merge_request.source_project.namespace, @merge_request.source_project, @merge_request.source_branch), remote: true, method: :delete, class: "btn btn-default btn-grouped btn-sm remove_source_branch" do
= icon('trash-o')
- Remove Source Branch
+ 删除来源分支
- if mr_can_be_reverted
= revert_commit_link(@merge_request.merge_commit, namespace_project_merge_request_path(@project.namespace, @project, @merge_request), btn_class: 'sm')
diff --git a/app/views/projects/merge_requests/widget/_open.html.haml b/app/views/projects/merge_requests/widget/_open.html.haml
index 55dbae598d3..07986141e68 100644
--- a/app/views/projects/merge_requests/widget/_open.html.haml
+++ b/app/views/projects/merge_requests/widget/_open.html.haml
@@ -24,6 +24,6 @@
.mr-widget-footer
%span
%i.fa.fa-check
- Accepting this merge request will close #{"issue".pluralize(@closes_issues.size)}
- = succeed '.' do
+ 正在接受此合并请求并将关闭 #{"个问题".pluralize(@closes_issues.size)}
+ = succeed '。' do
!= markdown issues_sentence(@closes_issues), pipeline: :gfm
diff --git a/app/views/projects/merge_requests/widget/open/_accept.html.haml b/app/views/projects/merge_requests/widget/open/_accept.html.haml
index 807833741af..3a87e98db45 100644
--- a/app/views/projects/merge_requests/widget/open/_accept.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_accept.html.haml
@@ -8,32 +8,32 @@
- if @ci_commit && @ci_commit.active?
%span.btn-group
= button_tag class: "btn btn-create js-merge-button merge_when_build_succeeds" do
- Merge When Build Succeeds
+ 构建成功时合并
= button_tag class: "btn btn-success dropdown-toggle", 'data-toggle' => 'dropdown' do
%span.caret
%span.sr-only
- Select Merge Moment
+ 选择合并瞬间
%ul.js-merge-dropdown.dropdown-menu.dropdown-menu-right{ role: 'menu' }
%li
= link_to "#", class: "merge_when_build_succeeds" do
= icon('check fw')
- Merge When Build Succeeds
+ 构建成功时合并
%li
= link_to "#", class: "accept_merge_request" do
= icon('warning fw')
- Merge Immediately
+ 立即合并
- else
= f.button class: "btn btn-create btn-grouped js-merge-button accept_merge_request #{status_class}" do
- Accept Merge Request
+ 接受合并请求
- if @merge_request.can_remove_source_branch?(current_user)
.accept-control.checkbox
= label_tag :should_remove_source_branch, class: "remove_source_checkbox" do
= check_box_tag :should_remove_source_branch
- Remove source branch
+ 删除来源分支
.accept-control.right
= link_to "#", class: "modify-merge-commit-link js-toggle-button" do
= icon('edit')
- Modify commit message
+ 修改提交信息
.js-toggle-content.hide.prepend-top-default
= render 'shared/commit_message_container', params: params,
text: @merge_request.merge_commit_message,
@@ -47,7 +47,7 @@
});
$('.accept_merge_request').on('click', function() {
- $('.js-merge-button').html("<i class='fa fa-spinner fa-spin'></i> Merge in progress");
+ $('.js-merge-button').html("<i class='fa fa-spinner fa-spin'></i> 正在合并");
});
$('.merge_when_build_succeeds').on('click', function() {
diff --git a/app/views/projects/merge_requests/widget/open/_archived.html.haml b/app/views/projects/merge_requests/widget/open/_archived.html.haml
index ab30fa6b243..21e6086f9ae 100644
--- a/app/views/projects/merge_requests/widget/open/_archived.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_archived.html.haml
@@ -1,4 +1,4 @@
%h4
- Project is archived
+ 项目已归档。
%p
- This merge request cannot be merged because archived projects cannot be written to.
+ 此合并请求无法被合并,因为已归档的项目无法写入。
diff --git a/app/views/projects/merge_requests/widget/open/_check.html.haml b/app/views/projects/merge_requests/widget/open/_check.html.haml
index e16878ba513..c86ebe086b6 100644
--- a/app/views/projects/merge_requests/widget/open/_check.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_check.html.haml
@@ -1,6 +1,6 @@
%strong
= icon("spinner spin")
- Checking ability to merge automatically&hellip;
+ 正在检查自动合并&hellip;
:javascript
$(function() {
diff --git a/app/views/projects/merge_requests/widget/open/_conflicts.html.haml b/app/views/projects/merge_requests/widget/open/_conflicts.html.haml
index e6c089fefb2..38e47ee0bf6 100644
--- a/app/views/projects/merge_requests/widget/open/_conflicts.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_conflicts.html.haml
@@ -1,10 +1,10 @@
%h4
= icon("exclamation-triangle")
- This merge request contains merge conflicts
+ 此合并请求包含有合并冲突
%p
- Please resolve these conflicts or
+ 请解决这些冲突或
- if @merge_request.can_be_merged_by?(current_user)
- #{link_to "merge this request manually", "#modal_merge_info", class: "how_to_merge_link vlink", "data-toggle" => "modal"}.
+ #{link_to "手工合并此请求", "#modal_merge_info", class: "how_to_merge_link vlink", "data-toggle" => "modal"}.
- else
- ask someone with write access to this repository to merge this request manually.
+ 询问具有此仓库写权限的成员来手工合并此请求。
diff --git a/app/views/projects/merge_requests/widget/open/_merge_when_build_succeeds.html.haml b/app/views/projects/merge_requests/widget/open/_merge_when_build_succeeds.html.haml
index 2168294c683..cd0bae04cd8 100644
--- a/app/views/projects/merge_requests/widget/open/_merge_when_build_succeeds.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_merge_when_build_succeeds.html.haml
@@ -1,16 +1,16 @@
%h4
- Set by #{link_to_member(@project, @merge_request.merge_user, avatar: true)}
- to be merged automatically when the build succeeds.
+ #{link_to_member(@project, @merge_request.merge_user, avatar: true)} 设置了
+ 构建成功时自动合并。
%div
- should_remove_source_branch = @merge_request.merge_params["should_remove_source_branch"].present?
%p
- = succeed '.' do
- The changes will be merged into
+ = succeed '。' do
+ 变更将被合并到
%span.label-branch= @merge_request.target_branch
- if should_remove_source_branch
- The source branch will be removed.
+ 来源分支将被删除。
- else
- The source branch will not be removed.
+ 来源分支将不会删除。
- remove_source_branch_button = @merge_request.can_remove_source_branch?(current_user) && !should_remove_source_branch && @merge_request.merge_user == current_user
- user_can_cancel_automatic_merge = @merge_request.can_cancel_merge_when_build_succeeds?(current_user)
@@ -19,8 +19,8 @@
- if remove_source_branch_button
= link_to merge_namespace_project_merge_request_path(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request, merge_when_build_succeeds: true, should_remove_source_branch: true), remote: true, method: :post, class: "btn btn-grouped btn-primary btn-sm remove_source_branch" do
= icon('times')
- Remove Source Branch When Merged
+ 合并时删除来源分支
- if user_can_cancel_automatic_merge
= link_to cancel_merge_when_build_succeeds_namespace_project_merge_request_path(@merge_request.target_project.namespace, @merge_request.target_project, @merge_request), remote: true, method: :post, class: "btn btn-grouped btn-warning btn-sm" do
- Cancel Automatic Merge
+ 取消自动合并
diff --git a/app/views/projects/merge_requests/widget/open/_missing_branch.html.haml b/app/views/projects/merge_requests/widget/open/_missing_branch.html.haml
index c9f07629493..fd2aa3aa0c0 100644
--- a/app/views/projects/merge_requests/widget/open/_missing_branch.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_missing_branch.html.haml
@@ -1,16 +1,16 @@
- unless @merge_request.source_branch_exists?
%h4
= icon("exclamation-triangle")
- Source branch
+ 来源分支
%span.label-branch= source_branch_with_namespace(@merge_request)
- does not exist
+ 不存在
%p
- Please restore the source branch or close this merge request and open a new merge request with a different source branch.
+ 请恢复来源分支或关闭此合并请求并使用其他的来源分支开启新的合并请求。
- else
%h4
= icon("exclamation-triangle")
- Target branch
+ 目标分支
%span.label-branch= @merge_request.target_branch
- does not exist
+ 不存在
%p
- Please restore the target branch or use a different target branch.
+ 请恢复目标分支或者使用其他的目标分支。
diff --git a/app/views/projects/merge_requests/widget/open/_not_allowed.html.haml b/app/views/projects/merge_requests/widget/open/_not_allowed.html.haml
index a8145558ca8..cbbd959ebb2 100644
--- a/app/views/projects/merge_requests/widget/open/_not_allowed.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_not_allowed.html.haml
@@ -1,4 +1,4 @@
%h4
- Ready to be merged automatically
+ 已准备好自动合并
%p
- Ask someone with write access to this repository to merge this request.
+ 请询问具有此仓库写权限的成员来合并此请求。
diff --git a/app/views/projects/merge_requests/widget/open/_nothing.html.haml b/app/views/projects/merge_requests/widget/open/_nothing.html.haml
index 35626b624b7..617566885ba 100644
--- a/app/views/projects/merge_requests/widget/open/_nothing.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_nothing.html.haml
@@ -1,8 +1,9 @@
%h4
= icon("exclamation-triangle")
- Nothing to merge from
+ 从
%span.label-branch= source_branch_with_namespace(@merge_request)
- into
+ 到
%span.label-branch= @merge_request.target_branch
+ 无需合并
%p
- Please push new commits to the source branch or use a different target branch.
+ 请推送新的提交到来源分支或者使用其他的目标分支。
diff --git a/app/views/projects/merge_requests/widget/open/_reload.html.haml b/app/views/projects/merge_requests/widget/open/_reload.html.haml
index acfc31725eb..63d2ccd33a5 100644
--- a/app/views/projects/merge_requests/widget/open/_reload.html.haml
+++ b/app/views/projects/merge_requests/widget/open/_reload.html.haml
@@ -1,6 +1,6 @@
%h4
= icon("exclamation-triangle")
- This merge request failed to be merged automatically
+ 此合并请求自动合并失败
%p
- Please reload the page to find out the reason.
+ 请重新载入本页面寻找原因。
diff --git a/app/views/projects/milestones/_form.html.haml b/app/views/projects/milestones/_form.html.haml
index 23f2bca7baf..7d2545762b0 100644
--- a/app/views/projects/milestones/_form.html.haml
+++ b/app/views/projects/milestones/_form.html.haml
@@ -20,21 +20,39 @@
.error-alert
.col-md-6
.form-group
- = f.label :due_date, "Due Date", class: "control-label"
+ = f.label :due_date, "到期日", class: "control-label"
.col-sm-10= f.hidden_field :due_date
.col-sm-10
.datepicker
.form-actions
- if @milestone.new_record?
- = f.submit 'Create milestone', class: "btn-create btn"
- = link_to "Cancel", namespace_project_milestones_path(@project.namespace, @project), class: "btn btn-cancel"
+ = f.submit '创建里程碑', class: "btn-create btn"
+ = link_to "取消", namespace_project_milestones_path(@project.namespace, @project), class: "btn btn-cancel"
-else
- = f.submit 'Save changes', class: "btn-save btn"
- = link_to "Cancel", namespace_project_milestone_path(@project.namespace, @project, @milestone), class: "btn btn-cancel"
+ = f.submit '保存修改', class: "btn-save btn"
+ = link_to "取消", namespace_project_milestone_path(@project.namespace, @project, @milestone), class: "btn btn-cancel"
:javascript
+ $.datepicker.regional['zh-CN'] = {
+ closeText: '关闭',
+ prevText: '&#x3C;上月',
+ nextText: '下月&#x3E;',
+ currentText: '今天',
+ monthNames: ['一月','二月','三月','四月','五月','六月',
+ '七月','八月','九月','十月','十一月','十二月'],
+ monthNamesShort: ['一月','二月','三月','四月','五月','六月',
+ '七月','八月','九月','十月','十一月','十二月'],
+ dayNames: ['星期日','星期一','星期二','星期三','星期四','星期五','星期六'],
+ dayNamesShort: ['周日','周一','周二','周三','周四','周五','周六'],
+ dayNamesMin: ['日','一','二','三','四','五','六'],
+ weekHeader: '周',
+ isRTL: false,
+ showMonthAfterYear: true,
+ yearSuffix: '年'
+ };
+ $.datepicker.setDefaults($.datepicker.regional['zh-CN']);
$(".datepicker").datepicker({
dateFormat: "yy-mm-dd",
onSelect: function(dateText, inst) { $("#milestone_due_date").val(dateText) }
diff --git a/app/views/projects/milestones/_header_title.html.haml b/app/views/projects/milestones/_header_title.html.haml
index 5f4b6982a6d..aa665a49c5e 100644
--- a/app/views/projects/milestones/_header_title.html.haml
+++ b/app/views/projects/milestones/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Milestones", namespace_project_milestones_path(@project.namespace, @project))
+- header_title project_title(@project, "里程碑", namespace_project_milestones_path(@project.namespace, @project))
diff --git a/app/views/projects/milestones/edit.html.haml b/app/views/projects/milestones/edit.html.haml
index 43f8863163d..3e6b78210b4 100644
--- a/app/views/projects/milestones/edit.html.haml
+++ b/app/views/projects/milestones/edit.html.haml
@@ -1,8 +1,8 @@
-- page_title "Edit", @milestone.title, "Milestones"
+- page_title "编辑", @milestone.title, "里程碑"
= render "header_title"
%h3.page-title
- Edit Milestone ##{@milestone.iid}
+ 编辑里程碑 ##{@milestone.iid}
%hr
diff --git a/app/views/projects/milestones/index.html.haml b/app/views/projects/milestones/index.html.haml
index abe567af1dd..f695ee4b2ab 100644
--- a/app/views/projects/milestones/index.html.haml
+++ b/app/views/projects/milestones/index.html.haml
@@ -1,4 +1,4 @@
-- page_title "Milestones"
+- page_title "里程碑"
= render "header_title"
@@ -7,9 +7,9 @@
.nav-controls
- if can?(current_user, :admin_milestone, @project)
- = link_to new_namespace_project_milestone_path(@project.namespace, @project), class: "btn btn-new", title: "New Milestone" do
+ = link_to new_namespace_project_milestone_path(@project.namespace, @project), class: "btn btn-new", title: "新里程碑" do
= icon('plus')
- New Milestone
+ 新里程碑
.milestones
%ul.content-list
@@ -17,6 +17,6 @@
- if @milestones.blank?
%li
- .nothing-here-block No milestones to show
+ .nothing-here-block 没有里程碑
= paginate @milestones, theme: "gitlab"
diff --git a/app/views/projects/milestones/new.html.haml b/app/views/projects/milestones/new.html.haml
index 0d016f78313..685ca49df25 100644
--- a/app/views/projects/milestones/new.html.haml
+++ b/app/views/projects/milestones/new.html.haml
@@ -1,8 +1,8 @@
-- page_title "New Milestone"
+- page_title "新里程碑"
= render "header_title"
%h3.page-title
- New Milestone
+ 新里程碑
%hr
diff --git a/app/views/projects/milestones/show.html.haml b/app/views/projects/milestones/show.html.haml
index be63875ab34..0b1bfc946c1 100644
--- a/app/views/projects/milestones/show.html.haml
+++ b/app/views/projects/milestones/show.html.haml
@@ -1,4 +1,4 @@
-- page_title @milestone.title, "Milestones"
+- page_title @milestone.title, "里程碑"
- page_description @milestone.description
= render "header_title"
@@ -6,13 +6,13 @@
.detail-page-header
.status-box{ class: status_box_class(@milestone) }
- if @milestone.closed?
- Closed
+ 已关闭
- elsif @milestone.expired?
- Expired
+ 已过期
- else
- Open
+ 未关闭
%span.identifier
- Milestone ##{@milestone.iid}
+ 里程碑 ##{@milestone.iid}
- if @milestone.expires_at
%span.creator
&middot;
@@ -20,17 +20,17 @@
.pull-right
- if can?(current_user, :admin_milestone, @project)
- if @milestone.active?
- = link_to 'Close Milestone', namespace_project_milestone_path(@project.namespace, @project, @milestone, milestone: {state_event: :close }), method: :put, class: "btn btn-close btn-nr btn-grouped"
+ = link_to '关闭里程碑', namespace_project_milestone_path(@project.namespace, @project, @milestone, milestone: {state_event: :close }), method: :put, class: "btn btn-close btn-nr btn-grouped"
- else
- = link_to 'Reopen Milestone', namespace_project_milestone_path(@project.namespace, @project, @milestone, milestone: {state_event: :activate }), method: :put, class: "btn btn-reopen btn-nr btn-grouped"
+ = link_to '重新打开里程碑', namespace_project_milestone_path(@project.namespace, @project, @milestone, milestone: {state_event: :activate }), method: :put, class: "btn btn-reopen btn-nr btn-grouped"
- = link_to namespace_project_milestone_path(@project.namespace, @project, @milestone), data: { confirm: 'Are you sure?' }, method: :delete, class: "btn btn-grouped btn-nr" do
+ = link_to namespace_project_milestone_path(@project.namespace, @project, @milestone), data: { confirm: '确定要继续么?' }, method: :delete, class: "btn btn-grouped btn-nr" do
= icon('trash-o')
- Delete
+ 删除
= link_to edit_namespace_project_milestone_path(@project.namespace, @project, @milestone), class: "btn btn-grouped btn-nr" do
= icon('pencil-square-o')
- Edit
+ 编辑
.detail-page-description.milestone-detail.second-block
%h2.title
diff --git a/app/views/projects/network/_head.html.haml b/app/views/projects/network/_head.html.haml
index 28a617538b5..3b31c77f379 100644
--- a/app/views/projects/network/_head.html.haml
+++ b/app/views/projects/network/_head.html.haml
@@ -3,4 +3,4 @@
= render partial: 'shared/ref_switcher', locals: {destination: 'graph'}
.oneline
- You can move around the graph by using the arrow keys.
+ 你可以使用光标键移动图表。
diff --git a/app/views/projects/network/show.html.haml b/app/views/projects/network/show.html.haml
index 8065663ca2a..d17d4e17f2d 100644
--- a/app/views/projects/network/show.html.haml
+++ b/app/views/projects/network/show.html.haml
@@ -1,18 +1,18 @@
-- page_title "Network", @ref
+- page_title "网络", @ref
= render "projects/commits/header_title"
= render "projects/commits/head"
= render "head"
.project-network
.controls
= form_tag namespace_project_network_path(@project.namespace, @project, @id), method: :get, class: 'form-inline network-form' do |f|
- = text_field_tag :extended_sha1, @options[:extended_sha1], placeholder: "Input an extended SHA1 syntax", class: 'search-input form-control input-mx-250 search-sha'
+ = text_field_tag :extended_sha1, @options[:extended_sha1], placeholder: "输入扩展 SHA1 语法", class: 'search-input form-control input-mx-250 search-sha'
= button_tag class: 'btn btn-success' do
= icon('search')
.inline.prepend-left-20
.checkbox.light
= label_tag :filter_ref do
= check_box_tag :filter_ref, 1, @options[:filter_ref]
- %span Begin with the selected commit
+ %span 从选择的提交开始
.network-graph
= spinner nil, true
diff --git a/app/views/projects/new.html.haml b/app/views/projects/new.html.haml
index 25233112132..0d6b1cb6bf9 100644
--- a/app/views/projects/new.html.haml
+++ b/app/views/projects/new.html.haml
@@ -1,8 +1,8 @@
-- page_title 'New Project'
-- header_title "Projects", root_path
+- page_title '新项目'
+- header_title "项目", root_path
%h3.page-title
- New Project
+ 新项目
%hr
.project-edit-container
@@ -13,7 +13,7 @@
= form_for @project, html: { class: 'new_project form-horizontal js-requires-input' } do |f|
.form-group.project-name-holder
= f.label :path, class: 'control-label' do
- Project path
+ 项目路径
.col-sm-10
.input-group
- if current_user.can_select_namespace?
@@ -29,13 +29,13 @@
- if current_user.can_create_group?
.help-block
- Want to house several dependent projects under the same namespace?
- = link_to "Create a group", new_group_path
+ 希望将几个相关联的项目放置于同一个命名空间下?
+ = link_to "创建群组", new_group_path
- if import_sources_enabled?
.project-import.js-toggle-container
.form-group
- %label.control-label Import project from
+ %label.control-label 导入项目
.col-sm-10
- if github_import_enabled?
- if github_import_configured?
@@ -78,7 +78,7 @@
- if google_code_import_enabled?
= link_to new_import_google_code_path, class: 'btn import_google_code' do
%i.fa.fa-google
- Google Code
+ Google 代码
- if fogbugz_import_enabled?
= link_to new_import_fogbugz_path, class: 'btn import_fogbugz' do
@@ -88,7 +88,7 @@
- if git_import_enabled?
= link_to "#", class: 'btn js-toggle-button import_git' do
%i.fa.fa-git
- %span Any repo by URL
+ %span 其他仓库的链接
.js-toggle-content.hide
= render "shared/import_form", f: f
@@ -97,22 +97,22 @@
.form-group
= f.label :description, class: 'control-label' do
- Description
- %span.light (optional)
+ 描述
+ %span.light (可选)
.col-sm-10
= f.text_area :description, class: "form-control", rows: 3, maxlength: 250, tabindex: 3
= render 'shared/visibility_level', f: f, visibility_level: default_project_visibility, can_change_visibility_level: true, form_model: @project
.form-actions
- = f.submit 'Create project', class: "btn btn-create project-submit", tabindex: 4
- = link_to 'Cancel', dashboard_projects_path, class: 'btn btn-cancel'
+ = f.submit '创建项目', class: "btn btn-create project-submit", tabindex: 4
+ = link_to '取消', dashboard_projects_path, class: 'btn btn-cancel'
.save-project-loader.hide
.center
%h2
%i.fa.fa-spinner.fa-spin
- Creating project &amp; repository.
- %p Please wait a moment, this page will automatically refresh when ready.
+ 正在创建项目 &amp; 版本库。
+ %p 请稍候,页面会处理完成后自动刷新。
:javascript
$('.how_to_import_link').bind('click', function (e) {
diff --git a/app/views/projects/no_repo.html.haml b/app/views/projects/no_repo.html.haml
index 720957e8336..f0e403e714f 100644
--- a/app/views/projects/no_repo.html.haml
+++ b/app/views/projects/no_repo.html.haml
@@ -1,22 +1,22 @@
%h2
%i.fa.fa-warning
- No repository
+ 没有仓库
%p.slead
- The repository for this project does not exist.
+ 该项目的仓库不存在。
%br
- This means you can not push code until you create an empty repository or import existing one.
+ 这意味着如果不创建一个新仓库或者导入已存在的仓库,就不能推送代码。
%hr
.no-repo-actions
= link_to namespace_project_repository_path(@project.namespace, @project), method: :post, class: 'btn btn-primary' do
- Create empty bare repository
+ 创建空的纯仓库
%strong.prepend-left-10.append-right-10 or
= link_to new_namespace_project_import_path(@project.namespace, @project), class: 'btn' do
- Import repository
+ 导入仓库
- if can? current_user, :remove_project, @project
.prepend-top-20
- = link_to 'Remove project', project_path(@project), data: { confirm: remove_project_message(@project)}, method: :delete, class: "btn btn-remove pull-right"
+ = link_to '删除项目', project_path(@project), data: { confirm: remove_project_message(@project)}, method: :delete, class: "btn btn-remove pull-right"
diff --git a/app/views/projects/notes/_hints.html.haml b/app/views/projects/notes/_hints.html.haml
index 6e7929bdab0..c08c15c173e 100644
--- a/app/views/projects/notes/_hints.html.haml
+++ b/app/views/projects/notes/_hints.html.haml
@@ -1,9 +1,9 @@
.comment-hints.clearfix
.pull-left
= link_to 'Markdown', help_page_path('markdown', 'markdown'), target: '_blank', tabindex: -1
- tip:
+ 提示:
= random_markdown_tip
.pull-right
= link_to '#', class: 'markdown-selector', tabindex: -1 do
= icon('paperclip')
- Attach a file
+ 附加文件
diff --git a/app/views/projects/notes/_note.html.haml b/app/views/projects/notes/_note.html.haml
index 2cf32e6093d..f7eeaece3db 100644
--- a/app/views/projects/notes/_note.html.haml
+++ b/app/views/projects/notes/_note.html.haml
@@ -7,10 +7,10 @@
.note-header
- if note_editable?(note)
.note-actions
- = link_to '#', title: 'Edit comment', class: 'js-note-edit' do
+ = link_to '#', title: '编辑评论', class: 'js-note-edit' do
= icon('pencil-square-o')
- = link_to namespace_project_note_path(note.project.namespace, note.project, note), title: 'Remove comment', method: :delete, data: { confirm: 'Are you sure you want to remove this comment?' }, remote: true, class: 'js-note-delete danger' do
+ = link_to namespace_project_note_path(note.project.namespace, note.project, note), title: '删除评论', method: :delete, data: { confirm: '确定要删除评论么?' }, remote: true, class: 'js-note-delete danger' do
= icon('trash-o')
- unless note.system
diff --git a/app/views/projects/notes/_notes_with_form.html.haml b/app/views/projects/notes/_notes_with_form.html.haml
index 910eb6cf66e..ce29ffd5b92 100644
--- a/app/views/projects/notes/_notes_with_form.html.haml
+++ b/app/views/projects/notes/_notes_with_form.html.haml
@@ -10,11 +10,11 @@
.disabled-profile
.disabled-comment
%span
- Please
- = link_to "register",new_user_session_path
- or
- = link_to "login",new_user_session_path
- to post a comment
+ 请
+ = link_to "注册",new_user_session_path
+ 或
+ = link_to "登录",new_user_session_path
+ 后发表评论
:javascript
var notes = new Notes("#{namespace_project_notes_path(namespace_id: @project.namespace, target_id: @noteable.id, target_type: @noteable.class.name.underscore)}", #{@notes.map(&:id).to_json}, #{Time.now.to_i}, "#{diff_view}")
diff --git a/app/views/projects/notes/discussions/_active.html.haml b/app/views/projects/notes/discussions/_active.html.haml
index 4f15a99d061..c8aa17da5fb 100644
--- a/app/views/projects/notes/discussions/_active.html.haml
+++ b/app/views/projects/notes/discussions/_active.html.haml
@@ -4,15 +4,15 @@
.discussion-actions
= link_to "#", class: "js-toggle-button" do
%i.fa.fa-chevron-up
- Show/hide discussion
+ 显示/隐藏讨论
%div
= link_to_member(@project, note.author, avatar: false)
- started a discussion
+ 开始讨论
= link_to diffs_namespace_project_merge_request_path(note.project.namespace, note.project, note.noteable, anchor: note.line_code) do
- %strong on the diff
+ %strong 在差异
.last-update.hide.js-toggle-content
- last_note = discussion_notes.last
- last updated by
+ 最后更新:
= link_to_member(@project, last_note.author, avatar: false)
%span.discussion-last-update
diff --git a/app/views/projects/notes/discussions/_commit.html.haml b/app/views/projects/notes/discussions/_commit.html.haml
index 3da2f2060b8..417651d7e16 100644
--- a/app/views/projects/notes/discussions/_commit.html.haml
+++ b/app/views/projects/notes/discussions/_commit.html.haml
@@ -4,14 +4,14 @@
.discussion-actions
= link_to "#", class: "js-toggle-button" do
%i.fa.fa-chevron-up
- Show/hide discussion
+ 显示/隐藏讨论
%div
= link_to_member(@project, note.author, avatar: false)
- started a discussion on commit
+ 开始讨论在提交
= link_to(note.noteable.short_id, namespace_project_commit_path(note.project.namespace, note.project, note.noteable), class: 'monospace')
.last-update.hide.js-toggle-content
- last_note = discussion_notes.last
- last updated by
+ 最后更新:
= link_to_member(@project, last_note.author, avatar: false)
%span.discussion-last-update
#{time_ago_with_tooltip(last_note.updated_at, placement: 'bottom', html_class: 'discussion_updated_ago')}
diff --git a/app/views/projects/notes/discussions/_outdated.html.haml b/app/views/projects/notes/discussions/_outdated.html.haml
index 218b0da3977..2788e2d1e32 100644
--- a/app/views/projects/notes/discussions/_outdated.html.haml
+++ b/app/views/projects/notes/discussions/_outdated.html.haml
@@ -4,14 +4,14 @@
.discussion-actions
= link_to "#", class: "js-toggle-button" do
%i.fa.fa-chevron-down
- Show/hide discussion
+ 显示/隐藏讨论
%div
= link_to_member(@project, note.author, avatar: false)
- started a discussion on the
- %strong outdated diff
+ 开始讨论在
+ %strong 过期的差异
%div
- last_note = discussion_notes.last
- last updated by
+ 最后更新:
= link_to_member(@project, last_note.author, avatar: false)
%span.discussion-last-update
#{time_ago_with_tooltip(last_note.updated_at, placement: 'bottom', html_class: 'discussion_updated_ago')}
diff --git a/app/views/projects/project_members/_group_members.html.haml b/app/views/projects/project_members/_group_members.html.haml
index c53033e367c..e5e9128ac89 100644
--- a/app/views/projects/project_members/_group_members.html.haml
+++ b/app/views/projects/project_members/_group_members.html.haml
@@ -1,17 +1,17 @@
.panel.panel-default
.panel-heading
%strong #{@group.name}
- group members
+ 群组成员
%small
(#{members.count})
- if can?(current_user, :admin_group_member, @group)
.controls
= link_to group_group_members_path(@group), class: 'btn' do
= icon('pencil-square-o')
- Manage group members
+ 编辑群组成员
%ul.content-list
- members.limit(20).each do |member|
= render 'groups/group_members/group_member', member: member, show_controls: false
- if members.count > 20
%li
- and #{members.count - 20} more. For full list visit #{link_to 'group members page', group_group_members_path(@group)}
+ 和 #{members.count - 20} 个更多成员。完整列表请访问#{link_to '群组成员页面', group_group_members_path(@group)}
diff --git a/app/views/projects/project_members/_header_title.html.haml b/app/views/projects/project_members/_header_title.html.haml
index a31f0a37fa2..a30bbea79fd 100644
--- a/app/views/projects/project_members/_header_title.html.haml
+++ b/app/views/projects/project_members/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Members", namespace_project_project_members_path(@project.namespace, @project))
+- header_title project_title(@project, "成员", namespace_project_project_members_path(@project.namespace, @project))
diff --git a/app/views/projects/project_members/_new_project_member.html.haml b/app/views/projects/project_members/_new_project_member.html.haml
index f0f3bb3c177..c31a236fedc 100644
--- a/app/views/projects/project_members/_new_project_member.html.haml
+++ b/app/views/projects/project_members/_new_project_member.html.haml
@@ -1,18 +1,18 @@
= form_for @project_member, as: :project_member, url: namespace_project_project_members_path(@project.namespace, @project), html: { class: 'form-horizontal users-project-form' } do |f|
.form-group
- = f.label :user_ids, "People", class: 'control-label'
+ = f.label :user_ids, "人", class: 'control-label'
.col-sm-10
= users_select_tag(:user_ids, multiple: true, class: 'input-large', scope: :all, email_user: true)
.help-block
- Search for users by name, username, or email, or invite new ones using their email address.
+ 搜索已存在的用户或使用电子邮箱地址邀请新用户。
.form-group
- = f.label :access_level, "Project Access", class: 'control-label'
+ = f.label :access_level, "项目访问", class: 'control-label'
.col-sm-10
= select_tag :access_level, options_for_select(ProjectMember.access_roles, @project_member.access_level), class: "project-access-select select2"
.help-block
- Read more about role permissions
- %strong= link_to "here", help_page_path("permissions", "permissions"), class: "vlink"
+ 关于角色权限的更多内容请参阅
+ %strong= link_to "这里", help_page_path("permissions", "permissions"), class: "vlink"
.form-actions
- = f.submit 'Add users to project', class: "btn btn-create"
+ = f.submit '增加用户到项目', class: "btn btn-create"
diff --git a/app/views/projects/project_members/_project_member.html.haml b/app/views/projects/project_members/_project_member.html.haml
index 05bf3a7ef6a..d2f30725122 100644
--- a/app/views/projects/project_members/_project_member.html.haml
+++ b/app/views/projects/project_members/_project_member.html.haml
@@ -9,41 +9,41 @@
= link_to user.name, user_path(user)
%span.cgray= user.username
- if user == current_user
- %span.label.label-success It's you
+ %span.label.label-success 自己
- if user.blocked?
%label.label.label-danger
- %strong Blocked
+ %strong 已禁用
- else
= image_tag avatar_icon(member.invite_email, 24), class: "avatar s24", alt: ''
%strong
= member.invite_email
%span.cgray
- invited
+ 被
- if member.created_by
- by
= link_to member.created_by.name, user_path(member.created_by)
+ 邀请
= time_ago_with_tooltip(member.created_at)
- if can?(current_user, :admin_project_member, @project)
- = link_to resend_invite_namespace_project_project_member_path(@project.namespace, @project, member), method: :post, class: "btn-xs btn", title: 'Resend invite' do
- Resend invite
+ = link_to resend_invite_namespace_project_project_member_path(@project.namespace, @project, member), method: :post, class: "btn-xs btn", title: '重发邀请' do
+ 重发邀请
- if can?(current_user, :admin_project_member, @project)
.pull-right
%strong= member.human_access
- if can?(current_user, :update_project_member, member)
= button_tag class: "btn-xs btn js-toggle-button",
- title: 'Edit access level', type: 'button' do
+ title: '编辑访问等级', type: 'button' do
%i.fa.fa-pencil-square-o
- if can?(current_user, :destroy_project_member, member)
&nbsp;
- if current_user == user
- = link_to leave_namespace_project_project_members_path(@project.namespace, @project), data: { confirm: leave_project_message(@project) }, method: :delete, class: "btn-xs btn btn-remove", title: 'Leave project' do
+ = link_to leave_namespace_project_project_members_path(@project.namespace, @project), data: { confirm: leave_project_message(@project) }, method: :delete, class: "btn-xs btn btn-remove", title: '离开项目' do
= icon("sign-out")
- Leave
+ 离开
- else
- = link_to namespace_project_project_member_path(@project.namespace, @project, member), data: { confirm: remove_from_project_team_message(@project, member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: 'Remove user from team' do
+ = link_to namespace_project_project_member_path(@project.namespace, @project, member), data: { confirm: remove_from_project_team_message(@project, member) }, method: :delete, remote: true, class: "btn-xs btn btn-remove", title: '从团队中删除用户' do
%i.fa.fa-minus.fa-inverse
.edit-member.hide.js-toggle-content
@@ -52,4 +52,4 @@
.prepend-top-10
= f.select :access_level, options_for_select(ProjectMember.access_roles, member.access_level), {}, class: 'form-control'
.prepend-top-10
- = f.submit 'Save', class: 'btn btn-save'
+ = f.submit '保存', class: 'btn btn-save'
diff --git a/app/views/projects/project_members/_team.html.haml b/app/views/projects/project_members/_team.html.haml
index e8dce30425f..d81138ce275 100644
--- a/app/views/projects/project_members/_team.html.haml
+++ b/app/views/projects/project_members/_team.html.haml
@@ -1,14 +1,14 @@
.panel.panel-default
.panel-heading
%strong #{@project.name}
- project members
+ 项目成员
%small
(#{members.count})
.controls
= form_tag namespace_project_project_members_path(@project.namespace, @project), method: :get, class: 'form-inline member-search-form' do
.form-group
- = search_field_tag :search, params[:search], { placeholder: 'Find existing member by name', class: 'form-control', spellcheck: false }
- = button_tag class: 'btn', title: 'Search' do
+ = search_field_tag :search, params[:search], { placeholder: '使用名称查找已存在的成员', class: 'form-control', spellcheck: false }
+ = button_tag class: 'btn', title: '搜索' do
= icon("search")
%ul.content-list
- members.each do |project_member|
diff --git a/app/views/projects/project_members/import.html.haml b/app/views/projects/project_members/import.html.haml
index 189906498cb..ee6bf31f1a2 100644
--- a/app/views/projects/project_members/import.html.haml
+++ b/app/views/projects/project_members/import.html.haml
@@ -1,17 +1,17 @@
-- page_title "Import members"
+- page_title "导入成员"
= render "header_title"
%h3.page-title
- Import members from another project
+ 从其他项目导入成员
%p.light
- Only project members will be imported. Group members will be skipped.
+ 只有项目成员才能被导入。群组成员会被跳过。
%hr
= form_tag apply_import_namespace_project_project_members_path(@project.namespace, @project), method: 'post', class: 'form-horizontal' do
.form-group
- = label_tag :source_project_id, "Project", class: 'control-label'
- .col-sm-10= select_tag(:source_project_id, options_from_collection_for_select(current_user.authorized_projects, :id, :name_with_namespace), prompt: "Select project", class: "select2 lg", required: true)
+ = label_tag :source_project_id, "项目", class: 'control-label'
+ .col-sm-10= select_tag(:source_project_id, options_from_collection_for_select(current_user.authorized_projects, :id, :name_with_namespace), prompt: "选择项目", class: "select2 lg", required: true)
.form-actions
- = button_tag 'Import project members', class: "btn btn-create"
- = link_to "Cancel", namespace_project_project_members_path(@project.namespace, @project), class: "btn btn-cancel"
+ = button_tag '导入项目成员', class: "btn btn-create"
+ = link_to "取消", namespace_project_project_members_path(@project.namespace, @project), class: "btn btn-cancel"
diff --git a/app/views/projects/project_members/index.html.haml b/app/views/projects/project_members/index.html.haml
index ebcfc907ebb..01c63991fbd 100644
--- a/app/views/projects/project_members/index.html.haml
+++ b/app/views/projects/project_members/index.html.haml
@@ -1,17 +1,17 @@
-- page_title "Members"
+- page_title "成员"
= render "header_title"
.project-members-page.prepend-top-default
- if can?(current_user, :admin_project_member, @project)
.panel.panel-default
.panel-heading
- Add new user to project
+ 增加新成员到项目
.controls
- = link_to import_namespace_project_project_members_path(@project.namespace, @project), class: "btn btn-grouped", title: "Import members from another project" do
- Import members
+ = link_to import_namespace_project_project_members_path(@project.namespace, @project), class: "btn btn-grouped", title: "从其他项目导入成员" do
+ 导入成员
.panel-body
%p.light
- Users with access to this project are listed below.
+ 可以访问此项目的用户全部显示在下面。
= render "new_project_member"
= render "team", members: @project_members
diff --git a/app/views/projects/protected_branches/_branches_list.html.haml b/app/views/projects/protected_branches/_branches_list.html.haml
index f68449b1863..a8817c78552 100644
--- a/app/views/projects/protected_branches/_branches_list.html.haml
+++ b/app/views/projects/protected_branches/_branches_list.html.haml
@@ -1,13 +1,13 @@
- unless @branches.empty?
%br
- %h4 Already Protected:
+ %h4 已经保护的:
.table-holder
%table.table.protected-branches-list
%thead
%tr.no-border
- %th Branch
- %th Developers can push
- %th Last commit
+ %th 分支
+ %th 开发者可以推送
+ %th 上次提交
%th
%tbody
@@ -18,7 +18,7 @@
= link_to namespace_project_commits_path(@project.namespace, @project, branch.name) do
%strong= branch.name
- if @project.root_ref?(branch.name)
- %span.label.label-info default
+ %span.label.label-info 默认
%td
= check_box_tag "developers_can_push", branch.id, branch.developers_can_push, "data-url" => @url
%td
@@ -28,8 +28,8 @@
&middot;
#{time_ago_with_tooltip(commit.committed_date)}
- else
- (branch was removed from repository)
+ (分支已从仓库中删除)
%td
.pull-right
- if can? current_user, :admin_project, @project
- = link_to 'Unprotect', [@project.namespace.becomes(Namespace), @project, branch], data: { confirm: 'Branch will be writable for developers. Are you sure?' }, method: :delete, class: "btn btn-remove btn-sm"
+ = link_to '取消保护', [@project.namespace.becomes(Namespace), @project, branch], data: { confirm: '该分支将允许开发者修改。确定要继续么?' }, method: :delete, class: "btn btn-remove btn-sm"
diff --git a/app/views/projects/protected_branches/index.html.haml b/app/views/projects/protected_branches/index.html.haml
index cfd7e1534ca..c7e60d615ec 100644
--- a/app/views/projects/protected_branches/index.html.haml
+++ b/app/views/projects/protected_branches/index.html.haml
@@ -1,15 +1,15 @@
-- page_title "Protected branches"
-%h3.page-title Protected branches
-%p.light Keep stable branches secure and force developers to use Merge Requests
+- page_title "保护分支"
+%h3.page-title 保护分支
+%p.light 此功能用于保护稳定分支被覆盖以及合并保护分支前必须强制代码评审
%hr
.well
- %p Protected branches are designed to
+ %p 保护分支设计为:
%ul
%li prevent pushes from everybody except #{link_to "masters", help_page_path("permissions", "permissions"), class: "vlink"}
%li prevent anyone from force pushing to the branch
%li prevent anyone from deleting the branch
- %p Read more about #{link_to "project permissions", help_page_path("permissions", "permissions"), class: "underlined-link"}
+ %p 点击#{link_to "项目权限", help_page_path("permissions", "permissions"), class: "underlined-link"}了解更多
- if can? current_user, :admin_project, @project
= form_for [@project.namespace.becomes(Namespace), @project, @protected_branch], html: { class: 'form-horizontal' } do |f|
@@ -20,16 +20,16 @@
%li= msg
.form-group
- = f.label :name, "Branch", class: 'control-label'
+ = f.label :name, "分支", class: 'control-label'
.col-sm-10
- = f.select(:name, @project.open_branches.map { |br| [br.name, br.name] } , {include_blank: true}, {class: "select2", data: {placeholder: "Select branch"}})
+ = f.select(:name, @project.open_branches.map { |br| [br.name, br.name] } , {include_blank: true}, {class: "select2", data: {placeholder: "选择分支"}})
.form-group
.col-sm-offset-2.col-sm-10
.checkbox
= f.label :developers_can_push do
= f.check_box :developers_can_push
- %strong Developers can push
- .help-block Allow developers to push to this branch
+ %strong 开发者可以推送
+ .help-block 允许开发者推送到此分支
.form-actions
- = f.submit 'Protect', class: "btn-create btn"
+ = f.submit '保护', class: "btn-create btn"
= render 'branches_list'
diff --git a/app/views/projects/releases/edit.html.haml b/app/views/projects/releases/edit.html.haml
index c4a3f06ee06..fc86a1ace4f 100644
--- a/app/views/projects/releases/edit.html.haml
+++ b/app/views/projects/releases/edit.html.haml
@@ -15,5 +15,5 @@
= render 'projects/notes/hints'
.error-alert
.form-actions.prepend-top-default
- = f.submit 'Save changes', class: 'btn btn-save'
- = link_to "Cancel", namespace_project_tag_path(@project.namespace, @project, @tag.name), class: "btn btn-default btn-cancel"
+ = f.submit '保存修改', class: 'btn btn-save'
+ = link_to "取消", namespace_project_tag_path(@project.namespace, @project, @tag.name), class: "btn btn-default btn-cancel"
diff --git a/app/views/projects/repositories/_feed.html.haml b/app/views/projects/repositories/_feed.html.haml
index 6ca919f7f80..2a205e45429 100644
--- a/app/views/projects/repositories/_feed.html.haml
+++ b/app/views/projects/repositories/_feed.html.haml
@@ -5,7 +5,7 @@
%strong
= commit.head.name
- if @project.root_ref?(commit.head.name)
- %span.label default
+ %span.label 默认
%td
%div
diff --git a/app/views/projects/runners/_runner.html.haml b/app/views/projects/runners/_runner.html.haml
index 47ec420189d..dd24f91c39a 100644
--- a/app/views/projects/runners/_runner.html.haml
+++ b/app/views/projects/runners/_runner.html.haml
@@ -13,14 +13,14 @@
.pull-right
- if @runners.include?(runner)
- if runner.belongs_to_one_project?
- = link_to 'Remove runner', runner_path(runner), data: { confirm: "Are you sure?" }, method: :delete, class: 'btn btn-danger btn-sm'
+ = link_to '删除 runner', runner_path(runner), data: { confirm: "确定要继续么?" }, method: :delete, class: 'btn btn-danger btn-sm'
- else
- runner_project = @project.runner_projects.find_by(runner_id: runner)
- = link_to 'Disable for this project', namespace_project_runner_project_path(@project.namespace, @project, runner_project), data: { confirm: "Are you sure?" }, method: :delete, class: 'btn btn-danger btn-sm'
+ = link_to '在此项目禁用', namespace_project_runner_project_path(@project.namespace, @project, runner_project), data: { confirm: "确定要继续么?" }, method: :delete, class: 'btn btn-danger btn-sm'
- elsif runner.specific?
= form_for [@project.namespace.becomes(Namespace), @project, @project.runner_projects.new] do |f|
= f.hidden_field :runner_id, value: runner.id
- = f.submit 'Enable for this project', class: 'btn btn-sm'
+ = f.submit '在此项目启用', class: 'btn btn-sm'
.pull-right
%small.light
\##{runner.id}
diff --git a/app/views/projects/runners/_shared_runners.html.haml b/app/views/projects/runners/_shared_runners.html.haml
index 6a37f444bb7..7741592da87 100644
--- a/app/views/projects/runners/_shared_runners.html.haml
+++ b/app/views/projects/runners/_shared_runners.html.haml
@@ -1,23 +1,23 @@
-%h3 Shared runners
+%h3 共享的 runners
.bs-callout.bs-callout-warning
- GitLab Runners do not offer secure isolation between projects that they do builds for. You are TRUSTING all GitLab users who can push code to project A, B or C to run shell scripts on the machine hosting runner X.
+ GitLab Runners 不能提供项目构建之间的安全隔离。你需要信任所有 GitLab 用户,他们可用推送代码到项目 A、B 或 C 来在 runner X 所在的机器上运行脚本。
%hr
+ &nbsp; 为此项目
- if @project.shared_runners_enabled?
= link_to toggle_shared_runners_namespace_project_runners_path(@project.namespace, @project), class: 'btn btn-warning', method: :post do
- Disable shared runners
+ 禁用共享的 runners
- else
= link_to toggle_shared_runners_namespace_project_runners_path(@project.namespace, @project), class: 'btn btn-success', method: :post do
- Enable shared runners
- &nbsp; for this project
+ 启用共享的 runners
- if @shared_runners_count.zero?
- This GitLab server does not provide any shared runners yet.
- Please use specific runners or ask the administrator to create one.
+ 此 GitLab 服务器还没有共享 runner。
+ 请使用特定的 runner 或者请求管理员创建共享的 runner。
- else
- %h4.underlined-title Available shared runners - #{@shared_runners_count}
+ %h4.underlined-title 可用的共享 runners - #{@shared_runners_count}
%ul.bordered-list.available-shared-runners
= render partial: 'runner', collection: @shared_runners, as: :runner
- if @shared_runners_count > 10
.light
- and #{@shared_runners_count - 10} more...
+ and #{@shared_runners_count - 10} 个更多...
diff --git a/app/views/projects/runners/_specific_runners.html.haml b/app/views/projects/runners/_specific_runners.html.haml
index 30cd1263a12..685cdc088af 100644
--- a/app/views/projects/runners/_specific_runners.html.haml
+++ b/app/views/projects/runners/_specific_runners.html.haml
@@ -1,29 +1,29 @@
-%h3 Specific runners
+%h3 特定的 runners
.bs-callout.help-callout
- %h4 How to setup a new project specific runner
+ %h4 如何设置一个新项目的特定 runner
%ol
%li
- Install GitLab Runner software.
- Checkout the #{link_to 'GitLab Runner section', 'https://about.gitlab.com/gitlab-ci/#gitlab-runner', target: '_blank'} to install it
+ 安装 GitLab Runner 软件。
+ 请参阅 #{link_to 'GitLab Runner 章节', 'https://about.gitlab.com/gitlab-ci/#gitlab-runner', target: '_blank'}来安装
%li
- Specify following URL during runner setup:
+ 在 runner 安装时使用下面的链接:
%code #{ci_root_url(only_path: false)}
%li
- Use the following registration token during setup:
+ 在设置时使用下面的注册授权码:
%code #{@project.runners_token}
%li
- Start runner!
+ 启动 runner!
- if @runners.any?
- %h4.underlined-title Runners activated for this project
+ %h4.underlined-title 此项目有效可用的 runner
%ul.bordered-list.activated-specific-runners
= render partial: 'runner', collection: @runners, as: :runner
- if @specific_runners.any?
- %h4.underlined-title Available specific runners
+ %h4.underlined-title 可用的特定 runner
%ul.bordered-list.available-specific-runners
= render partial: 'runner', collection: @specific_runners, as: :runner
= paginate @specific_runners
diff --git a/app/views/projects/runners/edit.html.haml b/app/views/projects/runners/edit.html.haml
index eba03028af8..5523edafa40 100644
--- a/app/views/projects/runners/edit.html.haml
+++ b/app/views/projects/runners/edit.html.haml
@@ -1,29 +1,29 @@
-- page_title "Edit", "#{@runner.description} ##{@runner.id}", "Runners"
+- page_title "编辑", "#{@runner.description} ##{@runner.id}", "Runners"
%h4 Runner ##{@runner.id}
%hr
= form_for @runner, url: runner_path(@runner), html: { class: 'form-horizontal' } do |f|
.form-group
- = label :active, "Active", class: 'control-label'
+ = label :active, "有效的", class: 'control-label'
.col-sm-10
.checkbox
= f.check_box :active
- %span.light Paused runners don't accept new builds
+ %span.light 暂停的 runner 不接受新构建
.form-group
= label_tag :token, class: 'control-label' do
- Token
+ 授权
.col-sm-10
= f.text_field :token, class: 'form-control', readonly: true
.form-group
= label_tag :description, class: 'control-label' do
- Description
+ 描述
.col-sm-10
= f.text_field :description, class: 'form-control'
.form-group
= label_tag :tag_list, class: 'control-label' do
- Tags
+ 标签
.col-sm-10
= f.text_field :tag_list, value: @runner.tag_list.to_s, class: 'form-control'
- .help-block You can setup jobs to only use runners with specific tags
+ .help-block 你可以设置作业只使用指定标签的 runner
.form-actions
- = f.submit 'Save changes', class: 'btn btn-save'
+ = f.submit '保存修改', class: 'btn btn-save'
diff --git a/app/views/projects/runners/index.html.haml b/app/views/projects/runners/index.html.haml
index 2d5b9f43c24..9a5f6c4cf0a 100644
--- a/app/views/projects/runners/index.html.haml
+++ b/app/views/projects/runners/index.html.haml
@@ -2,24 +2,24 @@
.light.prepend-top-default
%p
- A 'runner' is a process which runs a build.
- You can setup as many runners as you need.
+ 一个 'runner' 就是一个运行构建的进程。
+ 你可以按照自己的需要设置很多个 runner。
%br
- Runners can be placed on separate users, servers, and even on your local machine.
+ Runners 可以被部署在不同的用户、服务器上,甚至在你本地使用的机器上。
- %p Each runner can be in one of the following states:
+ %p 每个 runner 可以是下列状态之一:
%div
%ul
%li
- %span.label.label-success active
- \- runner is active and can process any new build
+ %span.label.label-success 有效的
+ \- runner 是有效可用的,可以处理任何新构建
%li
- %span.label.label-danger paused
- \- runner is paused and will not receive any new build
+ %span.label.label-danger 暂停的
+ \- runner 被暂停,不会接受任何新构建
%hr
-%p.lead To start serving your builds you can either add specific runners to your project or use shared runners
+%p.lead 要开始接受你的构建,需要你给你的项目增加特定的 runner 或者使用共享的 runner
.row
.col-sm-6
= render 'specific_runners'
diff --git a/app/views/projects/runners/show.html.haml b/app/views/projects/runners/show.html.haml
index 5bf4c09ca25..ae4b88e9de6 100644
--- a/app/views/projects/runners/show.html.haml
+++ b/app/views/projects/runners/show.html.haml
@@ -5,62 +5,62 @@
.pull-right
- if @runner.shared?
%span.runner-state.runner-state-shared
- Shared
+ 共享的
- else
%span.runner-state.runner-state-specific
- Specific
+ 特定的
.table-holder
%table.table
%thead
%tr
- %th Property Name
- %th Value
+ %th 属性名称
+ %th 值
%tr
%td
- Tags
+ 标签
%td
- @runner.tag_list.each do |tag|
%span.label.label-primary
= tag
%tr
%td
- Name
+ 名称
%td
= @runner.name
%tr
%td
- Version
+ 版本
%td
= @runner.version
%tr
%td
- Revision
+ 修订版本
%td
= @runner.revision
%tr
%td
- Platform
+ 平台
%td
= @runner.platform
%tr
%td
- Architecture
+ 架构
%td
= @runner.architecture
%tr
%td
- Description
+ 描述
%td
= @runner.description
%tr
%td
- Last contact
+ 最后联系时间
%td
- if @runner.contacted_at
- #{time_ago_in_words(@runner.contacted_at)} ago
+ #{time_ago_in_words(@runner.contacted_at)}之前
- else
- Never
+ 从未
diff --git a/app/views/projects/services/_form.html.haml b/app/views/projects/services/_form.html.haml
index 1b70880043a..ab82d2a4675 100644
--- a/app/views/projects/services/_form.html.haml
+++ b/app/views/projects/services/_form.html.haml
@@ -10,9 +10,9 @@
= render 'shared/service_settings', form: form
.form-actions
- = form.submit 'Save changes', class: 'btn btn-save'
+ = form.submit '保存修改', class: 'btn btn-save'
&nbsp;
- if @service.valid? && @service.activated?
- disabled = @service.can_test? ? '':'disabled'
- = link_to 'Test settings', test_namespace_project_service_path(@project.namespace, @project, @service.to_param), class: "btn #{disabled}"
- = link_to "Cancel", namespace_project_services_path(@project.namespace, @project), class: "btn btn-cancel"
+ = link_to '测试设置', test_namespace_project_service_path(@project.namespace, @project, @service.to_param), class: "btn #{disabled}"
+ = link_to "取消", namespace_project_services_path(@project.namespace, @project), class: "btn btn-cancel"
diff --git a/app/views/projects/services/edit.html.haml b/app/views/projects/services/edit.html.haml
index 50ed78286d2..3b321981506 100644
--- a/app/views/projects/services/edit.html.haml
+++ b/app/views/projects/services/edit.html.haml
@@ -1,2 +1,2 @@
-- page_title @service.title, "Services"
+- page_title @service.title, "服务"
= render 'form'
diff --git a/app/views/projects/services/index.html.haml b/app/views/projects/services/index.html.haml
index c1356f6db02..cbe27b7cda5 100644
--- a/app/views/projects/services/index.html.haml
+++ b/app/views/projects/services/index.html.haml
@@ -1,15 +1,15 @@
-- page_title "Services"
-%h3.page-title Project services
-%p.light Project services allow you to integrate GitLab with other applications
+- page_title "服务"
+%h3.page-title 项目服务
+%p.light 项目服务用于集成其他应用
.table-holder
%table.table
%thead
%tr
%th
- %th Service
- %th Description
- %th Last edit
+ %th 服务
+ %th 描述
+ %th 最后编辑
- @services.sort_by(&:title).each do |service|
%tr
%td
@@ -21,4 +21,4 @@
= service.description
%td.light
= time_ago_in_words service.updated_at
- ago
+ 之前
diff --git a/app/views/projects/show.html.haml b/app/views/projects/show.html.haml
index 4310f038fc9..0a2b011d5cc 100644
--- a/app/views/projects/show.html.haml
+++ b/app/views/projects/show.html.haml
@@ -2,7 +2,7 @@
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, namespace_project_path(@project.namespace, @project, format: :atom, private_token: current_user.private_token), title: "#{@project.name} activity")
+ = auto_discovery_link_tag(:atom, namespace_project_path(@project.namespace, @project, format: :atom, private_token: current_user.private_token), title: "#{@project.name} 活动")
= content_for :flash_message do
- if current_user && can?(current_user, :download_code, @project)
@@ -16,13 +16,13 @@
%ul.nav
%li
= link_to namespace_project_commits_path(@project.namespace, @project, current_ref) do
- = pluralize(number_with_delimiter(@project.commit_count), 'commit')
+ = pluralize(number_with_delimiter(@project.commit_count), '次提交', '次提交')
%li
= link_to namespace_project_branches_path(@project.namespace, @project) do
- = pluralize(number_with_delimiter(@repository.branch_names.count), 'branch')
+ = pluralize(number_with_delimiter(@repository.branch_names.count), '个分支', '个分支')
%li
= link_to namespace_project_tags_path(@project.namespace, @project) do
- = pluralize(number_with_delimiter(@repository.tag_names.count), 'tag')
+ = pluralize(number_with_delimiter(@repository.tag_names.count), '个标签', '个标签')
%li
= link_to project_files_path(@project) do
@@ -34,29 +34,29 @@
- if @repository.changelog
%li
- = link_to 'Changelog', changelog_path(@project)
+ = link_to '变更日志', changelog_path(@project)
- if @repository.license
%li
- = link_to 'License', license_path(@project)
+ = link_to '许可证', license_path(@project)
- if @repository.contribution_guide
%li
- = link_to 'Contribution guide', contribution_guide_path(@project)
+ = link_to '贡献指南', contribution_guide_path(@project)
- if current_user && can_push_branch?(@project, @project.default_branch)
- unless @repository.changelog
%li.missing
= link_to add_changelog_path(@project) do
- Add Changelog
+ 增加变更日志
- unless @repository.license
%li.missing
= link_to add_license_path(@project) do
- Add License
+ 增加许可证
- unless @repository.contribution_guide
%li.missing
= link_to add_contribution_guide_path(@project) do
- Add Contribution guide
+ 增加贡献指南
- if @repository.commit
.content-block.second-block.white
@@ -68,7 +68,7 @@
.text-warning.center.prepend-top-20
%p
= icon("exclamation-triangle fw")
- Archived project! Repository is read-only
+ 已归档项目!版本仓库只读
%div{class: "project-show-#{default_project_view}"}
= render default_project_view
diff --git a/app/views/projects/snippets/_actions.html.haml b/app/views/projects/snippets/_actions.html.haml
index 4a515469422..7a8b2343d91 100644
--- a/app/views/projects/snippets/_actions.html.haml
+++ b/app/views/projects/snippets/_actions.html.haml
@@ -1,11 +1,11 @@
-= link_to new_namespace_project_snippet_path(@project.namespace, @project), class: 'btn btn-grouped new-snippet-link', title: "New Snippet" do
+= link_to new_namespace_project_snippet_path(@project.namespace, @project), class: 'btn btn-grouped new-snippet-link', title: "新代码片段" do
= icon('plus')
- New Snippet
+ 新代码片段
- if can?(current_user, :admin_project_snippet, @snippet)
- = link_to namespace_project_snippet_path(@project.namespace, @project, @snippet), method: :delete, data: { confirm: "Are you sure?" }, class: "btn btn-grouped btn-remove", title: 'Delete Snippet' do
+ = link_to namespace_project_snippet_path(@project.namespace, @project, @snippet), method: :delete, data: { confirm: "确定要删除么?" }, class: "btn btn-grouped btn-remove", title: '删除代码片段' do
= icon('trash-o')
- Delete
+ 删除
- if can?(current_user, :update_project_snippet, @snippet)
= link_to edit_namespace_project_snippet_path(@project.namespace, @project, @snippet), class: "btn btn-grouped snippable-edit" do
= icon('pencil-square-o')
- Edit
+ 编辑
diff --git a/app/views/projects/snippets/_header_title.html.haml b/app/views/projects/snippets/_header_title.html.haml
index 04f0bbe9853..77d20c7488f 100644
--- a/app/views/projects/snippets/_header_title.html.haml
+++ b/app/views/projects/snippets/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, "Snippets", namespace_project_snippets_path(@project.namespace, @project))
+- header_title project_title(@project, "代码片段", namespace_project_snippets_path(@project.namespace, @project))
diff --git a/app/views/projects/snippets/edit.html.haml b/app/views/projects/snippets/edit.html.haml
index dc3ea1fcf12..8f12cf804b0 100644
--- a/app/views/projects/snippets/edit.html.haml
+++ b/app/views/projects/snippets/edit.html.haml
@@ -1,7 +1,7 @@
-- page_title "Edit", @snippet.title, "Snippets"
+- page_title "编辑", @snippet.title, "代码片段"
= render "header_title"
%h3.page-title
- Edit Snippet
+ 编辑代码片段
%hr
= render "shared/snippets/form", url: namespace_project_snippet_path(@project.namespace, @project, @snippet), visibility_level: @snippet.visibility_level
diff --git a/app/views/projects/snippets/index.html.haml b/app/views/projects/snippets/index.html.haml
index 4af963e14da..f8bf92e6620 100644
--- a/app/views/projects/snippets/index.html.haml
+++ b/app/views/projects/snippets/index.html.haml
@@ -1,13 +1,13 @@
-- page_title "Snippets"
+- page_title "代码片段"
= render "header_title"
.gray-content-block.top-block
.pull-right
- = link_to new_namespace_project_snippet_path(@project.namespace, @project), class: "btn btn-new", title: "New Snippet" do
+ = link_to new_namespace_project_snippet_path(@project.namespace, @project), class: "btn btn-new", title: "新代码片段" do
= icon('plus')
- New Snippet
+ 新代码片段
.oneline
- Share code pastes with others out of git repository
+ 在 git 版本仓库外共享代码
= render 'snippets/snippets'
diff --git a/app/views/projects/snippets/new.html.haml b/app/views/projects/snippets/new.html.haml
index e57237991b4..6702c728d58 100644
--- a/app/views/projects/snippets/new.html.haml
+++ b/app/views/projects/snippets/new.html.haml
@@ -1,7 +1,7 @@
-- page_title "New Snippets"
+- page_title "新代码片段"
= render "header_title"
%h3.page-title
- New Snippet
+ 新代码片段
%hr
= render "shared/snippets/form", url: namespace_project_snippets_path(@project.namespace, @project, @snippet), visibility_level: default_snippet_visibility
diff --git a/app/views/projects/snippets/show.html.haml b/app/views/projects/snippets/show.html.haml
index 7c599563ce4..d36a015a498 100644
--- a/app/views/projects/snippets/show.html.haml
+++ b/app/views/projects/snippets/show.html.haml
@@ -1,4 +1,4 @@
-- page_title @snippet.title, "Snippets"
+- page_title @snippet.title, "代码片段"
= render "header_title"
.snippet-holder
@@ -11,7 +11,7 @@
= @snippet.file_name
.file-actions.hidden-xs
= clipboard_button(clipboard_target: ".blob-content[data-blob-id='#{@snippet.id}']")
- = link_to 'Raw', raw_namespace_project_snippet_path(@project.namespace, @project, @snippet), class: "btn btn-sm", target: "_blank"
+ = link_to '原文件', raw_namespace_project_snippet_path(@project.namespace, @project, @snippet), class: "btn btn-sm", target: "_blank"
= render 'shared/snippets/blob'
diff --git a/app/views/projects/tags/_download.html.haml b/app/views/projects/tags/_download.html.haml
index 667057ef2d8..ef3e680967e 100644
--- a/app/views/projects/tags/_download.html.haml
+++ b/app/views/projects/tags/_download.html.haml
@@ -1,17 +1,17 @@
%span.btn-group.btn-grouped
= link_to archive_namespace_project_repository_path(project.namespace, project, ref: ref, format: 'zip'), class: 'btn btn-default', rel: 'nofollow' do
%i.fa.fa-download
- %span source code
+ %span 源代码
%a.btn.btn-default.dropdown-toggle{ 'data-toggle' => 'dropdown' }
%span.caret
%span.sr-only
- Select Archive Format
+ 选择打包格式
%ul.col-xs-10.dropdown-menu{ role: 'menu' }
%li
= link_to archive_namespace_project_repository_path(project.namespace, project, ref: ref, format: 'zip'), rel: 'nofollow' do
%i.fa.fa-download
- %span Download zip
+ %span 下载 zip
%li
= link_to archive_namespace_project_repository_path(project.namespace, project, ref: ref, format: 'tar.gz'), rel: 'nofollow' do
%i.fa.fa-download
- %span Download tar.gz
+ %span 下载 tar.gz
diff --git a/app/views/projects/tags/_tag.html.haml b/app/views/projects/tags/_tag.html.haml
index 399782273d3..1b4768aad36 100644
--- a/app/views/projects/tags/_tag.html.haml
+++ b/app/views/projects/tags/_tag.html.haml
@@ -15,18 +15,18 @@
= render 'projects/tags/download', ref: tag.name, project: @project
- if can?(current_user, :push_code, @project)
- = link_to edit_namespace_project_tag_release_path(@project.namespace, @project, tag.name), class: 'btn-grouped btn has_tooltip', title: "Edit release notes" do
+ = link_to edit_namespace_project_tag_release_path(@project.namespace, @project, tag.name), class: 'btn-grouped btn has_tooltip', title: "编辑发布备注" do
= icon("pencil")
- if can?(current_user, :admin_project, @project)
- = link_to namespace_project_tag_path(@project.namespace, @project, tag.name), class: 'btn btn-grouped btn-xs btn-remove remove-row has_tooltip', title: "Delete tag", method: :delete, data: { confirm: "Deleting the '#{tag.name}' tag cannot be undone. Are you sure?", container: 'body' }, remote: true do
+ = link_to namespace_project_tag_path(@project.namespace, @project, tag.name), class: 'btn btn-grouped btn-xs btn-remove remove-row has_tooltip', title: "删除标签", method: :delete, data: { confirm: "删除标签 '#{tag.name}' 无法恢复,确定要继续么?", container: 'body' }, remote: true do
= icon("trash-o")
- if commit
= render 'projects/branches/commit', commit: commit, project: @project
- else
%p
- Cant find HEAD commit for this tag
+ 无法找到该标签的 HEAD 提交
- if release && release.description.present?
.description.prepend-top-default
.wiki
diff --git a/app/views/projects/tags/index.html.haml b/app/views/projects/tags/index.html.haml
index 760347de0a9..32b932daf33 100644
--- a/app/views/projects/tags/index.html.haml
+++ b/app/views/projects/tags/index.html.haml
@@ -1,4 +1,4 @@
-- page_title "Tags"
+- page_title "标签"
= render "projects/commits/header_title"
= render "projects/commits/head"
@@ -7,9 +7,9 @@
.pull-right
= link_to new_namespace_project_tag_path(@project.namespace, @project), class: 'btn btn-create new-tag-btn' do
= icon('plus')
- New tag
+ 新标签
.oneline
- Tags give the ability to mark specific points in history as being important
+ 标签用于标识历史重要版本
.tags
- unless @tags.empty?
@@ -21,9 +21,9 @@
- else
.nothing-here-block
- Repository has no tags yet.
+ 版本库没有标签。
%br
%small
- Use git tag command to add a new one:
+ 使用 git tag 命令增加标签:
%br
%span.monospace git tag -a v1.4 -m 'version 1.4'
diff --git a/app/views/projects/tags/new.html.haml b/app/views/projects/tags/new.html.haml
index 77c7c4d23de..367dc20dce7 100644
--- a/app/views/projects/tags/new.html.haml
+++ b/app/views/projects/tags/new.html.haml
@@ -1,4 +1,4 @@
-- page_title "New Tag"
+- page_title "新标签"
= render "projects/commits/header_title"
- if @error
diff --git a/app/views/projects/tags/show.html.haml b/app/views/projects/tags/show.html.haml
index 8c7f93f93b6..582d5303eb5 100644
--- a/app/views/projects/tags/show.html.haml
+++ b/app/views/projects/tags/show.html.haml
@@ -1,21 +1,21 @@
-- page_title @tag.name, "Tags"
+- page_title @tag.name, "标签"
= render "projects/commits/header_title"
= render "projects/commits/head"
.gray-content-block
.pull-right
- if can?(current_user, :push_code, @project)
- = link_to edit_namespace_project_tag_release_path(@project.namespace, @project, @tag.name), class: 'btn-grouped btn has_tooltip', title: 'Edit release notes' do
+ = link_to edit_namespace_project_tag_release_path(@project.namespace, @project, @tag.name), class: 'btn-grouped btn has_tooltip', title: '编辑发布备注' do
= icon("pencil")
- = link_to namespace_project_tree_path(@project.namespace, @project, @tag.name), class: 'btn btn-grouped has_tooltip', title: 'Browse files' do
+ = link_to namespace_project_tree_path(@project.namespace, @project, @tag.name), class: 'btn btn-grouped has_tooltip', title: '浏览文件' do
= icon('files-o')
- = link_to namespace_project_commits_path(@project.namespace, @project, @tag.name), class: 'btn btn-grouped has_tooltip', title: 'Browse commits' do
+ = link_to namespace_project_commits_path(@project.namespace, @project, @tag.name), class: 'btn btn-grouped has_tooltip', title: '浏览提交' do
= icon('history')
- if can? current_user, :download_code, @project
= render 'projects/tags/download', ref: @tag.name, project: @project
- if can?(current_user, :admin_project, @project)
.pull-right
- = link_to namespace_project_tag_path(@project.namespace, @project, @tag.name), class: 'btn btn-remove remove-row grouped has_tooltip', title: "Delete tag", method: :delete, data: { confirm: "Deleting the '#{@tag.name}' tag cannot be undone. Are you sure?" } do
+ = link_to namespace_project_tag_path(@project.namespace, @project, @tag.name), class: 'btn btn-remove remove-row grouped has_tooltip', title: "删除标签", method: :delete, data: { confirm: "删除标签 '#{@tag.name}' 无法恢复,确定要继续么?" } do
%i.fa.fa-trash-o
.title
%span.item-title= @tag.name
@@ -26,7 +26,7 @@
- if @commit
= render 'projects/branches/commit', commit: @commit, project: @project
- else
- Cant find HEAD commit for this tag
+ 无法找到该标签的 HEAD 提交
.append-bottom-default.prepend-top-default
@@ -36,4 +36,4 @@
= preserve do
= markdown @release.description
- else
- This tag has no release notes.
+ 此标签无发布备注。
diff --git a/app/views/projects/tree/_spinner.html.haml b/app/views/projects/tree/_spinner.html.haml
index b47ad0f41e4..635bb648cd7 100644
--- a/app/views/projects/tree/_spinner.html.haml
+++ b/app/views/projects/tree/_spinner.html.haml
@@ -1,3 +1,3 @@
%span.log_loading.hide
%i.fa.fa-spinner.fa-spin
- Loading commit data...
+ 正在载入提交数据...
diff --git a/app/views/projects/tree/_tree_content.html.haml b/app/views/projects/tree/_tree_content.html.haml
index 558e6146ae9..8145e49d61e 100644
--- a/app/views/projects/tree/_tree_content.html.haml
+++ b/app/views/projects/tree/_tree_content.html.haml
@@ -3,10 +3,10 @@
%table.table#tree-slider{class: "table_#{@hex_path} tree-table" }
%thead
%tr
- %th Name
- %th Last Update
+ %th 名称
+ %th 最后更新
%th.hidden-xs
- .pull-left Last Commit
+ .pull-left 最后提交
.last-commit.hidden-sm.pull-left
&nbsp;
%i.fa.fa-angle-right
@@ -15,7 +15,7 @@
= link_to @commit.short_id, namespace_project_commit_path(@project.namespace, @project, @commit), class: "monospace"
&ndash;
= truncate(@commit.title, length: 50)
- = link_to 'History', namespace_project_commits_path(@project.namespace, @project, @id), class: 'pull-right'
+ = link_to '历史', namespace_project_commits_path(@project.namespace, @project, @id), class: 'pull-right'
- if @path.present?
%tr.tree-item
@@ -30,7 +30,7 @@
= render "projects/tree/readme", readme: tree.readme
- if can_edit_tree?
- = render 'projects/blob/upload', title: 'Upload New File', placeholder: 'Upload new file', button_title: 'Upload file', form_path: namespace_project_create_blob_path(@project.namespace, @project, @id), method: :post
+ = render 'projects/blob/upload', title: '上传新文件', placeholder: '上传新文件', button_title: '上传文件', form_path: namespace_project_create_blob_path(@project.namespace, @project, @id), method: :post
= render 'projects/blob/new_dir'
:javascript
diff --git a/app/views/projects/tree/_tree_header.html.haml b/app/views/projects/tree/_tree_header.html.haml
index 3eb626e6dca..58b1167a9bb 100644
--- a/app/views/projects/tree/_tree_header.html.haml
+++ b/app/views/projects/tree/_tree_header.html.haml
@@ -15,7 +15,7 @@
- if current_user
%li
- if !on_top_of_branch?
- %span.btn.btn-sm.add-to-tree.disabled.has_tooltip{title: "You can only add files when you are on a branch", data: { container: 'body' }}
+ %span.btn.btn-sm.add-to-tree.disabled.has_tooltip{title: "您只能在分支上增加文件", data: { container: 'body' }}
= icon('plus')
- else
%span.dropdown
@@ -26,15 +26,15 @@
%li
= link_to namespace_project_new_blob_path(@project.namespace, @project, @id) do
= icon('pencil fw')
- New file
+ 新文件
%li
= link_to '#modal-upload-blob', { 'data-target' => '#modal-upload-blob', 'data-toggle' => 'modal'} do
= icon('file fw')
- Upload file
+ 上传文件
%li
= link_to '#modal-create-new-dir', { 'data-target' => '#modal-create-new-dir', 'data-toggle' => 'modal'} do
= icon('folder fw')
- New directory
+ 新目录
- elsif can?(current_user, :fork_project, @project)
%li
- continue_params = { to: namespace_project_new_blob_path(@project.namespace, @project, @id),
@@ -44,32 +44,32 @@
continue: continue_params)
= link_to fork_path, method: :post do
= icon('pencil fw')
- New file
+ 新文件
%li
- continue_params = { to: request.fullpath,
- notice: edit_in_new_fork_notice + " Try to upload a file again.",
+ notice: edit_in_new_fork_notice + " 重试上传文件。",
notice_now: edit_in_new_fork_notice_now }
- fork_path = namespace_project_forks_path(@project.namespace, @project, namespace_key: current_user.namespace.id,
continue: continue_params)
= link_to fork_path, method: :post do
= icon('file fw')
- Upload file
+ 上传文件
%li
- continue_params = { to: request.fullpath,
- notice: edit_in_new_fork_notice + " Try to create a new directory again.",
+ notice: edit_in_new_fork_notice + " 重试创建目录。",
notice_now: edit_in_new_fork_notice_now }
- fork_path = namespace_project_forks_path(@project.namespace, @project, namespace_key: current_user.namespace.id,
continue: continue_params)
= link_to fork_path, method: :post do
= icon('folder fw')
- New directory
+ 新目录
%li.divider
%li
= link_to new_namespace_project_branch_path(@project.namespace, @project) do
= icon('code-fork fw')
- New branch
+ 新分支
%li
= link_to new_namespace_project_tag_path(@project.namespace, @project) do
= icon('tags fw')
- New tag
+ 新标签
diff --git a/app/views/projects/tree/show.html.haml b/app/views/projects/tree/show.html.haml
index 91fb2a44594..97a67346749 100644
--- a/app/views/projects/tree/show.html.haml
+++ b/app/views/projects/tree/show.html.haml
@@ -1,8 +1,8 @@
-- page_title @path.presence || "Files", @ref
-- header_title project_title(@project, "Files", project_files_path(@project))
+- page_title @path.presence || "文件", @ref
+- header_title project_title(@project, "文件", project_files_path(@project))
= content_for :meta_tags do
- if current_user
- = auto_discovery_link_tag(:atom, namespace_project_commits_url(@project.namespace, @project, @ref, format: :atom, private_token: current_user.private_token), title: "#{@project.name}:#{@ref} commits")
+ = auto_discovery_link_tag(:atom, namespace_project_commits_url(@project.namespace, @project, @ref, format: :atom, private_token: current_user.private_token), title: "#{@project.name}:#{@ref} 提交")
= render 'projects/last_push'
.tree-controls
diff --git a/app/views/projects/triggers/_trigger.html.haml b/app/views/projects/triggers/_trigger.html.haml
index 48b3b5c9920..6b647b55c4c 100644
--- a/app/views/projects/triggers/_trigger.html.haml
+++ b/app/views/projects/triggers/_trigger.html.haml
@@ -5,10 +5,10 @@
%td
- if trigger.last_trigger_request
- #{time_ago_in_words(trigger.last_trigger_request.created_at)} ago
+ #{time_ago_in_words(trigger.last_trigger_request.created_at)}之前
- else
- Never
+ 从未
%td
.pull-right
- = link_to 'Revoke', namespace_project_trigger_path(@project.namespace, @project, trigger), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-danger btn-sm btn-grouped"
+ = link_to '撤销', namespace_project_trigger_path(@project.namespace, @project, trigger), data: { confirm: '确定要继续么?'}, method: :delete, class: "btn btn-danger btn-sm btn-grouped"
diff --git a/app/views/projects/triggers/index.html.haml b/app/views/projects/triggers/index.html.haml
index bd346c4b8e6..27d19c4b8f5 100644
--- a/app/views/projects/triggers/index.html.haml
+++ b/app/views/projects/triggers/index.html.haml
@@ -1,9 +1,9 @@
-- page_title "Triggers"
+- page_title "触发器"
%h3.page-title
- Triggers
+ 触发器
%p.light
- Triggers can be used to force a rebuild of a specific branch or tag with an API call.
+ 触发器被 API 调用用于强制重新构建指定的分支或标签。
%hr.clearfix
@@ -11,22 +11,22 @@
.table-holder
%table.table
%thead
- %th Token
- %th Last used
+ %th 授权
+ %th 最后使用
%th
= render partial: 'trigger', collection: @triggers, as: :trigger
- else
- %h4 No triggers
+ %h4 没有触发器
= form_for @trigger, url: url_for(controller: 'projects/triggers', action: 'create'), html: { class: 'form-horizontal' } do |f|
.clearfix
- = f.submit "Add Trigger", class: 'btn btn-success pull-right'
+ = f.submit "增加触发器", class: 'btn btn-success pull-right'
%hr.clearfix
-if @triggers.any?
%h3
- Use CURL
+ 使用 CURL
%p.light
Copy the token above and set your branch or tag name. This is the reference that will be rebuild.
@@ -39,7 +39,7 @@
-F ref=REF_NAME \
#{builds_trigger_url(@project.id)}
%h3
- Use .gitlab-ci.yml
+ 使用 .gitlab-ci.yml
%p.light
Copy the snippet to
@@ -54,7 +54,7 @@
script:
- "curl -X POST -F token=TOKEN -F ref=REF_NAME #{builds_trigger_url(@project.id)}"
%h3
- Pass build variables
+ 通过构建变量传递
%p.light
Add
diff --git a/app/views/projects/variables/show.html.haml b/app/views/projects/variables/show.html.haml
index efe1e6f24c2..26f08c73e91 100644
--- a/app/views/projects/variables/show.html.haml
+++ b/app/views/projects/variables/show.html.haml
@@ -1,13 +1,13 @@
-- page_title "Variables"
+- page_title "变量"
%h3.page-title
- Secret Variables
+ 私密变量
%p.light
- These variables will be set to environment by the runner.
+ 这些变量将会设置为 runner 的环境变量,且不会显示在构建日志中。
%br
- So you can use them for passwords, secret keys or whatever you want.
+ 所以你可以使用它们来保存密码、密钥和其他你想设置的。
%br
- The value of the variable can be visible in build log if explicitly asked to do so.
+ 如果明确要求,变量的值可以在构建日志中可见。
%hr
@@ -15,7 +15,7 @@
= nested_form_for @project, url: url_for(controller: 'projects/variables', action: 'update'), html: { class: 'form-horizontal' } do |f|
- if @project.errors.any?
#error_explanation
- %p.lead= "#{pluralize(@project.errors.count, "error")} prohibited this project from being saved:"
+ %p.lead= "发生 #{pluralize(@project.errors.count, "个错误', '个错误")},无法保存:"
.alert.alert-error
%ul
- @project.errors.full_messages.each do |msg|
@@ -23,20 +23,20 @@
= f.fields_for :variables do |variable_form|
.form-group
- = variable_form.label :key, 'Key', class: 'control-label'
+ = variable_form.label :key, '键', class: 'control-label'
.col-sm-10
= variable_form.text_field :key, class: 'form-control', placeholder: "PROJECT_VARIABLE"
.form-group
- = variable_form.label :value, 'Value', class: 'control-label'
+ = variable_form.label :value, '值', class: 'control-label'
.col-sm-10
= variable_form.text_area :value, class: 'form-control', rows: 2, placeholder: ""
- = variable_form.link_to_remove "Remove this variable", class: 'btn btn-danger pull-right prepend-top-10'
+ = variable_form.link_to_remove "删除此变量", class: 'btn btn-danger pull-right prepend-top-10'
%hr
%p
.clearfix
- = f.link_to_add "Add a variable", :variables, class: 'btn btn-success pull-right'
+ = f.link_to_add "增加变量", :variables, class: 'btn btn-success pull-right'
.form-actions
- = f.submit 'Save changes', class: 'btn btn-save', return_to: request.original_url
+ = f.submit '保存修改', class: 'btn btn-save', return_to: request.original_url
diff --git a/app/views/projects/wikis/_form.html.haml b/app/views/projects/wikis/_form.html.haml
index f0d1932e23c..fde8753f01f 100644
--- a/app/views/projects/wikis/_form.html.haml
+++ b/app/views/projects/wikis/_form.html.haml
@@ -22,17 +22,17 @@
.error-alert
.help-block
- To link to a (new) page, simply type
- %code [Link Title](page-slug)
+ 链接到(新)页面只需要输入
+ %code [链接标题](page-slug)
\.
.form-group
- = f.label :commit_message, class: 'control-label'
+ = f.label :commit_message, '提交信息', class: 'control-label'
.col-sm-10= f.text_field :message, class: 'form-control', rows: 18
.form-actions
- if @page && @page.persisted?
- = f.submit 'Save changes', class: "btn-save btn"
- = link_to "Cancel", namespace_project_wiki_path(@project.namespace, @project, @page), class: "btn btn-cancel"
+ = f.submit '保存修改', class: "btn-save btn"
+ = link_to "取消", namespace_project_wiki_path(@project.namespace, @project, @page), class: "btn btn-cancel"
- else
- = f.submit 'Create page', class: "btn-create btn"
- = link_to "Cancel", namespace_project_wiki_path(@project.namespace, @project, :home), class: "btn btn-cancel"
+ = f.submit '创建页面', class: "btn-create btn"
+ = link_to "取消", namespace_project_wiki_path(@project.namespace, @project, :home), class: "btn btn-cancel"
diff --git a/app/views/projects/wikis/_header_title.html.haml b/app/views/projects/wikis/_header_title.html.haml
index 408adc36ca6..3bd4f9ce1f0 100644
--- a/app/views/projects/wikis/_header_title.html.haml
+++ b/app/views/projects/wikis/_header_title.html.haml
@@ -1 +1 @@
-- header_title project_title(@project, 'Wiki', get_project_wiki_path(@project))
+- header_title project_title(@project, '维基', get_project_wiki_path(@project))
diff --git a/app/views/projects/wikis/_main_links.html.haml b/app/views/projects/wikis/_main_links.html.haml
index 2b91b7e8f65..5d70cb46473 100644
--- a/app/views/projects/wikis/_main_links.html.haml
+++ b/app/views/projects/wikis/_main_links.html.haml
@@ -1,11 +1,11 @@
- if (@page && @page.persisted?)
= link_to namespace_project_wiki_history_path(@project.namespace, @project, @page), class: "btn btn-grouped" do
- Page History
+ 页面历史
- if can?(current_user, :create_wiki, @project)
= link_to namespace_project_wiki_edit_path(@project.namespace, @project, @page), class: "btn btn-grouped" do
%i.fa.fa-pencil-square-o
- Edit
+ 编辑
- if can?(current_user, :admin_wiki, @project)
- = link_to namespace_project_wiki_path(@project.namespace, @project, @page), data: { confirm: "Are you sure you want to delete this page?"}, method: :delete, class: "btn btn-remove" do
+ = link_to namespace_project_wiki_path(@project.namespace, @project, @page), data: { confirm: "确定要继续删除此页面么?"}, method: :delete, class: "btn btn-remove" do
= icon('trash')
- Delete
+ 删除
diff --git a/app/views/projects/wikis/_nav.html.haml b/app/views/projects/wikis/_nav.html.haml
index a722fbc5352..91706148021 100644
--- a/app/views/projects/wikis/_nav.html.haml
+++ b/app/views/projects/wikis/_nav.html.haml
@@ -1,19 +1,19 @@
.top-area
%ul.nav-links
= nav_link(html_options: {class: params[:id] == 'home' ? 'active' : '' }) do
- = link_to 'Home', namespace_project_wiki_path(@project.namespace, @project, :home)
+ = link_to '主页', namespace_project_wiki_path(@project.namespace, @project, :home)
= nav_link(path: 'wikis#pages') do
- = link_to 'Pages', namespace_project_wiki_pages_path(@project.namespace, @project)
+ = link_to '页面', namespace_project_wiki_pages_path(@project.namespace, @project)
= nav_link(path: 'wikis#git_access') do
= link_to namespace_project_wikis_git_access_path(@project.namespace, @project) do
- Git Access
+ Git 访问
.nav-controls
- if can?(current_user, :create_wiki, @project)
= link_to '#modal-new-wiki', class: "add-new-wiki btn btn-new", "data-toggle" => "modal" do
= icon('plus')
- New Page
+ 新页面
= render 'projects/wikis/new'
diff --git a/app/views/projects/wikis/_new.html.haml b/app/views/projects/wikis/_new.html.haml
index 919daf0a7b2..a9a3c69d392 100644
--- a/app/views/projects/wikis/_new.html.haml
+++ b/app/views/projects/wikis/_new.html.haml
@@ -3,12 +3,12 @@
.modal-content
.modal-header
%a.close{href: "#", "data-dismiss" => "modal"} ×
- %h3.page-title New Wiki Page
+ %h3.page-title 新维基页面
.modal-body
%form.new-wiki-page
.form-group
= label_tag :new_wiki_path do
- %span Page slug
+ %span 页面别名
= text_field_tag :new_wiki_path, nil, placeholder: 'how-to-setup', class: 'form-control', required: true, :'data-wikis-path' => namespace_project_wikis_path(@project.namespace, @project), autofocus: true
.form-actions
- = button_tag 'Create Page', class: 'build-new-wiki btn btn-create'
+ = button_tag '创建页面', class: 'build-new-wiki btn btn-create'
diff --git a/app/views/projects/wikis/edit.html.haml b/app/views/projects/wikis/edit.html.haml
index 4dd818c7f67..4da93a4165c 100644
--- a/app/views/projects/wikis/edit.html.haml
+++ b/app/views/projects/wikis/edit.html.haml
@@ -1,4 +1,4 @@
-- page_title "Edit", @page.title.capitalize, "Wiki"
+- page_title "编辑", @page.title.capitalize, "维基"
= render "header_title"
= render 'nav'
@@ -11,7 +11,7 @@
= @page.title.capitalize
%span.light
&middot;
- Edit Page
+ 编辑页面
.nav-controls
= render 'main_links'
diff --git a/app/views/projects/wikis/empty.html.haml b/app/views/projects/wikis/empty.html.haml
index c7e490c3cd1..e45c3eaf7aa 100644
--- a/app/views/projects/wikis/empty.html.haml
+++ b/app/views/projects/wikis/empty.html.haml
@@ -1,7 +1,7 @@
-- page_title "Wiki"
+- page_title "维基"
= render "header_title"
-%h3.page-title Empty page
+%h3.page-title 空页面
%hr
.error_message
- You are not allowed to create wiki pages
+ 你无权限创建维基页面
diff --git a/app/views/projects/wikis/git_access.html.haml b/app/views/projects/wikis/git_access.html.haml
index dd27ea2b11b..9f892bf4cf3 100644
--- a/app/views/projects/wikis/git_access.html.haml
+++ b/app/views/projects/wikis/git_access.html.haml
@@ -1,10 +1,10 @@
-- page_title "Git Access", "Wiki"
+- page_title "Git 访问", "维基"
= render "header_title"
= render 'nav'
.gray-content-block
%span.oneline
- Git access for
+ 使用 Git 访问
%strong= @project_wiki.path_with_namespace
.pull-right
@@ -12,18 +12,18 @@
.git-empty.prepend-top-default
%fieldset
- %legend Install Gollum:
+ %legend 安装 Gollum:
%pre.dark
:preserve
gem install gollum
- %legend Clone Your Wiki:
+ %legend 克隆维基版本库:
%pre.dark
:preserve
git clone #{ content_tag(:span, default_url_to_repo(@project_wiki), class: 'clone')}
cd #{h @project_wiki.path}
- %legend Start Gollum And Edit Locally:
+ %legend 运行 Gollum 并在本地编辑:
%pre.dark
:preserve
gollum
diff --git a/app/views/projects/wikis/history.html.haml b/app/views/projects/wikis/history.html.haml
index dcaddae2b04..fc818ddb716 100644
--- a/app/views/projects/wikis/history.html.haml
+++ b/app/views/projects/wikis/history.html.haml
@@ -1,4 +1,4 @@
-- page_title "History", @page.title.capitalize, "Wiki"
+- page_title "历史记录", @page.title.capitalize, "维基"
= render "header_title"
= render 'nav'
@@ -8,17 +8,17 @@
= link_to @page.title.capitalize, namespace_project_wiki_path(@project.namespace, @project, @page)
%span.light
&middot;
- History
+ 历史记录
.table-holder
%table.table
%thead
%tr
- %th Page version
- %th Author
- %th Commit Message
- %th Last updated
- %th Format
+ %th 页面版本
+ %th 作者
+ %th 提交信息
+ %th 最后更新
+ %th 格式
%tbody
- @page.versions.each_with_index do |version, index|
- commit = version
diff --git a/app/views/projects/wikis/pages.html.haml b/app/views/projects/wikis/pages.html.haml
index 92b494a513c..144ebabf7f6 100644
--- a/app/views/projects/wikis/pages.html.haml
+++ b/app/views/projects/wikis/pages.html.haml
@@ -1,4 +1,4 @@
-- page_title "Pages", "Wiki"
+- page_title "页面", "维基"
= render "header_title"
= render 'nav'
@@ -9,5 +9,5 @@
= link_to wiki_page.title, namespace_project_wiki_path(@project.namespace, @project, wiki_page)
%small (#{wiki_page.format})
.pull-right
- %small Last edited #{time_ago_with_tooltip(wiki_page.commit.authored_date)}
+ %small 最后编辑时间:#{time_ago_with_tooltip(wiki_page.commit.authored_date)}
= paginate @wiki_pages, theme: 'gitlab'
diff --git a/app/views/projects/wikis/show.html.haml b/app/views/projects/wikis/show.html.haml
index 067fb7f8f54..d684576eef1 100644
--- a/app/views/projects/wikis/show.html.haml
+++ b/app/views/projects/wikis/show.html.haml
@@ -1,4 +1,4 @@
-- page_title @page.title.capitalize, "Wiki"
+- page_title @page.title.capitalize, "维基"
= render "header_title"
= render 'nav'
@@ -8,15 +8,15 @@
%span.wiki-last-edit-by
&middot;
- last edited by #{@page.commit.author.name} #{time_ago_with_tooltip(@page.commit.authored_date)}
+ #{@page.commit.author.name} #{time_ago_with_tooltip(@page.commit.authored_date)}最后编辑
.nav-controls
= render 'main_links'
- if @page.historical?
.warning_message
- This is an old version of this page.
- You can view the #{link_to "most recent version", namespace_project_wiki_path(@project.namespace, @project, @page)} or browse the #{link_to "history", namespace_project_wiki_history_path(@project.namespace, @project, @page)}.
+ 这是本页面的旧版本。
+ 你可以查看#{link_to "最近修改版本", namespace_project_wiki_path(@project.namespace, @project, @page)}或浏览#{link_to "历史记录", namespace_project_wiki_history_path(@project.namespace, @project, @page)}。
.wiki-holder.prepend-top-default
diff --git a/app/views/search/_category.html.haml b/app/views/search/_category.html.haml
index 2c3fca439f3..bbc6df0a945 100644
--- a/app/views/search/_category.html.haml
+++ b/app/views/search/_category.html.haml
@@ -4,49 +4,49 @@
= link_to search_filter_path(scope: 'blobs') do
= icon('code fw')
%span
- Code
+ 代码
%span.badge
= @search_results.blobs_count
%li{class: ("active" if @scope == 'issues')}
= link_to search_filter_path(scope: 'issues') do
= icon('exclamation-circle fw')
%span
- Issues
+ 问题
%span.badge
= @search_results.issues_count
%li{class: ("active" if @scope == 'merge_requests')}
= link_to search_filter_path(scope: 'merge_requests') do
= icon('tasks fw')
%span
- Merge requests
+ 合并请求
%span.badge
= @search_results.merge_requests_count
%li{class: ("active" if @scope == 'milestones')}
= link_to search_filter_path(scope: 'milestones') do
= icon('clock-o fw')
%span
- Milestones
+ 里程碑
%span.badge
= @search_results.milestones_count
%li{class: ("active" if @scope == 'notes')}
= link_to search_filter_path(scope: 'notes') do
= icon('comments fw')
%span
- Comments
+ 评论
%span.badge
= @search_results.notes_count
%li{class: ("active" if @scope == 'wiki_blobs')}
= link_to search_filter_path(scope: 'wiki_blobs') do
= icon('book fw')
%span
- Wiki
+ 维基
%span.badge
= @search_results.wiki_blobs_count
%li{class: ("active" if @scope == 'commits')}
= link_to search_filter_path(scope: 'commits') do
= icon('history fw')
%span
- Commits
+ 提交
%span.badge
= @search_results.commits_count
@@ -55,14 +55,14 @@
= link_to search_filter_path(scope: 'snippet_blobs', snippets: true, group_id: nil, project_id: nil) do
= icon('code fw')
%span
- Snippet Contents
+ 代码片段内容
%span.badge
= @search_results.snippet_blobs_count
%li{class: ("active" if @scope == 'snippet_titles')}
= link_to search_filter_path(scope: 'snippet_titles', snippets: true, group_id: nil, project_id: nil) do
= icon('book fw')
%span
- Titles and Filenames
+ 标题和文件名
%span.badge
= @search_results.snippet_titles_count
@@ -71,28 +71,28 @@
= link_to search_filter_path(scope: 'projects') do
= icon('bookmark fw')
%span
- Projects
+ 项目
%span.badge
= @search_results.projects_count
%li{class: ("active" if @scope == 'issues')}
= link_to search_filter_path(scope: 'issues') do
= icon('exclamation-circle fw')
%span
- Issues
+ 问题
%span.badge
= @search_results.issues_count
%li{class: ("active" if @scope == 'merge_requests')}
= link_to search_filter_path(scope: 'merge_requests') do
= icon('tasks fw')
%span
- Merge requests
+ 合并请求
%span.badge
= @search_results.merge_requests_count
%li{class: ("active" if @scope == 'milestones')}
= link_to search_filter_path(scope: 'milestones') do
= icon('clock-o fw')
%span
- Milestones
+ 里程碑
%span.badge
= @search_results.milestones_count
diff --git a/app/views/search/_results.html.haml b/app/views/search/_results.html.haml
index 60df348891c..dc8243c2fc9 100644
--- a/app/views/search/_results.html.haml
+++ b/app/views/search/_results.html.haml
@@ -2,14 +2,15 @@
= render partial: "search/results/empty"
- else
.gray-content-block
- Search results for
+ 在
%code
= @search_term
- unless @show_snippets
- if @project
- in project #{link_to @project.name_with_namespace, [@project.namespace.becomes(Namespace), @project]}
+ 项目 #{link_to @project.name_with_namespace, [@project.namespace.becomes(Namespace), @project]}
- elsif @group
- in group #{link_to @group.name, @group}
+ 群组 #{link_to @group.name, @group}
+ 搜索结果
.results.prepend-top-10
.search-results
diff --git a/app/views/search/results/_empty.html.haml b/app/views/search/results/_empty.html.haml
index 05a63016c09..eebcb8148ad 100644
--- a/app/views/search/results/_empty.html.haml
+++ b/app/views/search/results/_empty.html.haml
@@ -2,5 +2,6 @@
.search_glyph
%h4
= icon('search')
- We couldn't find any results matching
+ 没有发生任何符合
%code #{@search_term}
+ 的结果
diff --git a/app/views/search/results/_issue.html.haml b/app/views/search/results/_issue.html.haml
index 710f5613c81..9534e031f14 100644
--- a/app/views/search/results/_issue.html.haml
+++ b/app/views/search/results/_issue.html.haml
@@ -12,4 +12,4 @@
#{issue.project.name_with_namespace}
- if issue.closed?
.pull-right
- %span.label.label-danger Closed
+ %span.label.label-danger 已关闭
diff --git a/app/views/search/results/_merge_request.html.haml b/app/views/search/results/_merge_request.html.haml
index faeb2b55c6f..c9ad4652d82 100644
--- a/app/views/search/results/_merge_request.html.haml
+++ b/app/views/search/results/_merge_request.html.haml
@@ -11,6 +11,6 @@
#{merge_request.project.name_with_namespace}
.pull-right
- if merge_request.merged?
- %span.label.label-primary Merged
+ %span.label.label-primary 已合并
- elsif merge_request.closed?
- %span.label.label-danger Closed
+ %span.label.label-danger 已关闭
diff --git a/app/views/search/results/_note.html.haml b/app/views/search/results/_note.html.haml
index 5fcba2b7e93..fc714152b14 100644
--- a/app/views/search/results/_note.html.haml
+++ b/app/views/search/results/_note.html.haml
@@ -3,14 +3,14 @@
%h5.note-search-caption.str-truncated
%i.fa.fa-comment
= link_to_member(project, note.author, avatar: false)
- commented on
+ 评论在
- if note.for_commit?
= link_to project do
= project.name_with_namespace
&middot;
= link_to namespace_project_commit_path(project.namespace, project, note.commit_id, anchor: dom_id(note)) do
- Commit #{truncate_sha(note.commit_id)}
+ 提交 #{truncate_sha(note.commit_id)}
- else
= link_to project do
= project.name_with_namespace
diff --git a/app/views/search/results/_snippet_blob.html.haml b/app/views/search/results/_snippet_blob.html.haml
index c9b7bd154af..7b1bcc0cb8e 100644
--- a/app/views/search/results/_snippet_blob.html.haml
+++ b/app/views/search/results/_snippet_blob.html.haml
@@ -5,7 +5,7 @@
.search-result-row
%span
= snippet.title
- by
+ 属于
= link_to user_snippets_path(snippet.author) do
= image_tag avatar_icon(snippet.author_email), class: "avatar avatar-inline s16", alt: ''
= snippet.author_name
@@ -24,7 +24,7 @@
= render_markup(snippet.file_name, chunk[:data])
- else
.file-content.code
- .nothing-here-block Empty file
+ .nothing-here-block 空文件
- else
.file-content.code.js-syntax-highlight
.line-numbers
@@ -49,4 +49,4 @@
= "..."
- else
.file-content.code
- .nothing-here-block Empty file
+ .nothing-here-block 空文件
diff --git a/app/views/search/results/_snippet_title.html.haml b/app/views/search/results/_snippet_title.html.haml
index c414acb6a11..c4e7702a92a 100644
--- a/app/views/search/results/_snippet_title.html.haml
+++ b/app/views/search/results/_snippet_title.html.haml
@@ -5,7 +5,7 @@
- if snippet_title.private?
%span.label.label-gray
%i.fa.fa-lock
- private
+ 私有
%span.cgray.monospace.tiny.pull-right.term
= snippet_title.file_name
@@ -16,7 +16,7 @@
.snippet-info
= "##{snippet_title.id}"
%span
- by
+ 属于
= link_to user_snippets_path(snippet_title.author) do
= image_tag avatar_icon(snippet_title.author_email), class: "avatar avatar-inline s16", alt: ''
= snippet_title.author_name
diff --git a/app/views/shared/_choose_group_avatar_button.html.haml b/app/views/shared/_choose_group_avatar_button.html.haml
index 000532b1c9a..66a64ed1d97 100644
--- a/app/views/shared/_choose_group_avatar_button.html.haml
+++ b/app/views/shared/_choose_group_avatar_button.html.haml
@@ -1,7 +1,7 @@
%a.choose-btn.btn.btn-sm.js-choose-group-avatar-button
%i.fa.fa-paperclip
- %span Choose File ...
+ %span 选择文件...
&nbsp;
-%span.file_name.js-avatar-filename File name...
+%span.file_name.js-avatar-filename 文件名...
= f.file_field :avatar, class: 'js-group-avatar-input hidden'
-.light The maximum file size allowed is 200KB.
+.light 允许的最大文件大小 200KB。
diff --git a/app/views/shared/_commit_message_container.html.haml b/app/views/shared/_commit_message_container.html.haml
index 7afbaeddee8..55c8a29ea1a 100644
--- a/app/views/shared/_commit_message_container.html.haml
+++ b/app/views/shared/_commit_message_container.html.haml
@@ -1,7 +1,7 @@
.form-group.commit_message-group
- nonce = SecureRandom.hex
= label_tag "commit_message-#{nonce}", class: 'control-label' do
- Commit message
+ 提交信息
.col-sm-10
.commit-message-container
.max-width-marker
@@ -12,5 +12,4 @@
id: "commit_message-#{nonce}"
- if local_assigns[:hint]
%p.hint
- Try to keep the first line under 52 characters
- and the others under 72.
+ 建议第一行最多 52 个字节,其他行最多 72 字节。
diff --git a/app/views/shared/_confirm_modal.html.haml b/app/views/shared/_confirm_modal.html.haml
index 34241cd8aad..05c6bbea775 100644
--- a/app/views/shared/_confirm_modal.html.haml
+++ b/app/views/shared/_confirm_modal.html.haml
@@ -4,20 +4,20 @@
.modal-header
%a.close{href: "#", "data-dismiss" => "modal"} ×
%h3.page-title
- Confirmation required
+ 需要确认
.modal-body
%p.cred.lead.js-confirm-text
%p
- This action can lead to data loss.
- To prevent accidental actions we ask you to confirm your intention.
+ 此动作会导致数据丢失。
+ 为防止有意外操作,所以要求额外的操作来确认你的实际意图。
%br
- Please type
+ 请输入
%code.js-confirm-danger-match #{phrase}
- to proceed or close this modal to cancel.
+ 继续操作或关闭本对话框取消操作。
.form-group
= text_field_tag 'confirm_name_input', '', class: 'form-control js-confirm-danger-input'
.form-actions
- = submit_tag 'Confirm', class: "btn btn-danger js-confirm-danger-submit"
+ = submit_tag '确认', class: "btn btn-danger js-confirm-danger-submit"
diff --git a/app/views/shared/_event_filter.html.haml b/app/views/shared/_event_filter.html.haml
index c38d9313dba..f5c69c57324 100644
--- a/app/views/shared/_event_filter.html.haml
+++ b/app/views/shared/_event_filter.html.haml
@@ -1,5 +1,5 @@
%ul.nav-links.event-filter
- = event_filter_link EventFilter.push, 'Push events'
- = event_filter_link EventFilter.merged, 'Merge events'
- = event_filter_link EventFilter.comments, 'Comments'
- = event_filter_link EventFilter.team, 'Team'
+ = event_filter_link EventFilter.push, '推送事件'
+ = event_filter_link EventFilter.merged, '合并事件'
+ = event_filter_link EventFilter.comments, '注释'
+ = event_filter_link EventFilter.team, '团队'
diff --git a/app/views/shared/_field.html.haml b/app/views/shared/_field.html.haml
index 8d6e16f74c3..cd1433959f0 100644
--- a/app/views/shared/_field.html.haml
+++ b/app/views/shared/_field.html.haml
@@ -9,7 +9,7 @@
.form-group
- if type == "password" && value.present?
- = form.label name, "Change #{title}", class: "control-label"
+ = form.label name, "修改 #{title}", class: "control-label"
- else
= form.label name, title, class: "control-label"
.col-sm-10
diff --git a/app/views/shared/_group_form.html.haml b/app/views/shared/_group_form.html.haml
index 67072b9fc2a..a94359501ab 100644
--- a/app/views/shared/_group_form.html.haml
+++ b/app/views/shared/_group_form.html.haml
@@ -1,13 +1,13 @@
- if @group.persisted?
.form-group
= f.label :name, class: 'control-label' do
- Group name
+ 群组名称
.col-sm-10
= f.text_field :name, placeholder: 'open-source', class: 'form-control'
.form-group
= f.label :path, class: 'control-label' do
- Group path
+ 群组路径
.col-sm-10
.input-group
.input-group-addon
@@ -17,13 +17,13 @@
- if @group.persisted?
.alert.alert-warning.prepend-top-10
%ul
- %li Changing group path can have unintended side effects.
- %li Renaming group path will rename directory for all related projects
- %li It will change web url for access group and group projects.
- %li It will change the git path to repositories under this group.
+ %li 修改群组路径会存在意想不到的副作用。
+ %li 重命名群组路径会重命名所有相关项目的路径
+ %li 包括改变群组和群组项目的网页访问链接。
+ %li 包括改变群组下版本库的 git 路径。
.form-group.group-description-holder
- = f.label :description, class: 'control-label'
+ = f.label :description, '描述', class: 'control-label'
.col-sm-10
= f.text_area :description, maxlength: 250,
class: 'form-control js-gfm-input', rows: 4
diff --git a/app/views/shared/_import_form.html.haml b/app/views/shared/_import_form.html.haml
index 627814bcfae..ecbc9a71fee 100644
--- a/app/views/shared/_import_form.html.haml
+++ b/app/views/shared/_import_form.html.haml
@@ -1,16 +1,16 @@
.form-group.import-url-data
= f.label :import_url, class: 'control-label' do
- %span Git repository URL
+ %span Git 仓库的链接
.col-sm-10
= f.text_field :import_url, class: 'form-control', placeholder: 'https://username:password@gitlab.company.com/group/project.git'
.well.prepend-top-20
%ul
%li
- The repository must be accessible over <code>http://</code>, <code>https://</code> or <code>git://</code>.
+ 版本仓库必须使用 <code>http://</code>、<code>https://</code> 或 <code>git://</code> 访问。
%li
- If your HTTP repository is not publicly accessible, add authentication information to the URL: <code>https://username:password@gitlab.company.com/group/project.git</code>.
+ 链接必须能公开访问或指定用户名和密码类似:<code>https://username:password@gitlab.company.com/group/project.git</code>。
%li
- The import will time out after 15 minutes. For repositories that take longer, use a clone/push combination.
+ 导入超过 4 分钟将会超时。对于大仓库,请使用 clone/push 组合操作。
%li
- To migrate an SVN repository, check out #{link_to "this document", "http://doc.gitlab.com/ce/workflow/importing/migrating_from_svn.html"}.
+ 对于合并 SVN 仓库,请查看#{link_to "此文档", "http://doc.gitlab.com/ce/workflow/importing/migrating_from_svn.html"}。
diff --git a/app/views/shared/_merge_requests.html.haml b/app/views/shared/_merge_requests.html.haml
index e74fc36c797..43ab4c75ebd 100644
--- a/app/views/shared/_merge_requests.html.haml
+++ b/app/views/shared/_merge_requests.html.haml
@@ -14,4 +14,4 @@
= paginate @merge_requests, theme: "gitlab"
- else
- .nothing-here-block No merge requests to show
+ .nothing-here-block 没有合并请求显示
diff --git a/app/views/shared/_milestone_expired.html.haml b/app/views/shared/_milestone_expired.html.haml
index b8eef15fbec..be536426732 100644
--- a/app/views/shared/_milestone_expired.html.haml
+++ b/app/views/shared/_milestone_expired.html.haml
@@ -1,5 +1,5 @@
- if milestone.expired? and not milestone.closed?
- %span.cred (Expired)
+ %span.cred (已过期)
- if milestone.expires_at
%span
= milestone.expires_at
diff --git a/app/views/shared/_milestones_filter.html.haml b/app/views/shared/_milestones_filter.html.haml
index cf16c203f9c..43062b6424e 100644
--- a/app/views/shared/_milestones_filter.html.haml
+++ b/app/views/shared/_milestones_filter.html.haml
@@ -1,10 +1,10 @@
%ul.nav-links
%li{class: ("active" if params[:state].blank? || params[:state] == 'opened')}
= link_to milestones_filter_path(state: 'opened') do
- Open
+ 未关闭
%li{class: ("active" if params[:state] == 'closed')}
= link_to milestones_filter_path(state: 'closed') do
- Closed
+ 已关闭
%li{class: ("active" if params[:state] == 'all')}
= link_to milestones_filter_path(state: 'all') do
- All
+ 全部
diff --git a/app/views/shared/_new_commit_form.html.haml b/app/views/shared/_new_commit_form.html.haml
index 0c8ac48bb58..fc0c40baeca 100644
--- a/app/views/shared/_new_commit_form.html.haml
+++ b/app/views/shared/_new_commit_form.html.haml
@@ -5,7 +5,7 @@
- else
- if can?(current_user, :push_code, @project)
.form-group.branch
- = label_tag 'target_branch', 'Target branch', class: 'control-label'
+ = label_tag 'target_branch', '目标分支', class: 'control-label'
.col-sm-10
= text_field_tag 'target_branch', @target_branch || tree_edit_branch, required: true, class: "form-control js-target-branch"
@@ -14,7 +14,7 @@
- nonce = SecureRandom.hex
= label_tag "create_merge_request-#{nonce}" do
= check_box_tag 'create_merge_request', 1, true, class: 'js-create-merge-request', id: "create_merge_request-#{nonce}"
- Start a <strong>new merge request</strong> with these changes
+ 从此提交开启<strong>新合并请求</strong>
- else
= hidden_field_tag 'target_branch', @target_branch || tree_edit_branch
= hidden_field_tag 'create_merge_request', 1
diff --git a/app/views/shared/_no_password.html.haml b/app/views/shared/_no_password.html.haml
index a43bf33751a..182ff4b0469 100644
--- a/app/views/shared/_no_password.html.haml
+++ b/app/views/shared/_no_password.html.haml
@@ -1,8 +1,8 @@
- if cookies[:hide_no_password_message].blank? && !current_user.hide_no_password && current_user.require_password?
.no-password-message.alert.alert-warning.hidden-xs
- You won't be able to pull or push project code via #{gitlab_config.protocol.upcase} until you #{link_to 'set a password', edit_profile_password_path} on your account
+ 你不能通过 #{gitlab_config.protocol.upcase} 拉取和推送项目代码,除非你立即#{link_to '设置账户密码', edit_profile_password_path}。
.pull-right
- = link_to "Don't show again", profile_path(user: {hide_no_password: true}), method: :put
+ = link_to "不再显示", profile_path(user: {hide_no_password: true}), method: :put
|
- = link_to 'Remind later', '#', class: 'hide-no-password-message'
+ = link_to '稍后提示', '#', class: 'hide-no-password-message'
diff --git a/app/views/shared/_outdated_browser.html.haml b/app/views/shared/_outdated_browser.html.haml
index 0eba1fe075f..572d363638a 100644
--- a/app/views/shared/_outdated_browser.html.haml
+++ b/app/views/shared/_outdated_browser.html.haml
@@ -1,8 +1,8 @@
- if outdated_browser?
- link = "https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/install/requirements.md#supported-web-browsers"
.browser-alert
- GitLab may not work properly because you are using an outdated web browser.
+ 很可能因为使用了过时的网页浏览器导致 GitLab 无法工作。
%br
- Please install a
- = link_to 'supported web browser', link
- for a better experience.
+ 请安装
+ = link_to '支持的网页浏览器', link
+ 获得更好的体验。
diff --git a/app/views/shared/_project_limit.html.haml b/app/views/shared/_project_limit.html.haml
index f4eb8e491b9..a888031b6cd 100644
--- a/app/views/shared/_project_limit.html.haml
+++ b/app/views/shared/_project_limit.html.haml
@@ -1,8 +1,8 @@
- if cookies[:hide_project_limit_message].blank? && !current_user.hide_project_limit && !current_user.can_create_project? && current_user.projects_limit > 0
.project-limit-message.alert.alert-warning.hidden-xs
- You won't be able to create new projects because you have reached your project limit.
+ 因为你创建的项目达到限制,无法创建新项目。
.pull-right
- = link_to "Don't show again", profile_path(user: {hide_project_limit: true}), method: :put, class: 'alert-link'
+ = link_to "不再显示", profile_path(user: {hide_project_limit: true}), method: :put, class: 'alert-link'
|
- = link_to 'Remind later', '#', class: 'hide-project-limit-message alert-link'
+ = link_to '稍后提醒', '#', class: 'hide-project-limit-message alert-link'
diff --git a/app/views/shared/_promo.html.haml b/app/views/shared/_promo.html.haml
index 09edf4000d5..b6a86136e00 100644
--- a/app/views/shared/_promo.html.haml
+++ b/app/views/shared/_promo.html.haml
@@ -1,5 +1,6 @@
.gitlab-promo
- = link_to 'Homepage', promo_url
- = link_to 'Blog', promo_url + '/blog/'
+ = link_to '主页', promo_url
+ = link_to "中文", "https://gitlab.com/larryli/gitlab/"
+ = link_to '博客', promo_url + '/blog/'
= link_to '@gitlab', 'https://twitter.com/gitlab'
- = link_to 'Requests', 'https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#feature-proposals'
+ = link_to '需求', 'https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#feature-proposals'
diff --git a/app/views/shared/_service_settings.html.haml b/app/views/shared/_service_settings.html.haml
index 5a60ff5a5da..cb261730e99 100644
--- a/app/views/shared/_service_settings.html.haml
+++ b/app/views/shared/_service_settings.html.haml
@@ -11,62 +11,62 @@
= markdown @service.help
.form-group
- = form.label :active, "Active", class: "control-label"
+ = form.label :active, "激活", class: "control-label"
.col-sm-10
= form.check_box :active
- if @service.supported_events.length > 1
.form-group
- = form.label :url, "Trigger", class: 'control-label'
+ = form.label :url, "触发", class: 'control-label'
.col-sm-10
- if @service.supported_events.include?("push")
%div
= form.check_box :push_events, class: 'pull-left'
.prepend-left-20
= form.label :push_events, class: 'list-label' do
- %strong Push events
+ %strong 推送事件
%p.light
- This url will be triggered by a push to the repository
+ 推送仓库时将触发此链接
- if @service.supported_events.include?("tag_push")
%div
= form.check_box :tag_push_events, class: 'pull-left'
.prepend-left-20
= form.label :tag_push_events, class: 'list-label' do
- %strong Tag push events
+ %strong 标签推送事件
%p.light
- This url will be triggered when a new tag is pushed to the repository
+ 新标签推送仓库时将触发此链接
- if @service.supported_events.include?("note")
%div
= form.check_box :note_events, class: 'pull-left'
.prepend-left-20
= form.label :note_events, class: 'list-label' do
- %strong Comments
+ %strong 评论
%p.light
- This url will be triggered when someone adds a comment
+ 有人增加评论时将触发此链接
- if @service.supported_events.include?("issue")
%div
= form.check_box :issues_events, class: 'pull-left'
.prepend-left-20
= form.label :issues_events, class: 'list-label' do
- %strong Issues events
+ %strong 问题事件
%p.light
- This url will be triggered when an issue is created/updated/merged
+ 问题创建、更新、合并时将触发此链接
- if @service.supported_events.include?("merge_request")
%div
= form.check_box :merge_requests_events, class: 'pull-left'
.prepend-left-20
= form.label :merge_requests_events, class: 'list-label' do
- %strong Merge Request events
+ %strong 合并请求事件
%p.light
- This url will be triggered when a merge request is created/updated/merged
+ 合并请求创建、更新、合并时将触发此链接
- if @service.supported_events.include?("build")
%div
= form.check_box :build_events, class: 'pull-left'
.prepend-left-20
= form.label :build_events, class: 'list-label' do
- %strong Build events
+ %strong 构建事件
%p.light
- This url will be triggered when a build status changes
+ 构建状态改变时将触发此链接
- @service.fields.each do |field|
diff --git a/app/views/shared/_visibility_level.html.haml b/app/views/shared/_visibility_level.html.haml
index 1c6ec198d3d..e5c1270bada 100644
--- a/app/views/shared/_visibility_level.html.haml
+++ b/app/views/shared/_visibility_level.html.haml
@@ -1,6 +1,6 @@
.form-group.project-visibility-level-holder
= f.label :visibility_level, class: 'control-label' do
- Visibility Level
+ 可见等级
= link_to "(?)", help_page_path("public_access", "public_access")
.col-sm-10
- if can_change_visibility_level
diff --git a/app/views/shared/_visibility_radios.html.haml b/app/views/shared/_visibility_radios.html.haml
index ebe2eb0433d..d234fd12e2c 100644
--- a/app/views/shared/_visibility_radios.html.haml
+++ b/app/views/shared/_visibility_radios.html.haml
@@ -12,4 +12,4 @@
- unless restricted_visibility_levels.empty?
.col-sm-10
%span.info
- Some visibility level settings have been restricted by the administrator.
+ 一些可见等级已被管理员限制。
diff --git a/app/views/shared/groups/_group.html.haml b/app/views/shared/groups/_group.html.haml
index 28e28789a8d..ddd74b5353c 100644
--- a/app/views/shared/groups/_group.html.haml
+++ b/app/views/shared/groups/_group.html.haml
@@ -9,7 +9,7 @@
= link_to edit_group_path(group), class: "btn-sm btn btn-grouped" do
%i.fa.fa-cogs
- = link_to leave_group_group_members_path(group), data: { confirm: leave_group_message(group.name) }, method: :delete, class: "btn-sm btn btn-grouped", title: 'Leave this group' do
+ = link_to leave_group_group_members_path(group), data: { confirm: leave_group_message(group.name) }, method: :delete, class: "btn-sm btn btn-grouped", title: '离开此群组' do
%i.fa.fa-sign-out
.stats
diff --git a/app/views/shared/issuable/_nav.html.haml b/app/views/shared/issuable/_nav.html.haml
index a6970b7eebb..1d0b00bacb7 100644
--- a/app/views/shared/issuable/_nav.html.haml
+++ b/app/views/shared/issuable/_nav.html.haml
@@ -1,25 +1,25 @@
%ul.nav-links.issues-state-filters
- if defined?(type) && type == :merge_requests
- - page_context_word = 'merge requests'
+ - page_context_word = '合并请求'
- else
- - page_context_word = 'issues'
+ - page_context_word = '问题'
%li{class: ("active" if params[:state] == 'opened')}
- = link_to page_filter_path(state: 'opened'), title: "Filter by #{page_context_word} that are currently opened." do
+ = link_to page_filter_path(state: 'opened'), title: "只显示当前未关闭的#{page_context_word}。" do
#{state_filters_text_for(:opened, @project)}
- if defined?(type) && type == :merge_requests
%li{class: ("active" if params[:state] == 'merged')}
- = link_to page_filter_path(state: 'merged'), title: 'Filter by merge requests that are currently merged.' do
+ = link_to page_filter_path(state: 'merged'), title: '只显示当前已合并的合并请求。' do
#{state_filters_text_for(:merged, @project)}
%li{class: ("active" if params[:state] == 'closed')}
- = link_to page_filter_path(state: 'closed'), title: 'Filter by merge requests that are currently closed and unmerged.' do
+ = link_to page_filter_path(state: 'closed'), title: '只显示当前已关闭、未合并的合并请求。' do
#{state_filters_text_for(:closed, @project)}
- else
%li{class: ("active" if params[:state] == 'closed')}
- = link_to page_filter_path(state: 'closed'), title: 'Filter by issues that are currently closed.' do
+ = link_to page_filter_path(state: 'closed'), title: '只显示当前已关闭的问题。' do
#{state_filters_text_for(:closed, @project)}
%li{class: ("active" if params[:state] == 'all')}
- = link_to page_filter_path(state: 'all'), title: "Show all #{page_context_word}." do
+ = link_to page_filter_path(state: 'all'), title: "显示全部#{page_context_word}。" do
#{state_filters_text_for(:all, @project)}
diff --git a/app/views/shared/issuable/_search_form.html.haml b/app/views/shared/issuable/_search_form.html.haml
index afad48499b7..9223aa6bc7c 100644
--- a/app/views/shared/issuable/_search_form.html.haml
+++ b/app/views/shared/issuable/_search_form.html.haml
@@ -1,5 +1,5 @@
= form_tag(path, method: :get, id: "issue_search_form", class: 'issue-search-form') do
- = search_field_tag :issue_search, params[:issue_search], { placeholder: 'Filter by name ...', class: 'form-control issue_search search-text-input input-short', spellcheck: false }
+ = search_field_tag :issue_search, params[:issue_search], { placeholder: '按名称过滤...', class: 'form-control issue_search search-text-input input-short', spellcheck: false }
= hidden_field_tag :state, params['state']
= hidden_field_tag :scope, params['scope']
= hidden_field_tag :assignee_id, params['assignee_id']
diff --git a/app/views/shared/issuable/_sidebar.html.haml b/app/views/shared/issuable/_sidebar.html.haml
index 2b95b19facc..fd8952ae4f4 100644
--- a/app/views/shared/issuable/_sidebar.html.haml
+++ b/app/views/shared/issuable/_sidebar.html.haml
@@ -110,7 +110,7 @@
= clipboard_button(clipboard_text: project_ref)
.cross-project-reference.hide-collapsed
%span
- Reference:
+ 参考:
%cite{title: project_ref}
= project_ref
= clipboard_button(clipboard_text: project_ref)
diff --git a/app/views/shared/snippets/_blob.html.haml b/app/views/shared/snippets/_blob.html.haml
index 773ce8ac240..b6a711e5162 100644
--- a/app/views/shared/snippets/_blob.html.haml
+++ b/app/views/shared/snippets/_blob.html.haml
@@ -8,4 +8,4 @@
= render 'shared/file_highlight', blob: @snippet
- else
.file-content.code
- .nothing-here-block Empty file
+ .nothing-here-block 空文件
diff --git a/app/views/shared/snippets/_form.html.haml b/app/views/shared/snippets/_form.html.haml
index 1041eccd1df..fa2cf28f8af 100644
--- a/app/views/shared/snippets/_form.html.haml
+++ b/app/views/shared/snippets/_form.html.haml
@@ -7,7 +7,7 @@
%li= msg
.form-group
- = f.label :title, class: 'control-label'
+ = f.label :title, "标题", class: 'control-label'
.col-sm-10
= f.text_field :title, class: 'form-control', required: true, autofocus: true
@@ -15,25 +15,25 @@
.file-editor
.form-group
- = f.label :file_name, "File", class: 'control-label'
+ = f.label :file_name, "文件", class: 'control-label'
.col-sm-10
.file-holder.snippet
.file-title
- = f.text_field :file_name, placeholder: "Optionally name this file to add code highlighting, e.g. example.rb for Ruby.", class: 'form-control snippet-file-name'
+ = f.text_field :file_name, placeholder: "可选的文件名称以便增加代码高亮,比如 example.rb 显示 Ruby 代码。", class: 'form-control snippet-file-name'
.file-content.code
%pre#editor= @snippet.content
= f.hidden_field :content, class: 'snippet-file-content'
.form-actions
- if @snippet.new_record?
- = f.submit 'Create snippet', class: "btn-create btn"
+ = f.submit '创建代码片段', class: "btn-create btn"
- else
- = f.submit 'Save changes', class: "btn-save btn"
+ = f.submit '保存修改', class: "btn-save btn"
- if @snippet.project_id
- = link_to "Cancel", namespace_project_snippets_path(@project.namespace, @project), class: "btn btn-cancel"
+ = link_to "取消", namespace_project_snippets_path(@project.namespace, @project), class: "btn btn-cancel"
- else
- = link_to "Cancel", snippets_path(@project), class: "btn btn-cancel"
+ = link_to "取消", snippets_path(@project), class: "btn btn-cancel"
:javascript
var editor = ace.edit("editor");
diff --git a/app/views/shared/snippets/_header.html.haml b/app/views/shared/snippets/_header.html.haml
index aa5acee9c14..b17e6dbf3fc 100644
--- a/app/views/shared/snippets/_header.html.haml
+++ b/app/views/shared/snippets/_header.html.haml
@@ -3,9 +3,9 @@
= visibility_level_icon(@snippet.visibility_level, fw: false)
= visibility_level_label(@snippet.visibility_level)
%span.identifier
- Snippet ##{@snippet.id}
+ 代码片段 ##{@snippet.id}
%span.creator
- &middot; created by #{link_to_member(@project, @snippet.author, size: 24)}
+ &middot; 由 #{link_to_member(@project, @snippet.author, size: 24)} 创建于
&middot;
= time_ago_with_tooltip(@snippet.created_at, placement: 'bottom', html_class: 'snippet_updated_ago')
- if @snippet.updated_at != @snippet.created_at
diff --git a/app/views/snippets/_actions.html.haml b/app/views/snippets/_actions.html.haml
index 1979ae6d5bc..7e0b8375dfc 100644
--- a/app/views/snippets/_actions.html.haml
+++ b/app/views/snippets/_actions.html.haml
@@ -1,11 +1,11 @@
-= link_to new_snippet_path, class: 'btn btn-grouped new-snippet-link', title: "New Snippet" do
+= link_to new_snippet_path, class: 'btn btn-grouped new-snippet-link', title: "新代码片段" do
= icon('plus')
- New Snippet
+ 新代码片段
- if can?(current_user, :update_personal_snippet, @snippet)
= link_to edit_snippet_path(@snippet), class: "btn btn-grouped snippable-edit" do
= icon('pencil-square-o')
- Edit
+ 编辑
- if can?(current_user, :admin_personal_snippet, @snippet)
- = link_to snippet_path(@snippet), method: :delete, data: { confirm: "Are you sure?" }, class: "btn btn-grouped btn-remove", title: 'Delete Snippet' do
+ = link_to snippet_path(@snippet), method: :delete, data: { confirm: "确定要继续么?" }, class: "btn btn-grouped btn-remove", title: '删除代码片段' do
= icon('trash-o')
- Delete
+ 删除
diff --git a/app/views/snippets/_snippets.html.haml b/app/views/snippets/_snippets.html.haml
index 80a3e731e1d..3145250ce56 100644
--- a/app/views/snippets/_snippets.html.haml
+++ b/app/views/snippets/_snippets.html.haml
@@ -2,6 +2,6 @@
= render partial: 'shared/snippets/snippet', collection: @snippets
- if @snippets.empty?
%li
- .nothing-here-block Nothing here.
+ .nothing-here-block 没有内容。
= paginate @snippets, theme: 'gitlab'
diff --git a/app/views/snippets/edit.html.haml b/app/views/snippets/edit.html.haml
index 82f44a9a5c3..181d30472e2 100644
--- a/app/views/snippets/edit.html.haml
+++ b/app/views/snippets/edit.html.haml
@@ -1,5 +1,5 @@
-- page_title "Edit", @snippet.title, "Snippets"
+- page_title "编辑", @snippet.title, "代码片段"
%h3.page-title
- Edit Snippet
+ 编辑代码片段
%hr
= render 'shared/snippets/form', url: snippet_path(@snippet), visibility_level: @snippet.visibility_level
diff --git a/app/views/snippets/index.html.haml b/app/views/snippets/index.html.haml
index 7e4918a6085..aad3db7dec4 100644
--- a/app/views/snippets/index.html.haml
+++ b/app/views/snippets/index.html.haml
@@ -1,13 +1,13 @@
-- page_title "By #{@user.name}", "Snippets"
+- page_title "属于 #{@user.name}", "代码片段"
%ol.breadcrumb
%li
= link_to snippets_path do
- Snippets
+ 代码片段
%li
= @user.name
.pull-right.hidden-xs
= link_to user_path(@user) do
- #{@user.name} profile page
+ #{@user.name} 个人资料页面
= render 'snippets'
diff --git a/app/views/snippets/new.html.haml b/app/views/snippets/new.html.haml
index 79e2392490d..d910a13674d 100644
--- a/app/views/snippets/new.html.haml
+++ b/app/views/snippets/new.html.haml
@@ -1,5 +1,5 @@
-- page_title "New Snippet"
+- page_title "新代码片段"
%h3.page-title
- New Snippet
+ 新代码片段
%hr
= render "shared/snippets/form", url: snippets_path(@snippet), visibility_level: default_snippet_visibility
diff --git a/app/views/snippets/show.html.haml b/app/views/snippets/show.html.haml
index a2b36568770..31e1a36aa0a 100644
--- a/app/views/snippets/show.html.haml
+++ b/app/views/snippets/show.html.haml
@@ -1,4 +1,4 @@
-- page_title @snippet.title, "Snippets"
+- page_title @snippet.title, "代码片段"
.snippet-holder
= render 'shared/snippets/header'
@@ -10,5 +10,5 @@
= @snippet.file_name
.file-actions.hidden-xs
= clipboard_button(clipboard_target: ".blob-content[data-blob-id='#{@snippet.id}']")
- = link_to 'Raw', raw_snippet_path(@snippet), class: "btn btn-sm", target: "_blank"
+ = link_to '原文件', raw_snippet_path(@snippet), class: "btn btn-sm", target: "_blank"
= render 'shared/snippets/blob'
diff --git a/app/views/users/calendar.html.haml b/app/views/users/calendar.html.haml
index 7f29918dba3..f888ad35975 100644
--- a/app/views/users/calendar.html.haml
+++ b/app/views/users/calendar.html.haml
@@ -7,4 +7,4 @@
'#{user_calendar_activities_path}'
);
-.calendar-hint Summary of issues, merge requests and push events
+.calendar-hint 问题、合并请求和推送事件摘要
diff --git a/app/views/users/calendar_activities.html.haml b/app/views/users/calendar_activities.html.haml
index 027a93a75fc..1d69ba09350 100644
--- a/app/views/users/calendar_activities.html.haml
+++ b/app/views/users/calendar_activities.html.haml
@@ -1,5 +1,5 @@
%h4.prepend-top-20
- %span.light Contributions for
+ %span.light 贡献
%strong #{@calendar_date.to_s(:short)}
%ul.bordered-list
diff --git a/app/views/users/show.atom.builder b/app/views/users/show.atom.builder
index e9e466c6350..b469571f723 100644
--- a/app/views/users/show.atom.builder
+++ b/app/views/users/show.atom.builder
@@ -1,6 +1,6 @@
xml.instruct!
xml.feed "xmlns" => "http://www.w3.org/2005/Atom", "xmlns:media" => "http://search.yahoo.com/mrss/" do
- xml.title "#{@user.name} activity"
+ xml.title "#{@user.name}活动"
xml.link href: user_url(@user, :atom), rel: "self", type: "application/atom+xml"
xml.link href: user_url(@user), rel: "alternate", type: "text/html"
xml.id user_url(@user)
diff --git a/app/views/users/show.html.haml b/app/views/users/show.html.haml
index bca816f22cb..df6486a1371 100644
--- a/app/views/users/show.html.haml
+++ b/app/views/users/show.html.haml
@@ -4,7 +4,7 @@
- @no_container = true
= content_for :meta_tags do
- = auto_discovery_link_tag(:atom, user_url(@user, format: :atom), title: "#{@user.name} activity")
+ = auto_discovery_link_tag(:atom, user_url(@user, format: :atom), title: "#{@user.name}活动")
= render 'shared/show_aside'
diff --git a/config/application.rb b/config/application.rb
index 5a0ac70aa2a..597d092bd7d 100644
--- a/config/application.rb
+++ b/config/application.rb
@@ -26,9 +26,10 @@ module Gitlab
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
- # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
- # config.i18n.default_locale = :de
- config.i18n.enforce_available_locales = false
+ config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
+ config.i18n.enforce_available_locales = true
+ config.i18n.default_locale = :zh
+ config.i18n.locale = :zh
# Configure the default encoding used in templates for Ruby 1.9.
config.encoding = "utf-8"
diff --git a/config/initializers/date_time_formats.rb b/config/initializers/date_time_formats.rb
index 57568203cab..57ab1c47a4a 100644
--- a/config/initializers/date_time_formats.rb
+++ b/config/initializers/date_time_formats.rb
@@ -1,9 +1,9 @@
# :short - 10 Nov
# :medium - Nov 10, 2007
# :long - November 10, 2007
-Date::DATE_FORMATS[:medium] = '%b %-d, %Y'
+Date::DATE_FORMATS[:medium] = '%Y-%m-%d'
# :short - 18 Jan 06:10
# :medium - Jan 18, 2007 6:10am
# :long - January 18, 2007 06:10
-Time::DATE_FORMATS[:medium] = '%b %-d, %Y %-I:%M%P'
+Time::DATE_FORMATS[:medium] = '%Y-%m-%d %H:%M'
diff --git a/config/locales/devise.zh.yml b/config/locales/devise.zh.yml
new file mode 100644
index 00000000000..1cb2da26915
--- /dev/null
+++ b/config/locales/devise.zh.yml
@@ -0,0 +1,61 @@
+# Additional translations at http://github.com/plataformatec/devise/wiki/I18n
+
+zh:
+ errors:
+ messages:
+ expired: "您已过期,请重新申请"
+ not_found: "没有找到"
+ already_confirmed: "已经激活,请重新登录"
+ not_locked: "未锁定"
+ not_saved:
+ one: "因为 1 个错误导致此 %{resource} 保存失败:"
+ other: "因为 %{count} 个错误导致此 %{resource} 保存失败:"
+
+ devise:
+ failure:
+ already_authenticated: '您已经登录。'
+ unauthenticated: '继续操作前请注册或者登录。'
+ unconfirmed: '继续操作前请先激活您的帐号。'
+ locked: '您的帐号已被锁定。'
+ not_found_in_database: '邮箱或密码错误。'
+ invalid: '邮箱或密码错误。'
+ invalid_token: '认证码无效。'
+ timeout: '您已登录超时,请重新登录。'
+ inactive: '您还没有激活帐户。'
+ sessions:
+ signed_in: '登录成功。'
+ signed_out: '退出成功。'
+ users_sessions:
+ user:
+ signed_in: '登录成功。'
+ passwords:
+ send_instructions: '稍后你将收到帐号激活的电子邮件。'
+ updated: '您的密码已修改成功,您现在已登录。'
+ updated_not_active: '您的密码已修改成功。'
+ send_paranoid_instructions: '如果您的邮箱存在于我们的数据库中,您将收到一封找回密码的邮件'
+ confirmations:
+ send_instructions: '稍后你将收到帐号激活的电子邮件。'
+ send_paranoid_instructions: '如果您的邮箱存在于我们的数据库中,您将收到一封激活账号的邮件。'
+ confirmed: '您的帐号已经激活,您现在已登录。'
+ registrations:
+ signed_up: '欢迎您!您已注册成功。'
+ updated: '帐号资料更新成功。'
+ update_needs_confirmation: '您更改了邮箱地址,我们需要验证您的新邮箱地址,请查看您的邮箱,点击激活链接来验证您的新邮箱地址。'
+ destroyed: '再见!您的帐户已成功注销。我们希望很快可以再见到您。'
+ signed_up_but_unconfirmed: '带有激活链接的信息已经发送到你的邮箱。请打开此链接来激活你的帐号'
+ signed_up_but_inactive: '虽然您已经注册成功,但因为你的帐号还未激活,所以你暂时无法登录'
+ signed_up_but_locked: '虽然您已经注册成功,但因为你的帐号已被锁定,所以你暂时无法登录'
+ unlocks:
+ send_instructions: '稍后你将收到帐号激活的电子邮件'
+ unlocked: '您的帐号已成功解锁,您现在已登录。'
+ send_paranoid_instructions: '如果您的邮箱存在于我们的数据库中,您将收到一封解锁账号的邮件。'
+ omniauth_callbacks:
+ success: '成功地从 %{kind} 获得授权。'
+ failure: '因为 %{reason},所以您无法从 %{kind} 获得授权。'
+ mailer:
+ confirmation_instructions:
+ subject: '激活信息'
+ reset_password_instructions:
+ subject: '重置密码信息'
+ unlock_instructions:
+ subject: '解锁信息'
diff --git a/config/locales/doorkeeper.zh.yml b/config/locales/doorkeeper.zh.yml
new file mode 100644
index 00000000000..dc82b4f00ed
--- /dev/null
+++ b/config/locales/doorkeeper.zh.yml
@@ -0,0 +1,151 @@
+zh:
+ activerecord:
+ attributes:
+ doorkeeper/application:
+ name: '名称'
+ redirect_uri: '登录回调地址'
+ errors:
+ models:
+ doorkeeper/application:
+ attributes:
+ redirect_uri:
+ fragment_present: '不能包含片段(#)'
+ invalid_uri: '必须是有效的 URL 格式'
+ relative_uri: '必须是绝对的 URL 地址'
+ secured_uri: '必须是 HTTPS/SSL 的 URL 地址'
+
+ mongoid:
+ attributes:
+ doorkeeper/application:
+ name: '名称'
+ redirect_uri: '登录回调地址'
+ errors:
+ models:
+ doorkeeper/application:
+ attributes:
+ redirect_uri:
+ fragment_present: '不能包含片段(#)'
+ invalid_uri: '必须是有效的 URL 格式'
+ relative_uri: '必须是绝对的 URL 地址'
+ secured_uri: '必须是 HTTPS/SSL 的 URL 地址'
+
+ mongo_mapper:
+ attributes:
+ doorkeeper/application:
+ name: '名称'
+ redirect_uri: '登录回调地址'
+ errors:
+ models:
+ doorkeeper/application:
+ attributes:
+ redirect_uri:
+ fragment_present: '不能包含片段(#)'
+ invalid_uri: '必须是有效的 URL 格式'
+ relative_uri: '必须是绝对的 URL 地址'
+ secured_uri: '必须是 HTTPS/SSL 的 URL 地址'
+
+ doorkeeper:
+ applications:
+ confirmations:
+ destroy: '确定要删除应用吗?'
+ buttons:
+ edit: '编辑'
+ destroy: '删除'
+ submit: '提交'
+ cancel: '取消'
+ authorize: '授权'
+ form:
+ error: '抱歉! 提交信息的时候遇到了下面的错误'
+ help:
+ redirect_uri: '每行只能有一个 URL'
+ native_redirect_uri: '使用 %{native_redirect_uri} 作为本地测试'
+ edit:
+ title: '修改应用'
+ index:
+ title: '你的应用'
+ new: '创建新应用'
+ name: '名称'
+ callback_url: '登录回调地址'
+ new:
+ title: '创建新应用'
+ show:
+ title: '应用: %{name}'
+ application_id: '应用 ID'
+ secret: '私钥'
+ callback_urls: '登录回调地址'
+ actions: '操作'
+
+ authorizations:
+ buttons:
+ authorize: '授权'
+ deny: '拒绝'
+ error:
+ title: '存在错误'
+ new:
+ title: '需要你授权'
+ prompt: '授权 %{client_name} 使用你的帐号?'
+ able_to: '此应用将会'
+ show:
+ title: '授权码'
+
+ authorized_applications:
+ confirmations:
+ revoke: '确定要注销此应用的认证信息吗?'
+ buttons:
+ revoke: '注销'
+ index:
+ title: '你授权的应用列表'
+ application: '应用'
+ created_at: '授权时间'
+ date_format: '%Y-%m-%d %H:%M:%S'
+
+ errors:
+ messages:
+ # Common error messages
+ invalid_request: '这个请求缺少必要的参数,或者参数值、格式不正确'
+ invalid_redirect_uri: '无效的登录回调地址'
+ unauthorized_client: '未授权的应用,请求无法执行'
+ access_denied: '用户或服务器拒绝了请求'
+ invalid_scope: '请求范围无效、未知或格式不正确'
+ server_error: '服务器异常,无法处理请求'
+ temporarily_unavailable: '服务器维护中,无法处理请求'
+
+ #configuration error messages
+ credential_flow_not_configured: 'Resource Owner Password Credentials flow failed due to Doorkeeper.configure.resource_owner_from_credentials being unconfigured.'
+ resource_owner_authenticator_not_configured: 'Resource Owner find failed due to Doorkeeper.configure.resource_owner_authenticator being unconfiged.'
+
+ # Access grant errors
+ unsupported_response_type: '服务器不支持这种 response type'
+
+ # Access token errors
+ invalid_client: '由于未知、不支持或没有客户端,认证失败'
+ invalid_grant: '授权方式无效,或者登录回调地址无效、过期或已被撤销'
+ unsupported_grant_type: '服务器不支持此类型的授权方式'
+
+ # Password Access token errors
+ invalid_resource_owner: '资源所有者认证无效或没有所有者'
+
+ invalid_token:
+ revoked: "Access Token 已被注销"
+ expired: "Access Token 已过期"
+ unknown: "Access Token 无效"
+
+ flash:
+ applications:
+ create:
+ notice: '应用创建成功'
+ destroy:
+ notice: '应用删除成功'
+ update:
+ notice: '应用修改成功'
+ authorized_applications:
+ destroy:
+ notice: '已成功注销了应用的认证信息'
+
+ layouts:
+ admin:
+ nav:
+ oauth2_provider: 'OAuth2 Provider'
+ applications: '应用'
+ application:
+ title: 'OAuth 认证'
diff --git a/config/locales/kaminari.zh.yml b/config/locales/kaminari.zh.yml
new file mode 100644
index 00000000000..41f371dc931
--- /dev/null
+++ b/config/locales/kaminari.zh.yml
@@ -0,0 +1,17 @@
+zh:
+ views:
+ pagination:
+ first: "第一页"
+ last: "最后一页"
+ previous: "上一页"
+ next: "下一页"
+ truncate: "..."
+ helpers:
+ page_entries_info:
+ one_page:
+ display_entries:
+ zero: "没有任何数据"
+ one: "共 <b>1</b> 条数据"
+ other: "共 <b>%{count}</b> 条数据"
+ more_pages:
+ display_entries: "显示数据 <b>%{first}&nbsp;-&nbsp;%{last}</b> 共 <b>%{total}</b> 条"
diff --git a/config/locales/sherlock.zh.yml b/config/locales/sherlock.zh.yml
new file mode 100644
index 00000000000..62b5c063c68
--- /dev/null
+++ b/config/locales/sherlock.zh.yml
@@ -0,0 +1,37 @@
+zh:
+ sherlock:
+ title: 夏洛克
+ delete_all_transactions: 删除所有事务
+ introduction: >
+ 显示夏洛克记录的所有事务列表。
+ 夏洛克自己的请求被忽略。
+ no_transactions: 没有事务显示
+ no_queries: 没有查询显示
+ no_file_samples: 没有文件样本显示
+ all_transactions: 所有事务
+ transaction: 事务
+ query: 查询
+ file_sample: 文件样本
+ type: 类型
+ path: 路径
+ time: 时间
+ queries: 查询
+ finished_at: 结束时间
+ ago: 之前
+ view: 查看
+ seconds: 秒
+ milliseconds: ms
+ general: 常规
+ id: ID
+ time_inclusive: 时间 (包括所有)
+ backtrace: 回溯
+ application_backtrace: 应用回溯
+ full_backtrace: 全部回溯
+ origin: 来源
+ line: 行
+ line_capitalized: 行
+ copy_to_clipboard: 复制到剪贴板
+ query_plan: 查询计划
+ events: 实践
+ percent: '%'
+ count: 总计
diff --git a/config/locales/zh.yml b/config/locales/zh.yml
new file mode 100644
index 00000000000..8c9614b139a
--- /dev/null
+++ b/config/locales/zh.yml
@@ -0,0 +1,219 @@
+# Sample localization file for English. Add more files in this directory for other locales.
+# See https://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.
+
+zh:
+ hello: "你好世界"
+ errors:
+ messages:
+ wrong_size: "大小错误 (应该是 %{file_size})"
+ size_too_small: "太小 (应该至少 %{file_size})"
+ size_too_big: "太大 (应该不超过 %{file_size})"
+ date:
+ abbr_day_names:
+ - 日
+ - 一
+ - 二
+ - 三
+ - 四
+ - 五
+ - 六
+ abbr_month_names:
+ -
+ - 1月
+ - 2月
+ - 3月
+ - 4月
+ - 5月
+ - 6月
+ - 7月
+ - 8月
+ - 9月
+ - 10月
+ - 11月
+ - 12月
+ day_names:
+ - 星期日
+ - 星期一
+ - 星期二
+ - 星期三
+ - 星期四
+ - 星期五
+ - 星期六
+ formats:
+ default: ! '%Y-%m-%d'
+ long: ! '%Y年%b%d日'
+ short: ! '%b%d日'
+ month_names:
+ -
+ - 一月
+ - 二月
+ - 三月
+ - 四月
+ - 五月
+ - 六月
+ - 七月
+ - 八月
+ - 九月
+ - 十月
+ - 十一月
+ - 十二月
+ order:
+ - :year
+ - :month
+ - :day
+ datetime:
+ distance_in_words:
+ about_x_hours:
+ one: 大约一小时
+ other: 大约 %{count} 小时
+ about_x_months:
+ one: 大约一个月
+ other: 大约 %{count} 个月
+ about_x_years:
+ one: 大约一年
+ other: 大约 %{count} 年
+ almost_x_years:
+ one: 接近一年
+ other: 接近 %{count} 年
+ half_a_minute: 半分钟
+ less_than_x_minutes:
+ one: 不到一分钟
+ other: 不到 %{count} 分钟
+ less_than_x_seconds:
+ one: 不到一秒
+ other: 不到 %{count} 秒
+ over_x_years:
+ one: 一年多
+ other: ! ' %{count} 年多'
+ x_days:
+ one: 一天
+ other: ! ' %{count} 天'
+ x_minutes:
+ one: 一分钟
+ other: ! ' %{count} 分钟'
+ x_months:
+ one: 一个月
+ other: ! ' %{count} 个月'
+ x_seconds:
+ one: 一秒
+ other: ! ' %{count} 秒'
+ prompts:
+ day: 日
+ hour: 时
+ minute: 分
+ month: 月
+ second: 秒
+ year: 年
+ errors: &errors
+ format: ! '%{attribute}%{message}'
+ messages:
+ accepted: 必须是可被接受的
+ blank: 不能为空字符
+ present: 必须是空白
+ confirmation: 与确认值不匹配
+ empty: 不能留空
+ equal_to: 必须等于 %{count}
+ even: 必须为双数
+ exclusion: 是保留关键字
+ greater_than: 必须大于 %{count}
+ greater_than_or_equal_to: 必须大于或等于 %{count}
+ inclusion: 不包含于列表中
+ invalid: 是无效的
+ less_than: 必须小于 %{count}
+ less_than_or_equal_to: 必须小于或等于 %{count}
+ not_a_number: 不是数字
+ not_an_integer: 必须是整数
+ odd: 必须为单数
+ record_invalid: ! '验证失败: %{errors}'
+ restrict_dependent_destroy:
+ one: 由於 %{record} 需要此记录,所以无法移除记录
+ many: 由於 %{record} 需要此记录,所以无法移除记录
+ taken: 已经被使用
+ too_long:
+ one: 过长(最长为一个字符)
+ other: 过长(最长为 %{count} 个字符)
+ too_short:
+ one: 过短(最短为一个字符)
+ other: 过短(最短为 %{count} 个字符)
+ wrong_length:
+ one: 长度非法(必须为一个字符)
+ other: 长度非法(必须为 %{count} 个字符)
+ other_than: 长度非法(不可为 %{count} 个字符
+ template:
+ body: 如下字段出现错误:
+ header:
+ one: 有 1 个错误发生导致「%{model}」无法被保存。
+ other: 有 %{count} 个错误发生导致「%{model}」无法被保存。
+ helpers:
+ select:
+ prompt: 请选择
+ submit:
+ create: 新增%{model}
+ submit: 储存%{model}
+ update: 更新%{model}
+ number:
+ currency:
+ format:
+ delimiter: ! ','
+ format: ! '%u %n'
+ precision: 2
+ separator: .
+ significant: false
+ strip_insignificant_zeros: false
+ unit: CN¥
+ format:
+ delimiter: ! ','
+ precision: 3
+ separator: .
+ significant: false
+ strip_insignificant_zeros: false
+ human:
+ decimal_units:
+ format: ! '%n %u'
+ units:
+ billion: 十亿
+ million: 百万
+ quadrillion: 千兆
+ thousand: 千
+ trillion: 兆
+ unit: ''
+ format:
+ delimiter: ''
+ precision: 1
+ significant: false
+ strip_insignificant_zeros: false
+ storage_units:
+ format: ! '%n %u'
+ units:
+ byte:
+ one: Byte
+ other: Bytes
+ gb: GB
+ kb: KB
+ mb: MB
+ tb: TB
+ percentage:
+ format:
+ delimiter: ''
+ precision:
+ format:
+ delimiter: ''
+ support:
+ array:
+ last_word_connector: ! ', 和 '
+ two_words_connector: ! ' 和 '
+ words_connector: ! ', '
+ time:
+ am: 上午
+ formats:
+ default: ! '%Y年%b%d日 %A %H:%M:%S %Z'
+ long: ! '%Y年%b%d日 %H:%M'
+ short: ! '%b%d日 %H:%M'
+ pm: 下午
+ # remove these aliases after 'activemodel' and 'activerecord' namespaces are removed from Rails repository
+ activemodel:
+ errors:
+ <<: *errors
+ activerecord:
+ errors:
+ <<: *errors
diff --git a/lib/gitlab/access.rb b/lib/gitlab/access.rb
index 6d0e30e916f..278460fb109 100644
--- a/lib/gitlab/access.rb
+++ b/lib/gitlab/access.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
# Gitlab::Access module
#
# Define allowed roles that can be used
@@ -27,16 +28,16 @@ module Gitlab
def options
{
- "Guest" => GUEST,
- "Reporter" => REPORTER,
- "Developer" => DEVELOPER,
- "Master" => MASTER,
+ "访客" => GUEST,
+ "报告者" => REPORTER,
+ "开发人员" => DEVELOPER,
+ "主程序员" => MASTER,
}
end
def options_with_owner
options.merge(
- "Owner" => OWNER
+ "所有者" => OWNER
)
end
@@ -51,9 +52,9 @@ module Gitlab
def protection_options
{
- "Not protected: Both developers and masters can push new commits, force push, or delete the branch." => PROTECTION_NONE,
- "Partially protected: Developers can push new commits, but cannot force push or delete the branch. Masters can do all of those." => PROTECTION_DEV_CAN_PUSH,
- "Fully protected: Developers cannot push new commits, force push, or delete the branch. Only masters can do any of those." => PROTECTION_FULL,
+ "不保护:开发人员和主程序员都可以推送新提交、强制推送和删除分支。" => PROTECTION_NONE,
+ "部分保护:开发人员可以推送新提交,但不能强制推送和删除分支。主程序员可以做上述操作。" => PROTECTION_DEV_CAN_PUSH,
+ "完全保护:开发人员不能推送新提交、强制推送和删除分支。只有主程序员可以做上述操作。" => PROTECTION_FULL,
}
end
diff --git a/lib/gitlab/themes.rb b/lib/gitlab/themes.rb
index 83f91de810c..2273f0dee82 100644
--- a/lib/gitlab/themes.rb
+++ b/lib/gitlab/themes.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
module Gitlab
# Module containing GitLab's application theme definitions and helper methods
# for accessing them.
@@ -10,12 +11,12 @@ module Gitlab
# All available Themes
THEMES = [
- Theme.new(1, 'Graphite', 'ui_graphite'),
- Theme.new(2, 'Charcoal', 'ui_charcoal'),
- Theme.new(3, 'Green', 'ui_green'),
- Theme.new(4, 'Gray', 'ui_gray'),
- Theme.new(5, 'Violet', 'ui_violet'),
- Theme.new(6, 'Blue', 'ui_blue')
+ Theme.new(1, '石墨色', 'ui_graphite'),
+ Theme.new(2, '炭黑色', 'ui_charcoal'),
+ Theme.new(3, '绿色', 'ui_green'),
+ Theme.new(4, '灰色', 'ui_gray'),
+ Theme.new(5, '紫色', 'ui_violet'),
+ Theme.new(6, '蓝色', 'ui_blue')
].freeze
# Convenience method to get a space-separated String of all the theme
diff --git a/lib/gitlab/visibility_level.rb b/lib/gitlab/visibility_level.rb
index a1ee1cba216..b0d5b3404c2 100644
--- a/lib/gitlab/visibility_level.rb
+++ b/lib/gitlab/visibility_level.rb
@@ -1,3 +1,4 @@
+#encoding: utf-8
# Gitlab::VisibilityLevel module
#
# Define allowed public modes that can be used for
@@ -26,9 +27,9 @@ module Gitlab
def options
{
- 'Private' => PRIVATE,
- 'Internal' => INTERNAL,
- 'Public' => PUBLIC
+ '私有' => PRIVATE,
+ '内部' => INTERNAL,
+ '公开' => PUBLIC
}
end
diff --git a/public/ci/build-canceled.svg b/public/ci/build-canceled.svg
index 922e28bf696..b3116d563fd 100644
--- a/public/ci/build-canceled.svg
+++ b/public/ci/build-canceled.svg
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="97" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="97" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#9f9f9f" d="M37 0h60v20H37z"/><path fill="url(#b)" d="M0 0h97v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">build</text><text x="18.5" y="14">build</text><text x="66" y="15" fill="#010101" fill-opacity=".3">canceled</text><text x="66" y="14">canceled</text></g></svg> \ No newline at end of file
+<svg xmlns="http://www.w3.org/2000/svg" width="97" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="97" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#9f9f9f" d="M37 0h60v20H37z"/><path fill="url(#b)" d="M0 0h97v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">构建</text><text x="18.5" y="14">构建</text><text x="66" y="15" fill="#010101" fill-opacity=".3">取消</text><text x="66" y="14">取消</text></g></svg> \ No newline at end of file
diff --git a/public/ci/build-failed.svg b/public/ci/build-failed.svg
index 1aefd3f1761..8dcc5fcb5e0 100644
--- a/public/ci/build-failed.svg
+++ b/public/ci/build-failed.svg
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="78" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="78" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#e05d44" d="M37 0h41v20H37z"/><path fill="url(#b)" d="M0 0h78v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">build</text><text x="18.5" y="14">build</text><text x="56.5" y="15" fill="#010101" fill-opacity=".3">failed</text><text x="56.5" y="14">failed</text></g></svg> \ No newline at end of file
+<svg xmlns="http://www.w3.org/2000/svg" width="78" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="78" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#e05d44" d="M37 0h41v20H37z"/><path fill="url(#b)" d="M0 0h78v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">构建</text><text x="18.5" y="14">构建</text><text x="56.5" y="15" fill="#010101" fill-opacity=".3">失败</text><text x="56.5" y="14">失败</text></g></svg> \ No newline at end of file
diff --git a/public/ci/build-pending.svg b/public/ci/build-pending.svg
index 536931af84d..50c9896b130 100644
--- a/public/ci/build-pending.svg
+++ b/public/ci/build-pending.svg
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="92" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="92" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#dfb317" d="M37 0h55v20H37z"/><path fill="url(#b)" d="M0 0h92v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">build</text><text x="18.5" y="14">build</text><text x="63.5" y="15" fill="#010101" fill-opacity=".3">pending</text><text x="63.5" y="14">pending</text></g></svg> \ No newline at end of file
+<svg xmlns="http://www.w3.org/2000/svg" width="92" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="92" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#dfb317" d="M37 0h55v20H37z"/><path fill="url(#b)" d="M0 0h92v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">构建</text><text x="18.5" y="14">构建</text><text x="63.5" y="15" fill="#010101" fill-opacity=".3">等待</text><text x="63.5" y="14">等待</text></g></svg> \ No newline at end of file
diff --git a/public/ci/build-running.svg b/public/ci/build-running.svg
index 0d71eef3c34..10154ec0fd5 100644
--- a/public/ci/build-running.svg
+++ b/public/ci/build-running.svg
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="90" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="90" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#dfb317" d="M37 0h53v20H37z"/><path fill="url(#b)" d="M0 0h90v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">build</text><text x="18.5" y="14">build</text><text x="62.5" y="15" fill="#010101" fill-opacity=".3">running</text><text x="62.5" y="14">running</text></g></svg> \ No newline at end of file
+<svg xmlns="http://www.w3.org/2000/svg" width="90" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="90" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#dfb317" d="M37 0h53v20H37z"/><path fill="url(#b)" d="M0 0h90v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">构建</text><text x="18.5" y="14">构建</text><text x="62.5" y="15" fill="#010101" fill-opacity=".3">运行</text><text x="62.5" y="14">运行</text></g></svg> \ No newline at end of file
diff --git a/public/ci/build-skipped.svg b/public/ci/build-skipped.svg
index f15507188e0..33794d38c5b 100644
--- a/public/ci/build-skipped.svg
+++ b/public/ci/build-skipped.svg
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="97" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="97" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#9f9f9f" d="M37 0h60v20H37z"/><path fill="url(#b)" d="M0 0h97v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">build</text><text x="18.5" y="14">build</text><text x="66" y="15" fill="#010101" fill-opacity=".3">skipped</text><text x="66" y="14">skipped</text></g></svg> \ No newline at end of file
+<svg xmlns="http://www.w3.org/2000/svg" width="97" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="97" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#9f9f9f" d="M37 0h60v20H37z"/><path fill="url(#b)" d="M0 0h97v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">构建</text><text x="18.5" y="14">构建</text><text x="66" y="15" fill="#010101" fill-opacity=".3">跳过</text><text x="66" y="14">跳过</text></g></svg> \ No newline at end of file
diff --git a/public/ci/build-success.svg b/public/ci/build-success.svg
index 43b67e45f42..80938046f0e 100644
--- a/public/ci/build-success.svg
+++ b/public/ci/build-success.svg
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="91" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="91" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#4c1" d="M37 0h54v20H37z"/><path fill="url(#b)" d="M0 0h91v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">build</text><text x="18.5" y="14">build</text><text x="63" y="15" fill="#010101" fill-opacity=".3">success</text><text x="63" y="14">success</text></g></svg> \ No newline at end of file
+<svg xmlns="http://www.w3.org/2000/svg" width="91" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="91" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#4c1" d="M37 0h54v20H37z"/><path fill="url(#b)" d="M0 0h91v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">构建</text><text x="18.5" y="14">构建</text><text x="63" y="15" fill="#010101" fill-opacity=".3">成功</text><text x="63" y="14">成功</text></g></svg> \ No newline at end of file
diff --git a/public/ci/build-unknown.svg b/public/ci/build-unknown.svg
index c72a2f5a7f5..97b98c0a347 100644
--- a/public/ci/build-unknown.svg
+++ b/public/ci/build-unknown.svg
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="98" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="98" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#9f9f9f" d="M37 0h61v20H37z"/><path fill="url(#b)" d="M0 0h98v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">build</text><text x="18.5" y="14">build</text><text x="66.5" y="15" fill="#010101" fill-opacity=".3">unknown</text><text x="66.5" y="14">unknown</text></g></svg> \ No newline at end of file
+<svg xmlns="http://www.w3.org/2000/svg" width="98" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="98" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h37v20H0z"/><path fill="#9f9f9f" d="M37 0h61v20H37z"/><path fill="url(#b)" d="M0 0h98v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11"><text x="18.5" y="15" fill="#010101" fill-opacity=".3">构建</text><text x="18.5" y="14">构建</text><text x="66.5" y="15" fill="#010101" fill-opacity=".3">未知</text><text x="66.5" y="14">未知</text></g></svg> \ No newline at end of file