[feat] add chill-player
This commit is contained in:
parent
9e02cb192a
commit
b5d0efc88f
4 changed files with 27 additions and 2 deletions
13
arch.scm
13
arch.scm
|
@ -48,11 +48,22 @@
|
||||||
"pavucontrol"
|
"pavucontrol"
|
||||||
))
|
))
|
||||||
|
|
||||||
|
(define %arch-misc
|
||||||
|
(list
|
||||||
|
"hy"
|
||||||
|
"python-requests"
|
||||||
|
|
||||||
|
"mpv"
|
||||||
|
))
|
||||||
|
|
||||||
(define arch-packages
|
(define arch-packages
|
||||||
(append
|
(append
|
||||||
%arch-base-packages
|
%arch-base-packages
|
||||||
(if (not (equal? "lighthouse" (getlogin)))
|
(if (not (equal? "lighthouse" (getlogin)))
|
||||||
%arch-de-things
|
(begin
|
||||||
|
%arch-de-things
|
||||||
|
%arch-misc
|
||||||
|
)
|
||||||
'())))
|
'())))
|
||||||
|
|
||||||
(define arch-services
|
(define arch-services
|
||||||
|
|
10
files/bin/chill-player
Executable file
10
files/bin/chill-player
Executable file
|
@ -0,0 +1,10 @@
|
||||||
|
#!/usr/bin/env hy
|
||||||
|
|
||||||
|
(import json)
|
||||||
|
(import requests)
|
||||||
|
(import subprocess)
|
||||||
|
|
||||||
|
(while True
|
||||||
|
(for [item (.json (requests.get "https://stream.chillhop.com/live/12355"))]
|
||||||
|
(print f"Now playing: {(:title item)} - {(:artists item)} - {(:fileId item)}")
|
||||||
|
(subprocess.run f"mpv https://stream.chillhop.com/mp3/{(:fileId item)}" :shell True :capture_output True)))
|
|
@ -69,6 +69,7 @@ ZSH_THEME="fox"
|
||||||
|
|
||||||
export LANG=en_US.UTF-8
|
export LANG=en_US.UTF-8
|
||||||
export LC_ALL=en_US.UTF-8
|
export LC_ALL=en_US.UTF-8
|
||||||
|
export PATH="$HOME/.local/bin:$PATH"
|
||||||
|
|
||||||
. $HOME/.guix-home/setup-environment
|
. $HOME/.guix-home/setup-environment
|
||||||
|
|
||||||
|
|
|
@ -54,7 +54,10 @@
|
||||||
(service home-files-service-type
|
(service home-files-service-type
|
||||||
`((".config/hypr/hyprland.conf" ,(local-file "files/hyprland.conf"))
|
`((".config/hypr/hyprland.conf" ,(local-file "files/hyprland.conf"))
|
||||||
(".config/hypr/hyprlock.conf" ,(local-file "files/hyprlock.conf"))
|
(".config/hypr/hyprlock.conf" ,(local-file "files/hyprlock.conf"))
|
||||||
(".config/hypr/hyprpaper.conf" ,(local-file "files/hyprpaper.conf"))))
|
(".config/hypr/hyprpaper.conf" ,(local-file "files/hyprpaper.conf"))
|
||||||
|
;; bin
|
||||||
|
(".local/bin" ,(local-file "files/bin" #:recursive? #t))
|
||||||
|
))
|
||||||
(service home-zsh-service-type
|
(service home-zsh-service-type
|
||||||
(home-zsh-configuration
|
(home-zsh-configuration
|
||||||
(zshrc (list (local-file "files/zshrc"))))))))
|
(zshrc (list (local-file "files/zshrc"))))))))
|
||||||
|
|
Loading…
Reference in a new issue