Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: bspwm and sxhkd don't include system path #2550

Closed
1 task done
JulesdeCube opened this issue Dec 12, 2021 · 3 comments
Closed
1 task done

bug: bspwm and sxhkd don't include system path #2550

JulesdeCube opened this issue Dec 12, 2021 · 3 comments
Assignees
Labels
bug triage Issues or feature request that have not been triaged yet

Comments

@JulesdeCube
Copy link

JulesdeCube commented Dec 12, 2021

Is there an existing issue for this?

  • I have searched the existing issues

Issue description

Desciption

when opening any terminal inside bspwn using sxhkd the path don't include system path, just the user path.

Steps to reproduce

with the following config:

  1. login to the user
  2. press Super + enter
  3. kitty launch
  4. launch the command tree (it work)
  5. launch the command vim or nix-shell (the console respond with a not found command)

configuration.nix

{ config, pkgs, lib, ... }:
{
  services.xserver = {
    enable = true ; 
    displayManager.lightdm.enable = true;
    displayManager.defaultSession = "none+bspwm";
    windowManager.bspwm.enable = true;
  };

  environment.systemPackages = with pkgs; [
    vim
    home-manager
  ];

  system.stateVersion = "21.05"; # Did you read the comment?

}

home.nix

{pkgs, lib, config, ... }:
{

  home.packages = with pkgs; [
    kitty
    tree
  ];

  xsession.windowManager.bspwm.enable = true;
  services.sxhkd.enable = true;
  services.sxhkd.keybindings = {
    "super + Return" = "kitty";
    };
}

Expected behavior

that then program installed using nixos configuration file be accessible under program launch under bspwm

Maintainer CC

@ncfavier

System information

- system: `"x86_64-linux"`
 - host os: `Linux 5.15.6, NixOS, 22.05 (Quokka)`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.4`
 - channels(root): `"nixos-22.05pre337103.581d2d6c9cd"`
 - channels(jules): `""`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`
@JulesdeCube JulesdeCube added bug triage Issues or feature request that have not been triaged yet labels Dec 12, 2021
@ncfavier
Copy link
Member

I won't have time to look into this before a couple of days, but right away this looks like the issue that was fixed by #1892, so the observed behaviour is strange.

@ncfavier
Copy link
Member

ncfavier commented Dec 16, 2021

Can't reproduce with the following test VM configuration:

{ lib, config, pkgs, ... }: {
  imports = [ <home-manager/nixos> ];

  services.xserver = {
    enable = true;
    displayManager.lightdm.enable = true;
    displayManager.defaultSession = "none+bspwm";
    windowManager.bspwm.enable = true;
  };

  environment.systemPackages = with pkgs; [
    vim
  ];

  users.users.test = {
    isNormalUser = true;
    password = "";
  };

  home-manager = {
    useGlobalPkgs = true;
    users.test = {
      home.packages = with pkgs; [
        kitty
        tree
      ];

      xsession.windowManager.bspwm.enable = true;
      services.sxhkd.enable = true;
      services.sxhkd.keybindings = {
        "super + Return" = "kitty";
      };

      home.stateVersion = config.system.stateVersion;
    };
  };

  virtualisation.memorySize = 2048;
  system.stateVersion = "22.05";
}

Running with nixos-rebuild build-vm -I nixpkgs=/path/to/nixpkgs-master -I home-manager=/path/to/hm-master -I nixos-config=vm.nix && ./result/bin/run-nixos-vm, I can spawn a terminal and run vim or nix-shell in it just fine.

Are you able to provide a minimal non-working example VM?

@JulesdeCube
Copy link
Author

I finally found the issues.

I use fish as default shell and this is broken in previous home manager version (work find with master branch).

I use the home-manager from the nixpkgs as describe in my first message.
But the home-manager package in the master branch of nixpkgs is out to date by 6 months.

there as already a pull request to bump the package to current version, but not it's merge: NixOS/nixpkgs#139980

thanks for your help and excuse me for the inconvenience.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug triage Issues or feature request that have not been triaged yet
Projects
None yet
Development

No branches or pull requests

5 participants