Merge pull request #32174 from lheckemann/weechat-all-default

weechat: default to enabling all plugins

Changed files
+9 -7
doc
pkgs
applications
networking
irc
weechat
+6 -4
doc/package-notes.xml
···
<section xml:id="sec-weechat">
<title>Weechat</title>
<para>
-
Weechat can currently be configured to include your choice of plugins.
-
To make use of this functionality, install an expression that overrides its configuration such as
+
Weechat can be configured to include your choice of plugins, reducing its
+
closure size from the default configuration which includes all available
+
plugins. To make use of this functionality, install an expression that
+
overrides its configuration such as
<programlisting>weechat.override {configure = {availablePlugins, ...}: {
-
plugins = with availablePlugins; [ python perl ];
-
}
+
plugins = with availablePlugins; [ python perl ];
+
}
}</programlisting>
</para>
<para>
+3 -3
pkgs/applications/networking/irc/weechat/default.nix
···
, rubySupport ? true, ruby
, tclSupport ? true, tcl
, extraBuildInputs ? []
-
, configure ? null
+
, configure ? { availablePlugins, ... }: { plugins = builtins.attrValues availablePlugins; }
, runCommand }:
let
···
ln -s $plugin $out/plugins
done
'';
-
in writeScriptBin "weechat" ''
+
in (writeScriptBin "weechat" ''
#!${stdenv.shell}
export WEECHAT_EXTRA_LIBDIR=${pluginsDir}
${lib.concatMapStringsSep "\n" (p: lib.optionalString (p ? extraEnv) p.extraEnv) plugins}
exec ${weechat}/bin/weechat "$@"
-
''
+
'') // { unwrapped = weechat; }