-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathvideo_uploader.py
35 lines (29 loc) · 1.5 KB
/
video_uploader.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#from uploader import resumable_upload
from video_generator import generate_video
import os
def upload_video():
#video_file = "youtube_video.mp4"
video_file_title = generate_video()
video_file = video_file_title["video"]
keywords = "reddit, writing, writing prompts, prompt, python, bot, api, github, text, to, speech"
#title = "EPIC Title"
title = video_file_title["title"]
title = "Writing Prompts from Reddit, Python " + title + " ... "
github_repo = " https://github.com/Sarthakdtu/Auto_YouTube_Video_Uploader "
description = "This is a video generated by using a text to speech python "
description += "library and both audio and video is generated using python. "
description += "The code for this video can be found on the github repository " + github_repo +" "
description += "The text for this is scrapped from reddit Writing Prompts subreddit (r/WritingPrompts)."
description += " Go and check taht out. Subscribe for more dull and monotonous reddit content.\n"
description += "Be EPIC"
category = "22"
privacy_status = "public"
exec_file = 'python uploader.py '
exec_file += ' --file=' + '"' +video_file + '"'
exec_file += ' --title=' + '"' + title + '"'
exec_file += ' --description=' + '"' + description + '"'
exec_file += ' --keywords=' + '"' + keywords + '"'
exec_file += ' --privacyStatus=' + '"' + privacy_status + '"'
exec_file += ' --category=' + '"' + category + '"'
return exec_file
os.system(upload_video())