Sha256: 0cd2f93429a1095606a898ebb19efc9d2655cfa59382fcca9d45f5b7907d4037

Contents?: true

Size: 1000 Bytes

Versions: 50

Compression:

Stored size: 1000 Bytes

Contents

#!/usr/bin/env ruby
# frozen_string_literal: true

require 'colored'
topics = []
$stdin.each_line do |topic|
  topics.push topic
  begin
    system 'tput civis'

    # i = top

    i = topic

    puts topic.cyan
    str = <<~EOF
      green() {
      	echo -ne "\e[32m$1\e[0m"
      }


      timeout 550s padsp ffmpeg -f alsa -ac 2 -i pulse -f x11grab -r 15 -s 1366x768 -i :0.0 -acodec pcm_s16le -vcodec libx264 -preset ultrafast -crf 0 -threads 0 output#{i.chomp}.mkv -y -loglevel quiet &
      # && echo Video done) & 2>/dev

      let i=0
      while true; do
      	let i=$i+1
      	let minutes=$i/60
      	let seconds=($i)%60
      	green "$i/550 seconds of video, $minutes $seconds\r"
      	sleep 1
      done
      done
    EOF

    File.write('/tmp/screencast', str)
    system 'bash /tmp/screencast'; rescue Interrupt
                                     system 'killall ffmpeg -9 -q'
                                     system 'tput cnorm'
  end
end

system 'clear'

puts topics.green

Version data entries

50 entries across 49 versions & 6 rubygems

Version Path
aliens-1.0.72 ./other/experimental_code/youtube_video
freespeech-1.0.72 ./other/experimental_code/youtube_video
freespeech-1.0.71 ./other/experimental_code/youtube_video
elonmusk-1.0.71 ./other/experimental_code/youtube_video
ufos-1.0.71 ./other/experimental_code/youtube_video
aliens-1.0.71 ./other/experimental_code/youtube_video
elonmusk-1.0.56 ./de/other/experimental_code/youtube_video
elonmusk-1.0.56 ./other/experimental_code/youtube_video
elonmusk-1.0.53 ./other/experimental_code/youtube_video
elonmusk-1.0.43 ./other/experimental_code/youtube_video