Beep-Media-Player for Torsmo
Publicado por Adão S. Raul Neto 18/10/2005
[ Hits: 5.683 ]
Homepage: https://github.com/adaoraul
Simples script que mostra o nome e o tempo da musica no torsmo
#!/usr/bin/perl -w # Script para mostrar a musica que está ouvindo no torsmo (torsmo.sf.net) # o script necessita do plugins bmp-songchange que pode ser baixodo em # http://bmp-plugins.berlios.de/ e com a seguinte configuração # # No BMP # "Song change" # "echo "%s" > /tmp/bmpsong && echo "%l" >> /tmp/bmpsong" # # No torsmo # $color ${execi 10 ~/.torsmo/bmp.pl} # obs.: ~/.torsmo/bmp.pl é o caminho do script use POSIX; my $numArgs = $#ARGV+1; my $key = $ARGV[0]; my @bmpsong; open(BMPSONG, "/tmp/bmp"); @bmpsong = <BMPSONG>; close BMPSONG; sub title { my $title; $title = $bmpsong[0]; chop($title); $title =~ s/(_[^_]*_[^_]*_)|(.mp3)|(.MP3)//; @title = split(/-/,$title); return $title[1]; } sub artist { my $title; $title = $bmpsong[0]; chop($title); $title =~ s/(_[^_]*_[^_]*_)|(.mp3)|(.MP3)//; @title = split(/-/,$title); return $title[0]; } sub tempo { my $lenght; my $minutos; my $segundos; $length = $bmpsong[1]; $length = $length / 1000; @length = split(/\./,$length); $segundos = $length[0]; while($segundos > 60) { $segundos = ($segundos - 60); $minutos++; } if (length($segundos) == 1) { $segundos = "0".$segundos; } return $minutos.":".$segundos; } if($key eq "Title") { my $title = title(); print "$title"; } elsif($key eq "Tempo") { my $tempo = tempo(); print "$tempo"; } elsif($key eq "Artist") { my $artist = artist(); print "$artist"; }
Wallpapers aleatórios no Fluxbox
Tirando screenshots facilmente !
Nenhum coment�rio foi encontrado.
Servidor de Backup com Ubuntu Server 24.04 LTS, RAID e Duplicati (Dell PowerEdge T420)
Visualizar câmeras IP ONVIF no Linux sem necessidade de instalar aplicativos
Atualizar Debian Online de uma Versão para outra
Instalar driver Nvidia no Debian 13
Redimensionando, espelhando, convertendo e rotacionando imagens com script
Debian 13 Trixie para Iniciantes
Convertendo pacotes DEB que usam ZSTD (Padrão Novo) para XZ (Padrão Antigo)