Yen Chi Hsuan
efa97bdcf1
Move write_xattr to utils.py
There are some other places that use xattr functions. It's better to
move it to a common place so that others can use it.
8 years ago
Yen Chi Hsuan
e9c0cdd389
[jython] Introduce compat_os_name
os.name is always 'java' on Jython
8 years ago
Sergey M․
611c1dd96e
[refactor] Single quotes consistency
8 years ago
Yen Chi Hsuan
c827d4cfdb
[xattr] Enhanced error messages on Windows
9 years ago
Yen Chi Hsuan
fbff30d2db
[xattr] Catch 'Argument list too long'
9 years ago
Yen Chi Hsuan
86c7fdb17c
[xattr] Enhance error handling to catch ENOSPC
Fixes #5589
9 years ago
Sergey M․
4515cb43ca
[xattrpp] Fix typo
9 years ago
Yen Chi Hsuan
8c8826176d
[xattr] Add version detection for python-pyxattr
For more information, see #5498 and changes to convertObj() in
iustin/pyxattr@cc84e466f63906d32ec1bf4a4fcae6a7bce9a4c8
9 years ago
Jaime Marquínez Ferrándiz
592e97e855
Postprocessors: use a list for the files that can be deleted
We could only know if we had to delete the original file, but this system allows to specify us more files (like subtitles).
9 years ago
Philipp Hagemeister
dcddc10a50
[test_unicode_literals] Arm unicode_literals check
From now on, the line
from __future__ import unicode_literals
should be contained in every single Python file lest we run into any more 2.x/3.x issues.
Going forward, we're likely to develop on 3.x only and would likely miss subtle bugs otherwise.
10 years ago
Jouke Waleson
5f6a1245ff
PEP8 applied
10 years ago
Philipp Hagemeister
8c25f81bee
[util] Move compatibility functions out of util
utils is large enough without these compatibility functions.
Everything that is present in newer versions of Python (i.e. with dev Python it's just an import) goes into compat.py .
Everything else (i.e. youtube-dl-specific helpers) goes into utils.py .
10 years ago
Philipp Hagemeister
0a871f6880
Provide compatibility check_output for 2.6 ( Fixes #2926 )
10 years ago
Philipp Hagemeister
bd1b906527
Remove unusued import
11 years ago
Philipp Hagemeister
a9ce0c631e
[xattr] Correct on Windows
11 years ago
Philipp Hagemeister
afc7bc33cb
[xattr] Always use UTF-8
On Windows and other systems, other encodings would break when trying to encode non-ASCII characters.
Simply use UTF-8, like every sane system.
11 years ago
Philipp Hagemeister
168da92b9a
[xattr] Rework
In particular, explicitly require NT before trying ADS, and do not try to parse process output that may be localized.
11 years ago
Philipp Hagemeister
2a2e2770cc
[xattr] Always output a warning message on errors
11 years ago
Philipp Hagemeister
42cc71e80b
[xattr] Write bytestrings, not characters
11 years ago
Philipp Hagemeister
496c19234c
Split postprocessor package into multiple modules
11 years ago