This file contains 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
sudo wget -4 https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl | |
sudo chmod a+rx /usr/local/bin/youtube-dl |
This file contains 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
#Youtube 1 : General | |
youtube-dl -4 --restrict-filenames --output "[%(uploader)s] %(title)s (%(id)s).%(ext)s" | |
#Youtube 2 : Music Videos | |
youtube-dl -4 -f bestvideo+bestaudio --restrict-filenames --add-metadata --output "%(title)s [%(uploader)s][%(upload_date)s][%(duration)s][%(id)s].%(ext)s" | |
#Programming 1 : Last file by extention | |
ls -t *py | head -1 | tr -d '\n' | xsel -ib | |
#Programming 2 : Last file by name | |
find -name "*06-27*" -printf "%f\n" | tr -d '\n' | xsel -ib | |
#Programming 3 : Las file by time | |
fc -ln -1 | xargs | tr -d '\n' | xsel -ib |
This file contains 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
def aBaR(n,e,f=None): | |
if f == None: | |
try: | |
print ("Array: {}\nType: {}\nShape: {}\nLength: {}\nFirst Data: {}\n".format(n,type(e),str(np.shape(e)),len(e),str(e[0]))) | |
except IndexError: | |
print ("Array: {}\nType: {}\nShape: {}\nLength: {}\n".format(n,type(e),str(np.shape(e)),len(e))) | |
else: | |
print ("Array: {}\nType: {}\nShape: {}\nLength: {}\nData: {}\n".format(n,type(e),str(np.shape(e)),len(e),str(e))) |
This file contains 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
def | |
def getAccounts(): | |
with open('./ig.txt') as f: | |
lines = f.read().splitlines() | |
return lines | |
def main(): | |
accs = getAccounts() |
This file contains 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
def newSection(): | |
def terminal_size(): | |
import fcntl, termios, struct | |
h, w, hp, wp = struct.unpack('HHHH', | |
fcntl.ioctl(0, termios.TIOCGWINSZ, | |
struct.pack('HHHH', 0, 0, 0, 0))) | |
return w | |
ter_int = terminal_size() | |
print ("\n" + ("_" * (int(ter_int))) + "\n\n") | |