WIP
This commit is contained in:
parent
0dc4fa7860
commit
7388e3635f
10
flake.nix
10
flake.nix
@ -50,6 +50,11 @@
|
|||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
ra-multiplex = {
|
||||||
|
url = "github:pr2502/ra-multiplex";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
# Nix expressions and keys (TODO: move keys to another solution like agenix)
|
# Nix expressions and keys (TODO: move keys to another solution like agenix)
|
||||||
# which should be kept from the main repo for privacy reasons.
|
# which should be kept from the main repo for privacy reasons.
|
||||||
#
|
#
|
||||||
@ -75,6 +80,7 @@
|
|||||||
secrets,
|
secrets,
|
||||||
sops-nix,
|
sops-nix,
|
||||||
vscode-server,
|
vscode-server,
|
||||||
|
ra-multiplex
|
||||||
# website
|
# website
|
||||||
}: let
|
}: let
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
@ -101,6 +107,10 @@
|
|||||||
inherit (nonrecursive-unstable-pkgs) atuin wstunnel;
|
inherit (nonrecursive-unstable-pkgs) atuin wstunnel;
|
||||||
})
|
})
|
||||||
|
|
||||||
|
(self: super: {
|
||||||
|
ra-multiplex = ra-multiplex.packages.${system}.default;
|
||||||
|
})
|
||||||
|
|
||||||
# https://github.com/NixOS/nixpkgs/pull/251706
|
# https://github.com/NixOS/nixpkgs/pull/251706
|
||||||
(self: super: {
|
(self: super: {
|
||||||
mozc = self.qt6Packages.callPackage ./package-overrides/mozc.nix { };
|
mozc = self.qt6Packages.callPackage ./package-overrides/mozc.nix { };
|
||||||
|
@ -51,6 +51,7 @@ in {
|
|||||||
./services/mpd.nix
|
./services/mpd.nix
|
||||||
./services/picom.nix
|
./services/picom.nix
|
||||||
./services/polybar.nix
|
./services/polybar.nix
|
||||||
|
./services/ra-multiplex.nix
|
||||||
./services/screen-locker.nix
|
./services/screen-locker.nix
|
||||||
# ./services/stalonetray.nix
|
# ./services/stalonetray.nix
|
||||||
./services/sxhkd.nix
|
./services/sxhkd.nix
|
||||||
|
@ -161,6 +161,9 @@ in
|
|||||||
"vsintellicode.modify.editor.suggestSelection" = "automaticallyOverrodeDefaultValue";
|
"vsintellicode.modify.editor.suggestSelection" = "automaticallyOverrodeDefaultValue";
|
||||||
"window.zoomLevel" = 1;
|
"window.zoomLevel" = 1;
|
||||||
|
|
||||||
|
"rust-analyzer.server.path" =
|
||||||
|
toString (pkgs.writeShellScript "ra-multiplex-client" "${lib.getExe pkgs.ra-multiplex} client");
|
||||||
|
|
||||||
"search.exclude" = {
|
"search.exclude" = {
|
||||||
"**/node_modules" = true;
|
"**/node_modules" = true;
|
||||||
"**/bower_components" = true;
|
"**/bower_components" = true;
|
||||||
|
36
home/services/ra-multiplex.nix
Normal file
36
home/services/ra-multiplex.nix
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
format = pkgs.formats.toml { };
|
||||||
|
package = pkgs.ra-multiplex;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
xdg.configFile."ra-multiplex/config.toml".source = format.generate "ra-multiplex-config.toml" {
|
||||||
|
# listen = "/var/run/user/1001/ra-mux/ra-multiplex.sock";
|
||||||
|
# connect = "/var/run/user/1001/ra-mux/ra-multiplex.sock";
|
||||||
|
listen = [ "127.0.0.1" 27631 ];
|
||||||
|
connect = [ "127.0.0.1" 27631 ];
|
||||||
|
pass_environment = [
|
||||||
|
"RUST_SRC_PATH"
|
||||||
|
"RUSTC_WRAPPER"
|
||||||
|
"SCCACHE_DIR"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.user.services.ra-multiplex = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Rust analyzer multiplex server";
|
||||||
|
};
|
||||||
|
|
||||||
|
Service = {
|
||||||
|
Type = "simple";
|
||||||
|
ExecStart = "${lib.getExe package} server";
|
||||||
|
Environment = [
|
||||||
|
"PATH=${lib.makeBinPath [ pkgs.rust-analyzer ]}"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
Install = {
|
||||||
|
WantedBy = [ "default.target" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user