Guest User

Youtube/Twitter Archive

a guest
Jun 21st, 2022
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.72 KB | None | 0 0
  1. Youtube
  2. Download yt-dlp or ytarchive and ffmpeg. Those have instructions already so I'll skip that. yt-dlp has an argument that allows it to function like ytarchive though I've never tested it. Once they're ready you can open up task scheduler
  3. Create New task. Name it whatever you like. Go to Triggers tab on top. Create new trigger. Set it to On a schedule, Daily, start time whenever you want, recur every 1 day.
  4. In advanced, repeat task every 15 minutes for a duration of 1 day, and tick Enabled. Ok window
  5. Go to the Actions tab and create new action. Start a program and select the ytarchive,exe. For arguments, it'll be quite the dump. I use this for a dedicated archive drive
  6. --cookies <path to cookies.txt> --merge --output "N:\Archive\%(channel)s\%(upload_date)s\%(title)s - [%(id)s] - [%(upload_date)s]\%(title)s" --retry-stream 15 --threads 3 --thumbnail --write-description --write-thumbnail https://www.youtube.com/channel/UCO_aKKYxn4tvrqPjcTzZ6EQ/live best
  7. Get your cookies from the cookies.txt addon used on youtube. Place it with the yt-dlp/ytarchive exes. merge will merge audio and video. You'll want to customize the output path in the beginning, but after Archive\ it'll create a folder with the channel name, then a folder inside with upload date, then inside with a stream title/ID/date, with the actual stream, thumbnail, and description being inside that. Threads determines how many download threads it'll do. The next three are self explanatory. The url is Fauna's channel url with /live on the end to always link to the current live stream. ytarchive handles live links well so it works out. best at the end will max out the stream quality, so if you want a lower quality archive you'll want to look that up. Confirm all that. Skip conditions. Settings tab: Enable Allow task to be run on demand, If the running task..., and if the task is already running do not start a new instance. Confirm all that, start the task, and run it. It should open up a command prompt window that says "You have opted to wait for a livestream to be scheduled. Waiting every 15 seconds." If you get that, then go back into the task's properties and choose "Run whether user is logged on or not" under general. That'll make it so future runs of the task are ran in the background instead of foreground. You can see them in task manager.
  8.  
  9. Twitter Space
  10. Install Node.js and FFMPEG as you normally would
  11. https://github.com/HitomaruKonpaku/twspace-crawler/blob/master/INSTALLATION.md
  12. I don't know the intricacies of linux, but for windows skip installing twspace-crawler for now. Install pm2 from this
  13. https://github.com/jessety/pm2-installer
  14. Skip down to windows install, open an admin cmd prompt, navigate to the downloaded folder and run the commands instructed
  15. node files should be in the equivalent of programdata/npm instead of roaming. You can replace the shortcut to pm2-installer with the originally downloaded folders if you want
  16. Go ahead and follow the twspace-crawler instructions now to install it. Get your .env and your config json from the github and paste them into the twspace-crawler directory inside npm. Follow the instructions to get your twitter API information for the .env and prune the config how you want it
  17. Get the ecosystem config from the pm2 section now. I changed the script section to the absolute path of the index,js. Should be twspace-crawler/dist/index,js
  18. I also changed the args to the absolute paths of the config and env
  19. in the elevated cmd, do pm2 start ecosystem,config,js, then pm2 save
  20. When you run pm2 list, it should look something like this
  21. https://litter.catbox.moe/n0yxm0.png (embed)
  22. Try restarting your PC and checking if the crawler is online after a couple minutes. Any time you interact with pm2 you'll need to be in an elevated cmd
Add Comment
Please, Sign In to add comment