1
0
mirror of https://github.com/danog/magnaluna.git synced 2024-11-26 19:44:46 +01:00

Add songs.php

This commit is contained in:
Daniil Gentili 2019-10-29 18:31:09 +01:00
parent 1f3cae095f
commit e7a18f1b3d
Signed by: danog
GPG Key ID: 8C1BE3B34B230CA7
2 changed files with 11 additions and 1 deletions

1
.gitignore vendored
View File

@ -6,7 +6,6 @@ magnabroadcast.php
broadcast.php
docs/.jekyll-metadata
songs.php
_site
# JetBrains IDE

11
songs.php Normal file
View File

@ -0,0 +1,11 @@
<?php
$songs = \glob('*raw');
if (!$songs) {
die('No songs defined! Convert some songs as described in https://docs.madelineproto.xyz/docs/CALLS.html#playing-mp3-files');
}
$songs_length = \count($songs);
for ($x = 0; $x < $songs_length; $x++) {
\shuffle($songs);
}