Commit Graph

8 Commits

Author SHA1 Message Date
Ihar Hrachyshka
567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00
Alex James
07587e8c9d convmv: add split bin output 2025-05-13 18:56:27 -05:00
Alex James
a94dd454e9 convmv: add dependencies to support additional encodings
This adds support for the following encodings:

```diff
diff --git a/a b/b
--- a/a
+++ b/b
@@ -4,8 +4,21 @@ AdobeSymbol
 AdobeZdingbat
 ascii
 ascii-ctrl
+big5-1984
+big5-2003
 big5-eten
 big5-hkscs
+big5ext
+big5plus
+cccii
+cns11643-1
+cns11643-2
+cns11643-3
+cns11643-4
+cns11643-5
+cns11643-6
+cns11643-7
+cns11643-f
 cp1006
 cp1026
 cp1047
@@ -46,15 +59,20 @@ cp949
 cp950
 dingbats
 euc-cn
+euc-jisx0213
 euc-jp
 euc-kr
+euc-tw
 gb12345-raw
+gb18030
 gb2312-raw
 gsm0338
 hp-roman8
 hz
+IMAP-UTF-7
 iso-2022-jp
 iso-2022-jp-1
+iso-2022-jp-3
 iso-2022-kr
 iso-8859-1
 iso-8859-10
@@ -75,6 +93,8 @@ iso-ir-165
 jis0201-raw
 jis0208-raw
 jis0212-raw
+jis0213-1-raw
+jis0213-2-raw
 johab
 koi8-f
 koi8-r
@@ -109,9 +129,11 @@ nextstep
 null
 posix-bc
 shiftjis
+shiftjisx0213
 symbol
 UCS-2BE
 UCS-2LE
+unisys
 UTF-16
 UTF-16BE
 UTF-16LE
```
2025-05-13 18:56:18 -05:00
Peder Bergebakken Sundt
7972442a9e treewide: finalAttrs.doCheck -> finalAttrs.finalPackage.doCheck 2025-03-03 05:40:39 +01:00
R. Ryantm
aa332bbbdc convmv: 2.05 -> 2.06 2025-03-01 00:37:13 +00:00
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
Alex James
d44cc3b616 convmv: add al3xtjames to maintainers 2024-06-28 22:55:28 -05:00
Alex James
9f51e9102d convmv: add Darwin support, reformat & migrate to pkgs/by-name
Add support for Darwin to convmv. This required disabling the tests as
APFS requires filenames to be valid UTF-8[^1]. This will also affect
Linux if a filesystem that enforces valid UTF-8 is used (such as ZFS
with `utf8only=on`).

While we're here, make some changes to clean up the derivation:

- Replace use of `rec` with `finalAttrs` pattern
- Replace `fetchurl` with `fetchzip`
- Added separate `man` output
- Replace `preBuild` hook with explicit `makeFlags` initialization
- Replace explicit `patchPhase` override with `prePatch` hook
- Enable `strictDeps`
- Disable redundant `patchShebangs` call (already done in `prePatch`
  hook)
- Address lints from `nixpkgs-hammer`
- Reformat with `nixfmt-rfc-style`
- Migrate to pkgs/by-name

[^1]: https://developer.apple.com/library/archive/documentation/FileManagement/Conceptual/APFS_Guide/FAQ/FAQ.html
2024-06-28 22:55:11 -05:00