summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAsh McKenzie <amckenzie@gitlab.com>2019-08-05 17:34:26 +1000
committerAsh McKenzie <amckenzie@gitlab.com>2019-08-05 17:34:26 +1000
commitafbcf479c263dd5a2b52f6f48fb8ce540e5250fc (patch)
tree0a07576a491e07c0c159e1f603b656a60871a6bb
parent15c2e501eab61f4827b463764fa4d40341131af0 (diff)
downloadgitlab-ce-ashmckenzie/rename-profile-to-settings.tar.gz
-rw-r--r--app/controllers/application_controller.rb4
-rw-r--r--app/controllers/concerns/enforces_two_factor_authentication.rb2
-rw-r--r--app/controllers/jwt_controller.rb2
-rw-r--r--app/controllers/oauth/applications_controller.rb2
-rw-r--r--app/controllers/omniauth_callbacks_controller.rb4
-rw-r--r--app/controllers/profiles/application_controller.rb5
-rw-r--r--app/controllers/profiles/u2f_registrations_controller.rb9
-rw-r--r--app/controllers/projects/git_http_client_controller.rb2
-rw-r--r--app/controllers/registrations_controller.rb2
-rw-r--r--app/controllers/settings/accounts_controller.rb (renamed from app/controllers/profiles/accounts_controller.rb)4
-rw-r--r--app/controllers/settings/active_sessions_controller.rb (renamed from app/controllers/profiles/active_sessions_controller.rb)2
-rw-r--r--app/controllers/settings/application_controller.rb5
-rw-r--r--app/controllers/settings/avatars_controller.rb (renamed from app/controllers/profiles/avatars_controller.rb)4
-rw-r--r--app/controllers/settings/chat_names_controller.rb (renamed from app/controllers/profiles/chat_names_controller.rb)8
-rw-r--r--app/controllers/settings/emails_controller.rb (renamed from app/controllers/profiles/emails_controller.rb)8
-rw-r--r--app/controllers/settings/gpg_keys_controller.rb (renamed from app/controllers/profiles/gpg_keys_controller.rb)8
-rw-r--r--app/controllers/settings/groups_controller.rb (renamed from app/controllers/profiles/groups_controller.rb)4
-rw-r--r--app/controllers/settings/keys_controller.rb (renamed from app/controllers/profiles/keys_controller.rb)6
-rw-r--r--app/controllers/settings/notifications_controller.rb (renamed from app/controllers/profiles/notifications_controller.rb)4
-rw-r--r--app/controllers/settings/passwords_controller.rb (renamed from app/controllers/profiles/passwords_controller.rb)8
-rw-r--r--app/controllers/settings/personal_access_tokens_controller.rb (renamed from app/controllers/profiles/personal_access_tokens_controller.rb)6
-rw-r--r--app/controllers/settings/preferences_controller.rb (renamed from app/controllers/profiles/preferences_controller.rb)4
-rw-r--r--app/controllers/settings/two_factor_auths_controller.rb (renamed from app/controllers/profiles/two_factor_auths_controller.rb)8
-rw-r--r--app/controllers/settings/u2f_registrations_controller.rb9
-rw-r--r--app/controllers/settings_controller.rb (renamed from app/controllers/profiles_controller.rb)6
-rw-r--r--app/helpers/application_helper.rb2
-rw-r--r--app/helpers/projects_helper.rb4
-rw-r--r--app/helpers/search_helper.rb4
-rw-r--r--app/helpers/settings_helper.rb (renamed from app/helpers/profiles_helper.rb)2
-rw-r--r--app/services/chat_names/authorize_user_service.rb2
-rw-r--r--app/views/admin/requests_profiles/index.html.haml2
-rw-r--r--app/views/devise/mailer/_confirmation_instructions_secondary.html.haml2
-rw-r--r--app/views/devise/mailer/_confirmation_instructions_secondary.text.erb2
-rw-r--r--app/views/layouts/_mailer.html.haml2
-rw-r--r--app/views/layouts/header/_current_user_dropdown.html.haml2
-rw-r--r--app/views/layouts/nav/sidebar/_profile.html.haml54
-rw-r--r--app/views/layouts/profile.html.haml2
-rw-r--r--app/views/notify/new_gpg_key_email.html.haml2
-rw-r--r--app/views/notify/new_gpg_key_email.text.erb2
-rw-r--r--app/views/notify/new_ssh_key_email.html.haml2
-rw-r--r--app/views/notify/new_ssh_key_email.text.erb2
-rw-r--r--app/views/settings/_email_settings.html.haml (renamed from app/views/profiles/_email_settings.html.haml)0
-rw-r--r--app/views/settings/_event_table.html.haml (renamed from app/views/profiles/_event_table.html.haml)0
-rw-r--r--app/views/settings/accounts/_providers.html.haml (renamed from app/views/profiles/accounts/_providers.html.haml)2
-rw-r--r--app/views/settings/accounts/show.html.haml (renamed from app/views/profiles/accounts/show.html.haml)6
-rw-r--r--app/views/settings/active_sessions/_active_session.html.haml (renamed from app/views/profiles/active_sessions/_active_session.html.haml)0
-rw-r--r--app/views/settings/active_sessions/index.html.haml (renamed from app/views/profiles/active_sessions/index.html.haml)0
-rw-r--r--app/views/settings/audit_log.html.haml (renamed from app/views/profiles/audit_log.html.haml)0
-rw-r--r--app/views/settings/chat_names/_chat_name.html.haml (renamed from app/views/profiles/chat_names/_chat_name.html.haml)2
-rw-r--r--app/views/settings/chat_names/index.html.haml (renamed from app/views/profiles/chat_names/index.html.haml)0
-rw-r--r--app/views/settings/chat_names/new.html.haml (renamed from app/views/profiles/chat_names/new.html.haml)4
-rw-r--r--app/views/settings/emails/index.html.haml (renamed from app/views/profiles/emails/index.html.haml)8
-rw-r--r--app/views/settings/gpg_keys/_form.html.haml (renamed from app/views/profiles/gpg_keys/_form.html.haml)0
-rw-r--r--app/views/settings/gpg_keys/_key.html.haml (renamed from app/views/profiles/gpg_keys/_key.html.haml)4
-rw-r--r--app/views/settings/gpg_keys/_key_table.html.haml (renamed from app/views/profiles/gpg_keys/_key_table.html.haml)0
-rw-r--r--app/views/settings/gpg_keys/index.html.haml (renamed from app/views/profiles/gpg_keys/index.html.haml)0
-rw-r--r--app/views/settings/keys/_form.html.haml (renamed from app/views/profiles/keys/_form.html.haml)0
-rw-r--r--app/views/settings/keys/_key.html.haml (renamed from app/views/profiles/keys/_key.html.haml)0
-rw-r--r--app/views/settings/keys/_key_details.html.haml (renamed from app/views/profiles/keys/_key_details.html.haml)0
-rw-r--r--app/views/settings/keys/_key_table.html.haml (renamed from app/views/profiles/keys/_key_table.html.haml)0
-rw-r--r--app/views/settings/keys/index.html.haml (renamed from app/views/profiles/keys/index.html.haml)0
-rw-r--r--app/views/settings/keys/show.html.haml (renamed from app/views/profiles/keys/show.html.haml)2
-rw-r--r--app/views/settings/notifications/_email_settings.html.haml (renamed from app/views/profiles/notifications/_email_settings.html.haml)0
-rw-r--r--app/views/settings/notifications/_group_settings.html.haml (renamed from app/views/profiles/notifications/_group_settings.html.haml)2
-rw-r--r--app/views/settings/notifications/_project_settings.html.haml (renamed from app/views/profiles/notifications/_project_settings.html.haml)0
-rw-r--r--app/views/settings/notifications/show.html.haml (renamed from app/views/profiles/notifications/show.html.haml)4
-rw-r--r--app/views/settings/passwords/edit.html.haml (renamed from app/views/profiles/passwords/edit.html.haml)4
-rw-r--r--app/views/settings/passwords/new.html.haml (renamed from app/views/profiles/passwords/new.html.haml)2
-rw-r--r--app/views/settings/personal_access_tokens/index.html.haml (renamed from app/views/profiles/personal_access_tokens/index.html.haml)2
-rw-r--r--app/views/settings/preferences/show.html.haml (renamed from app/views/profiles/preferences/show.html.haml)2
-rw-r--r--app/views/settings/preferences/update.js.erb (renamed from app/views/profiles/preferences/update.js.erb)0
-rw-r--r--app/views/settings/show.html.haml (renamed from app/views/profiles/show.html.haml)4
-rw-r--r--app/views/settings/two_factor_auths/_codes.html.haml (renamed from app/views/profiles/two_factor_auths/_codes.html.haml)2
-rw-r--r--app/views/settings/two_factor_auths/codes.html.haml (renamed from app/views/profiles/two_factor_auths/codes.html.haml)0
-rw-r--r--app/views/settings/two_factor_auths/create.html.haml (renamed from app/views/profiles/two_factor_auths/create.html.haml)0
-rw-r--r--app/views/settings/two_factor_auths/show.html.haml (renamed from app/views/profiles/two_factor_auths/show.html.haml)12
-rw-r--r--app/views/shared/_no_password.html.haml2
-rw-r--r--app/views/shared/_no_ssh.html.haml4
-rw-r--r--app/views/shared/_personal_access_tokens_table.html.haml2
-rw-r--r--app/views/shared/_project_limit.html.haml2
-rw-r--r--app/views/u2f/_register.html.haml2
-rw-r--r--app/views/users/show.html.haml2
-rw-r--r--config/routes.rb2
-rw-r--r--config/routes/settings.rb (renamed from config/routes/profile.rb)6
-rw-r--r--db/schema.rb111
-rw-r--r--locale/gitlab.pot2
-rw-r--r--qa/qa/page/profile/menu.rb2
-rw-r--r--qa/qa/runtime/browser.rb2
88 files changed, 216 insertions, 199 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb
index 1d55a073f3b..70d5c274526 100644
--- a/app/controllers/application_controller.rb
+++ b/app/controllers/application_controller.rb
@@ -284,7 +284,7 @@ class ApplicationController < ActionController::Base
password_expires_at = current_user&.password_expires_at
if password_expires_at && password_expires_at < Time.now
- return redirect_to new_profile_password_path
+ return redirect_to new_settings_password_path
end
end
@@ -341,7 +341,7 @@ class ApplicationController < ActionController::Base
def require_email
if current_user && current_user.temp_oauth_email? && session[:impersonator_id].nil?
- return redirect_to profile_path, notice: _('Please complete your profile with email address')
+ return redirect_to settings_path, notice: _('Please complete your profile with email address')
end
end
diff --git a/app/controllers/concerns/enforces_two_factor_authentication.rb b/app/controllers/concerns/enforces_two_factor_authentication.rb
index 825181568ad..123068bc6e0 100644
--- a/app/controllers/concerns/enforces_two_factor_authentication.rb
+++ b/app/controllers/concerns/enforces_two_factor_authentication.rb
@@ -17,7 +17,7 @@ module EnforcesTwoFactorAuthentication
def check_two_factor_requirement
if two_factor_authentication_required? && current_user && !current_user.temp_oauth_email? && !current_user.two_factor_enabled? && !skip_two_factor?
- redirect_to profile_two_factor_auth_path
+ redirect_to settings_two_factor_auth_path
end
end
diff --git a/app/controllers/jwt_controller.rb b/app/controllers/jwt_controller.rb
index 5ecf4f114cf..85811206346 100644
--- a/app/controllers/jwt_controller.rb
+++ b/app/controllers/jwt_controller.rb
@@ -41,7 +41,7 @@ class JwtController < ApplicationController
{ code: 'UNAUTHORIZED',
message: _('HTTP Basic: Access denied\n' \
'You must use a personal access token with \'api\' scope for Git over HTTP.\n' \
- 'You can generate one at %{profile_personal_access_tokens_url}') % { profile_personal_access_tokens_url: profile_personal_access_tokens_url } }
+ 'You can generate one at %{settings_personal_access_tokens_url}') % { profile_personal_access_tokens_url: profile_personal_access_tokens_url } }
]
}, status: :unauthorized
end
diff --git a/app/controllers/oauth/applications_controller.rb b/app/controllers/oauth/applications_controller.rb
index ab4ca56bb49..c1ab18d2d98 100644
--- a/app/controllers/oauth/applications_controller.rb
+++ b/app/controllers/oauth/applications_controller.rb
@@ -37,7 +37,7 @@ class Oauth::ApplicationsController < Doorkeeper::ApplicationsController
def verify_user_oauth_applications_enabled
return if Gitlab::CurrentSettings.user_oauth_applications?
- redirect_to profile_path
+ redirect_to settings_path
end
def set_index_vars
diff --git a/app/controllers/omniauth_callbacks_controller.rb b/app/controllers/omniauth_callbacks_controller.rb
index b1efa767154..cd4435761d7 100644
--- a/app/controllers/omniauth_callbacks_controller.rb
+++ b/app/controllers/omniauth_callbacks_controller.rb
@@ -110,11 +110,11 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
end
def redirect_identity_link_failed(error_message)
- redirect_to profile_account_path, notice: _("Authentication failed: %{error_message}") % { error_message: error_message }
+ redirect_to settings_account_path, notice: _("Authentication failed: %{error_message}") % { error_message: error_message }
end
def redirect_identity_linked
- redirect_to profile_account_path, notice: _('Authentication method updated')
+ redirect_to settings_account_path, notice: _('Authentication method updated')
end
def handle_service_ticket(provider, ticket)
diff --git a/app/controllers/profiles/application_controller.rb b/app/controllers/profiles/application_controller.rb
deleted file mode 100644
index 52b046ef64f..00000000000
--- a/app/controllers/profiles/application_controller.rb
+++ /dev/null
@@ -1,5 +0,0 @@
-# frozen_string_literal: true
-
-class Profiles::ApplicationController < ApplicationController
- layout 'profile'
-end
diff --git a/app/controllers/profiles/u2f_registrations_controller.rb b/app/controllers/profiles/u2f_registrations_controller.rb
deleted file mode 100644
index 866c4dee6e2..00000000000
--- a/app/controllers/profiles/u2f_registrations_controller.rb
+++ /dev/null
@@ -1,9 +0,0 @@
-# frozen_string_literal: true
-
-class Profiles::U2fRegistrationsController < Profiles::ApplicationController
- def destroy
- u2f_registration = current_user.u2f_registrations.find(params[:id])
- u2f_registration.destroy
- redirect_to profile_two_factor_auth_path, status: 302, notice: _("Successfully deleted U2F device.")
- end
-end
diff --git a/app/controllers/projects/git_http_client_controller.rb b/app/controllers/projects/git_http_client_controller.rb
index 956093b972b..494111de3c0 100644
--- a/app/controllers/projects/git_http_client_controller.rb
+++ b/app/controllers/projects/git_http_client_controller.rb
@@ -85,7 +85,7 @@ class Projects::GitHttpClientController < Projects::ApplicationController
def render_missing_personal_access_token
render plain: "HTTP Basic: Access denied\n" \
"You must use a personal access token with 'read_repository' or 'write_repository' scope for Git over HTTP.\n" \
- "You can generate one at #{profile_personal_access_tokens_url}",
+ "You can generate one at #{settings_personal_access_tokens_url}",
status: :unauthorized
end
diff --git a/app/controllers/registrations_controller.rb b/app/controllers/registrations_controller.rb
index 638934694e0..b5e8be2ea49 100644
--- a/app/controllers/registrations_controller.rb
+++ b/app/controllers/registrations_controller.rb
@@ -30,7 +30,7 @@ class RegistrationsController < Devise::RegistrationsController
session.try(:destroy)
redirect_to new_user_session_path, status: 303, notice: s_('Profiles|Account scheduled for removal.')
else
- redirect_to profile_account_path, status: 303, alert: destroy_confirmation_failure_message
+ redirect_to settings_account_path, status: 303, alert: destroy_confirmation_failure_message
end
end
diff --git a/app/controllers/profiles/accounts_controller.rb b/app/controllers/settings/accounts_controller.rb
index b03f4b7435f..a3aa9857444 100644
--- a/app/controllers/profiles/accounts_controller.rb
+++ b/app/controllers/settings/accounts_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::AccountsController < Profiles::ApplicationController
+class Settings::AccountsController < Settings::ApplicationController
include AuthHelper
def show
@@ -20,7 +20,7 @@ class Profiles::AccountsController < Profiles::ApplicationController
flash[:alert] = _("You are not allowed to unlink your primary login account")
end
- redirect_to profile_account_path
+ redirect_to settings_account_path
end
# rubocop: enable CodeReuse/ActiveRecord
diff --git a/app/controllers/profiles/active_sessions_controller.rb b/app/controllers/settings/active_sessions_controller.rb
index c473023cacb..a6de8834ea2 100644
--- a/app/controllers/profiles/active_sessions_controller.rb
+++ b/app/controllers/settings/active_sessions_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::ActiveSessionsController < Profiles::ApplicationController
+class Settings::ActiveSessionsController < Settings::ApplicationController
def index
@sessions = ActiveSession.list(current_user).reject(&:is_impersonated)
end
diff --git a/app/controllers/settings/application_controller.rb b/app/controllers/settings/application_controller.rb
new file mode 100644
index 00000000000..ae68d2e152e
--- /dev/null
+++ b/app/controllers/settings/application_controller.rb
@@ -0,0 +1,5 @@
+# frozen_string_literal: true
+
+class Settings::ApplicationController < ApplicationController
+ layout 'profile'
+end
diff --git a/app/controllers/profiles/avatars_controller.rb b/app/controllers/settings/avatars_controller.rb
index 3378a09628c..47e6be88854 100644
--- a/app/controllers/profiles/avatars_controller.rb
+++ b/app/controllers/settings/avatars_controller.rb
@@ -1,11 +1,11 @@
# frozen_string_literal: true
-class Profiles::AvatarsController < Profiles::ApplicationController
+class Settings::AvatarsController < Settings::ApplicationController
def destroy
@user = current_user
Users::UpdateService.new(current_user, user: @user).execute { |user| user.remove_avatar! }
- redirect_to profile_path, status: :found
+ redirect_to settings_path, status: :found
end
end
diff --git a/app/controllers/profiles/chat_names_controller.rb b/app/controllers/settings/chat_names_controller.rb
index 80b8279e91e..88d159f8dd9 100644
--- a/app/controllers/profiles/chat_names_controller.rb
+++ b/app/controllers/settings/chat_names_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::ChatNamesController < Profiles::ApplicationController
+class Settings::ChatNamesController < Settings::ApplicationController
before_action :chat_name_token, only: [:new]
before_action :chat_name_params, only: [:new, :create, :deny]
@@ -21,7 +21,7 @@ class Profiles::ChatNamesController < Profiles::ApplicationController
end
delete_chat_name_token
- redirect_to profile_chat_names_path
+ redirect_to settings_chat_names_path
end
def deny
@@ -29,7 +29,7 @@ class Profiles::ChatNamesController < Profiles::ApplicationController
flash[:notice] = _("Denied authorization of chat nickname %{user_name}.") % { user_name: chat_name_params[:user_name] }
- redirect_to profile_chat_names_path
+ redirect_to settings_chat_names_path
end
def destroy
@@ -41,7 +41,7 @@ class Profiles::ChatNamesController < Profiles::ApplicationController
flash[:alert] = _("Could not delete chat nickname %{chat_name}.") % { chat_name: @chat_name.chat_name }
end
- redirect_to profile_chat_names_path, status: :found
+ redirect_to settings_chat_names_path, status: :found
end
private
diff --git a/app/controllers/profiles/emails_controller.rb b/app/controllers/settings/emails_controller.rb
index f666a1150a6..37c9780c3a6 100644
--- a/app/controllers/profiles/emails_controller.rb
+++ b/app/controllers/settings/emails_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::EmailsController < Profiles::ApplicationController
+class Settings::EmailsController < Settings::ApplicationController
before_action :find_email, only: [:destroy, :resend_confirmation_instructions]
def index
@@ -14,14 +14,14 @@ class Profiles::EmailsController < Profiles::ApplicationController
flash[:alert] = @email.errors.full_messages.first
end
- redirect_to profile_emails_url
+ redirect_to settings_emails_url
end
def destroy
Emails::DestroyService.new(current_user, user: current_user).execute(@email)
respond_to do |format|
- format.html { redirect_to profile_emails_url, status: :found }
+ format.html { redirect_to settings_emails_url, status: :found }
format.js { head :ok }
end
end
@@ -33,7 +33,7 @@ class Profiles::EmailsController < Profiles::ApplicationController
flash[:alert] = _("There was a problem sending the confirmation email")
end
- redirect_to profile_emails_url
+ redirect_to settings_emails_url
end
private
diff --git a/app/controllers/profiles/gpg_keys_controller.rb b/app/controllers/settings/gpg_keys_controller.rb
index 8c34a66c374..cc40aff4108 100644
--- a/app/controllers/profiles/gpg_keys_controller.rb
+++ b/app/controllers/settings/gpg_keys_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::GpgKeysController < Profiles::ApplicationController
+class Settings::GpgKeysController < Settings::ApplicationController
before_action :set_gpg_key, only: [:destroy, :revoke]
def index
@@ -12,7 +12,7 @@ class Profiles::GpgKeysController < Profiles::ApplicationController
@gpg_key = GpgKeys::CreateService.new(current_user, gpg_key_params).execute
if @gpg_key.persisted?
- redirect_to profile_gpg_keys_path
+ redirect_to settings_gpg_keys_path
else
@gpg_keys = current_user.gpg_keys.select(&:persisted?)
render :index
@@ -23,7 +23,7 @@ class Profiles::GpgKeysController < Profiles::ApplicationController
@gpg_key.destroy
respond_to do |format|
- format.html { redirect_to profile_gpg_keys_url, status: :found }
+ format.html { redirect_to settings_gpg_keys_url, status: :found }
format.js { head :ok }
end
end
@@ -32,7 +32,7 @@ class Profiles::GpgKeysController < Profiles::ApplicationController
@gpg_key.revoke
respond_to do |format|
- format.html { redirect_to profile_gpg_keys_url, status: :found }
+ format.html { redirect_to settings_gpg_keys_url, status: :found }
format.js { head :ok }
end
end
diff --git a/app/controllers/profiles/groups_controller.rb b/app/controllers/settings/groups_controller.rb
index c755bcb718a..b16d1f8bf4b 100644
--- a/app/controllers/profiles/groups_controller.rb
+++ b/app/controllers/settings/groups_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::GroupsController < Profiles::ApplicationController
+class Settings::GroupsController < Settings::ApplicationController
include RoutableActions
def update
@@ -13,7 +13,7 @@ class Profiles::GroupsController < Profiles::ApplicationController
flash[:alert] = "Failed to save new settings for #{group.name}"
end
- redirect_back_or_default(default: profile_notifications_path)
+ redirect_back_or_default(default: settings_notifications_path)
end
private
diff --git a/app/controllers/profiles/keys_controller.rb b/app/controllers/settings/keys_controller.rb
index 055d900eece..1eb70f6a58d 100644
--- a/app/controllers/profiles/keys_controller.rb
+++ b/app/controllers/settings/keys_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::KeysController < Profiles::ApplicationController
+class Settings::KeysController < Settings::ApplicationController
skip_before_action :authenticate_user!, only: [:get_keys]
def index
@@ -16,7 +16,7 @@ class Profiles::KeysController < Profiles::ApplicationController
@key = Keys::CreateService.new(current_user, key_params.merge(ip_address: request.remote_ip)).execute
if @key.persisted?
- redirect_to profile_key_path(@key)
+ redirect_to settings_key_path(@key)
else
@keys = current_user.keys.select(&:persisted?)
render :index
@@ -28,7 +28,7 @@ class Profiles::KeysController < Profiles::ApplicationController
Keys::DestroyService.new(current_user).execute(@key)
respond_to do |format|
- format.html { redirect_to profile_keys_url, status: :found }
+ format.html { redirect_to settings_keys_url, status: :found }
format.js { head :ok }
end
end
diff --git a/app/controllers/profiles/notifications_controller.rb b/app/controllers/settings/notifications_controller.rb
index 617e5bb7cb3..18a39800340 100644
--- a/app/controllers/profiles/notifications_controller.rb
+++ b/app/controllers/settings/notifications_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::NotificationsController < Profiles::ApplicationController
+class Settings::NotificationsController < Settings::ApplicationController
# rubocop: disable CodeReuse/ActiveRecord
def show
@user = current_user
@@ -19,7 +19,7 @@ class Profiles::NotificationsController < Profiles::ApplicationController
flash[:alert] = _("Failed to save new settings")
end
- redirect_back_or_default(default: profile_notifications_path)
+ redirect_back_or_default(default: settings_notifications_path)
end
def user_params
diff --git a/app/controllers/profiles/passwords_controller.rb b/app/controllers/settings/passwords_controller.rb
index d2787c2e450..cc227cf4b9e 100644
--- a/app/controllers/profiles/passwords_controller.rb
+++ b/app/controllers/settings/passwords_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::PasswordsController < Profiles::ApplicationController
+class Settings::PasswordsController < Settings::ApplicationController
skip_before_action :check_password_expiration, only: [:new, :create]
skip_before_action :check_two_factor_requirement, only: [:new, :create]
@@ -14,7 +14,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_settings_password_path, alert: _('You must provide a valid current password')
return
end
@@ -45,7 +45,7 @@ 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_settings_password_path, alert: _('You must provide a valid current password')
return
end
@@ -62,7 +62,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_settings_password_path, notice: _('We sent you an email with reset password instructions')
end
private
diff --git a/app/controllers/profiles/personal_access_tokens_controller.rb b/app/controllers/settings/personal_access_tokens_controller.rb
index f1c07cd9a1d..a9cec61196e 100644
--- a/app/controllers/profiles/personal_access_tokens_controller.rb
+++ b/app/controllers/settings/personal_access_tokens_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::PersonalAccessTokensController < Profiles::ApplicationController
+class Settings::PersonalAccessTokensController < Settings::ApplicationController
def index
set_index_vars
@personal_access_token = finder.build
@@ -11,7 +11,7 @@ class Profiles::PersonalAccessTokensController < Profiles::ApplicationController
if @personal_access_token.save
PersonalAccessToken.redis_store!(current_user.id, @personal_access_token.token)
- redirect_to profile_personal_access_tokens_path, notice: _("Your new personal access token has been created.")
+ redirect_to settings_personal_access_tokens_path, notice: _("Your new personal access token has been created.")
else
set_index_vars
render :index
@@ -27,7 +27,7 @@ class Profiles::PersonalAccessTokensController < Profiles::ApplicationController
flash[:alert] = _("Could not revoke personal access token %{personal_access_token_name}.") % { personal_access_token_name: @personal_access_token.name }
end
- redirect_to profile_personal_access_tokens_path
+ redirect_to settings_personal_access_tokens_path
end
private
diff --git a/app/controllers/profiles/preferences_controller.rb b/app/controllers/settings/preferences_controller.rb
index 62f98d9e549..25ec2a434a4 100644
--- a/app/controllers/profiles/preferences_controller.rb
+++ b/app/controllers/settings/preferences_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::PreferencesController < Profiles::ApplicationController
+class Settings::PreferencesController < Settings::ApplicationController
before_action :user
def show
@@ -21,7 +21,7 @@ class Profiles::PreferencesController < Profiles::ApplicationController
end
respond_to do |format|
- format.html { redirect_to profile_preferences_path }
+ format.html { redirect_to settings_preferences_path }
format.js
end
end
diff --git a/app/controllers/profiles/two_factor_auths_controller.rb b/app/controllers/settings/two_factor_auths_controller.rb
index 95b9344c551..214e1da182b 100644
--- a/app/controllers/profiles/two_factor_auths_controller.rb
+++ b/app/controllers/settings/two_factor_auths_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class Profiles::TwoFactorAuthsController < Profiles::ApplicationController
+class Settings::TwoFactorAuthsController < Settings::ApplicationController
skip_before_action :check_two_factor_requirement
def show
@@ -58,7 +58,7 @@ class Profiles::TwoFactorAuthsController < Profiles::ApplicationController
if @u2f_registration.persisted?
session.delete(:challenges)
- redirect_to profile_two_factor_auth_path, notice: s_("Your U2F device was registered!")
+ redirect_to settings_two_factor_auth_path, notice: s_("Your U2F device was registered!")
else
@qr_code = build_qr_code
setup_u2f_registration
@@ -75,12 +75,12 @@ class Profiles::TwoFactorAuthsController < Profiles::ApplicationController
def destroy
current_user.disable_two_factor!
- redirect_to profile_account_path, status: :found
+ redirect_to settings_account_path, status: :found
end
def skip
if two_factor_grace_period_expired?
- redirect_to new_profile_two_factor_auth_path, alert: s_('Cannot skip two factor authentication setup')
+ redirect_to new_settings_two_factor_auth_path, alert: s_('Cannot skip two factor authentication setup')
else
session[:skip_two_factor] = current_user.otp_grace_period_started_at + two_factor_grace_period.hours
redirect_to root_path
diff --git a/app/controllers/settings/u2f_registrations_controller.rb b/app/controllers/settings/u2f_registrations_controller.rb
new file mode 100644
index 00000000000..92e12948dc4
--- /dev/null
+++ b/app/controllers/settings/u2f_registrations_controller.rb
@@ -0,0 +1,9 @@
+# frozen_string_literal: true
+
+class Settings::U2fRegistrationsController < Settings::ApplicationController
+ def destroy
+ u2f_registration = current_user.u2f_registrations.find(params[:id])
+ u2f_registration.destroy
+ redirect_to settings_two_factor_auth_path, status: 302, notice: _("Successfully deleted U2F device.")
+ end
+end
diff --git a/app/controllers/profiles_controller.rb b/app/controllers/settings_controller.rb
index 1d16ddb1608..34e7093dd05 100644
--- a/app/controllers/profiles_controller.rb
+++ b/app/controllers/settings_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class ProfilesController < Profiles::ApplicationController
+class SettingsController < Settings::ApplicationController
include ActionView::Helpers::SanitizeHelper
before_action :user
@@ -33,7 +33,7 @@ class ProfilesController < Profiles::ApplicationController
flash[:notice] = s_("Profiles|Incoming email token was successfully reset")
- redirect_to profile_personal_access_tokens_path
+ redirect_to settings_personal_access_tokens_path
end
def reset_feed_token
@@ -43,7 +43,7 @@ class ProfilesController < Profiles::ApplicationController
flash[:notice] = s_('Profiles|Feed token was successfully reset')
- redirect_to profile_personal_access_tokens_path
+ redirect_to settings_personal_access_tokens_path
end
# rubocop: disable CodeReuse/ActiveRecord
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index ffa5719fefb..a185a4ddee3 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -191,7 +191,7 @@ module ApplicationHelper
if admin
admin_user_key_path(@user, key)
else
- profile_key_path(key)
+ settings_key_path(key)
end
end
diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb
index 8d0079a4dd3..eebc211cce1 100644
--- a/app/helpers/projects_helper.rb
+++ b/app/helpers/projects_helper.rb
@@ -213,9 +213,9 @@ module ProjectsHelper
def link_to_set_password
if current_user.require_password_creation_for_git?
- link_to s_('SetPasswordToCloneLink|set a password'), edit_profile_password_path
+ link_to s_('SetPasswordToCloneLink|set a password'), edit_settings_password_path
else
- link_to s_('CreateTokenToCloneLink|create a personal access token'), profile_personal_access_tokens_path
+ link_to s_('CreateTokenToCloneLink|create a personal access token'), settings_personal_access_tokens_path
end
end
diff --git a/app/helpers/search_helper.rb b/app/helpers/search_helper.rb
index f5c4686a3bf..2098b01a5fa 100644
--- a/app/helpers/search_helper.rb
+++ b/app/helpers/search_helper.rb
@@ -59,8 +59,8 @@ module SearchHelper
# Autocomplete results for various settings pages
def default_autocomplete
[
- { category: "Settings", label: _("User settings"), url: profile_path },
- { category: "Settings", label: _("SSH Keys"), url: profile_keys_path },
+ { category: "Settings", label: _("User settings"), url: settings_path },
+ { category: "Settings", label: _("SSH Keys"), url: settings_keys_path },
{ category: "Settings", label: _("Dashboard"), url: root_path }
]
end
diff --git a/app/helpers/profiles_helper.rb b/app/helpers/settings_helper.rb
index 5a42e581867..84a5c1a9eaf 100644
--- a/app/helpers/profiles_helper.rb
+++ b/app/helpers/settings_helper.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-module ProfilesHelper
+module SettingsHelper
def commit_email_select_options(user)
private_email = user.private_commit_email
verified_emails = user.verified_emails - [private_email]
diff --git a/app/services/chat_names/authorize_user_service.rb b/app/services/chat_names/authorize_user_service.rb
index 78b53cb3637..aeb7e868101 100644
--- a/app/services/chat_names/authorize_user_service.rb
+++ b/app/services/chat_names/authorize_user_service.rb
@@ -14,7 +14,7 @@ module ChatNames
token = request_token
- new_profile_chat_name_url(token: token) if token
+ new_settings_chat_name_url(token: token) if token
end
private
diff --git a/app/views/admin/requests_profiles/index.html.haml b/app/views/admin/requests_profiles/index.html.haml
index 86bfeef580c..82c57aa737f 100644
--- a/app/views/admin/requests_profiles/index.html.haml
+++ b/app/views/admin/requests_profiles/index.html.haml
@@ -20,7 +20,7 @@
- profiles.each do |profile|
%li
= link_to profile.time.to_s(:long) + ' ' + profile.profile_mode.capitalize,
- admin_requests_profile_path(profile)
+ admin_requests_settings_path(profile)
- else
%p
No profiles found
diff --git a/app/views/devise/mailer/_confirmation_instructions_secondary.html.haml b/app/views/devise/mailer/_confirmation_instructions_secondary.html.haml
index ccc3e734276..92514499bcd 100644
--- a/app/views/devise/mailer/_confirmation_instructions_secondary.html.haml
+++ b/app/views/devise/mailer/_confirmation_instructions_secondary.html.haml
@@ -5,4 +5,4 @@
= link_to 'Confirm your email address', confirmation_url(@resource, confirmation_token: @token)
%p
If this email was added in error, you can remove it here:
- = link_to "Emails", profile_emails_url
+ = link_to "Emails", settings_emails_url
diff --git a/app/views/devise/mailer/_confirmation_instructions_secondary.text.erb b/app/views/devise/mailer/_confirmation_instructions_secondary.text.erb
index a3b28cb0b84..0193a0536cd 100644
--- a/app/views/devise/mailer/_confirmation_instructions_secondary.text.erb
+++ b/app/views/devise/mailer/_confirmation_instructions_secondary.text.erb
@@ -4,4 +4,4 @@ Use the link below to confirm your email address (<%= @resource.email %>)
<%= confirmation_url(@resource, confirmation_token: @token) %>
-If this email was added in error, you can remove it here: <%= profile_emails_url %>
+If this email was added in error, you can remove it here: <%= settings_emails_url %>
diff --git a/app/views/layouts/_mailer.html.haml b/app/views/layouts/_mailer.html.haml
index 6e8294d6adc..8e6f9d47290 100644
--- a/app/views/layouts/_mailer.html.haml
+++ b/app/views/layouts/_mailer.html.haml
@@ -70,7 +70,7 @@
%td{ style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;padding:25px 0;font-size:13px;line-height:1.6;color:#5c5c5c;" }
%img{ alt: "GitLab", height: "33", src: image_url('mailers/gitlab_footer_logo.gif'), style: "display:block;margin:0 auto 1em;", width: "90" }/
%div
- - manage_notifications_link = link_to(_("Manage all notifications"), profile_notifications_url, style: "color:#3777b0;text-decoration:none;")
+ - manage_notifications_link = link_to(_("Manage all notifications"), settings_notifications_url, style: "color:#3777b0;text-decoration:none;")
- help_link = link_to(_("Help"), help_url, style: "color:#3777b0;text-decoration:none;")
= _("You're receiving this email because of your account on %{host}. %{manage_notifications_link} &middot; %{help_link}").html_safe % { host: Gitlab.config.gitlab.host, manage_notifications_link: manage_notifications_link, help_link: help_link }
diff --git a/app/views/layouts/header/_current_user_dropdown.html.haml b/app/views/layouts/header/_current_user_dropdown.html.haml
index 808290afcad..a0634884c61 100644
--- a/app/views/layouts/header/_current_user_dropdown.html.haml
+++ b/app/views/layouts/header/_current_user_dropdown.html.haml
@@ -20,7 +20,7 @@
= link_to s_("CurrentUser|Profile"), current_user, class: 'profile-link', data: { user: current_user.username }
- if current_user_menu?(:settings)
%li
- = link_to s_("CurrentUser|Settings"), profile_path, data: { qa_selector: 'settings_link' }
+ = link_to s_("CurrentUser|Settings"), settings_path, data: { qa_selector: 'settings_link' }
- if current_user_menu?(:sign_out)
%li.divider
%li
diff --git a/app/views/layouts/nav/sidebar/_profile.html.haml b/app/views/layouts/nav/sidebar/_profile.html.haml
index 7dd33f3c641..0f7f6b521de 100644
--- a/app/views/layouts/nav/sidebar/_profile.html.haml
+++ b/app/views/layouts/nav/sidebar/_profile.html.haml
@@ -1,155 +1,155 @@
.nav-sidebar{ class: ("sidebar-collapsed-desktop" if collapsed_sidebar?) }
.nav-sidebar-inner-scroll
.context-header
- = link_to profile_path, title: _('Profile Settings') do
+ = link_to settings_path, title: _('Profile Settings') do
.avatar-container.s40.settings-avatar
= image_tag avatar_icon_for_user(current_user, 40), class: "avatar s40 avatar-tile", alt: current_user.name
.sidebar-context-title= _('User Settings')
%ul.sidebar-top-level-items
= nav_link(path: 'profiles#show', html_options: {class: 'home'}) do
- = link_to profile_path do
+ = link_to settings_path do
.nav-icon-container
= sprite_icon('profile')
%span.nav-item-name
= _('Profile')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(path: 'profiles#show', html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_path do
+ = link_to settings_path do
%strong.fly-out-top-item-name
= _('Profile')
= nav_link(controller: [:accounts, :two_factor_auths]) do
- = link_to profile_account_path do
+ = link_to settings_account_path do
.nav-icon-container
= sprite_icon('account')
%span.nav-item-name
= _('Account')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: [:accounts, :two_factor_auths], html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_account_path do
+ = link_to settings_account_path do
%strong.fly-out-top-item-name
= _('Account')
= render_if_exists 'layouts/nav/sidebar/profile_billing_link'
= nav_link(controller: 'oauth/applications') do
- = link_to applications_profile_path do
+ = link_to applications_settings_path do
.nav-icon-container
= sprite_icon('applications')
%span.nav-item-name
= _('Applications')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: 'oauth/applications', html_options: { class: "fly-out-top-item" } ) do
- = link_to applications_profile_path do
+ = link_to applications_settings_path do
%strong.fly-out-top-item-name
= _('Applications')
= nav_link(controller: :chat_names) do
- = link_to profile_chat_names_path do
+ = link_to settings_chat_names_path do
.nav-icon-container
= sprite_icon('comment')
%span.nav-item-name
= _('Chat')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :chat_names, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_chat_names_path do
+ = link_to settings_chat_names_path do
%strong.fly-out-top-item-name
= _('Chat')
= nav_link(controller: :personal_access_tokens) do
- = link_to profile_personal_access_tokens_path do
+ = link_to settings_personal_access_tokens_path do
.nav-icon-container
= sprite_icon('token')
%span.nav-item-name
= _('Access Tokens')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :personal_access_tokens, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_personal_access_tokens_path do
+ = link_to settings_personal_access_tokens_path do
%strong.fly-out-top-item-name
= _('Access Tokens')
= nav_link(controller: :emails) do
- = link_to profile_emails_path do
+ = link_to settings_emails_path do
.nav-icon-container
= sprite_icon('mail')
%span.nav-item-name
= _('Emails')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :emails, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_emails_path do
+ = link_to settings_emails_path do
%strong.fly-out-top-item-name
= _('Emails')
- if current_user.allow_password_authentication?
= nav_link(controller: :passwords) do
- = link_to edit_profile_password_path do
+ = link_to edit_settings_password_path do
.nav-icon-container
= sprite_icon('lock')
%span.nav-item-name
= _('Password')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :passwords, html_options: { class: "fly-out-top-item" } ) do
- = link_to edit_profile_password_path do
+ = link_to edit_settings_password_path do
%strong.fly-out-top-item-name
= _('Password')
= nav_link(controller: :notifications) do
- = link_to profile_notifications_path do
+ = link_to settings_notifications_path do
.nav-icon-container
= sprite_icon('notifications')
%span.nav-item-name
= _('Notifications')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :notifications, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_notifications_path do
+ = link_to settings_notifications_path do
%strong.fly-out-top-item-name
= _('Notifications')
= nav_link(controller: :keys) do
- = link_to profile_keys_path do
+ = link_to settings_keys_path do
.nav-icon-container
= sprite_icon('key')
%span.nav-item-name
= _('SSH Keys')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :keys, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_keys_path do
+ = link_to settings_keys_path do
%strong.fly-out-top-item-name
= _('SSH Keys')
= nav_link(controller: :gpg_keys) do
- = link_to profile_gpg_keys_path do
+ = link_to settings_gpg_keys_path do
.nav-icon-container
= sprite_icon('key-modern')
%span.nav-item-name
= _('GPG Keys')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :gpg_keys, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_gpg_keys_path do
+ = link_to settings_gpg_keys_path do
%strong.fly-out-top-item-name
= _('GPG Keys')
= nav_link(controller: :preferences) do
- = link_to profile_preferences_path do
+ = link_to settings_preferences_path do
.nav-icon-container
= sprite_icon('preferences')
%span.nav-item-name
= _('Preferences')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :preferences, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_preferences_path do
+ = link_to settings_preferences_path do
%strong.fly-out-top-item-name
= _('Preferences')
= nav_link(controller: :active_sessions) do
- = link_to profile_active_sessions_path do
+ = link_to settings_active_sessions_path do
.nav-icon-container
= sprite_icon('monitor-lines')
%span.nav-item-name
= _('Active Sessions')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :active_sessions, html_options: { class: "fly-out-top-item" } ) do
- = link_to profile_active_sessions_path do
+ = link_to settings_active_sessions_path do
%strong.fly-out-top-item-name
= _('Active Sessions')
= nav_link(path: 'profiles#audit_log') do
- = link_to audit_log_profile_path do
+ = link_to audit_log_settings_path do
.nav-icon-container
= sprite_icon('log')
%span.nav-item-name
= _('Authentication log')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(path: 'profiles#audit_log', html_options: { class: "fly-out-top-item" } ) do
- = link_to audit_log_profile_path do
+ = link_to audit_log_settings_path do
%strong.fly-out-top-item-name
= _('Authentication Log')
diff --git a/app/views/layouts/profile.html.haml b/app/views/layouts/profile.html.haml
index 7aca64663e0..733d2317061 100644
--- a/app/views/layouts/profile.html.haml
+++ b/app/views/layouts/profile.html.haml
@@ -1,5 +1,5 @@
- page_title _("User Settings")
-- header_title _("User Settings"), profile_path unless header_title
+- header_title _("User Settings"), settings_path unless header_title
- sidebar "dashboard"
- nav "profile"
- @left_sidebar = true
diff --git a/app/views/notify/new_gpg_key_email.html.haml b/app/views/notify/new_gpg_key_email.html.haml
index b857705e01f..d5acb5bf593 100644
--- a/app/views/notify/new_gpg_key_email.html.haml
+++ b/app/views/notify/new_gpg_key_email.html.haml
@@ -7,4 +7,4 @@
%code= @gpg_key.fingerprint
%p
If this key was added in error, you can remove it under
- = link_to "GPG Keys", profile_gpg_keys_url
+ = link_to "GPG Keys", settings_gpg_keys_url
diff --git a/app/views/notify/new_gpg_key_email.text.erb b/app/views/notify/new_gpg_key_email.text.erb
index 92ea851eee4..5fcbb5afd42 100644
--- a/app/views/notify/new_gpg_key_email.text.erb
+++ b/app/views/notify/new_gpg_key_email.text.erb
@@ -4,4 +4,4 @@ A new GPG key was added to your account:
Fingerprint: <%= @gpg_key.fingerprint %>
-If this key was added in error, you can remove it at <%= profile_gpg_keys_url %>
+If this key was added in error, you can remove it at <%= settings_gpg_keys_url %>
diff --git a/app/views/notify/new_ssh_key_email.html.haml b/app/views/notify/new_ssh_key_email.html.haml
index d031842be95..e9f5c8e1615 100644
--- a/app/views/notify/new_ssh_key_email.html.haml
+++ b/app/views/notify/new_ssh_key_email.html.haml
@@ -7,4 +7,4 @@
%code= @key.title
%p
If this key was added in error, you can remove it under
- = link_to "SSH Keys", profile_keys_url
+ = link_to "SSH Keys", settings_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 690357d69ed..2723eddccf3 100644
--- a/app/views/notify/new_ssh_key_email.text.erb
+++ b/app/views/notify/new_ssh_key_email.text.erb
@@ -4,4 +4,4 @@ A new public key was added to your account:
Title: <%= @key.title %>
-If this key was added in error, you can remove it at <%= profile_keys_url %>
+If this key was added in error, you can remove it at <%= settings_keys_url %>
diff --git a/app/views/profiles/_email_settings.html.haml b/app/views/settings/_email_settings.html.haml
index fb4da08e129..fb4da08e129 100644
--- a/app/views/profiles/_email_settings.html.haml
+++ b/app/views/settings/_email_settings.html.haml
diff --git a/app/views/profiles/_event_table.html.haml b/app/views/settings/_event_table.html.haml
index 977ff30d5a6..977ff30d5a6 100644
--- a/app/views/profiles/_event_table.html.haml
+++ b/app/views/settings/_event_table.html.haml
diff --git a/app/views/profiles/accounts/_providers.html.haml b/app/views/settings/accounts/_providers.html.haml
index 068f9cc70f7..c0f9098d92a 100644
--- a/app/views/profiles/accounts/_providers.html.haml
+++ b/app/views/settings/accounts/_providers.html.haml
@@ -10,7 +10,7 @@
= provider_image_tag(provider)
- if auth_active?(provider)
- if unlink_allowed
- = link_to unlink_profile_account_path(provider: provider), method: :delete, class: 'provider-btn' do
+ = link_to unlink_settings_account_path(provider: provider), method: :delete, class: 'provider-btn' do
= s_('Profiles|Disconnect')
- else
%a.provider-btn
diff --git a/app/views/profiles/accounts/show.html.haml b/app/views/settings/accounts/show.html.haml
index e6380817c8f..58484e386f0 100644
--- a/app/views/profiles/accounts/show.html.haml
+++ b/app/views/settings/accounts/show.html.haml
@@ -15,10 +15,10 @@
%p
#{_('Status')}: #{current_user.two_factor_enabled? ? _('Enabled') : _('Disabled')}
- if current_user.two_factor_enabled?
- = link_to _('Manage two-factor authentication'), profile_two_factor_auth_path, class: 'btn btn-info'
+ = link_to _('Manage two-factor authentication'), settings_two_factor_auth_path, class: 'btn btn-info'
- else
.append-bottom-10
- = link_to _('Enable two-factor authentication'), profile_two_factor_auth_path, class: 'btn btn-success'
+ = link_to _('Enable two-factor authentication'), settings_two_factor_auth_path, class: 'btn btn-success'
%hr
- if display_providers_on_profile?
@@ -41,7 +41,7 @@
= succeed '.' do
= link_to s_('Profiles|Learn more'), help_page_path('user/profile/index', anchor: 'changing-your-username'), target: '_blank'
.col-lg-8
- - data = { initial_username: current_user.username, root_url: root_url, action_url: update_username_profile_path(format: :json) }
+ - data = { initial_username: current_user.username, root_url: root_url, action_url: update_username_settings_path(format: :json) }
#update-username{ data: data }
%hr
diff --git a/app/views/profiles/active_sessions/_active_session.html.haml b/app/views/settings/active_sessions/_active_session.html.haml
index bb31049111c..bb31049111c 100644
--- a/app/views/profiles/active_sessions/_active_session.html.haml
+++ b/app/views/settings/active_sessions/_active_session.html.haml
diff --git a/app/views/profiles/active_sessions/index.html.haml b/app/views/settings/active_sessions/index.html.haml
index d651319fc3f..d651319fc3f 100644
--- a/app/views/profiles/active_sessions/index.html.haml
+++ b/app/views/settings/active_sessions/index.html.haml
diff --git a/app/views/profiles/audit_log.html.haml b/app/views/settings/audit_log.html.haml
index 275c0428d34..275c0428d34 100644
--- a/app/views/profiles/audit_log.html.haml
+++ b/app/views/settings/audit_log.html.haml
diff --git a/app/views/profiles/chat_names/_chat_name.html.haml b/app/views/settings/chat_names/_chat_name.html.haml
index ff67f92ad07..c1ff667310e 100644
--- a/app/views/profiles/chat_names/_chat_name.html.haml
+++ b/app/views/settings/chat_names/_chat_name.html.haml
@@ -24,4 +24,4 @@
= _('Never')
%td
- = link_to _('Remove'), profile_chat_name_path(chat_name), method: :delete, class: 'btn btn-danger float-right', data: { confirm: _('Are you sure you want to revoke this nickname?') }
+ = link_to _('Remove'), settings_chat_name_path(chat_name), method: :delete, class: 'btn btn-danger float-right', data: { confirm: _('Are you sure you want to revoke this nickname?') }
diff --git a/app/views/profiles/chat_names/index.html.haml b/app/views/settings/chat_names/index.html.haml
index 0c8098a97d5..0c8098a97d5 100644
--- a/app/views/profiles/chat_names/index.html.haml
+++ b/app/views/settings/chat_names/index.html.haml
diff --git a/app/views/profiles/chat_names/new.html.haml b/app/views/settings/chat_names/new.html.haml
index d86941b7a29..44277a3aa33 100644
--- a/app/views/profiles/chat_names/new.html.haml
+++ b/app/views/settings/chat_names/new.html.haml
@@ -7,9 +7,9 @@
%hr
.actions
- = form_tag profile_chat_names_path, method: :post do
+ = form_tag settings_chat_names_path, method: :post do
= hidden_field_tag :token, @chat_name_token.token
= submit_tag "Authorize", class: "btn btn-success wide float-left"
- = form_tag deny_profile_chat_names_path, method: :delete do
+ = form_tag deny_settings_chat_names_path, method: :delete do
= hidden_field_tag :token, @chat_name_token.token
= submit_tag "Deny", class: "btn btn-danger prepend-left-10"
diff --git a/app/views/profiles/emails/index.html.haml b/app/views/settings/emails/index.html.haml
index 3c20518c038..c67041affeb 100644
--- a/app/views/profiles/emails/index.html.haml
+++ b/app/views/settings/emails/index.html.haml
@@ -10,7 +10,7 @@
.col-lg-8
%h4.prepend-top-0
= _('Add email address')
- = form_for 'email', url: profile_emails_path do |f|
+ = form_for 'email', url: settings_emails_path do |f|
.form-group
= f.label :email, _('Email'), class: 'label-bold'
= f.text_field :email, class: 'form-control'
@@ -26,7 +26,7 @@
%li
= _('Your Commit Email will be used for web based operations, such as edits and merges.')
%li
- - address = profile_notifications_path
+ - address = settings_notifications_path
- notification_message = _('Your Default Notification Email will be used for account notifications if a %{openingTag}group-specific email address%{closingTag} is not set.') % { openingTag: "<a href='#{address}'>".html_safe, closingTag: '</a>'.html_safe}
= notification_message.html_safe
%li
@@ -56,8 +56,8 @@
%span.badge.badge-info= s_('Profiles|Notification email')
- unless email.confirmed?
- confirm_title = "#{email.confirmation_sent_at ? _('Resend confirmation email') : _('Send confirmation email')}"
- = link_to confirm_title, resend_confirmation_instructions_profile_email_path(email), method: :put, class: 'btn btn-sm btn-warning prepend-left-10'
+ = link_to confirm_title, resend_confirmation_instructions_settings_email_path(email), method: :put, class: 'btn btn-sm btn-warning prepend-left-10'
- = link_to profile_email_path(email), data: { confirm: _('Are you sure?')}, method: :delete, class: 'btn btn-sm btn-danger prepend-left-10' do
+ = link_to settings_email_path(email), data: { confirm: _('Are you sure?')}, method: :delete, class: 'btn btn-sm btn-danger prepend-left-10' do
%span.sr-only= _('Remove')
= icon('trash')
diff --git a/app/views/profiles/gpg_keys/_form.html.haml b/app/views/settings/gpg_keys/_form.html.haml
index 225487b2638..225487b2638 100644
--- a/app/views/profiles/gpg_keys/_form.html.haml
+++ b/app/views/settings/gpg_keys/_form.html.haml
diff --git a/app/views/profiles/gpg_keys/_key.html.haml b/app/views/settings/gpg_keys/_key.html.haml
index f8351644df5..06c14429b8a 100644
--- a/app/views/profiles/gpg_keys/_key.html.haml
+++ b/app/views/settings/gpg_keys/_key.html.haml
@@ -19,9 +19,9 @@
.float-right
%span.key-created-at
= s_('Profiles|Created %{time_ago}'.html_safe) % { time_ago:time_ago_with_tooltip(key.created_at)}
- = link_to profile_gpg_key_path(key), data: { confirm: _('Are you sure? Removing this GPG key does not affect already signed commits.') }, method: :delete, class: "btn btn-danger prepend-left-10" do
+ = link_to settings_gpg_key_path(key), data: { confirm: _('Are you sure? Removing this GPG key does not affect already signed commits.') }, method: :delete, class: "btn btn-danger prepend-left-10" do
%span.sr-only= _('Remove')
= icon('trash')
- = link_to revoke_profile_gpg_key_path(key), data: { confirm: _('Are you sure? All commits that were signed with this GPG key will be unverified.') }, method: :put, class: "btn btn-danger prepend-left-10" do
+ = link_to revoke_settings_gpg_key_path(key), data: { confirm: _('Are you sure? All commits that were signed with this GPG key will be unverified.') }, method: :put, class: "btn btn-danger prepend-left-10" do
%span.sr-only= _('Revoke')
= _('Revoke')
diff --git a/app/views/profiles/gpg_keys/_key_table.html.haml b/app/views/settings/gpg_keys/_key_table.html.haml
index ebbd1c8f672..ebbd1c8f672 100644
--- a/app/views/profiles/gpg_keys/_key_table.html.haml
+++ b/app/views/settings/gpg_keys/_key_table.html.haml
diff --git a/app/views/profiles/gpg_keys/index.html.haml b/app/views/settings/gpg_keys/index.html.haml
index f9f898a9225..f9f898a9225 100644
--- a/app/views/profiles/gpg_keys/index.html.haml
+++ b/app/views/settings/gpg_keys/index.html.haml
diff --git a/app/views/profiles/keys/_form.html.haml b/app/views/settings/keys/_form.html.haml
index 63ef5eaa172..63ef5eaa172 100644
--- a/app/views/profiles/keys/_form.html.haml
+++ b/app/views/settings/keys/_form.html.haml
diff --git a/app/views/profiles/keys/_key.html.haml b/app/views/settings/keys/_key.html.haml
index b9d73d89334..b9d73d89334 100644
--- a/app/views/profiles/keys/_key.html.haml
+++ b/app/views/settings/keys/_key.html.haml
diff --git a/app/views/profiles/keys/_key_details.html.haml b/app/views/settings/keys/_key_details.html.haml
index 0ef01dec493..0ef01dec493 100644
--- a/app/views/profiles/keys/_key_details.html.haml
+++ b/app/views/settings/keys/_key_details.html.haml
diff --git a/app/views/profiles/keys/_key_table.html.haml b/app/views/settings/keys/_key_table.html.haml
index 4a6d8a1870d..4a6d8a1870d 100644
--- a/app/views/profiles/keys/_key_table.html.haml
+++ b/app/views/settings/keys/_key_table.html.haml
diff --git a/app/views/profiles/keys/index.html.haml b/app/views/settings/keys/index.html.haml
index da6aa0fce3a..da6aa0fce3a 100644
--- a/app/views/profiles/keys/index.html.haml
+++ b/app/views/settings/keys/index.html.haml
diff --git a/app/views/profiles/keys/show.html.haml b/app/views/settings/keys/show.html.haml
index 360de7a0c11..e173a805c79 100644
--- a/app/views/profiles/keys/show.html.haml
+++ b/app/views/settings/keys/show.html.haml
@@ -1,4 +1,4 @@
-- add_to_breadcrumbs "SSH Keys", profile_keys_path
+- add_to_breadcrumbs "SSH Keys", settings_keys_path
- breadcrumb_title @key.title
- page_title @key.title, _('SSH Keys')
- @content_class = "limit-container-width" unless fluid_layout
diff --git a/app/views/profiles/notifications/_email_settings.html.haml b/app/views/settings/notifications/_email_settings.html.haml
index 34dcf8f5402..34dcf8f5402 100644
--- a/app/views/profiles/notifications/_email_settings.html.haml
+++ b/app/views/settings/notifications/_email_settings.html.haml
diff --git a/app/views/profiles/notifications/_group_settings.html.haml b/app/views/settings/notifications/_group_settings.html.haml
index cf17ee44145..d0391609bb6 100644
--- a/app/views/profiles/notifications/_group_settings.html.haml
+++ b/app/views/settings/notifications/_group_settings.html.haml
@@ -13,5 +13,5 @@
= render 'shared/notifications/button', notification_setting: setting
.table-section.section-30
- = form_for @user.notification_settings.find { |ns| ns.source == group }, url: profile_notifications_group_path(group), method: :put, html: { class: 'update-notifications' } do |f|
+ = form_for @user.notification_settings.find { |ns| ns.source == group }, url: settings_notifications_group_path(group), method: :put, html: { class: 'update-notifications' } do |f|
= f.select :notification_email, @user.all_emails, { include_blank: 'Global notification email' }, class: 'select2 js-group-notification-email'
diff --git a/app/views/profiles/notifications/_project_settings.html.haml b/app/views/settings/notifications/_project_settings.html.haml
index 823fec3fab4..823fec3fab4 100644
--- a/app/views/profiles/notifications/_project_settings.html.haml
+++ b/app/views/settings/notifications/_project_settings.html.haml
diff --git a/app/views/profiles/notifications/show.html.haml b/app/views/settings/notifications/show.html.haml
index 1f311e9a4a4..aa899156707 100644
--- a/app/views/profiles/notifications/show.html.haml
+++ b/app/views/settings/notifications/show.html.haml
@@ -21,7 +21,7 @@
%h5.prepend-top-0
= _('Global notification settings')
- = form_for @user, url: profile_notifications_path, method: :put, html: { class: 'update-notifications prepend-top-default' } do |f|
+ = form_for @user, url: settings_notifications_path, method: :put, html: { class: 'update-notifications prepend-top-default' } do |f|
= render_if_exists 'profiles/notifications/email_settings', form: f
= label_tag :global_notification_level, "Global notification level", class: "label-bold"
@@ -32,7 +32,7 @@
.clearfix
- = form_for @user, url: profile_notifications_path, method: :put do |f|
+ = form_for @user, url: settings_notifications_path, method: :put do |f|
%label{ for: 'user_notified_of_own_activity' }
= f.check_box :notified_of_own_activity
%span= _('Receive notifications about your own activity')
diff --git a/app/views/profiles/passwords/edit.html.haml b/app/views/settings/passwords/edit.html.haml
index ac8c31189d0..f2b4ac3f9fa 100644
--- a/app/views/profiles/passwords/edit.html.haml
+++ b/app/views/settings/passwords/edit.html.haml
@@ -14,7 +14,7 @@
= _('Change your password')
- else
= _('Change your password or recover your current one')
- = form_for @user, url: profile_password_path, method: :put, html: {class: "update-password"} do |f|
+ = form_for @user, url: settings_password_path, method: :put, html: {class: "update-password"} do |f|
= form_errors(@user)
- unless @user.password_automatically_set?
@@ -32,4 +32,4 @@
.prepend-top-default.append-bottom-default
= f.submit _('Save password'), class: "btn btn-success append-right-10"
- unless @user.password_automatically_set?
- = link_to _('I forgot my password'), reset_profile_password_path, method: :put, class: "account-btn-link"
+ = link_to _('I forgot my password'), reset_settings_password_path, method: :put, class: "account-btn-link"
diff --git a/app/views/profiles/passwords/new.html.haml b/app/views/settings/passwords/new.html.haml
index ce60455ab89..748b0017109 100644
--- a/app/views/profiles/passwords/new.html.haml
+++ b/app/views/settings/passwords/new.html.haml
@@ -3,7 +3,7 @@
%h3.page-title= _('Set up new password')
%hr
-= form_for @user, url: profile_password_path, method: :post do |f|
+= form_for @user, url: settings_password_path, method: :post do |f|
%p.slead
= _('Please set a new password before proceeding.')
%br
diff --git a/app/views/profiles/personal_access_tokens/index.html.haml b/app/views/settings/personal_access_tokens/index.html.haml
index 65ef9690062..f3cc0fdceae 100644
--- a/app/views/profiles/personal_access_tokens/index.html.haml
+++ b/app/views/settings/personal_access_tokens/index.html.haml
@@ -16,7 +16,7 @@
- if @new_personal_access_token
= render "shared/personal_access_tokens_created_container", new_token_value: @new_personal_access_token
- = render "shared/personal_access_tokens_form", path: profile_personal_access_tokens_path, impersonation: false, token: @personal_access_token, scopes: @scopes
+ = render "shared/personal_access_tokens_form", path: settings_personal_access_tokens_path, impersonation: false, token: @personal_access_token, scopes: @scopes
= render "shared/personal_access_tokens_table", impersonation: false, active_tokens: @active_personal_access_tokens, inactive_tokens: @inactive_personal_access_tokens
diff --git a/app/views/profiles/preferences/show.html.haml b/app/views/settings/preferences/show.html.haml
index d16e2dddbe0..5a99f2e3962 100644
--- a/app/views/profiles/preferences/show.html.haml
+++ b/app/views/settings/preferences/show.html.haml
@@ -1,7 +1,7 @@
- page_title _('Preferences')
- @content_class = "limit-container-width" unless fluid_layout
-= form_for @user, url: profile_preferences_path, remote: true, method: :put, html: { class: 'row prepend-top-default js-preferences-form' } do |f|
+= form_for @user, url: settings_preferences_path, remote: true, method: :put, html: { class: 'row prepend-top-default js-preferences-form' } do |f|
.col-lg-4.application-theme
%h4.prepend-top-0
= s_('Preferences|Navigation theme')
diff --git a/app/views/profiles/preferences/update.js.erb b/app/views/settings/preferences/update.js.erb
index 8966dd3fd86..8966dd3fd86 100644
--- a/app/views/profiles/preferences/update.js.erb
+++ b/app/views/settings/preferences/update.js.erb
diff --git a/app/views/profiles/show.html.haml b/app/views/settings/show.html.haml
index ffb90bbd354..9c00cc91996 100644
--- a/app/views/profiles/show.html.haml
+++ b/app/views/settings/show.html.haml
@@ -2,7 +2,7 @@
- @content_class = "limit-container-width" unless fluid_layout
- gravatar_link = link_to Gitlab.config.gravatar.host, 'https://' + Gitlab.config.gravatar.host
-= bootstrap_form_for @user, url: profile_path, method: :put, html: { multipart: true, class: 'edit-user prepend-top-default js-quick-submit gl-show-field-errors' }, authenticity_token: true do |f|
+= bootstrap_form_for @user, url: settings_path, method: :put, html: { multipart: true, class: 'edit-user prepend-top-default js-quick-submit gl-show-field-errors' }, authenticity_token: true do |f|
= form_errors(@user)
.row
@@ -32,7 +32,7 @@
.form-text.text-muted= s_("Profiles|The maximum file size allowed is 200KB.")
- if @user.avatar?
%hr
- = link_to s_("Profiles|Remove avatar"), profile_avatar_path, data: { confirm: s_("Profiles|Avatar will be removed. Are you sure?") }, method: :delete, class: 'btn btn-danger btn-inverted'
+ = link_to s_("Profiles|Remove avatar"), settings_avatar_path, data: { confirm: s_("Profiles|Avatar will be removed. Are you sure?") }, method: :delete, class: 'btn btn-danger btn-inverted'
%hr
.row
diff --git a/app/views/profiles/two_factor_auths/_codes.html.haml b/app/views/settings/two_factor_auths/_codes.html.haml
index be0af977011..e086db29a7b 100644
--- a/app/views/profiles/two_factor_auths/_codes.html.haml
+++ b/app/views/settings/two_factor_auths/_codes.html.haml
@@ -9,5 +9,5 @@
%span.monospace= code
.d-flex
- = link_to _('Proceed'), profile_account_path, class: 'btn btn-success append-right-10'
+ = link_to _('Proceed'), settings_account_path, class: 'btn btn-success append-right-10'
= link_to _('Download codes'), "data:text/plain;charset=utf-8,#{CGI.escape(@codes.join("\n"))}", download: "gitlab-recovery-codes.txt", class: 'btn btn-default'
diff --git a/app/views/profiles/two_factor_auths/codes.html.haml b/app/views/settings/two_factor_auths/codes.html.haml
index 53907ebffab..53907ebffab 100644
--- a/app/views/profiles/two_factor_auths/codes.html.haml
+++ b/app/views/settings/two_factor_auths/codes.html.haml
diff --git a/app/views/profiles/two_factor_auths/create.html.haml b/app/views/settings/two_factor_auths/create.html.haml
index 973eb8136c4..973eb8136c4 100644
--- a/app/views/profiles/two_factor_auths/create.html.haml
+++ b/app/views/settings/two_factor_auths/create.html.haml
diff --git a/app/views/profiles/two_factor_auths/show.html.haml b/app/views/settings/two_factor_auths/show.html.haml
index 5501e63e027..5aca4e27129 100644
--- a/app/views/profiles/two_factor_auths/show.html.haml
+++ b/app/views/settings/two_factor_auths/show.html.haml
@@ -1,8 +1,8 @@
- page_title _('Two-Factor Authentication'), _('Account')
-- add_to_breadcrumbs(_('Two-Factor Authentication'), profile_account_path)
+- add_to_breadcrumbs(_('Two-Factor Authentication'), settings_account_path)
- @content_class = "limit-container-width" unless fluid_layout
-.js-two-factor-auth{ 'data-two-factor-skippable' => "#{two_factor_skippable?}", 'data-two_factor_skip_url' => skip_profile_two_factor_auth_path }
+.js-two-factor-auth{ 'data-two-factor-skippable' => "#{two_factor_skippable?}", 'data-two_factor_skip_url' => skip_settings_two_factor_auth_path }
.row.prepend-top-default
.col-lg-4
%h4.prepend-top-0
@@ -16,11 +16,11 @@
%p
= _('If you lose your recovery codes you can generate new ones, invalidating all previous codes.')
%div
- = link_to _('Disable two-factor authentication'), profile_two_factor_auth_path,
+ = link_to _('Disable two-factor authentication'), settings_two_factor_auth_path,
method: :delete,
data: { confirm: _('Are you sure? This will invalidate your registered applications and U2F devices.') },
class: 'btn btn-danger append-right-10'
- = form_tag codes_profile_two_factor_auth_path, {style: 'display: inline-block', method: :post} do |f|
+ = form_tag codes_settings_two_factor_auth_path, {style: 'display: inline-block', method: :post} do |f|
= submit_tag _('Regenerate recovery codes'), class: 'btn'
- else
@@ -43,7 +43,7 @@
= _('Key: %{key}') %{ key: current_user.otp_secret.scan(/.{4}/).join(' ') }
%p.two-factor-new-manual-content
= _('Time based: Yes')
- = form_tag profile_two_factor_auth_path, method: :post do |f|
+ = form_tag settings_two_factor_auth_path, method: :post do |f|
- if @error
.alert.alert-danger
= @error
@@ -90,7 +90,7 @@
%tr
%td= registration.name.presence || _("<no name set>")
%td= registration.created_at.to_date.to_s(:medium)
- %td= link_to _('Delete'), profile_u2f_registration_path(registration), method: :delete, class: "btn btn-danger float-right", data: { confirm: _('Are you sure you want to delete this device? This action cannot be undone.') }
+ %td= link_to _('Delete'), settings_u2f_registration_path(registration), method: :delete, class: "btn btn-danger float-right", data: { confirm: _('Are you sure you want to delete this device? This action cannot be undone.') }
- else
.settings-message.text-center
diff --git a/app/views/shared/_no_password.html.haml b/app/views/shared/_no_password.html.haml
index 9b1a467df6b..96d4fc6c605 100644
--- a/app/views/shared/_no_password.html.haml
+++ b/app/views/shared/_no_password.html.haml
@@ -4,6 +4,6 @@
- set_password_message = _("You won't be able to pull or push project code via %{protocol} until you %{set_password_link} on your account") % translation_params
= set_password_message.html_safe
.alert-link-group
- = link_to _("Don't show again"), profile_path(user: {hide_no_password: true}), method: :put
+ = link_to _("Don't show again"), settings_path(user: {hide_no_password: true}), method: :put
|
= link_to _('Remind later'), '#', class: 'hide-no-password-message'
diff --git a/app/views/shared/_no_ssh.html.haml b/app/views/shared/_no_ssh.html.haml
index 17ef5327341..5a36c37090e 100644
--- a/app/views/shared/_no_ssh.html.haml
+++ b/app/views/shared/_no_ssh.html.haml
@@ -1,9 +1,9 @@
- if show_no_ssh_key_message?
.no-ssh-key-message.alert.alert-warning
- - add_ssh_key_link = link_to s_('MissingSSHKeyWarningLink|add an SSH key'), profile_keys_path, class: 'alert-link'
+ - add_ssh_key_link = link_to s_('MissingSSHKeyWarningLink|add an SSH key'), settings_keys_path, class: 'alert-link'
- ssh_message = _("You won't be able to pull or push project code via SSH until you %{add_ssh_key_link} to your profile") % { add_ssh_key_link: add_ssh_key_link }
= ssh_message.html_safe
.alert-link-group
- = link_to _("Don't show again"), profile_path(user: {hide_no_ssh_key: true}), method: :put, class: 'alert-link'
+ = link_to _("Don't show again"), settings_path(user: {hide_no_ssh_key: true}), method: :put, class: 'alert-link'
|
= link_to _('Remind later'), '#', class: 'hide-no-ssh-message alert-link'
diff --git a/app/views/shared/_personal_access_tokens_table.html.haml b/app/views/shared/_personal_access_tokens_table.html.haml
index 823117f37ca..66cf8c776dd 100644
--- a/app/views/shared/_personal_access_tokens_table.html.haml
+++ b/app/views/shared/_personal_access_tokens_table.html.haml
@@ -29,7 +29,7 @@
- else
%span.token-never-expires-label= _('Never')
%td= token.scopes.present? ? token.scopes.join(", ") : _('<no scopes selected>')
- - path = impersonation ? revoke_admin_user_impersonation_token_path(token.user, token) : revoke_profile_personal_access_token_path(token)
+ - path = impersonation ? revoke_admin_user_impersonation_token_path(token.user, token) : revoke_settings_personal_access_token_path(token)
%td= link_to _('Revoke'), path, method: :put, class: "btn btn-danger float-right qa-revoke-button", data: { confirm: _('Are you sure you want to revoke this %{type} Token? This action cannot be undone.') % { type: type } }
- else
.settings-message.text-center
diff --git a/app/views/shared/_project_limit.html.haml b/app/views/shared/_project_limit.html.haml
index 2c52eccccb6..a7022f6f249 100644
--- a/app/views/shared/_project_limit.html.haml
+++ b/app/views/shared/_project_limit.html.haml
@@ -3,6 +3,6 @@
You won't be able to create new projects because you have reached your project limit.
.float-right
- = link_to "Don't show again", profile_path(user: {hide_project_limit: true}), method: :put, class: 'alert-link'
+ = link_to "Don't show again", settings_path(user: {hide_project_limit: true}), method: :put, class: 'alert-link'
|
= link_to 'Remind later', '#', class: 'hide-project-limit-message alert-link'
diff --git a/app/views/u2f/_register.html.haml b/app/views/u2f/_register.html.haml
index ef3835332a7..1eddc57e44d 100644
--- a/app/views/u2f/_register.html.haml
+++ b/app/views/u2f/_register.html.haml
@@ -31,7 +31,7 @@
.row.append-bottom-10
.col-md-12
%p= _("Your device was successfully set up! Give it a name and register it with the GitLab server.")
- = form_tag(create_u2f_profile_two_factor_auth_path, method: :post) do
+ = form_tag(create_u2f_settings_two_factor_auth_path, method: :post) do
.row.append-bottom-10
.col-md-3
= text_field_tag 'u2f_registration[name]', nil, class: 'form-control', placeholder: _("Pick a name")
diff --git a/app/views/users/show.html.haml b/app/views/users/show.html.haml
index b3a73030859..813f07d1fa5 100644
--- a/app/views/users/show.html.haml
+++ b/app/views/users/show.html.haml
@@ -12,7 +12,7 @@
.cover-block.user-cover-block{ class: [('border-bottom' if profile_tabs.empty?)] }
.cover-controls
- if @user == current_user
- = link_to profile_path, class: 'btn btn-default has-tooltip', title: s_('UserProfile|Edit profile'), 'aria-label': 'Edit profile' do
+ = link_to settings_path, class: 'btn btn-default has-tooltip', title: s_('UserProfile|Edit profile'), 'aria-label': 'Edit profile' do
= icon('pencil')
- elsif current_user
- if @user.abuse_report
diff --git a/config/routes.rb b/config/routes.rb
index 459f2b22bf0..79241b13a9e 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -180,7 +180,7 @@ Rails.application.routes.draw do
draw :uploads
draw :explore
draw :admin
- draw :profile
+ draw :settings
draw :dashboard
draw :group
draw :user
diff --git a/config/routes/profile.rb b/config/routes/settings.rb
index 83a2b33514b..b507ad6c486 100644
--- a/config/routes/profile.rb
+++ b/config/routes/settings.rb
@@ -1,7 +1,9 @@
# for secondary email confirmations - uses the same confirmation controller as :users
-devise_for :emails, path: 'profile/emails', controllers: { confirmations: :confirmations }
+devise_for :emails, path: 'settings/emails', controllers: { confirmations: :confirmations }
-resource :profile, only: [:show, :update] do
+# TODO: add /profile/* redirect to /settings/*
+
+resource :settings, only: [:show, :update] do
member do
get :audit_log
get :applications, to: 'oauth/applications#index'
diff --git a/db/schema.rb b/db/schema.rb
index 709f9ce2541..50a16201cc8 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -63,7 +63,6 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.datetime "updated_at"
t.string "home_page_url"
t.integer "default_branch_protection", default: 2
- t.text "help_text"
t.text "restricted_visibility_levels"
t.boolean "version_check_enabled", default: true
t.integer "max_attachment_size", default: 10, null: false
@@ -105,8 +104,6 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.integer "container_registry_token_expire_delay", default: 5
t.text "after_sign_up_text"
t.boolean "user_default_external", default: false, null: false
- t.boolean "elasticsearch_indexing", default: false, null: false
- t.boolean "elasticsearch_search", default: false, null: false
t.string "repository_storages", default: "default"
t.string "enabled_git_access_protocol"
t.boolean "domain_blacklist_enabled", default: false
@@ -128,37 +125,18 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.boolean "html_emails_enabled", default: true
t.string "plantuml_url"
t.boolean "plantuml_enabled"
- t.integer "shared_runners_minutes", default: 0, null: false
- t.bigint "repository_size_limit", default: 0
t.integer "terminal_max_session_time", default: 0, null: false
t.integer "unique_ips_limit_per_user"
t.integer "unique_ips_limit_time_window"
t.boolean "unique_ips_limit_enabled", default: false, null: false
t.string "default_artifacts_expire_in", default: "0", null: false
- t.string "elasticsearch_url", default: "http://localhost:9200"
- t.boolean "elasticsearch_aws", default: false, null: false
- t.string "elasticsearch_aws_region", default: "us-east-1"
- t.string "elasticsearch_aws_access_key"
- t.string "elasticsearch_aws_secret_access_key"
- t.integer "geo_status_timeout", default: 10
t.string "uuid"
t.decimal "polling_interval_multiplier", default: "1.0", null: false
- t.boolean "elasticsearch_experimental_indexer"
t.integer "cached_markdown_version"
- t.boolean "check_namespace_plan", default: false, null: false
- t.integer "mirror_max_delay", default: 300, null: false
- t.integer "mirror_max_capacity", default: 100, null: false
- t.integer "mirror_capacity_threshold", default: 50, null: false
t.boolean "prometheus_metrics_enabled", default: true, null: false
- t.boolean "authorized_keys_enabled", default: true, null: false
t.boolean "help_page_hide_commercial_content", default: false
t.string "help_page_support_url"
- t.boolean "slack_app_enabled", default: false
- t.string "slack_app_id"
- t.string "slack_app_secret"
- t.string "slack_app_verification_token"
t.integer "performance_bar_allowed_group_id"
- t.boolean "allow_group_owners_to_manage_ldap", default: true, null: false
t.boolean "hashed_storage_enabled", default: true, null: false
t.boolean "project_export_enabled", default: true, null: false
t.boolean "auto_devops_enabled", default: true, null: false
@@ -171,38 +149,22 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.boolean "throttle_authenticated_web_enabled", default: false, null: false
t.integer "throttle_authenticated_web_requests_per_period", default: 7200, null: false
t.integer "throttle_authenticated_web_period_in_seconds", default: 3600, null: false
+ t.boolean "password_authentication_enabled_for_web"
+ t.boolean "password_authentication_enabled_for_git", default: true, null: false
t.integer "gitaly_timeout_default", default: 55, null: false
t.integer "gitaly_timeout_medium", default: 30, null: false
t.integer "gitaly_timeout_fast", default: 10, null: false
- t.boolean "mirror_available", default: true, null: false
- t.boolean "password_authentication_enabled_for_web"
- t.boolean "password_authentication_enabled_for_git", default: true, null: false
+ t.boolean "authorized_keys_enabled", default: true, null: false
t.string "auto_devops_domain"
- t.boolean "external_authorization_service_enabled", default: false, null: false
- t.string "external_authorization_service_url"
- t.string "external_authorization_service_default_label"
t.boolean "pages_domain_verification_enabled", default: true, null: false
t.string "user_default_internal_regex"
t.boolean "allow_local_requests_from_hooks_and_services", default: false, null: false
- t.float "external_authorization_service_timeout", default: 0.5
- t.text "external_auth_client_cert"
- t.text "encrypted_external_auth_client_key"
- t.string "encrypted_external_auth_client_key_iv"
- t.string "encrypted_external_auth_client_key_pass"
- t.string "encrypted_external_auth_client_key_pass_iv"
- t.string "email_additional_text"
t.boolean "enforce_terms", default: false
- t.integer "file_template_project_id"
- t.boolean "pseudonymizer_enabled", default: false, null: false
+ t.boolean "mirror_available", default: true, null: false
t.boolean "hide_third_party_offers", default: false, null: false
- t.boolean "snowplow_enabled", default: false, null: false
- t.string "snowplow_collector_uri"
- t.string "snowplow_site_id"
- t.string "snowplow_cookie_domain"
t.boolean "instance_statistics_visibility_private", default: false, null: false
t.boolean "web_ide_clientside_preview_enabled", default: false, null: false
t.boolean "user_show_add_ssh_key_message", default: true, null: false
- t.integer "custom_project_templates_group_id"
t.integer "usage_stats_set_by_user_id"
t.integer "receive_max_input_size"
t.integer "diff_max_patch_bytes", default: 102400, null: false
@@ -212,11 +174,18 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.string "runners_registration_token_encrypted"
t.integer "local_markdown_version", default: 0, null: false
t.integer "first_day_of_week", default: 0, null: false
- t.boolean "elasticsearch_limit_indexing", default: false, null: false
t.integer "default_project_creation", default: 2, null: false
+ t.boolean "external_authorization_service_enabled", default: false, null: false
+ t.string "external_authorization_service_url"
+ t.string "external_authorization_service_default_label"
+ t.float "external_authorization_service_timeout", default: 0.5
+ t.text "external_auth_client_cert"
+ t.text "encrypted_external_auth_client_key"
+ t.string "encrypted_external_auth_client_key_iv"
+ t.string "encrypted_external_auth_client_key_pass"
+ t.string "encrypted_external_auth_client_key_pass_iv"
t.string "lets_encrypt_notification_email"
t.boolean "lets_encrypt_terms_of_service_accepted", default: false, null: false
- t.string "geo_node_allowed_ips", default: "0.0.0.0/0, ::/0"
t.integer "elasticsearch_shards", default: 5, null: false
t.integer "elasticsearch_replicas", default: 1, null: false
t.text "encrypted_lets_encrypt_private_key"
@@ -224,10 +193,42 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.string "required_instance_ci_template"
t.boolean "dns_rebinding_protection_enabled", default: true, null: false
t.boolean "default_project_deletion_protection", default: false, null: false
- t.boolean "grafana_enabled", default: false, null: false
t.boolean "lock_memberships_to_ldap", default: false, null: false
+ t.text "help_text"
+ t.boolean "elasticsearch_indexing", default: false, null: false
+ t.boolean "elasticsearch_search", default: false, null: false
+ t.integer "shared_runners_minutes", default: 0, null: false
+ t.bigint "repository_size_limit", default: 0
+ t.string "elasticsearch_url", default: "http://localhost:9200"
+ t.boolean "elasticsearch_aws", default: false, null: false
+ t.string "elasticsearch_aws_region", default: "us-east-1"
+ t.string "elasticsearch_aws_access_key"
+ t.string "elasticsearch_aws_secret_access_key"
+ t.integer "geo_status_timeout", default: 10
+ t.boolean "elasticsearch_experimental_indexer"
+ t.boolean "check_namespace_plan", default: false, null: false
+ t.integer "mirror_max_delay", default: 300, null: false
+ t.integer "mirror_max_capacity", default: 100, null: false
+ t.integer "mirror_capacity_threshold", default: 50, null: false
+ t.boolean "slack_app_enabled", default: false
+ t.string "slack_app_id"
+ t.string "slack_app_secret"
+ t.string "slack_app_verification_token"
+ t.boolean "allow_group_owners_to_manage_ldap", default: true, null: false
+ t.string "email_additional_text"
+ t.integer "file_template_project_id"
+ t.boolean "pseudonymizer_enabled", default: false, null: false
+ t.boolean "snowplow_enabled", default: false, null: false
+ t.string "snowplow_collector_uri"
+ t.string "snowplow_site_id"
+ t.string "snowplow_cookie_domain"
+ t.integer "custom_project_templates_group_id"
+ t.boolean "elasticsearch_limit_indexing", default: false, null: false
+ t.string "geo_node_allowed_ips", default: "0.0.0.0/0, ::/0"
t.boolean "time_tracking_limit_to_hours", default: false, null: false
+ t.boolean "grafana_enabled", default: false, null: false
t.string "grafana_url", default: "/-/grafana", null: false
+ t.boolean "login_recaptcha_protection_enabled", default: false, null: false
t.string "outbound_local_requests_whitelist", limit: 255, default: [], null: false, array: true
t.integer "raw_blob_request_limit", default: 300, null: false
t.index ["custom_project_templates_group_id"], name: "index_application_settings_on_custom_project_templates_group_id"
@@ -409,10 +410,10 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.integer "project_id"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
- t.string "name", default: "Development", null: false
- t.integer "milestone_id"
t.integer "group_id"
+ t.integer "milestone_id"
t.integer "weight"
+ t.string "name", default: "Development", null: false
t.index ["group_id"], name: "index_boards_on_group_id"
t.index ["milestone_id"], name: "index_boards_on_milestone_id"
t.index ["project_id"], name: "index_boards_on_project_id"
@@ -2154,6 +2155,8 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.boolean "membership_lock", default: false
t.integer "last_ci_minutes_usage_notification_level"
t.integer "subgroup_creation_level", default: 1
+ t.index "lower((name)::text)", name: "index_on_namespaces_lower_name"
+ t.index "lower((path)::text)", name: "index_on_namespaces_lower_path"
t.index ["created_at"], name: "index_namespaces_on_created_at"
t.index ["custom_project_templates_group_id", "type"], name: "index_namespaces_on_custom_project_templates_group_id_and_type", where: "(custom_project_templates_group_id IS NOT NULL)"
t.index ["file_template_project_id"], name: "index_namespaces_on_file_template_project_id"
@@ -2568,7 +2571,7 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.index ["project_id"], name: "index_project_import_data_on_project_id"
end
- create_table "project_incident_management_settings", primary_key: "project_id", id: :serial, force: :cascade do |t|
+ create_table "project_incident_management_settings", primary_key: "project_id", id: :integer, default: nil, force: :cascade do |t|
t.boolean "create_issue", default: true, null: false
t.boolean "send_email", default: false, null: false
t.text "issue_template_key"
@@ -2724,6 +2727,8 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.boolean "reset_approvals_on_push", default: true
t.boolean "service_desk_enabled", default: true
t.integer "approvals_before_merge", default: 0, null: false
+ t.index "lower((name)::text)", name: "index_projects_on_lower_name"
+ t.index "lower((path)::text)", name: "index_on_projects_lower_path"
t.index ["archived", "pending_delete", "merge_requests_require_code_owner_approval"], name: "projects_requiring_code_owner_approval", where: "((pending_delete = false) AND (archived = false) AND (merge_requests_require_code_owner_approval = true))"
t.index ["created_at"], name: "index_projects_on_created_at"
t.index ["creator_id"], name: "index_projects_on_creator_id"
@@ -2918,7 +2923,10 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.string "path", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
+ t.index "lower((path)::text) varchar_pattern_ops", name: "index_redirect_routes_on_path_unique_text_pattern_ops", unique: true
+ t.index "lower((path)::text)", name: "index_on_redirect_routes_lower_path"
t.index ["path"], name: "index_redirect_routes_on_path", unique: true
+ t.index ["path"], name: "index_redirect_routes_on_path_text_pattern_ops", opclass: :varchar_pattern_ops
t.index ["source_type", "source_id"], name: "index_redirect_routes_on_source_type_and_source_id"
end
@@ -3012,6 +3020,7 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.datetime "created_at"
t.datetime "updated_at"
t.string "name"
+ t.index "lower((path)::text)", name: "index_on_routes_lower_path"
t.index ["path"], name: "index_routes_on_path", unique: true
t.index ["path"], name: "index_routes_on_path_text_pattern_ops", opclass: :varchar_pattern_ops
t.index ["source_type", "source_id"], name: "index_routes_on_source_type_and_source_id", unique: true
@@ -3118,6 +3127,9 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.integer "cached_markdown_version"
t.text "description"
t.text "description_html"
+ t.string "encrypted_secret"
+ t.string "encrypted_secret_iv"
+ t.string "encrypted_secret_salt"
t.index ["author_id"], name: "index_snippets_on_author_id"
t.index ["file_name"], name: "index_snippets_on_file_name_trigram", opclass: :gin_trgm_ops, using: :gin
t.index ["project_id"], name: "index_snippets_on_project_id"
@@ -3442,6 +3454,9 @@ ActiveRecord::Schema.define(version: 2019_07_31_084415) do
t.text "note"
t.integer "roadmap_layout", limit: 2
t.integer "bot_type", limit: 2
+ t.index "lower((email)::text)", name: "index_on_users_lower_email"
+ t.index "lower((name)::text)", name: "index_on_users_name_lower"
+ t.index "lower((username)::text)", name: "index_on_users_lower_username"
t.index ["accepted_term_id"], name: "index_users_on_accepted_term_id"
t.index ["admin"], name: "index_users_on_admin"
t.index ["bot_type"], name: "index_users_on_bot_type"
diff --git a/locale/gitlab.pot b/locale/gitlab.pot
index 117625e717f..ca56cf15010 100644
--- a/locale/gitlab.pot
+++ b/locale/gitlab.pot
@@ -5380,7 +5380,7 @@ msgstr ""
msgid "GroupsTree|Search by name"
msgstr ""
-msgid "HTTP Basic: Access denied\\nYou must use a personal access token with 'api' scope for Git over HTTP.\\nYou can generate one at %{profile_personal_access_tokens_url}"
+msgid "HTTP Basic: Access denied\\nYou must use a personal access token with 'api' scope for Git over HTTP.\\nYou can generate one at %{settings_personal_access_tokens_url}"
msgstr ""
msgid "Header logo was successfully removed."
diff --git a/qa/qa/page/profile/menu.rb b/qa/qa/page/profile/menu.rb
index 2d503499e13..423053f80c5 100644
--- a/qa/qa/page/profile/menu.rb
+++ b/qa/qa/page/profile/menu.rb
@@ -5,7 +5,7 @@ module QA
module Profile
class Menu < Page::Base
view 'app/views/layouts/nav/sidebar/_profile.html.haml' do
- element :access_token_link, 'link_to profile_personal_access_tokens_path' # rubocop:disable QA/ElementWithPattern
+ element :access_token_link, 'link_to settings_personal_access_tokens_path' # rubocop:disable QA/ElementWithPattern
element :access_token_title, 'Access Tokens' # rubocop:disable QA/ElementWithPattern
element :top_level_items, '.sidebar-top-level-items' # rubocop:disable QA/ElementWithPattern
element :ssh_keys, 'SSH Keys' # rubocop:disable QA/ElementWithPattern
diff --git a/qa/qa/runtime/browser.rb b/qa/qa/runtime/browser.rb
index 2987bb1a213..b8e671e9179 100644
--- a/qa/qa/runtime/browser.rb
+++ b/qa/qa/runtime/browser.rb
@@ -89,7 +89,7 @@ module QA
# Use the same profile on QA runs if CHROME_REUSE_PROFILE is true.
# Useful to speed up local QA.
if QA::Runtime::Env.reuse_chrome_profile?
- qa_profile_dir = ::File.expand_path('../../tmp/qa-profile', __dir__)
+ qa_settings_dir = ::File.expand_path('../../tmp/qa-profile', __dir__)
options.add_argument("user-data-dir=#{qa_profile_dir}")
end