Skip to content

Adding Custom Functions to Liquidsoap Server #1847

Answered by vitoyucepi
paulcurtis26 asked this question in Q&A
Discussion options

You must be logged in to vote

Hi, @paulcurtis26.
I have the same problem at start. There's no sources over the internet with liquidsoap code samples.
The only way to learn the language is to read official wiki page about it.

Also I recommend to use the book - it has some code snippets and other things.

And finally I created a local clone of official repo and look for examples there.
I've never used OCaml so the sources are not very useful for me, but I can definitely recommend libs and tests.

As for your code. This is reformated snippet.

def addCurtisMoveCommand(s)
  def moveToCurtisRadio(skip)
    lines = get_process_lines("/home/pi/Music/NewMusicRadio/CopyFilesToCurtisRadio.sh")
    if skip == "true" then
      log(…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by smimram
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
2 participants
Converted from issue

This discussion was converted from issue #1841 on August 24, 2021 11:38.