Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
heptapod
heptapod
Commits
086bb9aa352e
Commit
e8584548
authored
Dec 20, 2017
by
Douglas Barbosa Alexandre
Browse files
Handle exceptions when writing to .git/config
parent
524cf7684def
Changes
1
Hide whitespace changes
Inline
Side-by-side
app/models/project.rb
View file @
086bb9aa
...
...
@@ -1440,6 +1440,9 @@ def after_rename_repo
def
write_repository_config
(
key
,
value
,
prefix: :gitlab
)
key
=
[
prefix
,
key
].
compact
.
join
(
'.'
)
repo
.
config
[
key
]
=
value
rescue
Gitlab
::
Git
::
Repository
::
NoRepository
=>
e
Rails
.
logger
.
error
(
"Error writing key
#{
key
}
to .git/config for project
#{
full_path
}
(
#{
id
}
):
#{
e
.
message
}
."
)
nil
end
def
rename_repo_notify!
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment