1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages.id/osx/shuf.md

403 B

shuf

Generate permutasi acak. Informasi lebih lanjut: https://www.unix.com/man-page/linux/1/shuf/.

  • Acak urutan baris di sebuah file dan outputkan hasilnya:

shuf {{nama_file}}

  • Hanya mengoutputkan 5 entri dari hasil:

shuf -n {{5}} {{nama_file}}

  • Menuliskan output ke file lain:

shuf {{nama_file}} -o {{nama_file_output}}

  • Men-generate angka acak dari 1-10:

shuf -i {{1-10}}