Skip to content

Instantly share code, notes, and snippets.

View lemenkov's full-sized avatar

Peter Lemenkov lemenkov

View GitHub Profile
@lemenkov
lemenkov / gist:2049881
Created March 16, 2012 12:34
How to record screen
ffmpeg -y -r 25 -s 1280x1024 -f x11grab -i :0.0+0,0 -vcodec libvpx ~/screen.webm
ffmpeg -y -r 25 -s 1280x1024 -f x11grab -i :0.0+0,0 -vcodec libx264 -vpre lossless_ultrafast ~/screen.mp4
@lemenkov
lemenkov / gist:2947110
Last active July 19, 2021 14:05
How to convert from any video format to mkv with ffmpeg/libav w/o recompressing
# "-fflags +genpts" - add this to regenerate packet timestamps (in case of error "Can't write packet with unknown timestamp")
./ffmpeg -fflags +genpts -i "/media/nfs/Nostromo/video/Japan Sinks (Nihon Chinbotsu) 1973 - WMV/NihonChinbotsu_1973.wmv" -acodec copy -vcodec copy ~/Desktop/NihonChinbotsu_1973.mkv
@lemenkov
lemenkov / gist:3713262
Created September 13, 2012 09:44
How to verify SSL cert against a given Root cert
# CA-bundle -> Public Cert.
openssl verify -CAfile ~/your-ca-bundle.crt ~/your-cert.crt
@lemenkov
lemenkov / sdp rtp ids
Created December 28, 2012 08:51
Random SDP payload codes
0 PCMU/8000
0 PCMU/8000/1
2 G721/8000
2 G721/8000/1
2 G726-32/8000
2 G726-32/8000/1
3 GSM/8000
4 g723/8000
4 G723/8000
4 G723/8000/1
set terminal png
set output "output.png"
plot "~/feat.txt" u 1:2 with lines t 'Number of Features in Fedora' ; set xlabel "Release number" ; set ylabel "Features number" ; set xrange [6:20] ; set yrange [10:100] ; set xtics 1 ; set datafile separator ","
replot
@lemenkov
lemenkov / gist:5101234
Created March 6, 2013 17:32
Post-install tasks
yum remove sendmail
yum remove Net*
yum install vim-enhanced ssmtp fvwm xorg-x11-server-Xorg rxvt-unicode firefox git
yum install xorg-x11-drv-evdev xorg-x11-drv-intel
yum install net-tools avahi nss-mdns mc
yum install xorg-x11-xdm
@lemenkov
lemenkov / gist:5821575
Created June 20, 2013 09:53
How to mount SAMBA resource w/o password and w/o knowing SAMBA shares' names
$ sudo yum install cifs-utils samba-client
$ smbclient -L 192.168.100.1
Enter petro's password: <press enter for empty password>
Domain=[TIHON] OS=[Windows 7 Ultimate 7601 Service Pack 1] Server=[Windows 7 Ultimate 6.1]
Sharename Type Comment
--------- ---- -------
ADMIN$ Disk Удаленный Admin
Bin.Win32 Disk
C$ Disk Стандартный общий ресурс
rpmbuild -bs erlang.spec --define '%el6 1'
work ~: gnuplot
gnuplot> set autoscale
gnuplot> plot "results.sched_default" every::15000::50000 using 2 with lines , "results.sched_high" every::15000::50000 using 2 with lines , "results.sched_low" every::15000::50000 using 2 with lines
gnuplot> replot
@lemenkov
lemenkov / gist:6048791
Last active December 20, 2015 01:28
Fedora PPC Koji hub nano-HOWTO
* "real" build
fedpkg clone mypackage
cd mypackage
koji-ppc build rawhide "$(fedpkg giturl)"
* scratchbuild:
koji-ppc build --scratch rawhide /path/to/yourpkg.src.rpm