本網站在啟用 JavaScript 的情況下可以運作的更好。
首頁
探索
說明
登入
JustAnotherArchivist
/
little-things
關注
2
收藏
0
複製
0
程式碼
問題
0
合併請求
0
版本發佈
0
Wiki
活動
瀏覽代碼
Fix removenonyt performance by using simpler fixed-string patterns instead of a PCRE
master
JustAnotherArchivist
2 年之前
父節點
b27a428787
當前提交
6d019e63fc
共有
1 個檔案被更改
,包括
1 行新增
和
1 行删除
分割檢視
Diff Options
Show Stats
Download Patch File
Download Diff File
+1
-1
youtube-extract
+ 1
- 1
youtube-extract
查看文件
@@ -23,7 +23,7 @@ domainPattern = re.compile(r'/(www\.|m\.)?(youtube\.(com|de|fr|co\.uk|it|es|at|p
if mode == 'removenonyt':
# Anything in here could never be as fast as grep, so just delegate to that...
os.execlp('grep', 'grep', '-
P', domainPattern.pattern + '|' + domainPattern.pattern.replace('/', '%2F') + '|/youtu\.be/|%2Fyoutu\.be%2F
')
os.execlp('grep', 'grep', '-
Fai', '-e', 'youtube', '-e', 'youtu.be', '-e', 'ytimg.com', '-e', '?v=', '-e', '%3Fv%3D', '-e', '&v=', '-e', '%26v%3D
')
sys.exit(0)
assert mode == 'massage'
Write
Preview
Loading…
取消
儲存