Last active
April 11, 2025 22:49
-
-
Save aliorhun/86bfe20b02662c56980b7b96f82dd208 to your computer and use it in GitHub Desktop.
Tarihe göre sıralama
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # gemini 2.0 flash'a yazdırılıp, eksikleri düzenlenmiştir. | |
| # Klasör adını belirtin (veya script çalıştırıldığında argüman olarak alınabilir) | |
| klasor_adi="a2" | |
| # Klasördeki tüm dosyaları oluşturulma zamanına göre sıralayarak listeleyin | |
| dosyalar=$(ls -ltr "$klasor_adi" | awk '{print $9}') | |
| # Dosyaları döngüye alın | |
| sayac=1 | |
| for dosya in $dosyalar; do | |
| # Yeni dosya adını oluşturun (ilk isim + artan sıralı sayı) | |
| yeni_dosya_adi="yenidosya-${sayac}.png" | |
| # Dosyayı yeniden adlandırın | |
| mv "$klasor_adi/$dosya" "$klasor_adi/$yeni_dosya_adi" | |
| # Sayacı artırın | |
| sayac=$((sayac + 1)) | |
| done | |
| echo "Dosyalar yeniden adlandırıldı." | |
| # ps2pdf -dPDFSETTINGS=/ebook input.pdf output.pdf | |
| # gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment