This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import logging | |
import os | |
import requests | |
logging.basicConfig(level=logging.DEBUG) | |
class DownloadSession(requests.Session): | |
buffer_size = 1024 * 1024 | |
def __init__(self, user, password): | |
super(DownloadSession, self).__init__() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "Terminal" | |
activate | |
-- set profile buzz | |
tell me to set buzz to path to resource "dl.sh" as text | |
do script "cd ~/Downloads && bash " & quoted form of the POSIX path of buzz & " && say Buzz done" | |
-- close profile buzz window | |
end tell |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function canFullScreen() { | |
return document.body.webkitRequestFullScreen || | |
document.body.requestFullScreen || | |
document.body.mozRequestFullScreen; | |
} | |
function isFullScreen() { | |
return document.fullScreenElement || | |
document.mozFullScreen || |