diff --git a/third_party/nixpkgs/default.nix b/third_party/nixpkgs/default.nix index e95c1610d..7c21ff9df 100644 --- a/third_party/nixpkgs/default.nix +++ b/third_party/nixpkgs/default.nix @@ -70,10 +70,7 @@ import nixpkgsSrc (commonNixpkgsArgs // { commitsOverlay stableOverlay ] ++ (if depotOverlays then [ - depot.third_party.overlays.haskell depot.third_party.overlays.tvl - depot.third_party.overlays.ecl-static - depot.third_party.overlays.dhall (import depot.third_party.sources.rust-overlay) ] else [ ] ++ additionalOverlays); }) diff --git a/third_party/overlays/dhall/OWNERS b/third_party/overlays/dhall/OWNERS deleted file mode 100644 index a64022791..000000000 --- a/third_party/overlays/dhall/OWNERS +++ /dev/null @@ -1 +0,0 @@ -Profpatsch diff --git a/third_party/overlays/dhall/default.nix b/third_party/overlays/dhall/default.nix deleted file mode 100644 index 462503599..000000000 --- a/third_party/overlays/dhall/default.nix +++ /dev/null @@ -1,30 +0,0 @@ -{ ... }: - -self: super: - -let - - # binary releases of dhall tools, since the build in nixpkgs is - # broken most of the time. The binaries are also fully static - # builds, instead of the half-static crap that nixpkgs produces. - easy-dhall-nix = - import - (builtins.fetchTarball { - url = "https://github.com/justinwoo/easy-dhall-nix/archive/dce9acbb99776a7f1344db4751d6080380f76f57.tar.gz"; - sha256 = "0ckp6515gfvbxm08yyll87d9vg8sq2l21gwav2npzvwc3xz2lccf"; - }) - { pkgs = self; }; -in -{ - # ATTN: see the haskell overlay for some overrides we need. - - # dhall = easy-dhall-nix.dhall-simple; - # dhall-nix = easy-dhall-nix.dhall-nix-simple; - dhall-bash = easy-dhall-nix.dhall-bash-simple; - dhall-docs = easy-dhall-nix.dhall-docs-simple; - dhall-json = easy-dhall-nix.dhall-json-simple; - dhall-lsp-server = easy-dhall-nix.dhall-lsp-simple; - # not yet in dhall-simple - # dhall-nixpkgs = easy-dhall-nix.dhall-nixpkgs-simple; - dhall-yaml = easy-dhall-nix.dhall-yaml-simple; -} diff --git a/third_party/overlays/ecl-static.nix b/third_party/overlays/ecl-static.nix deleted file mode 100644 index d81075bde..000000000 --- a/third_party/overlays/ecl-static.nix +++ /dev/null @@ -1,28 +0,0 @@ -{ ... }: - -self: super: - -{ - # Statically linked ECL with statically linked dependencies. - # Works quite well, but solving this properly in a nixpkgs - # context will require figuring out cross compilation (for - # pkgsStatic), so we're gonna use this override for now. - # - # Note that ecl-static does mean that we have things - # statically linked against GMP and ECL which are LGPL. - # I believe this should be alright: The way ppl are gonna - # interact with the distributed binaries (i. e. the binary - # cache) is Nix in the depot monorepo, so the separability - # requirement should be satisfied: Source code or overriding - # would be available as ways to swap out the used GMP in the - # program. - # See https://www.gnu.org/licenses/gpl-faq.en.html#LGPLStaticVsDynamic - ecl-static = (super.pkgsMusl.ecl.override { - inherit (self.pkgsStatic) gmp libffi boehmgc; - }).overrideAttrs (drv: rec { - configureFlags = drv.configureFlags ++ [ - "--disable-shared" - "--with-dffi=no" # will fail at runtime anyways if statically linked - ]; - }); -} diff --git a/third_party/overlays/haskell/.skip-subtree b/third_party/overlays/haskell/.skip-subtree deleted file mode 100644 index 2a528eaa8..000000000 --- a/third_party/overlays/haskell/.skip-subtree +++ /dev/null @@ -1 +0,0 @@ -extra-pkgs need to be callPackage-ed diff --git a/third_party/overlays/haskell/OWNERS b/third_party/overlays/haskell/OWNERS deleted file mode 100644 index 5f87d2f27..000000000 --- a/third_party/overlays/haskell/OWNERS +++ /dev/null @@ -1,2 +0,0 @@ -Profpatsch -sterni diff --git a/third_party/overlays/haskell/default.nix b/third_party/overlays/haskell/default.nix deleted file mode 100644 index 5273991dd..000000000 --- a/third_party/overlays/haskell/default.nix +++ /dev/null @@ -1,62 +0,0 @@ -# Defines an overlay for overriding Haskell packages, for example to -# avoid breakage currently present in nixpkgs or to modify package -# versions. - -{ lib, ... }: - -self: super: # overlay parameters for the nixpkgs overlay - -let - haskellLib = self.haskell.lib.compose; -in -{ - haskellPackages = super.haskellPackages.override { - overrides = hsSelf: hsSuper: { - punycode = haskellLib.appendPatch - (self.fetchpatch { - name = "punycode-mtl-2.3.patch"; - url = "https://github.com/litherum/punycode/pull/5/commits/41e55c8b7cef14563e6d04a7190dbabff5a77886.patch"; - sha256 = "03kgmy4z36jv16ffp5jrig2gr8ydc8cl1iscc7difisaq88mxvqc"; - }) - hsSuper.punycode; - - # Build with deprecated ansi-wl-pprint is broken now, use HEAD which switched to - # prettyprinter - tmp-postgres = haskellLib.overrideSrc - { - version = "unstable-2023-08-08"; - src = self.fetchFromGitHub { - owner = "jfischoff"; - repo = "tmp-postgres"; - rev = "7f2467a6d6d5f6db7eed59919a6773fe006cf22b"; - sha256 = "0l1gdx5s8ximgawd3yzfy47pv5pgwqmjqp8hx5rbrq68vr04wkbl"; - }; - } - (hsSuper.tmp-postgres.override { - ansi-wl-pprint = hsSelf.prettyprinter; - }); - - pa-prelude = hsSelf.callPackage ./extra-pkgs/pa-prelude.nix { }; - pa-error-tree = hsSelf.callPackage ./extra-pkgs/pa-error-tree-0.1.0.0.nix { }; - pa-field-parser = hsSelf.callPackage ./extra-pkgs/pa-field-parser.nix { }; - pa-label = hsSelf.callPackage ./extra-pkgs/pa-label.nix { }; - pa-pretty = hsSelf.callPackage ./extra-pkgs/pa-pretty-0.1.1.0.nix { }; - pa-json = hsSelf.callPackage ./extra-pkgs/pa-json.nix { }; - pa-run-command = hsSelf.callPackage ./extra-pkgs/pa-run-command-0.1.0.0.nix { }; - }; - }; - - haskell = lib.recursiveUpdate super.haskell { - packages.ghc8107 = super.haskell.packages.ghc8107.override { - overrides = hsSelf: hsSuper: { - # TODO(sterni): TODO(grfn): patch xanthous to work with random-fu 0.3.*, - # so we can use GHC 9.0.2 and benefit from upstream binary cache. - random-fu = hsSelf.callPackage ./extra-pkgs/random-fu-0.2.nix { }; - rvar = hsSelf.callPackage ./extra-pkgs/rvar-0.2.nix { }; - - # TODO(grfn): port to brick 1.4 (EventM gains an additional type argument in 1.0) - brick = hsSelf.callPackage ./extra-pkgs/brick-0.73.nix { }; - }; - }; - }; -} diff --git a/third_party/overlays/haskell/extra-pkgs/brick-0.73.nix b/third_party/overlays/haskell/extra-pkgs/brick-0.73.nix deleted file mode 100644 index c5e2883c7..000000000 --- a/third_party/overlays/haskell/extra-pkgs/brick-0.73.nix +++ /dev/null @@ -1,70 +0,0 @@ -{ mkDerivation -, base -, bytestring -, config-ini -, containers -, contravariant -, data-clist -, deepseq -, directory -, dlist -, exceptions -, filepath -, lib -, microlens -, microlens-mtl -, microlens-th -, QuickCheck -, stm -, template-haskell -, text -, text-zipper -, transformers -, unix -, vector -, vty -, word-wrap -}: -mkDerivation { - pname = "brick"; - version = "0.73"; - sha256 = "741c8d0717f0ab5addd5d3acc88cb36d645a0c73907bde509b2fd9d9bc02039c"; - isLibrary = true; - isExecutable = true; - libraryHaskellDepends = [ - base - bytestring - config-ini - containers - contravariant - data-clist - deepseq - directory - dlist - exceptions - filepath - microlens - microlens-mtl - microlens-th - stm - template-haskell - text - text-zipper - transformers - unix - vector - vty - word-wrap - ]; - testHaskellDepends = [ - base - containers - microlens - QuickCheck - vector - vty - ]; - homepage = "https://github.com/jtdaugherty/brick/"; - description = "A declarative terminal user interface library"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/pa-error-tree-0.1.0.0.nix b/third_party/overlays/haskell/extra-pkgs/pa-error-tree-0.1.0.0.nix deleted file mode 100644 index a38cd4efa..000000000 --- a/third_party/overlays/haskell/extra-pkgs/pa-error-tree-0.1.0.0.nix +++ /dev/null @@ -1,10 +0,0 @@ -{ mkDerivation, base, containers, lib, pa-prelude }: -mkDerivation { - pname = "pa-error-tree"; - version = "0.1.0.0"; - sha256 = "f82d3d905e8d9f0d31c81f31c424b9a95c65a8925517ccac92134f410cf8d639"; - libraryHaskellDepends = [ base containers pa-prelude ]; - homepage = "https://github.com/possehl-analytics/pa-hackage"; - description = "Collect a tree of errors and pretty-print"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/pa-field-parser.nix b/third_party/overlays/haskell/extra-pkgs/pa-field-parser.nix deleted file mode 100644 index a3c146ee0..000000000 --- a/third_party/overlays/haskell/extra-pkgs/pa-field-parser.nix +++ /dev/null @@ -1,39 +0,0 @@ -{ mkDerivation -, aeson -, aeson-better-errors -, attoparsec -, base -, case-insensitive -, containers -, lib -, pa-error-tree -, pa-prelude -, scientific -, semigroupoids -, template-haskell -, text -, time -}: -mkDerivation { - pname = "pa-field-parser"; - version = "0.3.0.0"; - sha256 = "528c2b6bf5ad6454861b059c7eb6924f4c32bcb5b8faa4c2389d9ddfd92fcd57"; - libraryHaskellDepends = [ - aeson - aeson-better-errors - attoparsec - base - case-insensitive - containers - pa-error-tree - pa-prelude - scientific - semigroupoids - template-haskell - text - time - ]; - homepage = "https://github.com/possehl-analytics/pa-hackage"; - description = "“Vertical” parsing of values"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/pa-json.nix b/third_party/overlays/haskell/extra-pkgs/pa-json.nix deleted file mode 100644 index 8ce838b22..000000000 --- a/third_party/overlays/haskell/extra-pkgs/pa-json.nix +++ /dev/null @@ -1,43 +0,0 @@ -{ mkDerivation -, aeson -, aeson-better-errors -, aeson-pretty -, base -, base64-bytestring -, bytestring -, containers -, lib -, pa-error-tree -, pa-field-parser -, pa-label -, pa-prelude -, scientific -, text -, time -, vector -}: -mkDerivation { - pname = "pa-json"; - version = "0.3.0.0"; - sha256 = "45e79765e57e21400f3f3b1e86094473fac61d298618d7e34f6cad4988d8923b"; - libraryHaskellDepends = [ - aeson - aeson-better-errors - aeson-pretty - base - base64-bytestring - bytestring - containers - pa-error-tree - pa-field-parser - pa-label - pa-prelude - scientific - text - time - vector - ]; - homepage = "https://github.com/possehl-analytics/pa-hackage"; - description = "Our JSON parsers/encoders"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/pa-label.nix b/third_party/overlays/haskell/extra-pkgs/pa-label.nix deleted file mode 100644 index 7cfa257c8..000000000 --- a/third_party/overlays/haskell/extra-pkgs/pa-label.nix +++ /dev/null @@ -1,10 +0,0 @@ -{ mkDerivation, base, lib }: -mkDerivation { - pname = "pa-label"; - version = "0.1.1.0"; - sha256 = "b40183900c045641c0632ed8e53a326c0c0e9c2806568613c03b3131d9016183"; - libraryHaskellDepends = [ base ]; - homepage = "https://github.com/possehl-analytics/pa-hackage"; - description = "Labels, and labelled tuples and enums (GHC >9.2)"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/pa-prelude.nix b/third_party/overlays/haskell/extra-pkgs/pa-prelude.nix deleted file mode 100644 index 17e1996ab..000000000 --- a/third_party/overlays/haskell/extra-pkgs/pa-prelude.nix +++ /dev/null @@ -1,43 +0,0 @@ -{ mkDerivation -, base -, bytestring -, containers -, error -, exceptions -, lib -, mtl -, profunctors -, PyF -, scientific -, semigroupoids -, template-haskell -, text -, these -, validation-selective -, vector -}: -mkDerivation { - pname = "pa-prelude"; - version = "0.2.0.0"; - sha256 = "68015f7c19e9c618fc04e2516baccfce52af24efb9ca1480162c9ea0aef7f301"; - libraryHaskellDepends = [ - base - bytestring - containers - error - exceptions - mtl - profunctors - PyF - scientific - semigroupoids - template-haskell - text - these - validation-selective - vector - ]; - homepage = "https://github.com/possehl-analytics/pa-hackage"; - description = "The Possehl Analytics Prelude"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/pa-pretty-0.1.1.0.nix b/third_party/overlays/haskell/extra-pkgs/pa-pretty-0.1.1.0.nix deleted file mode 100644 index d6dadef84..000000000 --- a/third_party/overlays/haskell/extra-pkgs/pa-pretty-0.1.1.0.nix +++ /dev/null @@ -1,29 +0,0 @@ -{ mkDerivation -, aeson -, aeson-pretty -, ansi-terminal -, base -, hscolour -, lib -, nicify-lib -, pa-prelude -, text -}: -mkDerivation { - pname = "pa-pretty"; - version = "0.1.1.0"; - sha256 = "da925a7cf2ac49c5769d7ebd08c2599b537efe45b3d506bf4d7c8673633ef6c9"; - libraryHaskellDepends = [ - aeson - aeson-pretty - ansi-terminal - base - hscolour - nicify-lib - pa-prelude - text - ]; - homepage = "https://github.com/possehl-analytics/pa-hackage"; - description = "Some pretty-printing helpers"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/pa-run-command-0.1.0.0.nix b/third_party/overlays/haskell/extra-pkgs/pa-run-command-0.1.0.0.nix deleted file mode 100644 index b12eb5efb..000000000 --- a/third_party/overlays/haskell/extra-pkgs/pa-run-command-0.1.0.0.nix +++ /dev/null @@ -1,25 +0,0 @@ -{ mkDerivation -, base -, bytestring -, lib -, monad-logger -, pa-prelude -, text -, typed-process -}: -mkDerivation { - pname = "pa-run-command"; - version = "0.1.0.0"; - sha256 = "37837e0cddedc9b615063f0357115739c53b5dcb8af82ce86a95a3a5c88c29a3"; - libraryHaskellDepends = [ - base - bytestring - monad-logger - pa-prelude - text - typed-process - ]; - homepage = "https://github.com/possehl-analytics/pa-hackage"; - description = "Helper functions for spawning subprocesses"; - license = lib.licenses.bsd3; -} diff --git a/third_party/overlays/haskell/extra-pkgs/random-fu-0.2.nix b/third_party/overlays/haskell/extra-pkgs/random-fu-0.2.nix deleted file mode 100644 index 1626eca7b..000000000 --- a/third_party/overlays/haskell/extra-pkgs/random-fu-0.2.nix +++ /dev/null @@ -1,41 +0,0 @@ -{ mkDerivation -, base -, erf -, lib -, math-functions -, monad-loops -, mtl -, random -, random-shuffle -, random-source -, rvar -, syb -, template-haskell -, transformers -, vector -}: -mkDerivation { - pname = "random-fu"; - version = "0.2.7.7"; - sha256 = "8466bcfb5290bdc30a571c91e1eb526c419ea9773bc118996778b516cfc665ca"; - revision = "1"; - editedCabalFile = "16nhymfriygqr2by9v72vdzv93v6vhd9z07pgaji4zvv66jikv82"; - libraryHaskellDepends = [ - base - erf - math-functions - monad-loops - mtl - random - random-shuffle - random-source - rvar - syb - template-haskell - transformers - vector - ]; - homepage = "https://github.com/mokus0/random-fu"; - description = "Random number generation"; - license = lib.licenses.publicDomain; -} diff --git a/third_party/overlays/haskell/extra-pkgs/rvar-0.2.nix b/third_party/overlays/haskell/extra-pkgs/rvar-0.2.nix deleted file mode 100644 index c00f5a1a8..000000000 --- a/third_party/overlays/haskell/extra-pkgs/rvar-0.2.nix +++ /dev/null @@ -1,25 +0,0 @@ -{ mkDerivation -, base -, lib -, MonadPrompt -, mtl -, random-source -, transformers -}: -mkDerivation { - pname = "rvar"; - version = "0.2.0.6"; - sha256 = "01e18875ffde43f9591a8acd9f60c9c51704a026e51c1a6797faecd1c7ae8cd3"; - revision = "1"; - editedCabalFile = "1jn9ivlj3k65n8d9sfsp882m5lvni1ah79mk0cvkz91pgywvkiyq"; - libraryHaskellDepends = [ - base - MonadPrompt - mtl - random-source - transformers - ]; - homepage = "https://github.com/mokus0/random-fu"; - description = "Random Variables"; - license = lib.licenses.publicDomain; -} diff --git a/third_party/overlays/patches/0001-configure-ac-version.patch b/third_party/overlays/patches/0001-configure-ac-version.patch deleted file mode 100644 index fa2575cb9..000000000 --- a/third_party/overlays/patches/0001-configure-ac-version.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/configure.ac b/configure.ac -index e861e42..018c19c 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -26,7 +26,7 @@ - #;**********************************************************************; - - AC_INIT([tpm2-pkcs11], -- [m4_esyscmd_s([git describe --tags --always --dirty])], -+ [git-@VERSION@], - [https://github.com/tpm2-software/tpm2-pkcs11/issues], - [], - [https://github.com/tpm2-software/tpm2-pkcs11]) diff --git a/third_party/overlays/patches/0001-home-environment-fix-compatibility-with-Nix-2.3.patch b/third_party/overlays/patches/0001-home-environment-fix-compatibility-with-Nix-2.3.patch deleted file mode 100644 index df437f12c..000000000 --- a/third_party/overlays/patches/0001-home-environment-fix-compatibility-with-Nix-2.3.patch +++ /dev/null @@ -1,32 +0,0 @@ -From ade86998762034b7b8699c6f6919a40da902294d Mon Sep 17 00:00:00 2001 -From: Vincent Ambo -Date: Fri, 21 Feb 2025 17:45:23 +0300 -Subject: [PATCH] home-environment: fix compatibility with Nix 2.3 - ---- - modules/home-environment.nix | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/modules/home-environment.nix b/modules/home-environment.nix -index 652ac086..eacb8605 100644 ---- a/modules/home-environment.nix -+++ b/modules/home-environment.nix -@@ -755,13 +755,13 @@ in - - # Create a temporary GC root to prevent collection during activation. - trap 'run rm -f $VERBOSE_ARG "$newGenGcPath"' EXIT -- run --silence nix-store --realise "$newGenPath" --add-root "$newGenGcPath" -+ run --quiet nix-store --realise "$newGenPath" --add-root "$newGenGcPath" --indirect - - ${activationCmds} - - ${lib.optionalString (!config.uninstall) '' - # Create the "current generation" GC root. -- run --silence nix-store --realise "$newGenPath" --add-root "$currentGenGcPath" -+ run --silence nix-store --realise "$newGenPath" --add-root "$currentGenGcPath" --indirect - - if [[ -e "$legacyGenGcPath" ]]; then - run rm $VERBOSE_ARG "$legacyGenGcPath" --- -2.48.1 - diff --git a/third_party/overlays/patches/buf-tests-dont-use-file-transport.patch b/third_party/overlays/patches/buf-tests-dont-use-file-transport.patch deleted file mode 100644 index 34be80eb3..000000000 --- a/third_party/overlays/patches/buf-tests-dont-use-file-transport.patch +++ /dev/null @@ -1,64 +0,0 @@ -commit e9219b88de5ed37af337ee2d2e71e7ec7c0aad1b -Author: Robbert van Ginkel -Date: Thu Oct 20 16:43:28 2022 -0400 - - Fix git unit test by using fake git server rather than file:// (#1518) - - More recent versions of git fix a CVE by disabling some usage of the - `file://` transport, see - https://github.blog/2022-10-18-git-security-vulnerabilities-announced/#cve-2022-39253. - We were using this transport in tests. - - Instead, use https://git-scm.com/docs/git-http-backend to serve up this - repository locally so we don't have to use the file protocol. This - should be a more accurate tests, since we mostly expect submodules to - come from servers. - -diff --git a/.golangci.yml b/.golangci.yml -index 318d1171..865e03e7 100644 ---- a/.golangci.yml -+++ b/.golangci.yml -@@ -136,3 +136,8 @@ issues: - - linters: - - containedctx - path: private/bufpkg/bufmodule/bufmoduleprotocompile -+ # We should be able to use net/http/cgi in a unit test, in addition the CVE mentions only versions of go < 1.6.3 are affected. -+ - linters: -+ - gosec -+ path: private/pkg/git/git_test.go -+ text: "G504:" -diff --git a/private/pkg/git/git_test.go b/private/pkg/git/git_test.go -index 7b77b6cd..7132054e 100644 ---- a/private/pkg/git/git_test.go -+++ b/private/pkg/git/git_test.go -@@ -17,6 +17,8 @@ package git - import ( - "context" - "errors" -+ "net/http/cgi" -+ "net/http/httptest" - "os" - "os/exec" - "path/filepath" -@@ -213,6 +215,21 @@ func createGitDirs( - runCommand(ctx, t, container, runner, "git", "-C", submodulePath, "add", "test.proto") - runCommand(ctx, t, container, runner, "git", "-C", submodulePath, "commit", "-m", "commit 0") - -+ gitExecPath, err := command.RunStdout(ctx, container, runner, "git", "--exec-path") -+ require.NoError(t, err) -+ t.Log(filepath.Join(string(gitExecPath), "git-http-backend")) -+ // https://git-scm.com/docs/git-http-backend#_description -+ f, err := os.Create(filepath.Join(submodulePath, ".git", "git-daemon-export-ok")) -+ require.NoError(t, err) -+ require.NoError(t, f.Close()) -+ server := httptest.NewServer(&cgi.Handler{ -+ Path: filepath.Join(strings.TrimSpace(string(gitExecPath)), "git-http-backend"), -+ Dir: submodulePath, -+ Env: []string{"GIT_PROJECT_ROOT=" + submodulePath}, -+ }) -+ t.Cleanup(server.Close) -+ submodulePath = server.URL -+ - originPath := filepath.Join(tmpDir, "origin") - require.NoError(t, os.MkdirAll(originPath, 0777)) - runCommand(ctx, t, container, runner, "git", "-C", originPath, "init") diff --git a/third_party/overlays/patches/notmuch-dottime.patch b/third_party/overlays/patches/notmuch-dottime.patch deleted file mode 100644 index 7a9cfc6cc..000000000 --- a/third_party/overlays/patches/notmuch-dottime.patch +++ /dev/null @@ -1,81 +0,0 @@ -From 569438172fa0e38129de4e61a72e06eff3330dca Mon Sep 17 00:00:00 2001 -From: Vincent Ambo -Date: Thu, 10 Dec 2020 10:53:47 +0100 -Subject: [PATCH] time: Use dottime for formatting non-relative timestamps - ---- - notmuch-time.c | 10 +++++----- - util/gmime-extra.c | 7 +++++-- - util/gmime-extra.h | 2 ++ - 3 files changed, 12 insertions(+), 7 deletions(-) - -diff --git a/notmuch-time.c b/notmuch-time.c -index cc7ffc23..3030a667 100644 ---- a/notmuch-time.c -+++ b/notmuch-time.c -@@ -50,8 +50,8 @@ notmuch_time_relative_date (const void *ctx, time_t then) - time_t delta; - char *result; - -- localtime_r (&now, &tm_now); -- localtime_r (&then, &tm_then); -+ gmtime_r (&now, &tm_now); -+ gmtime_r (&then, &tm_then); - - result = talloc_zero_size (ctx, RELATIVE_DATE_MAX); - if (result == NULL) -@@ -78,16 +78,16 @@ notmuch_time_relative_date (const void *ctx, time_t then) - if (tm_then.tm_wday == tm_now.tm_wday && - delta < DAY) { - strftime (result, RELATIVE_DATE_MAX, -- "Today %R", &tm_then); /* Today 12:30 */ -+ "Today %k·%M", &tm_then); /* Today 12·30 */ - return result; - } else if ((tm_now.tm_wday + 7 - tm_then.tm_wday) % 7 == 1) { - strftime (result, RELATIVE_DATE_MAX, -- "Yest. %R", &tm_then); /* Yest. 12:30 */ -+ "Yest. %k·%M", &tm_then); /* Yest. 12·30 */ - return result; - } else { - if (tm_then.tm_wday != tm_now.tm_wday) { - strftime (result, RELATIVE_DATE_MAX, -- "%a. %R", &tm_then); /* Mon. 12:30 */ -+ "%a. %k·%M", &tm_then); /* Mon. 12·30 */ - return result; - } - } -diff --git a/util/gmime-extra.c b/util/gmime-extra.c -index 04d8ed3d..868a2f69 100644 ---- a/util/gmime-extra.c -+++ b/util/gmime-extra.c -@@ -131,10 +131,13 @@ g_mime_message_get_date_string (void *ctx, GMimeMessage *message) - GDateTime *parsed_date = g_mime_message_get_date (message); - - if (parsed_date) { -- char *date = g_mime_utils_header_format_date (parsed_date); -+ char *date = g_date_time_format( -+ parsed_date, -+ "%a, %d %b %Y %H·%M%z" -+ ); - return g_string_talloc_strdup (ctx, date); - } else { -- return talloc_strdup (ctx, "Thu, 01 Jan 1970 00:00:00 +0000"); -+ return talloc_strdup (ctx, "Thu, 01 Jan 1970 00·00:00"); - } - } - -diff --git a/util/gmime-extra.h b/util/gmime-extra.h -index 094309ec..e6c98f8d 100644 ---- a/util/gmime-extra.h -+++ b/util/gmime-extra.h -@@ -1,5 +1,7 @@ - #ifndef _GMIME_EXTRA_H - #define _GMIME_EXTRA_H -+#include -+#include - #include - #include - --- -2.29.2.576.ga3fc446d84-goog - diff --git a/third_party/overlays/patches/treefmt-fix-no-cache.patch b/third_party/overlays/patches/treefmt-fix-no-cache.patch deleted file mode 100644 index 2ad9d595e..000000000 --- a/third_party/overlays/patches/treefmt-fix-no-cache.patch +++ /dev/null @@ -1,43 +0,0 @@ -From 601af097720079ea40db100b1dd6aefba4685e7c Mon Sep 17 00:00:00 2001 -From: Florian Klink -Date: Mon, 1 Jul 2024 17:34:08 +0300 -Subject: [PATCH] fix: only try opening the cache if cache is enabled - -Otherwise `--no-cache` still fails to open the cache. ---- - cli/format.go | 12 ++++++++---- - 1 file changed, 8 insertions(+), 4 deletions(-) - -diff --git a/cli/format.go b/cli/format.go -index 492a4f3..8ccf578 100644 ---- a/cli/format.go -+++ b/cli/format.go -@@ -118,9 +118,11 @@ func (f *Format) Run() (err error) { - f.formatters[name] = formatter - } - -- // open the cache -- if err = cache.Open(f.TreeRoot, f.ClearCache, f.formatters); err != nil { -- return err -+ // open the cache if configured -+ if !f.NoCache { -+ if cache.Open(f.TreeRoot, f.ClearCache, f.formatters); err != nil { -+ return err -+ } - } - - // create an app context and listen for shutdown -@@ -148,7 +150,9 @@ func (f *Format) Run() (err error) { - f.processedCh = make(chan *walk.File, cap(f.filesCh)) - - // start concurrent processing tasks in reverse order -- eg.Go(f.updateCache(ctx)) -+ if !f.NoCache { -+ eg.Go(f.updateCache(ctx)) -+ } - eg.Go(f.applyFormatters(ctx)) - eg.Go(f.walkFilesystem(ctx)) - --- -2.44.1 -