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

yabai: 4.0.4 -> 5.0.2 #203504

Merged
merged 1 commit into from
Jan 3, 2023
Merged

yabai: 4.0.4 -> 5.0.2 #203504

merged 1 commit into from
Jan 3, 2023

Conversation

IvarWithoutBones
Copy link
Member

@IvarWithoutBones IvarWithoutBones commented Nov 28, 2022

This update removes the need for the yabai-load-sa script on x86_64-darwin. The scripting addition can now simply be installed and launched with yabai --load-sa, just like the official installation methods.

I've used this only on x86_64-darwin where everything works as expected, testing on aarch64-darwin would be appreciated.

Note that the update is required for yabai to work on the new MacOS Ventura, so I suggest that it would be best to backport this PR to 21.11.

Description of changes
Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 22.11 Release Notes (or backporting 22.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@IvarWithoutBones IvarWithoutBones mentioned this pull request Nov 28, 2022
13 tasks
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux labels Nov 28, 2022
@ShooTeX
Copy link

ShooTeX commented Nov 28, 2022

hey @IvarWithoutBones I would like to test it on my m1 mac, but I'm pretty new to nix. I'm using flakes and nix-darwin. Do I need to make an overlay to test it in my current environment? I already have the old yabai configured.

my setup:
https://github.com/ShooTeX/.dotfiles

@IvarWithoutBones
Copy link
Member Author

IvarWithoutBones commented Nov 29, 2022

hey @IvarWithoutBones I would like to test it on my m1 mac, but I'm pretty new to nix. I'm using flakes and nix-darwin. Do I need to make an overlay to test it in my current environment? I already have the old yabai configured.

my setup: https://github.com/ShooTeX/.dotfiles

Thanks for the quick response! The best way to test this would indeed be using an overlay, here is an example on how I would do that from a flake:

{
  inputs = {
    # Use my fork of nixpkgs, with the commit fixed to the latest on this PRs branch
    ivar-nixpkgs-yabai-5_0_1.url = "github:IvarWithoutBones/nixpkgs?rev=161530fa3434ea801419a8ca33dcd97ffb8e6fee";
  };

  outputs =
    { ivar-nixpkgs-yabai-5_0_1
    }:
    {
      darwinConfigurations.foo = darwinSystem {
        modules = [{
          nixpkgs.overlays = [(self: super: {
            yabai-5_0_1 = (import ivar-nixpkgs-yabai-5_0_1 { inherit (final) system; }).yabai;
          })];
        }];
      };
    };
}

Then, your yabai configuration could set the package option to use the updated derivation:

services.yabai = {
  enable = true;
  package = pkgs.yabai-5_0_1;
};

@ShooTeX
Copy link

ShooTeX commented Nov 29, 2022

looks like it's building and working fine, but the scripting addition doesn't seem to work. I don't get any errors or infinite dock restarted when I enable enableScriptingAddition. But I think this is a yabai issue, I'll need to check that again. I'm on Ventura btw.

EDIT: scripting addition does seem to work aswell, it was my yabai config. 🥳
thanks for the work @IvarWithoutBones

@richban
Copy link

richban commented Dec 20, 2022

Could u update it to 5.0.2 there has been a new release which fixes some issues for OSX Ventura

This removes the need for the yabai-load-sa script on x86_64-darwin, the
scripting addition can now simply be installed/launched with
`yabai --load-sa`.
@IvarWithoutBones IvarWithoutBones changed the title yabai: 4.0.4 -> 5.0.1 yabai: 4.0.4 -> 5.0.2 Dec 23, 2022
@IvarWithoutBones
Copy link
Member Author

Could u update it to 5.0.2 there has been a new release which fixes some issues for OSX Ventura

Thanks for letting me know about the new release, I've pushed an update to the derivation. As before it works fine on x86_64-darwin.

@ofborg ofborg bot added 10.rebuild-linux: 1-10 10.rebuild-linux: 1 and removed 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux labels Dec 23, 2022
@ShooTeX
Copy link

ShooTeX commented Dec 24, 2022

Could u update it to 5.0.2 there has been a new release which fixes some issues for OSX Ventura

Thanks for letting me know about the new release, I've pushed an update to the derivation. As before it works fine on x86_64-darwin.

works fine on aarch64-darwin aswell. Ventura 13.1

@joedevivo
Copy link
Contributor

works fine on aarch64-darwin aswell. Ventura 13.1

Using the overlay as well. Just switched over from managing this with homebrew and so far so good :D

@Artturin Artturin merged commit 099f6ed into NixOS:master Jan 3, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Jan 3, 2023

Backport failed for release-22.11, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally.

git fetch origin release-22.11
git worktree add -d .worktree/backport-203504-to-release-22.11 origin/release-22.11
cd .worktree/backport-203504-to-release-22.11
git checkout -b backport-203504-to-release-22.11
ancref=$(git merge-base d7e2c900d7330e3f748ec1239ba169691521563b 27d6a8b410d9e5280d6e76692156dce5d9d6ef86)
git cherry-pick -x $ancref..27d6a8b410d9e5280d6e76692156dce5d9d6ef86

@IvarWithoutBones IvarWithoutBones deleted the bump-yabai branch January 4, 2023 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10 10.rebuild-linux: 1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants