From beeb8159dc4f4750262ef52cd25af08cc9c86cb2 Mon Sep 17 00:00:00 2001 From: "Adam C. Stephens" Date: Tue, 9 Jun 2026 13:13:24 -0400 Subject: [PATCH] beamPackages.elixir-ls: 0.30.0 -> 0.31.0 Changelog: https://github.com/elixir-lsp/elixir-ls/releases/tag/v0.31.0 --- .../beam-modules/elixir-ls/default.nix | 4 +-- .../beam-modules/elixir-ls/launch.sh.patch | 25 +++++++++++-------- 2 files changed, 17 insertions(+), 12 deletions(-) diff --git a/pkgs/development/beam-modules/elixir-ls/default.nix b/pkgs/development/beam-modules/elixir-ls/default.nix index 067c907e31cc..0a1c6b294dfc 100644 --- a/pkgs/development/beam-modules/elixir-ls/default.nix +++ b/pkgs/development/beam-modules/elixir-ls/default.nix @@ -9,13 +9,13 @@ stdenv.mkDerivation rec { pname = "elixir-ls"; - version = "0.30.0"; + version = "0.31.0"; src = fetchFromGitHub { owner = "elixir-lsp"; repo = "elixir-ls"; rev = "v${version}"; - hash = "sha256-GtkFuof60cOTlHuhcwCnIVtGx6KlHrcazTa/UjAIGAQ="; + hash = "sha256-AKJJyQUCZSsFpqVPtwL7+arCOzDC0251MwooEM8JFM4="; }; patches = [ diff --git a/pkgs/development/beam-modules/elixir-ls/launch.sh.patch b/pkgs/development/beam-modules/elixir-ls/launch.sh.patch index 59f12bbccbf7..b1dbb3356764 100644 --- a/pkgs/development/beam-modules/elixir-ls/launch.sh.patch +++ b/pkgs/development/beam-modules/elixir-ls/launch.sh.patch @@ -1,8 +1,8 @@ diff --git c/scripts/launch.sh w/scripts/launch.sh -index 524f2294..bbea062d 100755 +index d5247535..bbea062d 100755 --- c/scripts/launch.sh +++ w/scripts/launch.sh -@@ -1,114 +1,4 @@ +@@ -1,119 +1,4 @@ -#!/bin/sh -# Actual launcher. This does the hard work of figuring out the best way -# to launch the language server or the debug adapter. @@ -98,7 +98,12 @@ index 524f2294..bbea062d 100755 - # Look for mise executable - if command -v mise >/dev/null 2>&1; then - >&2 echo "mise executable found at $(command -v mise), activating" -- eval "$($(command -v mise) env -s "$preferred_shell")" +- # mise env does not support all shells (e.g. nushell); fall back to bash +- case "$preferred_shell" in +- bash|zsh|fish|elvish|xonsh|pwsh) mise_shell="$preferred_shell" ;; +- *) mise_shell="bash" ;; +- esac +- eval "$($(command -v mise) env -s "$mise_shell")" - export_stdlib_path "mise which elixir" - else - >&2 echo "mise not found" @@ -115,13 +120,13 @@ index 524f2294..bbea062d 100755 - fi -fi +#!/usr/bin/env bash - + # In case that people want to tweak the path, which Elixir to use, or # whatever prior to launching the language server or the debug adapter, we -@@ -127,12 +17,8 @@ fi +@@ -132,12 +17,8 @@ fi # script so we can correctly configure the Erlang library path to # include the local .ez files, and then do what we were asked to do. - + -if [ -z "${ELS_INSTALL_PREFIX}" ]; then - SCRIPT=$(readlink_f "$0") - SCRIPTPATH=$(dirname "$SCRIPT") @@ -130,18 +135,18 @@ index 524f2294..bbea062d 100755 -fi +SCRIPT=$(readlink -f "$0") +SCRIPTPATH=$(dirname "$SCRIPT")/../scripts - + # Unset MIX_OS_DEPS_COMPILE_PARTITION_COUNT as it pollutes stdout # breaking LSP protocol. See https://github.com/elixir-lsp/elixir-ls/issues/1195 -@@ -141,19 +27,16 @@ unset MIX_OS_DEPS_COMPILE_PARTITION_COUNT +@@ -146,19 +27,16 @@ unset MIX_OS_DEPS_COMPILE_PARTITION_COUNT export MIX_ENV=prod # Mix.install prints to stdout and reads from stdin # we need to make sure it doesn't interfere with LSP/DAP -echo "" | elixir "$SCRIPTPATH/quiet_install.exs" >/dev/null || exit 1 +echo "" | @elixir@/bin/elixir "$SCRIPTPATH/quiet_install.exs" >/dev/null || exit 1 - + default_erl_opts="-kernel standard_io_encoding latin1 +sbwt none +sbwtdcpu none +sbwtdio none" - + -if [ "$preferred_shell" = "bash" ]; then - . "$dirname/exec.bash" -elif [ "$preferred_shell" = "zsh" ]; then