Skip to content

Instantly share code, notes, and snippets.

View maikonalexandre's full-sized avatar
🌪️
Cooking new apps

Maikon Alexandre maikonalexandre

🌪️
Cooking new apps
View GitHub Profile
@thelinuxlich
thelinuxlich / assertHTTP.ts
Last active February 23, 2024 19:45
A assert on steroids for web services
import { getReasonPhrase } from 'http-status-codes'
export type ALLOWED_HTTP_STATUS_CODES =
| '400'
| '401'
| '403'
| '404'
| '500'
| '501'
| '502'
@lalizita
lalizita / ffmpeg_video_examples.sh
Created October 24, 2023 22:38
ffmpeg scripts for video processing
# Cut/Trim video
ffmpeg -ss 5 -i input.mp4 -to 10 output.mp4
# Video to gif
ffmpeg -ss 61.0 -t 2.5 -i <input> -filter_complex "[0:v] fps=12,scale=w=480:h=-1,split [a][b];[a] palettegen=stats_mode=single [p];[b][p] paletteuse=new=1" output.gif
# thumbnail
ffmpeg -i mov_bbb.mp4 -ss 00:00:03 -r 1 -s 1280x720 -f image2 thumb_mov.jpeg
#text in video