File elixir-ls.spec of Package elixir-ls

Name:           elixir-ls
Version:        0.29.3
Release:        1%{?dist}
Summary:        LSP for elixir
License:        Apache-2.0
URL:            https://github.com/elixir-lsp/elixir-ls
Source0:        https://github.com/elixir-lsp/elixir-ls/releases/download/v%{version}/%{name}-v%{version}.zip
Source1:        90_elixir-ls.conf

BuildRequires:  unzip

# required because of build of vscodium in the same repo that also provides libvulkan
# BuildRequires:  vulkan-loader

ExclusiveArch:  x86_64

%description
A frontend-independent IDE "smartness" server for Elixir. Implements the "Language Server Protocol" standard and provides debugger support via the "Debug Adapter Protocol"

%global debug_package %{nil}

%prep
%setup -C -n %{name}-v%{version}

%build
# binary distribution --> no build step required

%install
# see https://docs.fedoraproject.org/en-US/packaging-guidelines/RPMMacros/ for the folders
mkdir -p %{buildroot}%{_bindir}
mkdir -p %{buildroot}%{_datadir}/elixir-ls
mkdir -p %{buildroot}/etc/environment.d

cp language_server.sh %{buildroot}%{_bindir}
cp launch.sh %{buildroot}%{_bindir}
cp * %{buildroot}%{_datadir}/elixir-ls/
cp %{SOURCE1} %{buildroot}/etc/environment.d/

%files
%{_bindir}/language_server.sh
%{_bindir}/launch.sh
%{_datadir}/elixir-ls/
%dir /etc/environment.d
/etc/environment.d/90_elixir-ls.conf
openSUSE Build Service is sponsored by