Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Lyse
boydl
Commits
79d9acc8
Commit
79d9acc8
authored
Jun 19, 2012
by
Lysander Trischler
Browse files
Fix whitespace
parent
c7686e44
Changes
1
Hide whitespace changes
Inline
Side-by-side
boydl
View file @
79d9acc8
...
...
@@ -79,7 +79,7 @@ for item in channel.getElementsByTagName("item"):
m
=
link_regex
.
search
(
item
.
getElementsByTagName
(
"description"
)[
0
].
firstChild
.
data
)
if
m
:
url
=
m
.
group
(
1
)
#
# if description link cannot be parsed use feed proxy's URL
#
...
...
@@ -89,7 +89,7 @@ for item in channel.getElementsByTagName("item"):
me
,
item
.
getElementsByTagName
(
'title'
)[
0
].
firstChild
.
data
)),
url
=
item
.
getElementsByTagName
(
"link"
)[
0
].
firstChild
.
data
print
(
url
)
#
# skip already downloaded videos
# Always read the index newly so parallel running boydls may
...
...
@@ -99,7 +99,7 @@ for item in channel.getElementsByTagName("item"):
# therefore fetch the video twice or more often. Because this
# scenario is considered to happen only very rarly we don't
# care about it here. Most of the time this holds.
#
#
cont
=
False
index_stream
=
open
(
index_file
,
"rb"
)
for
line
in
index_stream
.
readlines
():
...
...
@@ -144,7 +144,7 @@ for item in channel.getElementsByTagName("item"):
index_stream
=
open
(
index_file
,
"ab"
)
index_stream
.
write
(
"%s
\n
"
%
url
)
index_stream
.
close
()
cmd
=
ydl
+
' '
+
yurl
print
(
'—'
*
80
)
exit_code
=
os
.
system
(
cmd
)
%
255
...
...
@@ -153,4 +153,3 @@ for item in channel.getElementsByTagName("item"):
error_stream
=
open
(
error_file
,
"ab"
)
error_stream
.
write
(
"%s
\t
%s
\t
%d
\n
"
%
(
url
,
cmd
,
exit_code
))
error_stream
.
close
()
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