Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
tails
tails
Commits
cc729b82
Commit
cc729b82
authored
Sep 15, 2015
by
anonym
Browse files
Allow '+' and ':' in video capture filenames.
This makes timestamps and timezone info easier to read.
parent
4546a8f6
Changes
1
Hide whitespace changes
Inline
Side-by-side
features/support/hooks.rb
View file @
cc729b82
...
...
@@ -114,7 +114,7 @@ Before('@product') do |scenario|
if
$config
[
"CAPTURE"
]
video_name
=
"capture-"
+
"
#{
scenario
.
name
}
-
#{
TIME_AT_START
}
.mkv"
# Sanitize the filename from unix-hostile filename characters
bad_filename_chars
=
Regexp
.
new
(
"[^A-Za-z0-9_
\\
-.,]"
)
bad_filename_chars
=
Regexp
.
new
(
"[^A-Za-z0-9_
\\
-.,
+:
]"
)
video_name
.
gsub!
(
bad_filename_chars
,
'_'
)
@video_path
=
"
#{
$config
[
'TMPDIR'
]
}
/
#{
video_name
}
"
capture
=
IO
.
popen
([
'avconv'
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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