Skip to content

Commit

Permalink
Workflow, documentation and packaging.
Browse files Browse the repository at this point in the history
- Added the workflow to the repository, enabling automatic update of the online documentation
- Added some introductory .mld file for the odoc
- Modified the requirements to stick with latest version
  • Loading branch information
gabyfle committed Nov 8, 2024
1 parent 17ba8c0 commit d3bd89e
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 26 deletions.
29 changes: 15 additions & 14 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,22 @@ jobs:
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
ocaml-compiler:
- "5.1"
- "5.2"

runs-on: ${{ matrix.os }}
runs-on: self-hosted

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install & Verify FFmpeg version
run: |
sudo apt-get update
sudo apt-get install -y ffmpeg libavcodec-dev libavformat-dev libavutil-dev libswscale-dev libswresample-dev libavfilter-dev
ffmpeg -version
- name: Install OCaml
uses: ocaml/setup-ocaml@v2
with:
Expand All @@ -39,11 +43,9 @@ jobs:
run: opam exec -- dune runtest

- name: Build SoundML documentation
if: matrix.os == 'ubuntu-latest'
run: opam install odoc && opam exec -- dune build @doc

- name: Upload odoc documentation
if: matrix.os == 'ubuntu-latest'
uses: actions/upload-artifact@v4
with:
name: doc
Expand All @@ -52,16 +54,15 @@ jobs:
_build/default/_doc/_html/odoc.support
lint-fmt:
needs: build
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- name: Checkout tree
uses: actions/checkout@v4

- name: Install OCaml
uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: "5.1"
ocaml-compiler: "5.2"
dune-cache: true

- uses: ocaml/setup-ocaml/lint-fmt@v2
Expand All @@ -79,8 +80,8 @@ jobs:
name: doc
path: doc/

- name: Move documentation
run: mv doc/soundml doc/doc
- name: Move SoundML root to... root !
run: mv -v doc/soundml/* doc/

- name: Deploy to VPS Server
uses: easingthemes/ssh-deploy@main
Expand All @@ -89,6 +90,6 @@ jobs:
ARGS: "-rlgoDzvc -i"
SOURCE: "/doc/"
REMOTE_HOST: ${{ secrets.HOST }}
REMOTE_USER: ${{ secrets.USERNAME }}
REMOTE_USER: ${{ secrets.USER }}
TARGET: ${{ secrets.PATH }}
EXCLUDE: "/ocaml/, *.md"
EXCLUDE: "/ocaml/, *.md, dune, *.mld"
13 changes: 7 additions & 6 deletions dune-project
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,21 @@

(license Apache-2.0)

(documentation https://github.com/gabyfle/soundml)
(documentation https://soundml.gabyfle.dev)

(package
(name soundml)
(synopsis "A library to play with sound")
(synopsis
"An OCaml library to embed sound processing in your applications.")
(description
"SoundML is a library built on top of Owl to analyse sounds files.")
"SoundML is a library built on top of Owl to analyse sounds files. It can read, write audio, extract various features from audio files and much more.")
(depends
(ocaml
(>= 5.1.0))
(>= 5.2.0))
dune
(owl
(>= 1.1))
(ffmpeg
(>= 1.1.11)))
(>= 1.2.1)))
(tags
(sound gabyfle)))
(sound owl ffmpeg gabyfle)))
12 changes: 6 additions & 6 deletions soundml.opam
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
# This file is generated by dune, edit dune-project instead
opam-version: "2.0"
synopsis: "A library to play with sound"
synopsis: "An OCaml library to embed sound processing in your applications."
description:
"SoundML is a library built on top of Owl to analyse sounds files."
"SoundML is a library built on top of Owl to analyse sounds files. It can read, write audio, extract various features from audio files and much more."
maintainer: ["Gabriel Santamaria <[email protected]>"]
authors: ["Gabriel Santamaria <[email protected]>"]
license: "Apache-2.0"
tags: ["sound" "gabyfle"]
tags: ["sound" "owl" "ffmpeg" "gabyfle"]
homepage: "https://github.com/gabyfle/soundml"
doc: "https://github.com/gabyfle/soundml"
doc: "https://soundml.gabyfle.dev"
bug-reports: "https://github.com/gabyfle/soundml/issues"
depends: [
"ocaml" {>= "5.1.0"}
"ocaml" {>= "5.2.0"}
"dune" {>= "3.15"}
"owl" {>= "1.1"}
"ffmpeg" {>= "1.1.11"}
"ffmpeg" {>= "1.2.1"}
"odoc" {with-doc}
]
build: [
Expand Down

0 comments on commit d3bd89e

Please sign in to comment.