diff --git a/.busted.lua b/.busted.lua index cfafed4..3aa0614 100644 --- a/.busted.lua +++ b/.busted.lua @@ -1,6 +1,7 @@ return { default = { verbose = true, + helper = "./spec/_helper.lua", lpath = "./src/?.lua;./src/?/init.lua;./src/?/?.lua;./tests/?.lua", }, } diff --git a/.ci/pipeline.yml b/.ci/pipeline.yml deleted file mode 100644 index dd5fb3d..0000000 --- a/.ci/pipeline.yml +++ /dev/null @@ -1,57 +0,0 @@ ---- -resources: -- name: repo - type: git - icon: github - source: - uri: https://git.sclu1034.dev/lucas/lua-libpulse-glib - branch: ci - -jobs: -- name: test - plan: - - get: repo - trigger: true - - in_parallel: - - task: run-test-5.1 - file: repo/.ci/test.yml - vars: - lua-version: 5.1 - - task: run-test-5.2 - file: repo/.ci/test.yml - vars: - lua-version: 5.2 - - task: run-test-5.3 - file: repo/.ci/test.yml - vars: - lua-version: 5.3 - # There is no rock for 5.4 LGI, yet. And I don't want to build that from source. - - try: - task: run-test-5.4 - file: repo/.ci/test.yml - vars: - lua-version: 5.4 - -- name: rock - plan: - - get: repo - trigger: true - - in_parallel: - - task: run-rock-5.1 - file: repo/.ci/rock.yml - vars: - lua-version: 5.1 - - task: run-rock-5.2 - file: repo/.ci/rock.yml - vars: - lua-version: 5.2 - - task: run-rock-5.3 - file: repo/.ci/rock.yml - vars: - lua-version: 5.3 - # There is no rock for 5.4 LGI, yet. And I don't want to build that from source. - - try: - task: run-rock-5.4 - file: repo/.ci/rock.yml - vars: - lua-version: 5.4 diff --git a/.ci/rock.sh b/.ci/rock.sh deleted file mode 100755 index 4e863aa..0000000 --- a/.ci/rock.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh - -set -ex - -sudo enable-lua ${LUA_VERSION:-5.1} -eval "$(luarocks --lua-version ${LUA_VERSION:-5.1} path)" - -luarocks --lua-version ${LUA_VERSION:-5.1} install lgi -luarocks --lua-version ${LUA_VERSION:-5.1} install ldoc -luarocks --lua-version ${LUA_VERSION:-5.1} install lua-discount - -luarocks --lua-version ${LUA_VERSION:-5.1} make rocks/lua-libpulse-glib-scm-1.rockspec - -sudo disable-lua ${LUA_VERSION:-5.1} diff --git a/.ci/rock.yml b/.ci/rock.yml deleted file mode 100644 index e8754b4..0000000 --- a/.ci/rock.yml +++ /dev/null @@ -1,20 +0,0 @@ - ---- -platform: linux - -image_resource: - type: registry-image - source: - repository: registry.local:5000/lua-clib-pulse - tag: latest - -inputs: -- name: repo - -params: - CI: true - LUA_VERSION: ((lua-version)) - -run: - path: .ci/rock.sh - dir: repo diff --git a/.ci/test.sh b/.ci/test.sh deleted file mode 100755 index f07b1ff..0000000 --- a/.ci/test.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh - -set -ex - -mkdir -p "${BUILD_DIR:-./build}" - -CMAKE_ARGS="" - -if [ -n "$CI" ]; then - CMAKE_ARGS="-DCI=ON" -fi - -sudo enable-lua ${LUA_VERSION:-5.1} -eval "$(luarocks --lua-version ${LUA_VERSION:-5.1} path)" - -luarocks --lua-version ${LUA_VERSION:-5.1} install busted -luarocks --lua-version ${LUA_VERSION:-5.1} install lgi -luarocks --lua-version ${LUA_VERSION:-5.1} install ldoc -luarocks --lua-version ${LUA_VERSION:-5.1} install lua-discount - -make -j $(nproc) -C ${SOURCE_DIR:-.} LUA_VERSION=${LUA_VERSION:-5.1} LUA=lua - -sudo disable-lua ${LUA_VERSION:-5.1} diff --git a/.ci/test.yml b/.ci/test.yml deleted file mode 100644 index 0b0dc5d..0000000 --- a/.ci/test.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- -platform: linux - -image_resource: - type: registry-image - source: - repository: registry.local:5000/lua-clib-pulse - tag: latest - -inputs: -- name: repo - -params: - CI: true - SOURCE_DIR: repo - BUILD_DIR: /tmp/build-output - LUA_VERSION: ((lua-version)) - -run: - path: repo/.ci/test.sh diff --git a/Makefile b/Makefile index a8899ee..0e47432 100644 --- a/Makefile +++ b/Makefile @@ -50,9 +50,7 @@ TEST_ARGS ?= --output=TAP CCFLAGS += -Werror endif -.PHONY: all clean doc doc-content doc-styles install uninstall test check rock - -all: build doc +.PHONY: clean doc doc-content doc-styles install uninstall test check rock build: $(TARGET) diff --git a/README.adoc b/README.adoc index 0e4d6cb..77416f8 100644 --- a/README.adoc +++ b/README.adoc @@ -5,6 +5,7 @@ ifdef::env-github,env-browser[] :toc: macro :toclevels: 1 endif::[] +ifdef::env-github[] :branch: master :status: :outfilesuffix: .adoc @@ -14,15 +15,16 @@ endif::[] :note-caption: :paperclip: :tip-caption: :bulb: :warning-caption: :warning: -:url-ci: https://ci.sclu1034.dev/teams/main/pipelines/lgi-libpulse-glib -:url-ci-badge: https://ci.sclu1034.dev/api/v1/teams/main/pipelines/lgi-libpulse-glib/badge +endif::[] +:url-ci-github: https://github.com/sclu1034/lua-libpulse-glib/actions +:url-ci-badge-github: https://img.shields.io/github/workflow/status/sclu1034/lua-libpulse-glib/Lint%20&%20Test?style=flat-square :url-license-badge: https://img.shields.io/badge/license-GPLv3-brightgreen?style=flat-square :url-luarocks-badge: https://img.shields.io/luarocks/v/sclu1034/lua-libpulse-glib?style=flat-square :url-luarocks-link: https://luarocks.org/modules/sclu1034/lua-libpulse-glib image:{url-license-badge}[License] ifdef::status[] -image:{url-ci-badge}[Build Status (Concourse CI), link={url-ci}] +image:{url-ci-badge-github}[Build Status (GitHub Actions), link={url-ci-github}] endif::[] image:{url-luarocks-badge}[LuaRocks Package, link={url-luarocks-link}] diff --git a/src/lua_libpulse_glib/proplist.h b/src/lua_libpulse_glib/proplist.h index 4c3d3e2..15d2d31 100644 --- a/src/lua_libpulse_glib/proplist.h +++ b/src/lua_libpulse_glib/proplist.h @@ -310,9 +310,7 @@ static const struct luaU_enumfield proplist_enum[] = { { "FORMAT_RATE", PA_PROP_FORMAT_RATE }, { "FORMAT_CHANNELS", PA_PROP_FORMAT_CHANNELS }, { "FORMAT_CHANNEL_MAP", PA_PROP_FORMAT_CHANNEL_MAP }, -#if PA_CHECK_VERSION(15, 0, 0) { "CONTEXT_FORCE_DISABLE_SHM", PA_PROP_CONTEXT_FORCE_DISABLE_SHM }, { "BLUETOOTH_CODEC", PA_PROP_BLUETOOTH_CODEC }, -#endif { NULL, NULL } };