Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
86a8955c
Commit
86a8955c
authored
Aug 26, 2018
by
Jasper Maes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rails 5: replace removed silence_stream
parent
68b84d81
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
1 deletion
+17
-1
changelogs/unreleased/rails5-silence-stream.yml
changelogs/unreleased/rails5-silence-stream.yml
+5
-0
lib/tasks/gettext.rake
lib/tasks/gettext.rake
+12
-1
No files found.
changelogs/unreleased/rails5-silence-stream.yml
0 → 100644
View file @
86a8955c
---
title
:
'
Rails
5:
replace
removed
silence_stream'
merge_request
:
21387
author
:
Jasper Maes
type
:
other
lib/tasks/gettext.rake
View file @
86a8955c
...
...
@@ -82,7 +82,7 @@ namespace :gettext do
# `gettext:find` writes touches to temp files to `stderr` which would cause
# `static-analysis` to report failures. We can ignore these.
silence_s
tream
(
$stderr
)
do
silence_s
dterr
do
Rake
::
Task
[
'gettext:find'
].
invoke
end
...
...
@@ -118,4 +118,15 @@ namespace :gettext do
end
end
end
def
silence_sdterr
(
&
block
)
old_stderr
=
$stderr
.
dup
$stderr
.
reopen
(
File
::
NULL
)
$stderr
.
sync
=
true
yield
ensure
$stderr
.
reopen
(
old_stderr
)
old_stderr
.
close
end
end
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