Commit Graph

9 Commits

Author SHA1 Message Date
Artturin
e0464e4788 treewide: replace stdenv.is with stdenv.hostPlatform.is
In preparation for the deprecation of `stdenv.isX`.

These shorthands are not conducive to cross-compilation because they
hide the platforms.

Darwin might get cross-compilation for which the continued usage of `stdenv.isDarwin` will get in the way

One example of why this is bad and especially affects compiler packages
https://www.github.com/NixOS/nixpkgs/pull/343059

There are too many files to go through manually but a treewide should
get users thinking when they see a `hostPlatform.isX` in a place where it
doesn't make sense.

```
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv.is" "stdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv'.is" "stdenv'.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "clangStdenv.is" "clangStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "gccStdenv.is" "gccStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenvNoCC.is" "stdenvNoCC.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "inherit (stdenv) is" "inherit (stdenv.hostPlatform) is"
fd --type f "\.nix" | xargs sd --fixed-strings "buildStdenv.is" "buildStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "effectiveStdenv.is" "effectiveStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "originalStdenv.is" "originalStdenv.hostPlatform.is"
```
2024-09-25 00:04:37 +03:00
R. Ryantm
7209339f1c diesel-cli: 2.2.3 -> 2.2.4 2024-09-08 18:02:35 +00:00
seth
2434f2f15b
diesel-cli: 2.2.1 -> 2.2.3
Changelog: https://github.com/diesel-rs/diesel/releases/tag/v2.2.3
Diff: https://github.com/diesel-rs/diesel/compare/v2.2.2...v2.2.3
2024-08-25 22:34:12 -04:00
Julius Michaelis
6a9beaf893 treewide: skip generating shell completions using $out/bin/… when cross compiling
This focuses on Rust packages, since the most commonly used argument
parser library (clap/structopt) makes the following pattern natural and
thus common:

  postInstall = ''
    installShellCompletion --cmd foo \
      --bash <($out/bin/foo completion bash) \
      …

This commit just guards those with

lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform)

splitting the string where unrelated actions are performed.
2024-08-04 10:50:48 +09:00
seth
f5f90aa696
diesel-cli: 2.1.1 -> 2.2.1
Changelog: https://github.com/diesel-rs/diesel/releases/tag/v2.2.1
Diff: https://github.com/diesel-rs/diesel/compare/v2.1.1...v2.2.1
2024-07-15 13:17:07 -04:00
seth
bc73ec689d
diesel-cli: modernize
- add version test
- skip tests requiring live database
- add updateScript
- update upstream URLs
  - linking directly to the diesel website makes more sense, as it's the
  actual homepage, not where the code is hosted
  the regular version changelogs should also include information on the
  cli
2024-07-10 15:38:29 -04:00
seth
342dab5b73
diesel-cli: add maintainer getchoo 2024-07-10 15:38:19 -04:00
seth
78a212761a
diesel-cli: format with nixfmt 2024-06-12 05:08:49 -04:00
seth
8ad3581ac9
diesel-cli: migrate to by-name 2024-06-12 05:08:31 -04:00