1 of 42

Youtube 不要砍我影片R

海豹

2 of 42

About me

  • CV: https://seadog007.work
  • About Me: https://seadog007.me A

3 of 42

蛤???

A project that can let you mirror Youtube to your Google Drive from the video list you give.

4 of 42

Why?

5 of 42

6 of 42

7 of 42

8 of 42

“$VIDEO_NAME”The YouTube account associated with this video has been terminated due to multiple third-party notifications of copyright infringement.

This video is no longer available because the YouTube account associated with this video has been terminated.

This video has been removed for violating YouTube’s Community Guidelines.

This video has been removed for violating YouTube’s policy on harmful or dangerous content.

“$VIDEO_NAME” This video is no longer available due to a copyright claim by $COMPANY_NAME.

This video has been removed for violating YouTube’s policy on nudity or sexual content.

9 of 42

Storage?

10 of 42

11 of 42

Shell Script

12 of 42

gdrive mkdir -p \`cat ../index.json | jq -r '."'${line:0:1}'"."'${line:1:1}'"'\` $line | sed -e "s/Directory\ //" -e "s/\ created//"

13 of 42

cat ../index.json | jq -r '."'${line:0:1}'"."'${line:1:1}'"'

14 of 42

awk 'NR==FNR{a[$0]=1;next}!a[$0]' log "$1" > new_query

15 of 42

GitHub: seadog007/Youtube_Cloner

16 of 42

17 of 42

Time Cost: 1 hr

18 of 42

19 of 42

20 of 42

21 of 42

Telegram Bot

22 of 42

23 of 42

How to create a “Bash” Telegram Bot in 2 minutes in 5 lines

海豹

24 of 42

Code

1 while true

2 do

3 who=`who` && [ $? -eq 0 ] && [ "$who" != "$lastwho" ] && curl --data "chat_id=80973595&text=$who" -X GET https://api.telegram.org/bot_token/sendMessage && lastwho=$who

4 sleep 1

5 done

25 of 42

Compressed

while true; do; who=`who` && [ $? -eq 0 ] && [ "$who" != "$lastwho" ] && curl --data "chat_id=80973595&text=$who" -X GET https://api.telegram.org/bot_token/sendMessage && lastwho=$who; sleep 1; done

26 of 42

1. Prepare Bot Token

Telegram: @botfather

Live Demo

27 of 42

2. Get Your User ID

Telegram: @RawDataBot

Live Demo

28 of 42

3. Fetch Your Data

who=`who`

29 of 42

4. Comparing Your Data

[ $? -eq 0 ] && [ "$who" != "$lastwho" ]

30 of 42

5. Send the Message

curl --data "chat_id=id&text=$who" -X GET https://api.telegram.org/bot_token/sendMessage

31 of 42

6. Put it in a Loop

While true�do

done

32 of 42

Time Cost: 1 min

33 of 42

Web Interface

https://seadog007.download/

34 of 42

35 of 42

36 of 42

ETH Address???

37 of 42

Time Cost: 2 hr

38 of 42

分散式架構

39 of 42

55%

40 of 42

Master

100%

Worker

10%

41 of 42

GPG Implentment

42 of 42

Time Cost: > 1 hr