kime icon indicating copy to clipboard operation
kime copied to clipboard

Fix mismatched cargoDeps in nix and update attribute syntax

Open nakoo opened this issue 1 year ago • 3 comments

Summary

This PR includes

  1. fix mismatched cargoDeps in nix
  2. update mkDerivation not to use override
  3. replace discouraged with keyword
~ % nix-info -m
 - system: `"x86_64-linux"`
 - host os: `Linux 6.6.44, NixOS, 24.11 (Vicuna), 24.11.20240811.a58bc8a`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.18.5`
 - channels(root): `""`
 - channels(user): `""`
 - nixpkgs: `/nix/store/h60m1fwahjd2mv6gsg77ji3vb4gpj4dk-source`
 
~ % nix build .\#kime --no-link --print-out-paths 
/nix/store/czi7nb7327z5hwk372kn5hxd16jk432j-kime-3.1.1

Note

mkDerivation finalAttrs makes it possible to use overrideAttrs properly unlike rec. It's current recommendation model of nixpkgs and there's ongoing discussion to replace rec automatically.

https://github.com/NixOS/nixpkgs/pull/119942 https://github.com/NixOS/nixpkgs/issues/293452#issuecomment-2209394047

Checklist

  • [x] I have documented my changes properly to adequate places
  • [x] I have updated the docs/CHANGELOG.md

nakoo avatar Aug 14 '24 19:08 nakoo

nixpkgs has been merged. https://github.com/NixOS/nixpkgs/pull/334078

nakoo avatar Aug 19 '24 22:08 nakoo

nix build github:Riey/kime/refs/pull/682/head

성공적으로 빌드되는 것을 확인했습니다.

변경사항에 반대하는 건 아니지만, 여기서 finalAttrs를 사용하는 이유가 있나요? 그리고 기존의 rec도 필요가 없는 것처럼 보입니다.

honnip avatar Sep 09 '24 07:09 honnip

nix build github:Riey/kime/refs/pull/682/head

성공적으로 빌드되는 것을 확인했습니다.

변경사항에 반대하는 건 아니지만, 여기서 finalAttrs를 사용하는 이유가 있나요? 그리고 기존의 rec도 필요가 없는 것처럼 보입니다.

You're right. I moved src following your advice. I did this is because I wanted to use flake so don't have to wait nixpkgs merge. I also changed flake.nix to match current spec.

nakoo avatar Sep 09 '24 11:09 nakoo