Skip to content

Instantly share code, notes, and snippets.

View pemre's full-sized avatar

Emre Piskin pemre

View GitHub Profile
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Risk vs Probability Matrix</title>
<!-- Tailwind CSS -->
<script src="https://cdn.tailwindcss.com"></script>
<!-- React & ReactDOM -->
<script crossorigin src="https://unpkg.com/react@18/umd/react.production.min.js"></script>
@pemre
pemre / yen-euro-convert.html
Created March 13, 2025 07:57
Ultra simple experimental yen<>euro converter
<!DOCTYPE html>
<html lang="tr">
<head>
<meta charset="UTF-8">
<title>Yen-Euro Çevirici & OCR</title>
<style>
body {
font-family: Arial, sans-serif;
padding: 20px;
background-color: #f5f5f5;
@pemre
pemre / paralel-islem-yapma.md
Created November 3, 2024 07:42
Birden fazla komutu aynı anda çalıştıp durum bilgisini takip etmek

Birden fazla komutu aynı anda çalıştıp durum bilgisini takip etmek

GNU Parallel ile Komutları Paralel Çalıştırma Özeti

1. Komutları bir dosyaya kaydet:

  • Örneğin, commands.txt dosyasına her satıra bir komut gelecek şekilde komutlarını yaz.
yt-dlp "https://example.com/video1.m3u8" -o "video1.mp4"
yt-dlp "https://example.com/video2.m3u8" -o "video2.mp4"
...
const safeJsonParse = (str) => {
try {
return [null, JSON.parse(str)];
} catch (err) {
return [err];
}
};
// EXAMPLE USAGE
const checkEditorSession = (url, widget) => {
# When keyboard layout is stuck in Manjaro, try this to switch to tr-TR layout
setxkbmap tr
S01E01.mp4 https://atv-vod.ercdn.net/video/dizi/avrupa-yakasi/1_h71t/cff15aa6-4a8f-471b-8ba4-fc42cf761814.hb.smil/hlssubplaylist-ovbnqq8h_oacns17.m3u8?st=8fhZsVWEaubj7tU--t1dZA&e=1715545438
S01E02.mp4 https://atv-vod.ercdn.net/video/dizi/avrupa-yakasi/2_1mvq/f277fff2-8f66-44c8-a384-003e8c68529f.hb.smil/hlssubplaylist-ovbnqq8h_oacnc17.m3u8?st=loGb4azXE0EqsK6T2CbKBA&e=1715506155
S01E03.mp4 https://atv-vod.ercdn.net/video/dizi/avrupa-yakasi/3_4c92/8e1dce83-6c6c-405a-96d1-f30739afdd3d.hb.smil/hlssubplaylist-ovbnqq8h_oacnI27.m3u8?st=kVBPYsq2J9wLTtcpVZ4bvg&e=1715544733
S01E04.mp4 https://atv-vod.ercdn.net/video/dizi/avrupa-yakasi/4_zmod/0c8dc40b-8405-433a-80d0-d7bf44c1b340.hb.smil/hlssubplaylist-ovbnqq8h_oacngN7.m3u8?st=myeVeYovNeWR2RQr1A8e9g&e=1715544778
S01E05.mp4 https://atv-vod.ercdn.net/video/dizi/avrupa-yakasi/5_im09/d3eb1443-e1c2-41f3-bd60-a59405399445.hb.smil/hlssubplaylist-ovbnqq8h_oacnQ27.m3u8?st=3FAVLpRFX602piXEm7izDg&e=1715544781
S01E06.mp4 https://atv-vod.ercdn.net/video/dizi/avrupa-yakasi/6_dv4x/d37db
@pemre
pemre / description.txt
Last active August 6, 2023 08:23
Go Horse Process enhanced image 4k
To print a high quality poster of Go Horse Process image, I've enhanced it in various ways.
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/71aa_3234/index.m3u8 -o S01E01.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/ad20_3227/index.m3u8 -o S01E02.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/3afb_3228/index.m3u8 -o S01E03.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/9a02_3229/index.m3u8 -o S01E04.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/d812_3230/index.m3u8 -o S01E05.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/1d88_3231/index.m3u8 -o S01E06.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/e3a3_3232/index.m3u8 -o S01E07.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/f7b0_3233/index.m3u8 -o S01E08.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/16eb_3235/index.m3u8 -o S01E09.mp4
yt-dlp https://media.duhnet.tv/S1/HLS_VOD/9939_3244/index.m3u8 -o S01E10.mp4

How to convert mkv from VOB or ISO files

From ISO

ffmpeg -fflags +genpts -i *.iso -acodec copy -vcodec copy out.mkv

From VOB

// TODO You may put them under an npm package one day...
// --------------------------------------------------
const fs = require('fs');
const deleteFile = (filename) => {
try {
fs.unlinkSync(filename);
} catch (err) {