Merge master into staging-next

This commit is contained in:
nixpkgs-ci[bot]
2026-04-10 00:26:54 +00:00
committed by GitHub
125 changed files with 2776 additions and 767 deletions
+2
View File
@@ -286,6 +286,8 @@
- the `autossh-ng` NixOS module was introduced as a simpler alternative to the existing `autossh` module.
- Added `haskell.packages.microhs`, a set of Haskell packages built with MicroHs.
- `gnuradio`: Overriding the `.pkgs` package set is now possible with a `packageOverrides` function, like with `python.pkgs` and other language-specific package sets.
Example:
+14
View File
@@ -1192,6 +1192,20 @@
githubId = 49609151;
name = "Popa Ioan Alexandru";
};
AlexandreTunstall = {
name = "Alex Tunstall";
email = "alex@tunstall.xyz";
matrix = "@alex:tunstall.xyz";
github = "AlexandreTunstall";
githubId = 32900877;
keys = [
{
# Fetch with WKD (e.g. gpg --locate-external-keys alex@tunstall.xyz)
# The fetched key should have this fingerprint (please let me know if not)
fingerprint = "51A5 8478 068E B19D FD35 D542 F6CA 1AD5 54DC A5E4";
}
];
};
alexandru0-dev = {
email = "alexandru.italia32+nixpkgs@gmail.com";
github = "alexandru0-dev";
@@ -67,6 +67,23 @@ let
# TODO: Refactor `hardware.graphics` to ease referencing the closure
# NOTE: A naive implementation may e.g. introduce a conditional infinite recursion (https://github.com/NixOS/nixpkgs/pull/488199)
nvidia-gpu.unsafeFollowSymlinks = true;
zluda = {
onFeatures = [
"cuda"
];
paths = [
pkgs.addDriverRunpath.driverLink
"/dev/dri"
"/dev/kfd"
"/sys/devices/virtual/kfd"
# As per https://www.kernel.org/doc/Documentation/admin-guide/devices.txt
# 226 is the major ID for "Direct Rendering Infrastructure (DRI)" devices
"/sys/dev/char/226:*"
]
++ config.hardware.graphics.extraPackages;
unsafeFollowSymlinks = true;
};
};
in
{
@@ -82,6 +99,16 @@ in
You may extend or override the exposed paths via the
`programs.nix-required-mounts.allowedPatterns.nvidia-gpu.paths` option.
'';
presets.zluda.enable = lib.mkEnableOption ''
Same as `programs.nix-required-mounts.presets.nvidia-gpu` but adds paths
to the sandbox that are needed for running CUDA applications on top of
the ZLUDA translation layer combined with AMD GPUs.
You may extend or override the exposed paths via the
`programs.nix-required-mounts.allowedPatterns.zluda.paths` option.
'';
allowedPatterns =
with lib.types;
lib.mkOption {
@@ -122,6 +149,14 @@ in
inherit (defaults) nvidia-gpu;
};
})
(lib.mkIf cfg.presets.zluda.enable {
hardware.graphics.enable = lib.mkDefault true;
hardware.amdgpu.zluda.enable = lib.mkDefault true;
nix.settings.system-features = cfg.allowedPatterns.zluda.onFeatures;
programs.nix-required-mounts.allowedPatterns = {
inherit (defaults) zluda;
};
})
]
);
}
+32 -21
View File
@@ -40,30 +40,41 @@ in
};
opencl.enable = lib.mkEnableOption "OpenCL support using ROCM runtime library";
zluda.enable = lib.mkEnableOption "CUDA support using ZLUDA runtime library";
zluda.package = lib.mkPackageOption pkgs "zluda" { };
};
config = {
boot.kernelParams =
lib.optionals cfg.legacySupport.enable [
"amdgpu.si_support=1"
"amdgpu.cik_support=1"
"radeon.si_support=0"
"radeon.cik_support=0"
]
++ lib.optionals cfg.overdrive.enable [
"amdgpu.ppfeaturemask=${cfg.overdrive.ppfeaturemask}"
];
config = lib.mkMerge [
{
boot.kernelParams =
lib.optionals cfg.legacySupport.enable [
"amdgpu.si_support=1"
"amdgpu.cik_support=1"
"radeon.si_support=0"
"radeon.cik_support=0"
]
++ lib.optionals cfg.overdrive.enable [
"amdgpu.ppfeaturemask=${cfg.overdrive.ppfeaturemask}"
];
boot.initrd.kernelModules = lib.optionals cfg.initrd.enable [ "amdgpu" ];
hardware.graphics = lib.mkIf cfg.opencl.enable {
enable = lib.mkDefault true;
extraPackages = [
pkgs.rocmPackages.clr
pkgs.rocmPackages.clr.icd
];
};
};
boot.initrd.kernelModules = lib.optionals cfg.initrd.enable [ "amdgpu" ];
}
(lib.mkIf cfg.opencl.enable {
hardware.graphics = {
enable = lib.mkDefault true;
extraPackages = [
pkgs.rocmPackages.clr
pkgs.rocmPackages.clr.icd
];
};
})
(lib.mkIf cfg.zluda.enable {
hardware.graphics = {
enable = lib.mkDefault true;
extraPackages = [ cfg.zluda.package ];
};
})
];
meta = {
maintainers = with lib.maintainers; [ johnrtitor ];
@@ -16,19 +16,19 @@ let
inherit tiling_wm;
};
stableVersion = {
version = "2025.3.2.6"; # "Android Studio Panda 2 | 2025.3.2"
sha256Hash = "sha256-MpQtjNdogZLPPNB78oL7EgA1ub2bVubxPFVA5tOYB+k=";
url = "https://edgedl.me.gvt1.com/android/studio/ide-zips/2025.3.2.6/android-studio-panda2-linux.tar.gz";
version = "2025.3.3.6"; # "Android Studio Panda 3 | 2025.3.3"
sha256Hash = "sha256-NBrA/BfbyYfQUw4M+zJxJUgFM9ZzOoifITdja+zUhqU=";
url = "https://edgedl.me.gvt1.com/android/studio/ide-zips/2025.3.3.6/android-studio-panda3-linux.tar.gz";
};
betaVersion = {
version = "2025.3.2.5"; # "Android Studio Panda 2 | 2025.3.2 RC 1"
sha256Hash = "sha256-qpmc7MO48GV2nnxEdRstg3ne0Gvlrgk9UX5Dr60gAMM=";
url = "https://edgedl.me.gvt1.com/android/studio/ide-zips/2025.3.2.5/android-studio-panda2-rc1-linux.tar.gz";
version = "2025.3.3.5"; # "Android Studio Panda 3 | 2025.3.3 RC 1"
sha256Hash = "sha256-lKpFKw2Oq7OlDrPjFJhMH3aQsJO7TeOKy7HGUCE0B1U=";
url = "https://edgedl.me.gvt1.com/android/studio/ide-zips/2025.3.3.5/android-studio-panda3-rc1-linux.tar.gz";
};
latestVersion = {
version = "2025.3.3.2"; # "Android Studio Panda 3 | 2025.3.3 Canary 2"
sha256Hash = "sha256-z8GpBqyEnbyyBc0XPo5q52WS5d7b4292QgUj0FPW+C0=";
url = "https://edgedl.me.gvt1.com/android/studio/ide-zips/2025.3.3.2/android-studio-panda3-canary2-linux.tar.gz";
version = "2025.3.4.3"; # "Android Studio Panda 4 | 2025.3.4 Canary 3"
sha256Hash = "sha256-8fqHdU6IPuRmcJeCZQOqUPgfild9k98sLnN77dl2Hs8=";
url = "https://edgedl.me.gvt1.com/android/studio/ide-zips/2025.3.4.3/android-studio-panda4-canary3-linux.tar.gz";
};
in
{
@@ -16,7 +16,7 @@ getLatest() {
*) local select=".channel == \"${channel^}\"" ;;
esac
local result="$(echo "$RELEASES_JSON" \
| jq -r ".content.item[] | select(${select}) | [.version, .${attribute}] | join(\" \")" \
| jq -r ".content.item[] | select(${select}) | [.version, (${attribute})] | join(\" \")" \
| sort --version-sort \
| cut -d' ' -f 2- \
| tail -n 1)"
@@ -24,14 +24,14 @@ getLatest() {
if [[ -n "$result" ]]; then
echo "$result"
else
echo "could not find the latest $attribute for $channel"
echo "could not find the latest $attribute for $channel" >&2
exit 1
fi
}
updateChannel() {
local channel="$1"
local latestVersion="$(getLatest "version" "$channel")"
local latestVersion="$(getLatest ".version" "$channel")"
local localVersion="$(nix --extra-experimental-features nix-command eval --raw --file . androidStudioPackages."${channel}".version)"
if [[ "${latestVersion}" == "${localVersion}" ]]; then
@@ -40,15 +40,24 @@ updateChannel() {
fi
echo "updating $channel from $localVersion to $latestVersion"
local latestHash="$(nix-prefetch-url "https://dl.google.com/dl/android/studio/ide-zips/${latestVersion}/android-studio-${latestVersion}-linux.tar.gz")"
local latestSri="$(nix --extra-experimental-features nix-command hash to-sri --type sha256 "$latestHash")"
local latestUrl="$(getLatest "[.download[] | select(.link | endswith(\"-linux.tar.gz\"))][0].link" "$channel")"
local latestHash="$(getLatest "[.download[] | select(.link | endswith(\"-linux.tar.gz\"))][0].checksum" "$channel")"
if [[ "$latestUrl" != https://edgedl.me.gvt1.com/android/studio/* ]]; then
echo "URL '$latestUrl' had an unexpected value, maybe the server changed?" >&2
exit 1
fi
local latestSri="$(nix --extra-experimental-features nix-command hash convert --from base16 --hash-algo sha256 "$latestHash")"
local localUrl="$(nix --extra-experimental-features nix-command eval --json --file . androidStudioPackages."${channel}".unwrapped.src.drvAttrs.urls | jq -r '.[0]')"
local localHash="$(nix --extra-experimental-features nix-command eval --raw --file . androidStudioPackages."${channel}".unwrapped.src.drvAttrs.outputHash)"
sed -i "s~${localHash}~${latestSri}~g" "${DEFAULT_NIX}"
# Match the formatting of default.nix: `version = "2021.3.1.14"; # "Android Studio Dolphin (2021.3.1) Beta 5"`
local versionString="${latestVersion}\"; # \"$(getLatest "name" "${channel}")\""
local versionString="${latestVersion}\"; # \"$(getLatest ".name" "${channel}")\""
sed -i "s~${localUrl}~${latestUrl}~g" "${DEFAULT_NIX}"
sed -i "s~${localVersion}.*~${versionString}~g" "${DEFAULT_NIX}"
echo "updated ${channel} to ${latestVersion}"
echo "updated ${channel} to ${latestVersion}" >&2
}
if (( $# == 0 )); then
@@ -60,8 +69,10 @@ else
case "$1" in
beta|canary|stable)
updateChannel "$1" ;;
dev)
echo "no autoupdate for dev" >&2 && exit 0 ;;
*)
echo "unknown channel: $1" && exit 1 ;;
echo "unknown channel: $1" >&2 && exit 1 ;;
esac
shift 1
done
@@ -83,6 +83,10 @@
"date": "2026-02-04",
"new": "bats-vim"
},
"bitbake-vim": {
"date": "2026-04-09",
"new": "bitbake"
},
"calendar": {
"date": "2026-02-04",
"new": "calendar-vim"
@@ -1582,6 +1582,19 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
bitbake = buildVimPlugin {
pname = "bitbake";
version = "2.12.0-unstable-2026-04-08";
src = fetchFromGitHub {
owner = "openembedded";
repo = "bitbake";
rev = "5d722b5d65e4eef7befe6376983385421e993f86";
hash = "sha256-nOnNIXRUxsYNaEBhWuzCMTg37C9/S4ekxNbCpvBe+TU=";
};
meta.homepage = "https://github.com/openembedded/bitbake/";
meta.hydraPlatforms = [ ];
};
blame-nvim = buildVimPlugin {
pname = "blame.nvim";
version = "0-unstable-2026-02-12";
@@ -2245,6 +2258,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
clangd_extensions-nvim = buildVimPlugin {
pname = "clangd_extensions.nvim";
version = "0-unstable-2026-01-12";
src = fetchgit {
url = "https://git.sr.ht/~p00f/clangd_extensions.nvim";
rev = "997d20e6bc83ea1a6223c08d2b9db76943abf56b";
hash = "sha256-5XES8qyl3tdMmsT+mkVcJ1sC5AKJDpHI/elsoB8XE/8=";
};
meta.homepage = "https://git.sr.ht/~p00f/clangd_extensions.nvim";
meta.hydraPlatforms = [ ];
};
claude-code-nvim = buildVimPlugin {
pname = "claude-code.nvim";
version = "0.4.3-unstable-2026-02-04";
@@ -2414,6 +2439,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
cmp-async-path = buildVimPlugin {
pname = "cmp-async-path";
version = "0-unstable-2026-01-28";
src = fetchgit {
url = "https://codeberg.org/FelipeLema/cmp-async-path/";
rev = "f8af3f726e07f2e9d37672eaa9102581aefce149";
hash = "sha256-ALMK7TnEB7/UZibVgOl4r6/gYsHCo6YAZcAR536VL4g=";
};
meta.homepage = "https://codeberg.org/FelipeLema/cmp-async-path/";
meta.hydraPlatforms = [ ];
};
cmp-beancount = buildVimPlugin {
pname = "cmp-beancount";
version = "0-unstable-2025-11-26";
@@ -6021,6 +6058,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
gitlab-vim = buildVimPlugin {
pname = "gitlab.vim";
version = "1.1.0-unstable-2026-03-17";
src = fetchgit {
url = "https://gitlab.com/gitlab-org/editor-extensions/gitlab.vim";
rev = "cb750761acf8dc17f4f1051d1b4ade6c0aaeb432";
hash = "sha256-rhYz3Z1Dcffvo8E3390gOBcqfFclWJ19wTKwp6L/874=";
};
meta.homepage = "https://gitlab.com/gitlab-org/editor-extensions/gitlab.vim";
meta.hydraPlatforms = [ ];
};
gitlineage-nvim = buildVimPlugin {
pname = "gitlineage.nvim";
version = "0-unstable-2026-02-14";
@@ -6451,6 +6500,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
hare-vim = buildVimPlugin {
pname = "hare.vim";
version = "0-unstable-2026-02-05";
src = fetchgit {
url = "https://git.sr.ht/~sircmpwn/hare.vim";
rev = "cbc1195ce25b853788d3006c34ff6be0aba6483d";
hash = "sha256-zueMmX8rHXMpnv6ukrcFcTIWVOoYrBC/0Tn2+5fTRlU=";
};
meta.homepage = "https://git.sr.ht/~sircmpwn/hare.vim";
meta.hydraPlatforms = [ ];
};
harpoon = buildVimPlugin {
pname = "harpoon";
version = "0-unstable-2024-08-29";
@@ -7337,6 +7398,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
jsonfly-nvim = buildVimPlugin {
pname = "jsonfly.nvim";
version = "0-unstable-2025-11-02";
src = fetchgit {
url = "https://git.myzel394.app/Myzel394/jsonfly.nvim";
rev = "3d58635cb195a5435743e7882c6ac7cff710204f";
hash = "sha256-bTh/6zmYQ+XqBsccKo8i149nU5bBfFv+8UKMayHIoo4=";
};
meta.homepage = "https://git.myzel394.app/Myzel394/jsonfly.nvim";
meta.hydraPlatforms = [ ];
};
jule-nvim = buildVimPlugin {
pname = "jule.nvim";
version = "0-unstable-2025-12-26";
@@ -8273,6 +8346,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
lsp_lines-nvim = buildVimPlugin {
pname = "lsp_lines.nvim";
version = "3.0.0-unstable-2024-12-21";
src = fetchgit {
url = "https://git.sr.ht/~whynothugo/lsp_lines.nvim";
rev = "a92c755f182b89ea91bd8a6a2227208026f27b4d";
hash = "sha256-jHiIZemneQACTDYZXBJqX2/PRTBoxq403ILvt1Ej1ZM=";
};
meta.homepage = "https://git.sr.ht/~whynothugo/lsp_lines.nvim";
meta.hydraPlatforms = [ ];
};
lsp_signature-nvim = buildVimPlugin {
pname = "lsp_signature.nvim";
version = "0.3.1-unstable-2026-04-07";
@@ -11640,6 +11725,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
nvim-julia-autotest = buildVimPlugin {
pname = "nvim-julia-autotest";
version = "0-unstable-2022-10-31";
src = fetchgit {
url = "https://gitlab.com/usmcamp0811/nvim-julia-autotest";
rev = "b74e2f9c961e604cb56cc23f87188348bfa0f33f";
hash = "sha256-IaNsbBe5q7PB9Q/N/Z9nEnP6jlkQ6+xlkC0TCFnJpkk=";
};
meta.homepage = "https://gitlab.com/usmcamp0811/nvim-julia-autotest";
meta.hydraPlatforms = [ ];
};
nvim-jump = buildVimPlugin {
pname = "nvim-jump";
version = "0-unstable-2026-04-08";
@@ -13813,6 +13910,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
rainbow-delimiters-nvim = buildVimPlugin {
pname = "rainbow-delimiters.nvim";
version = "0.12.0-unstable-2026-04-06";
src = fetchgit {
url = "https://gitlab.com/HiPhish/rainbow-delimiters.nvim";
rev = "aab6caaffd79b8def22ec4320a5344f7c42f58d2";
hash = "sha256-aQM0Ay5GZZwcTnZ2PV4iucyBmoik98EAeIPIIJSxuYk=";
};
meta.homepage = "https://gitlab.com/HiPhish/rainbow-delimiters.nvim";
meta.hydraPlatforms = [ ];
};
rainbow_csv = buildVimPlugin {
pname = "rainbow_csv";
version = "4.3.0-unstable-2024-07-05";
@@ -14712,6 +14821,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
sonarlint-nvim = buildVimPlugin {
pname = "sonarlint.nvim";
version = "0-unstable-2026-01-19";
src = fetchgit {
url = "https://gitlab.com/schrieveslaach/sonarlint.nvim";
rev = "acd09b78969ddc965a7ddf59abb9d9eec5ecd94f";
hash = "sha256-71emILbp291AZmh9Rc0S92mbkcZ88zjCvPTaumEM7Qg=";
};
meta.homepage = "https://gitlab.com/schrieveslaach/sonarlint.nvim";
meta.hydraPlatforms = [ ];
};
sonarqube-nvim = buildVimPlugin {
pname = "sonarqube.nvim";
version = "0-unstable-2025-06-24";
@@ -21822,6 +21943,18 @@ final: prev: {
meta.hydraPlatforms = [ ];
};
vim-stationeers-ic10-syntax = buildVimPlugin {
pname = "vim-stationeers-ic10-syntax";
version = "0-unstable-2025-11-02";
src = fetchgit {
url = "https://gitlab.com/LittleMorph/vim-ic10";
rev = "74446a16078ef4f3d2088136b32af939fb6bc2a4";
hash = "sha256-YCxrSB7eRQ54iZhpcsAR930Uccj+2ZyogpYGKbcSlys=";
};
meta.homepage = "https://gitlab.com/LittleMorph/vim-ic10";
meta.hydraPlatforms = [ ];
};
vim-strip-trailing-whitespace = buildVimPlugin {
pname = "vim-strip-trailing-whitespace";
version = "1.0-unstable-2022-02-01";
@@ -1,21 +0,0 @@
{
vimUtils,
fetchFromGitHub,
}:
vimUtils.buildVimPlugin rec {
pname = "bitbake-vim";
version = "2.10.4";
# The tags are very messy on the upstream repo. We prefer disabling automatic updates for this plugin.
# nixpkgs-update: no auto update
src = fetchFromGitHub {
owner = "openembedded";
repo = "bitbake";
tag = version;
hash = "sha256-gdxPnRhd4Hj1PWgCU5A/+639ndJXlkdArOBZt6eiZWA=";
};
sourceRoot = "source/contrib/vim";
meta.homepage = "https://github.com/openembedded/bitbake/";
}
@@ -1,26 +0,0 @@
{
lib,
fetchFromSourcehut,
nix-update-script,
vimUtils,
}:
vimUtils.buildVimPlugin {
pname = "clangd_extensions.nvim";
version = "0-unstable-2025-01-27";
src = fetchFromSourcehut {
owner = "~p00f";
repo = "clangd_extensions.nvim";
rev = "db28f29be928d18cbfb86fbfb9f83f584f658feb";
hash = "sha256-XdA638W0Zb85v5uAUNpvUiiQXGKOM2xykD2ClLk8Qpo=";
};
passthru.updateScript = nix-update-script { };
meta = {
description = "Clangd's off-spec features for neovim's LSP client";
homepage = "https://git.sr.ht/~p00f/clangd_extensions.nvim";
license = lib.licenses.mit;
platforms = lib.platforms.all;
};
}
@@ -1,31 +0,0 @@
{
lib,
vimUtils,
fetchFromCodeberg,
nix-update-script,
vimPlugins,
}:
vimUtils.buildVimPlugin {
pname = "cmp-async-path";
version = "0-unstable-2026-01-28";
src = fetchFromCodeberg {
owner = "FelipeLema";
repo = "cmp-async-path";
rev = "f8af3f726e07f2e9d37672eaa9102581aefce149";
hash = "sha256-ALMK7TnEB7/UZibVgOl4r6/gYsHCo6YAZcAR536VL4g=";
};
checkInputs = [ vimPlugins.nvim-cmp ];
passthru.updateScript = nix-update-script {
extraArgs = [ "--version=branch" ];
};
meta = {
description = "Nvim-cmp source for filesystem paths with async processing";
homepage = "https://codeberg.org/FelipeLema/cmp-async-path/";
license = lib.licenses.mit;
platforms = lib.platforms.all;
};
}
@@ -1,29 +0,0 @@
{
lib,
vimUtils,
fetchFromGitLab,
nix-update-script,
}:
let
version = "0.1.1";
in
vimUtils.buildVimPlugin {
pname = "gitlab.vim";
inherit version;
src = fetchFromGitLab {
owner = "gitlab-org/editor-extensions";
repo = "gitlab.vim";
rev = "v${version}";
hash = "sha256-W/FV+i/QJYX6A8uyxAQN4ov1kMd9UFCghFmSQp1kbnM=";
};
passthru.updateScript = nix-update-script { };
meta = {
description = "Integrate GitLab Duo with Neovim";
homepage = "https://gitlab.com/gitlab-org/editor-extensions/gitlab.vim";
license = lib.licenses.mit;
platforms = lib.platforms.all;
};
}
@@ -1,26 +0,0 @@
{
lib,
vimUtils,
fetchFromSourcehut,
nix-update-script,
}:
vimUtils.buildVimPlugin {
pname = "hare.vim";
version = "0-unstable-2025-04-24";
src = fetchFromSourcehut {
owner = "~sircmpwn";
repo = "hare.vim";
rev = "41b8b615f46a39d807a9a069039aac79c925c389";
hash = "sha256-GPFoQI6tipcLzkvjaeufmMrNnQM46lPas9D1SwzjKF4=";
};
passthru.updateScript = nix-update-script { };
meta = {
description = "Hare programming in Vim";
homepage = "https://git.sr.ht/~sircmpwn/hare.vim";
license = lib.licenses.vim;
platforms = lib.platforms.all;
};
}
@@ -1,27 +0,0 @@
{
lib,
fetchFromGitea,
vimUtils,
nix-update-script,
}:
vimUtils.buildVimPlugin {
pname = "jsonfly.nvim";
version = "0-unstable-2025-06-07";
src = fetchFromGitea {
domain = "git.myzel394.app";
owner = "Myzel394";
repo = "jsonfly.nvim";
rev = "db4394d856059d99d82ea2c75d033721e9dcb1fc";
hash = "sha256-PmYm+vZ0XONoHUo08haBozbXRpN+/LAlr6Fyg7anTNw=";
};
passthru.updateScript = nix-update-script { };
meta = {
description = "Search blazingly fast for JSON / XML / YAML keys via Telescope";
homepage = "https://git.myzel394.app/Myzel394/jsonfly.nvim";
platforms = lib.platforms.all;
maintainers = with lib.maintainers; [ myzel394 ];
};
}
@@ -1,29 +0,0 @@
{
lib,
vimUtils,
fetchFromSourcehut,
nix-update-script,
}:
let
version = "3.0.0";
in
vimUtils.buildVimPlugin {
pname = "lsp_lines.nvim";
inherit version;
src = fetchFromSourcehut {
owner = "~whynothugo";
repo = "lsp_lines.nvim";
rev = "v${version}";
hash = "sha256-QsvmPOer7JgO7Y+N/iaNJD7Kmy69gnlV4CeyaQesNvA=";
};
passthru.updateScript = nix-update-script { };
meta = {
description = "Neovim diagnostics using virtual lines";
homepage = "https://git.sr.ht/~whynothugo/lsp_lines.nvim";
license = lib.licenses.mit;
platforms = lib.platforms.all;
};
}
@@ -1,28 +0,0 @@
{
lib,
vimUtils,
fetchFromGitLab,
nix-update-script,
}:
vimUtils.buildVimPlugin {
pname = "nvim-julia-autotest";
version = "0-unstable-2022-10-31";
src = fetchFromGitLab {
owner = "usmcamp0811";
repo = "nvim-julia-autotest";
rev = "b74e2f9c961e604cb56cc23f87188348bfa0f33f";
hash = "sha256-IaNsbBe5q7PB9Q/N/Z9nEnP6jlkQ6+xlkC0TCFnJpkk=";
};
passthru.updateScript = nix-update-script {
extraArgs = [ "--version=branch" ];
};
meta = {
description = "Automatically run Julia tests when you save runtest.jl file";
homepage = "https://gitlab.com/usmcamp0811/nvim-julia-autotest";
license = lib.licenses.gpl3;
platforms = lib.platforms.all;
};
}
@@ -1,33 +0,0 @@
{
lib,
vimUtils,
fetchFromGitLab,
nix-update-script,
}:
vimUtils.buildVimPlugin rec {
pname = "rainbow-delimiters.nvim";
version = "0.12.0";
src = fetchFromGitLab {
owner = "HiPhish";
repo = "rainbow-delimiters.nvim";
tag = "v${version}";
hash = "sha256-q4cBvF8d5h+BM1LTm5aq02OBVmwSUb9rC1smHlxbRzg=";
};
nvimSkipModules = [
# rainbow-delimiters.types.lua
"rainbow-delimiters.types"
# Test that requires an unpackaged dependency
"rainbow-delimiters._test.highlight"
];
passthru.updateScript = nix-update-script { };
meta = {
description = "Rainbow delimiters for Neovim with Tree-sitter";
homepage = "https://gitlab.com/HiPhish/rainbow-delimiters.nvim";
license = lib.licenses.gpl3;
platforms = lib.platforms.all;
};
}
@@ -1,28 +0,0 @@
{
lib,
vimUtils,
fetchFromGitLab,
nix-update-script,
}:
vimUtils.buildVimPlugin {
pname = "sonarlint.nvim";
version = "0-unstable-2026-01-19";
src = fetchFromGitLab {
owner = "schrieveslaach";
repo = "sonarlint.nvim";
rev = "acd09b78969ddc965a7ddf59abb9d9eec5ecd94f";
hash = "sha256-71emILbp291AZmh9Rc0S92mbkcZ88zjCvPTaumEM7Qg=";
};
passthru.updateScript = nix-update-script {
extraArgs = [ "--version=branch" ];
};
meta = {
homepage = "https://gitlab.com/schrieveslaach/sonarlint.nvim";
description = "Extensions for the built-in Language Server Protocol support in Neovim for sonarlint-language-server";
license = lib.licenses.gpl3;
maintainers = [ lib.maintainers.sinics ];
};
}
@@ -1,28 +0,0 @@
{
lib,
vimUtils,
fetchFromGitLab,
nix-update-script,
}:
vimUtils.buildVimPlugin {
pname = "vim-ic10";
version = "0-unstable-2025-11-02";
src = fetchFromGitLab {
owner = "LittleMorph";
repo = "vim-ic10";
rev = "74446a16078ef4f3d2088136b32af939fb6bc2a4";
hash = "sha256-YCxrSB7eRQ54iZhpcsAR930Uccj+2ZyogpYGKbcSlys=";
};
passthru.updateScript = nix-update-script {
extraArgs = [ "--version=branch" ];
};
meta = {
description = "Stationeers IC10 syntax highlighting for Vim";
homepage = "https://gitlab.com/LittleMorph/vim-ic10";
license = lib.licenses.mit;
platforms = lib.platforms.all;
};
}
@@ -304,6 +304,10 @@ assertNoAdditions {
];
};
bitbake = super.bitbake.overrideAttrs {
sourceRoot = "source/contrib/vim";
};
blink-cmp-conventional-commits = super.blink-cmp-conventional-commits.overrideAttrs {
dependencies = [ self.blink-cmp ];
};
@@ -506,6 +510,10 @@ assertNoAdditions {
];
};
cmp-async-path = super.cmp-async-path.overrideAttrs {
checkInputs = [ self.nvim-cmp ];
};
cmp-beancount = super.cmp-beancount.overrideAttrs {
checkInputs = [ self.nvim-cmp ];
};
@@ -1560,6 +1568,14 @@ assertNoAdditions {
'';
};
jsonfly-nvim = super.jsonfly-nvim.overrideAttrs (old: {
meta = old.meta // {
maintainers = old.meta.maintainers or [ ] ++ [
lib.maintainers.myzel394
];
};
});
jupytext-nvim = super.jupytext-nvim.overrideAttrs {
passthru.python3Dependencies = ps: [ ps.jupytext ];
};
@@ -3163,6 +3179,15 @@ assertNoAdditions {
];
};
rainbow-delimiters-nvim = super.rainbow-delimiters-nvim.overrideAttrs {
nvimSkipModules = [
# rainbow-delimiters.types.lua
"rainbow-delimiters.types"
# Test that requires an unpackaged dependency
"rainbow-delimiters._test.highlight"
];
};
range-highlight-nvim = super.range-highlight-nvim.overrideAttrs {
dependencies = [ self.cmd-parser-nvim ];
};
@@ -3362,6 +3387,14 @@ assertNoAdditions {
];
};
sonarlint-nvim = super.sonarlint-nvim.overrideAttrs (old: {
meta = old.meta // {
maintainers = old.meta.maintainers or [ ] ++ [
lib.maintainers.sinics
];
};
});
spaceman-nvim = super.spaceman-nvim.overrideAttrs {
# Optional telescope integration
nvimSkipModules = "spaceman.adapters.telescope";
@@ -120,6 +120,7 @@ https://github.com/rbgrouleff/bclose.vim/,,
https://github.com/sontungexpt/better-diagnostic-virtual-text/,HEAD,
https://github.com/max397574/better-escape.nvim/,,
https://github.com/LunarVim/bigfile.nvim/,,
https://github.com/openembedded/bitbake/,HEAD,
https://github.com/FabijanZulj/blame.nvim/,HEAD,
https://github.com/APZelos/blamer.nvim/,HEAD,
https://github.com/Kaiser-Yang/blink-cmp-avante/,HEAD,
@@ -171,6 +172,7 @@ https://github.com/declancm/cinnamon.nvim/,HEAD,
https://github.com/projekt0n/circles.nvim/,,
https://github.com/zootedb0t/citruszest.nvim/,,
https://github.com/xavierd/clang_complete/,,
https://git.sr.ht/~p00f/clangd_extensions.nvim,HEAD,
https://github.com/greggh/claude-code.nvim/,HEAD,
https://github.com/pittcat/claude-fzf-history.nvim/,HEAD,
https://github.com/pittcat/claude-fzf.nvim/,HEAD,
@@ -184,6 +186,7 @@ https://github.com/Civitasv/cmake-tools.nvim/,,
https://github.com/winston0410/cmd-parser.nvim/,,
https://github.com/vim-scripts/cmdalias.vim/,HEAD,
https://github.com/tzachar/cmp-ai/,HEAD,
https://codeberg.org/FelipeLema/cmp-async-path/,HEAD,
https://github.com/crispgm/cmp-beancount/,HEAD,
https://github.com/hrsh7th/cmp-buffer/,,
https://github.com/hrsh7th/cmp-calc/,,
@@ -461,6 +464,7 @@ https://github.com/polarmutex/git-worktree.nvim/,HEAD,
https://github.com/projekt0n/github-nvim-theme/,HEAD,
https://github.com/wintermute-cell/gitignore.nvim/,HEAD,
https://github.com/vim-scripts/gitignore.vim/,,
https://gitlab.com/gitlab-org/editor-extensions/gitlab.vim,HEAD,
https://github.com/LionyxML/gitlineage.nvim/,HEAD,
https://github.com/ruifm/gitlinker.nvim/,,
https://github.com/trevorhauter/gitportal.nvim/,,
@@ -494,6 +498,7 @@ https://github.com/junegunn/gv.vim/,,
https://github.com/chrishrb/gx.nvim/,HEAD,
https://github.com/TheSnakeWitcher/hardhat.nvim/,HEAD,
https://github.com/m4xshen/hardtime.nvim/,HEAD,
https://git.sr.ht/~sircmpwn/hare.vim,HEAD,
https://github.com/ThePrimeagen/harpoon/,master,
https://github.com/ThePrimeagen/harpoon/,harpoon2,harpoon2
https://github.com/kiyoon/haskell-scope-highlighting.nvim/,HEAD,
@@ -562,6 +567,7 @@ https://github.com/HiPhish/jinja.vim/,HEAD,
https://github.com/NicolasGB/jj.nvim/,HEAD,
https://github.com/vito-c/jq.vim/,,
https://github.com/neoclide/jsonc.vim/,,
https://git.myzel394.app/Myzel394/jsonfly.nvim,HEAD,
https://github.com/julelang/jule.nvim/,HEAD,
https://github.com/julelang/jule.nvim/,HEAD,
https://github.com/JuliaEditorSupport/julia-vim/,,
@@ -635,6 +641,7 @@ https://github.com/ahmedkhalf/lsp-rooter.nvim/,,
https://github.com/nvim-lua/lsp-status.nvim/,,
https://github.com/VonHeikemen/lsp-zero.nvim/,v3.x,
https://github.com/nvim-lua/lsp_extensions.nvim/,,
https://git.sr.ht/~whynothugo/lsp_lines.nvim,HEAD,
https://github.com/ray-x/lsp_signature.nvim/,,
https://github.com/lspcontainers/lspcontainers.nvim/,,
https://github.com/deathbeam/lspecho.nvim/,HEAD,
@@ -894,6 +901,7 @@ https://github.com/nvim-java/nvim-java-refactor/,HEAD,
https://github.com/nvim-java/nvim-java-test/,HEAD,
https://codeberg.org/mfussenegger/nvim-jdtls/,,
https://github.com/gennaro-tedesco/nvim-jqx/,,
https://gitlab.com/usmcamp0811/nvim-julia-autotest,HEAD,
https://github.com/yorickpeterse/nvim-jump/,HEAD,
https://github.com/anasinnyk/nvim-k8s-crd/,HEAD,
https://github.com/ethanholz/nvim-lastplace/,HEAD,
@@ -1061,6 +1069,7 @@ https://github.com/stefandtw/quickfix-reflector.vim/,,
https://github.com/dannyob/quickfixstatus/,,
https://github.com/jbyuki/quickmath.nvim/,HEAD,
https://github.com/luochen1990/rainbow/,,
https://gitlab.com/HiPhish/rainbow-delimiters.nvim,HEAD,
https://github.com/mechatroner/rainbow_csv/,HEAD,
https://github.com/kien/rainbow_parentheses.vim/,,
https://github.com/vim-scripts/random.vim/,,
@@ -1130,6 +1139,7 @@ https://github.com/leath-dub/snipe.nvim/,HEAD,
https://github.com/norcalli/snippets.nvim/,,
https://github.com/craftzdog/solarized-osaka.nvim/,HEAD,
https://github.com/shaunsingh/solarized.nvim/,HEAD,
https://gitlab.com/schrieveslaach/sonarlint.nvim,HEAD,
https://github.com/iamkarasik/sonarqube.nvim/,HEAD,
https://github.com/sainnhe/sonokai/,,
https://github.com/sQVe/sort.nvim/,HEAD,
@@ -1676,6 +1686,7 @@ https://github.com/kbenzie/vim-spirv/,,
https://github.com/yorokobi/vim-splunk/,HEAD,
https://github.com/mhinz/vim-startify/,,
https://github.com/dstein64/vim-startuptime/,,
https://gitlab.com/LittleMorph/vim-ic10,HEAD,vim-stationeers-ic10-syntax
https://github.com/axelf4/vim-strip-trailing-whitespace/,,
https://github.com/nbouscal/vim-stylish-haskell/,,
https://github.com/alx741/vim-stylishask/,,
@@ -3073,8 +3073,8 @@ let
mktplcRef = {
name = "compare-folders";
publisher = "moshfeu";
version = "0.28.0";
hash = "sha256-QoaZ/P2lIaJQjD9RF7+pUJkOneR9olCe6xuT/9vsiZ4=";
version = "0.29.0";
hash = "sha256-oX4182qaoHbvZC9MdzzARBlW4MbtE7H0Fg687K5h2XQ=";
};
meta = {
@@ -54,13 +54,13 @@
"vendorHash": "sha256-Kk0YeStlev8AurZasORMe/42Rd3ZPFoFMat/rMpZFbE="
},
"aminueza_minio": {
"hash": "sha256-aWsMTUNIDwBzI/qsy78uA3ELnzUA+c4jP2jGD7QqrvI=",
"hash": "sha256-Qt51J0DcwrpJ9+8s8KwngGhhFhZQQYv3dAwFGOYvavo=",
"homepage": "https://registry.terraform.io/providers/aminueza/minio",
"owner": "aminueza",
"repo": "terraform-provider-minio",
"rev": "v3.28.1",
"rev": "v3.30.0",
"spdx": "AGPL-3.0",
"vendorHash": "sha256-kg6RylB2sW5XLWxJLmIDq3h54rzQoCKrxVu7L76lvCE="
"vendorHash": "sha256-Mm7IwFX51hsG3ducCbanRoelgkyK6pe+9K8d18U01Z8="
},
"argoproj-labs_argocd": {
"hash": "sha256-c6+WY4oXL8evvPk/RzVrwtgq4XLB/LzAH5tpjErbE60=",
@@ -274,13 +274,13 @@
"vendorHash": "sha256-3o6YRDrq4rQhNAFyqiGJrAoxuAykWw85OExRGSE3kGI="
},
"datadog_datadog": {
"hash": "sha256-Is1XgOFmRl1Ieua5ZlBI/4bHal4AhsPhbl95r97bYN4=",
"hash": "sha256-WMggvZAgj36OyelTSE8I/1GRoTivs7q9szUbAFi6XdY=",
"homepage": "https://registry.terraform.io/providers/DataDog/datadog",
"owner": "DataDog",
"repo": "terraform-provider-datadog",
"rev": "v4.3.0",
"rev": "v4.4.0",
"spdx": "MPL-2.0",
"vendorHash": "sha256-4A7qf+1RZYWyA5G/qSFhOjDR4GUtGzkh6m81n3Nvads="
"vendorHash": "sha256-2uj7Ff8g43s2T+zQIbTYFxxuaLpFxPQRo2z/0HNmh9k="
},
"datadrivers_nexus": {
"hash": "sha256-yfxlDln4brI8QTFnhVsNOO3vRiqft3YWytvy2GMNBdY=",
@@ -364,13 +364,13 @@
"vendorHash": "sha256-RtS88NqkO1nG/8znM0sQqsAIfDc+sOMy8N4T4hmvaVA="
},
"e-breuninger_netbox": {
"hash": "sha256-a9YE3zbMPLKyrD2hG31ymKxI780ONzKfzEPHCN2NhyA=",
"hash": "sha256-hY3XZFMP1qT4mHJpxsVSGsyd025NOeJogbh2m9hk7qE=",
"homepage": "https://registry.terraform.io/providers/e-breuninger/netbox",
"owner": "e-breuninger",
"repo": "terraform-provider-netbox",
"rev": "v5.2.1",
"rev": "v5.3.0",
"spdx": "MPL-2.0",
"vendorHash": "sha256-/kTRJnHbr9crrzdKsDz0q7svYTmiuDbSW/6kBfGgyZY="
"vendorHash": "sha256-5IZeoZpZj4vgAlyxbycs+IPeOEBS1tw3tM/7zoT4DCg="
},
"equinix_equinix": {
"hash": "sha256-Tn8CnLx2ibkj7qlzpYCX7Cm+yoTcZujVELMJSbG+/ec=",
+3 -3
View File
@@ -8,13 +8,13 @@
}:
stdenv.mkDerivation {
pname = "airwindows";
version = "0-unstable-2026-04-01";
version = "0-unstable-2026-04-04";
src = fetchFromGitHub {
owner = "airwindows";
repo = "airwindows";
rev = "974a26ea5a96a3cd57c3f8f8d95745bb765a5a72";
hash = "sha256-Gin8I86TpLVG9SzfErVZobryW3rZQEidwLrUb7sd+rs=";
rev = "714ffb2db6f799067e63bf1f88ae8a89f4ee0d3c";
hash = "sha256-Ed8U0AC+9ggsPS+fWfm7yBdnygjhHIdUtJlML2J4zKY=";
};
# we patch helpers because honestly im spooked out by where those variables
+2 -2
View File
@@ -8,11 +8,11 @@
stdenv.mkDerivation (finalAttrs: {
pname = "allure";
version = "2.38.1";
version = "2.39.0";
src = fetchurl {
url = "https://github.com/allure-framework/allure2/releases/download/${finalAttrs.version}/allure-${finalAttrs.version}.tgz";
hash = "sha256-y241mNyZsqiwvYgFeAgqxevq6bLiwKEdx1yFD7aXNr0=";
hash = "sha256-dDg/ZgacwPbsLQ/a0vHXYfExhPbNKJM0sdz8QjdzVmU=";
};
dontConfigure = true;
@@ -8,13 +8,13 @@
stdenvNoCC.mkDerivation (finalAttrs: {
pname = "application-title-bar";
version = "0.9.0";
version = "0.9.1";
src = fetchFromGitHub {
owner = "antroids";
repo = "application-title-bar";
tag = "v${finalAttrs.version}";
hash = "sha256-bnuMlssXALcFBnBY0iXhZO4QqW2hM9r0y8Ywe2X2/wA=";
hash = "sha256-UsAZaYA088nJWnVkT7Awcib3G3JUNTY0mA8ao+9m4d0=";
};
propagatedUserEnvPkgs = with kdePackages; [ kconfig ];
+3 -3
View File
@@ -10,17 +10,17 @@
}:
buildGoModule (finalAttrs: {
pname = "aws-vault";
version = "7.9.13";
version = "7.9.14";
src = fetchFromGitHub {
owner = "ByteNess";
repo = "aws-vault";
rev = "v${finalAttrs.version}";
hash = "sha256-O0O7sIx9h5DKrKdqi0ecNM6ImRmCsrUGnk94yn5SRYg=";
hash = "sha256-L3WJtS94EYgNqgwM2Gzayx89l2aKHkjaGNwOtfJMk3o=";
};
proxyVendor = true;
vendorHash = "sha256-RcQQL+exDBQn5vo+9OT5ShD92WDDjfE+Seqmofiz7hs=";
vendorHash = "sha256-axxV3XCxZVY3UM0yzC2ziTO0cbwJiNnDkOKAQADKUKA=";
nativeBuildInputs = [
installShellFiles
+3 -3
View File
@@ -8,16 +8,16 @@
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "cargo-leptos";
version = "0.3.5";
version = "0.3.6";
src = fetchFromGitHub {
owner = "leptos-rs";
repo = "cargo-leptos";
rev = "v${finalAttrs.version}";
hash = "sha256-wSnz3Hi+hUTwYFXoWMC6Uq9UH0+q0vHoryNwn4t8iMk=";
hash = "sha256-Y81cCy1w4FoWRyTN15BuC9Z8FSVPJxYObXms0rJHxwM=";
};
cargoHash = "sha256-2ax2yH/dMgXRVNffbl59OTeeMG+v83MnQnsyylrW22s=";
cargoHash = "sha256-Wv1gsrcrsJ3izYYFCPMO4ds1w6RQcIlWh+GcsckoKM4=";
nativeBuildInputs = [ pkg-config ];
+3 -3
View File
@@ -12,18 +12,18 @@
stdenv.mkDerivation (finalAttrs: {
pname = "cdk8s-cli";
version = "2.205.6";
version = "2.206.3";
src = fetchFromGitHub {
owner = "cdk8s-team";
repo = "cdk8s-cli";
rev = "v${finalAttrs.version}";
hash = "sha256-ZHorjCZbZ8Lu7DwhAbCC/uKNrg+rYwL75NCjKskh/JM=";
hash = "sha256-ezxwAhSxDSmP4DhT4vF8nuO+TcnWgLk5szJb3RIv1xg=";
};
yarnOfflineCache = fetchYarnDeps {
inherit (finalAttrs) src;
hash = "sha256-VAy3k99JB2j4MUCwXKyxSl+9OmGC1/xoJBF1/Xvuc54=";
hash = "sha256-fkG7gre4OOpoZf/vQAJU0Lnbl7eDsgZy0H/+4C7aWvI=";
};
nativeBuildInputs = [
+2 -2
View File
@@ -13,12 +13,12 @@
}:
stdenv.mkDerivation (finalAttrs: {
pname = "clojure";
version = "1.12.4.1618";
version = "1.12.4.1629";
src = fetchurl {
# https://github.com/clojure/brew-install/releases
url = "https://github.com/clojure/brew-install/releases/download/${finalAttrs.version}/clojure-tools-${finalAttrs.version}.tar.gz";
hash = "sha256-E3adptY6mN6yAkN4rhpk5O4hGsEDU0DfynppRMQc3iE=";
hash = "sha256-swBF0lh+vAvPHKKoXHXXHcVtfHTefu5tx/3vwl93KM4=";
};
nativeBuildInputs = [
+2 -2
View File
@@ -9,13 +9,13 @@
buildGoModule (finalAttrs: {
pname = "cog";
version = "0.1.5";
version = "0.1.6";
src = fetchFromGitHub {
owner = "grafana";
repo = "cog";
tag = "v${finalAttrs.version}";
hash = "sha256-QMYqrPmJjDmB7Kc9HZN9ypqtiwF9Cah3fnj4iMM8W4Y=";
hash = "sha256-Dbp+7+nokUUKP8GW3xqRhx3Zn1ltEndkpk1iHRRgPug=";
};
vendorHash = "sha256-KOk8SvajH98jjvoPZPC4UAsF5tXKjn1xcVq5juQXQVA=";
+2 -2
View File
@@ -8,13 +8,13 @@
buildGoModule (finalAttrs: {
pname = "ctlptl";
version = "0.9.1";
version = "0.9.2";
src = fetchFromGitHub {
owner = "tilt-dev";
repo = "ctlptl";
rev = "v${finalAttrs.version}";
hash = "sha256-vbg3gaVCFkQ6jKguNq6ClstEKpTrk9ryUG572emEY4U=";
hash = "sha256-0Y1baXkb37UKtT/lcoFdunRkxIpSCh+zfkjkZZ9SfXU=";
};
vendorHash = "sha256-b9lzCNjO0rrK/kJlw5dssuQD/cyf/Wu/LJ2YNQ645LE=";
+3 -3
View File
@@ -10,16 +10,16 @@
buildGoModule (finalAttrs: {
pname = "cue";
version = "0.16.0";
version = "0.16.1";
src = fetchFromGitHub {
owner = "cue-lang";
repo = "cue";
tag = "v${finalAttrs.version}";
hash = "sha256-dmoBux8yeyXa2bNL/qpQ0UDdXlAV8/aT1Xc4xnH0EFQ=";
hash = "sha256-mTj3XMWByNrKjm+/MOQGLyUKIv4JJ8i6Oaphbzls84U=";
};
vendorHash = "sha256-KPhwu4Z8PcXr74NEZ9+Uz7FHIMzcKqkd20FDFW+a2NA=";
vendorHash = "sha256-HXRrVPjPc10Q1MVr1d9vZBWgSVqNZ5J0UgvP/hTPfcg=";
subPackages = [ "cmd/*" ];
+4 -4
View File
@@ -11,16 +11,16 @@
buildGoModule (finalAttrs: {
pname = "discordo";
version = "0-unstable-2026-03-30";
version = "0-unstable-2026-04-09";
src = fetchFromGitHub {
owner = "ayn2op";
repo = "discordo";
rev = "48f3b5316c6a340da845c5d050b9de44d680184a";
hash = "sha256-1SOpy8XCdfsY/Fbp4NjDS9KFA/zcSIIjZHMjIEYB+8M=";
rev = "d804e0271c51239e18109dd786be73347cf21dfd";
hash = "sha256-dgj3JWJ3NGwBvvHV/phfjIHa612XNUfYArXXpzJ0Mf4=";
};
vendorHash = "sha256-yQlx61R1Lx5fkctSkm64uYLqHeZZydVubpIaP00XA+U=";
vendorHash = "sha256-BSYPEUE6qyNY4+ur+uVB66ogYVktm9AUCzLTMiJMmKQ=";
env.CGO_ENABLED = 1;
+2 -2
View File
@@ -59,13 +59,13 @@ in
stdenv.mkDerivation (finalAttrs: {
pname = "easyeffects";
version = "8.1.6";
version = "8.1.8";
src = fetchFromGitHub {
owner = "wwmm";
repo = "easyeffects";
tag = "v${finalAttrs.version}";
hash = "sha256-MNBlhwF8quJ0wXBzwyn7KM2TNgbYbWYHTK6itn0fUVU=";
hash = "sha256-U0+OGxej5my2KpqzRTiHrB80arkWT1mxHOSxOCDsnb0=";
};
nativeBuildInputs = [
+3 -3
View File
@@ -10,7 +10,7 @@
rustPlatform.buildRustPackage (finalAttrs: {
pname = "ffizer";
version = "2.13.7";
version = "2.13.8";
buildFeatures = [ "cli" ];
@@ -18,10 +18,10 @@ rustPlatform.buildRustPackage (finalAttrs: {
owner = "ffizer";
repo = "ffizer";
rev = finalAttrs.version;
hash = "sha256-r4jaqjHYDZxftU7J6hGMXW/Oq+8biy9bFoHIOt33ta8=";
hash = "sha256-TV1+bupdJFmq72F4MbqyyvE/p9PufdeOUo24mPYvuAc=";
};
cargoHash = "sha256-+aXhumywpcynKz0R0wWPWhEMfqiPBuwLbIFsABvWTnA=";
cargoHash = "sha256-iEdNyzY4fzfQkayXIKthv4ofl11+U2KfV63VvXrR6HQ=";
nativeBuildInputs = [
pkg-config
+4 -4
View File
@@ -9,10 +9,10 @@
}:
let
version = "2.8.3";
srcHash = "sha256-5bs7atecd7NqUrJySMxOe01zGpTMbgrau5B6QkUTRyg=";
vendorHash = "sha256-ICI9Lace4gv2GE/nb9y5yRlvsOkujr2DA2gQ8PnIrIs=";
manifestsHash = "sha256-V1rWHu23K4224eiwUuueG2vk3LsdgtvVGZVQG5vBhLQ=";
version = "2.8.5";
srcHash = "sha256-2Q6l+egcRntGjieXpXz/frGGw4GMhGXxQAUOAZfxBE4=";
vendorHash = "sha256-D92vOyTvlpOou/1WHS6xpb4e8igZMQhm4DP7SVSLKPI=";
manifestsHash = "sha256-X0Cf8UZufqUWKLxYVjblYNCz5IU/s+mI+h6TpTeks5k=";
manifests = fetchzip {
url = "https://github.com/fluxcd/flux2/releases/download/v${version}/manifests.tar.gz";
@@ -1,38 +1,20 @@
{
stdenv,
buildPythonApplication,
fetchFromGitHub,
isPyPy,
lib,
chevron,
defusedxml,
packaging,
psutil,
pyinstrument,
setuptools,
nixosTests,
pytestCheckHook,
which,
podman,
selenium,
python-jose,
# Optional dependencies:
fastapi,
jinja2,
pysnmp,
stdenv,
fetchFromGitHub,
hddtemp,
uvicorn,
requests,
prometheus-client,
shtab,
nixosTests,
podman,
python3Packages,
which,
}:
buildPythonApplication (finalAttrs: {
python3Packages.buildPythonApplication (finalAttrs: {
pname = "glances";
version = "4.5.2";
pyproject = true;
disabled = isPyPy;
disabled = python3Packages.isPyPy;
src = fetchFromGitHub {
owner = "nicolargo";
@@ -41,7 +23,7 @@ buildPythonApplication (finalAttrs: {
hash = "sha256-o/q/zW7lRKQg+u4XblwNIswCVIroMdeUaPTNkN8QKwo=";
};
build-system = [ setuptools ];
build-system = with python3Packages; [ setuptools ];
# On Darwin this package segfaults due to mismatch of pure and impure
# CoreFoundation. This issues was solved for binaries but for interpreted
@@ -56,34 +38,40 @@ buildPythonApplication (finalAttrs: {
# some tests fail in darwin sandbox
doCheck = !stdenv.hostPlatform.isDarwin;
dependencies = [
defusedxml
packaging
psutil
pyinstrument
pysnmp
fastapi
uvicorn
requests
jinja2
python-jose
which
prometheus-client
shtab
]
++ lib.optional stdenv.hostPlatform.isLinux hddtemp;
dependencies =
with python3Packages;
[
defusedxml
packaging
psutil
pyinstrument
pysnmp
fastapi
uvicorn
requests
jinja2
python-jose
prometheus-client
shtab
]
++ [ which ]
++ lib.optionals stdenv.hostPlatform.isLinux [ hddtemp ];
passthru.tests = {
service = nixosTests.glances;
};
nativeCheckInputs = [
chevron
which
pytestCheckHook
selenium
podman
];
nativeCheckInputs =
with python3Packages;
[
chevron
pytestCheckHook
selenium
]
++ [
podman
which
];
disabledTestPaths = [
# Message: Unable to obtain driver for chrome
@@ -0,0 +1,40 @@
diff --git a/go.mod b/go.mod
index 60f4e32..87a9269 100644
--- a/go.mod
+++ b/go.mod
@@ -4,7 +4,6 @@ go 1.25.5
require (
github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c
- github.com/bazelbuild/rules_go v0.44.2
github.com/cenkalti/backoff v2.2.1+incompatible
github.com/cilium/ebpf v0.12.3
github.com/containerd/cgroups v1.0.4
@@ -44,7 +43,6 @@ require (
github.com/Microsoft/go-winio v0.6.0 // indirect
github.com/Microsoft/hcsshim v0.9.12 // indirect
github.com/containerd/ttrpc v1.1.2 // indirect
- github.com/creack/pty v1.1.24 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/docker/go-events v0.0.0-20190806004212-e31b211e4f1c // indirect
github.com/docker/go-units v0.4.0 // indirect
@@ -53,7 +51,6 @@ require (
github.com/golang/protobuf v1.5.4 // indirect
github.com/google/go-cmp v0.7.0 // indirect
github.com/google/gofuzz v1.2.0 // indirect
- github.com/googleapis/enterprise-certificate-proxy v0.3.6 // indirect
github.com/googleapis/gnostic v0.5.5 // indirect
github.com/hashicorp/errwrap v1.1.0 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect
@@ -68,11 +65,9 @@ require (
go.opencensus.io v0.24.0 // indirect
golang.org/x/net v0.44.0 // indirect
golang.org/x/oauth2 v0.30.0 // indirect
- golang.org/x/telemetry v0.0.0-20250908211612-aef8a434d053 // indirect
golang.org/x/term v0.35.0 // indirect
golang.org/x/text v0.29.0 // indirect
golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect
- google.golang.org/api v0.249.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20250818200422-3122310a409c // indirect
google.golang.org/grpc v1.75.1 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
+6 -4
View File
@@ -12,7 +12,7 @@
buildGoModule {
pname = "gvisor";
version = "20251110.0";
version = "20260406.0";
# gvisor provides a synthetic go branch (https://github.com/google/gvisor/tree/go)
# that can be used to build gvisor without bazel.
@@ -21,8 +21,8 @@ buildGoModule {
src = fetchFromGitHub {
owner = "google";
repo = "gvisor";
rev = "2617196c08506a30764bf6261b79d52797916dda";
hash = "sha256-qx1uCRTJVotSbTojBf/Nj8LfLdUvsnxMkPuyJjLLadM=";
rev = "db8d2c9abca39156c61ee2769d52b8a11accbe16";
hash = "sha256-T0ilLqZTX2KNZdR7wuMnYimnL+G5Tbkd77IULCZE764=";
};
# Replace the placeholder with the actual path to ldconfig
@@ -31,7 +31,7 @@ buildGoModule {
--replace-fail '"/sbin/ldconfig"' '"${glibc}/bin/ldconfig"'
'';
vendorHash = "sha256-Ey4M3NK/+AVkr7r0aA+kAfNk1yVfnDn3Izy7u74HFkE=";
vendorHash = "sha256-8Zkgt5hegYEHnG1lF+wLgdru6t3l+Z/qKRvJHukZbPo=";
nativeBuildInputs = [ makeWrapper ];
@@ -60,6 +60,8 @@ buildGoModule {
mv $out/bin/shim $out/bin/containerd-shim-runsc-v1
'';
patches = [ ./fix-go-mod-tidy.diff ];
passthru.tests = { inherit (nixosTests) gvisor; };
meta = {
+4
View File
@@ -33,6 +33,7 @@
re2,
systemd,
tomlplusplus,
uwsm,
wayland,
wayland-protocols,
wayland-scanner,
@@ -100,6 +101,9 @@ customStdenv.mkDerivation (finalAttrs: {
--replace-fail "@PREFIX@/" ""
substituteInPlace example/hyprland.desktop.in \
--replace-fail "@PREFIX@/" ""
substituteInPlace systemd/hyprland-uwsm.desktop \
--replace-fail "Exec=uwsm " "Exec=${lib.getExe uwsm} " \
--replace-fail "TryExec=uwsm" "TryExec=${lib.getExe uwsm}"
'';
# variables used by CMake, and shown in `hyprctl version`
@@ -0,0 +1,25 @@
From 979dcc049c1d8b8b537ddf42133dba38ef17ee7f Mon Sep 17 00:00:00 2001
From: azban <me@azban.net>
Date: Sat, 21 Mar 2026 11:23:30 -0600
Subject: [PATCH] increase recursion limit to fix matrix-sdk-sqlite
This is a temporary fix for build errors in the matrix-sdk-sqlite dependency. A more durable fix should be checked for in https://github.com/matrix-org/matrix-rust-sdk/issues/6254.
---
src/main.rs | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/main.rs b/src/main.rs
index 0a316c7..794f838 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -15,6 +15,7 @@
#![allow(clippy::needless_return)]
#![allow(clippy::result_large_err)]
#![allow(clippy::bool_assert_comparison)]
+#![recursion_limit = "256"]
use std::collections::VecDeque;
use std::convert::TryFrom;
use std::fmt::Display;
--
2.51.2
+4
View File
@@ -19,6 +19,10 @@ rustPlatform.buildRustPackage (finalAttrs: {
hash = "sha256-nvEOtV1Y5K9E1Lj+bPnQ6k1AneDM9OT3RbV3Urm/1Qs=";
};
patches = [
./0001-increase-recursion-limit-to-fix-matrix-sdk-sqlite.patch
];
cargoHash = "sha256-uWYNFNoCiqw6gYuHZWmZmZVs7lKNvhzjwEyxgcbvv+8=";
nativeBuildInputs = [
@@ -5,7 +5,7 @@
buildDotnetModule,
dotnetCorePackages,
powershell,
autoSignDarwinBinariesHook,
darwin,
glibcLocales,
}:
buildDotnetModule (finalAttrs: {
@@ -15,7 +15,7 @@ buildDotnetModule (finalAttrs: {
src = fetchFromGitHub {
owner = "icsharpcode";
repo = "ILSpy";
rev = "v${finalAttrs.version}";
tag = "v${finalAttrs.version}";
hash = "sha256-YkZEStCI6Omu8HgClm5qHnXxm5pKJVILtbydY8vAFic=";
};
@@ -23,7 +23,7 @@ buildDotnetModule (finalAttrs: {
powershell
]
++ lib.optionals (stdenvNoCC.hostPlatform.isDarwin && stdenvNoCC.hostPlatform.isAarch64) [
autoSignDarwinBinariesHook
darwin.autoSignDarwinBinariesHook
];
# https://github.com/NixOS/nixpkgs/issues/38991
@@ -42,7 +42,7 @@ buildDotnetModule (finalAttrs: {
description = "Tool for decompiling .NET assemblies and generating portable PDBs";
mainProgram = "ilspycmd";
homepage = "https://github.com/icsharpcode/ILSpy";
changelog = "https://github.com/icsharpcode/ILSpy/releases/tag/${finalAttrs.src.rev}";
changelog = "https://github.com/icsharpcode/ILSpy/releases/tag/${finalAttrs.src.tag}";
license = with lib.licenses; [
mit
# third party dependencies
+3 -11
View File
@@ -8,16 +8,16 @@
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "iwe";
version = "0.0.64";
version = "0.0.67";
src = fetchFromGitHub {
owner = "iwe-org";
repo = "iwe";
tag = "iwe-v${finalAttrs.version}";
hash = "sha256-aqoUTatYUUFKw3ZQYagQ0KchQM3JMgSzL/hG6CiyG9U=";
hash = "sha256-/irCQgMDuO2boitdTyl4OlkMvuyFPfsTx8Jo/VhLYuw=";
};
cargoHash = "sha256-iTudRDC53wZvWwuPYGG3rQfsC/th+3FwpiqZsZnbekg=";
cargoHash = "sha256-oAIF+ekKzvfT7WzQ+PE4RWUUMMDkBOFBdgwUMXBZsFk=";
cargoBuildFlags = [
"--package=iwe"
@@ -28,14 +28,6 @@ rustPlatform.buildRustPackage (finalAttrs: {
substituteInPlace crates/iwe/tests/common.rs --replace-fail \
'binary_path.push("target");' \
'binary_path.push("target/${stdenv.hostPlatform.rust.rustcTarget}");'
# Tests here are looking for /usr to exist, which is not present in a build environment
substituteInPlace crates/iwes/tests/transform_test.rs --replace-fail \
'cwd: Some("/usr".to_string()),' \
'cwd: Some("/tmp".to_string()),'
substituteInPlace crates/iwes/tests/transform_test.rs --replace-fail \
'vec![uri(1).to_edit("/usr\n")]' \
'vec![uri(1).to_edit("/tmp\n")]'
'';
nativeInstallCheckInputs = [ versionCheckHook ];
+3 -3
View File
@@ -6,15 +6,15 @@
buildGoModule (finalAttrs: {
pname = "jumppad";
version = "0.24.0";
version = "0.25.1";
src = fetchFromGitHub {
owner = "jumppad-labs";
repo = "jumppad";
rev = finalAttrs.version;
hash = "sha256-OH06qQ+gkPv9McHr+YiMRiqTvdvhW9UqcEJK2NZxGQo=";
hash = "sha256-Dqwug09ESljbgANQdmRyQCOswGDxOwhkd7yQiLdEh8M=";
};
vendorHash = "sha256-m2aMRQ/K8etAKgGEcMbOrx2cYxp3ncdLe70Q3zYdj4I=";
vendorHash = "sha256-5eI41EKgi61dVFAvsgxI2Vk1zrxtVinxYKquKlaSOyQ=";
subPackages = [ "." ];
+2 -2
View File
@@ -15,13 +15,13 @@
stdenv.mkDerivation (finalAttrs: {
pname = "libphonenumber";
version = "9.0.27";
version = "9.0.28";
src = fetchFromGitHub {
owner = "google";
repo = "libphonenumber";
tag = "v${finalAttrs.version}";
hash = "sha256-Qcn7Ms2YizAJK5IPVW/NeCUkfH8bk5Mg0xjcMcsE5H8=";
hash = "sha256-Mi+FpM8viPUWgzT8tp3zc9e5fsI9xhlsdsYYlaVRTNk=";
};
patches = [
+3 -3
View File
@@ -11,14 +11,14 @@
python3Packages.buildPythonApplication {
pname = "lichess-bot";
version = "2026.3.29.1";
version = "2026.4.3.1";
pyproject = false;
src = fetchFromGitHub {
owner = "lichess-bot-devs";
repo = "lichess-bot";
rev = "bfd5e5e1005be7c5c4a7c880b6981c7e265fc066";
hash = "sha256-ZsrepZLbIJEqbxyads+nFeO+FPFQ7H56wE6eaT79Fys=";
rev = "98c70bbd693e12eafe1eff40996fb61c08c60ddb";
hash = "sha256-GpnplQ+MQdA+RrLKaq2JO7TQjJY1jWGxSu/Kbg5bBEo=";
};
propagatedBuildInputs = with python3Packages; [
+3 -3
View File
@@ -18,16 +18,16 @@ let
in
rustPlatform.buildRustPackage (finalAttrs: {
pname = "lockbook-desktop";
version = "26.3.22";
version = "26.4.9";
src = fetchFromGitHub {
owner = "lockbook";
repo = "lockbook";
tag = finalAttrs.version;
hash = "sha256-Mroh2xSLe5dlKNXxTPyP9RzLtwcEf2JXZnE1tN4t1fE=";
hash = "sha256-MQobOqixxWDuHMLVk7pfIquLSA3rZNYn4MaENAoIsuM=";
};
cargoHash = "sha256-hPQlDG2eFmiPXkCyjk10fpVDAbq3R8mQs7bOHbCBhwg=";
cargoHash = "sha256-sLfZ8c2cbXT2NXcopqKJaX1SMlsi3Zy9V+VDi6zarxs=";
nativeBuildInputs = [
pkg-config
@@ -4,19 +4,19 @@
fetchurl,
cctools,
fixDarwinDylibNames,
autoSignDarwinBinariesHook,
darwin,
replaceVars,
buildPackages,
binutils,
}:
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "lp_solve";
version = "5.5.2.11";
src = fetchurl {
url = "mirror://sourceforge/project/lpsolve/lpsolve/${version}/lp_solve_${version}_source.tar.gz";
sha256 = "sha256-bUq/9cxqqpM66ObBeiJt8PwLZxxDj2lxXUHQn+gfkC8=";
url = "mirror://sourceforge/project/lpsolve/lpsolve/${finalAttrs.version}/lp_solve_${finalAttrs.version}_source.tar.gz";
hash = "sha256-bUq/9cxqqpM66ObBeiJt8PwLZxxDj2lxXUHQn+gfkC8=";
};
nativeBuildInputs =
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
fixDarwinDylibNames
]
++ lib.optionals (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64) [
autoSignDarwinBinariesHook
darwin.autoSignDarwinBinariesHook
];
env = {
@@ -81,4 +81,4 @@ stdenv.mkDerivation rec {
maintainers = [ ];
platforms = lib.platforms.unix;
};
}
})
@@ -18,21 +18,21 @@
rustPlatform.buildRustPackage (finalAttrs: {
pname = "matrix-authentication-service";
version = "1.14.0";
version = "1.15.0";
src = fetchFromGitHub {
owner = "element-hq";
repo = "matrix-authentication-service";
tag = "v${finalAttrs.version}";
hash = "sha256-/13RYd5p46eM2rX5y9bPzHB63zCeZ2NbLDqTnk3+Vn8=";
hash = "sha256-q3MtMRdvuL0olnqvqK8uWeFCT7UpKjZN4zz9ZFlyGd4=";
};
cargoHash = "sha256-eNmD/O7t2YykGlVqovBxi/DKPQ2W2mxxCOaMBzqhTZo=";
cargoHash = "sha256-FV4ZKR6lq8b5PMj+mZ+/RBWLmoGc6WuAXw00+PGJUi8=";
npmDeps = fetchNpmDeps {
name = "${finalAttrs.pname}-${finalAttrs.version}-npm-deps";
src = "${finalAttrs.src}/${finalAttrs.npmRoot}";
hash = "sha256-lWFJEjTVHMkmFnfjjIDtE/T3nw4qF3IJhUayfFVLPQo=";
hash = "sha256-OA7T8dTWEb8QiiRBx1A/R8H2Bu/xv3RFr8K9IVU3674=";
};
npmRoot = "frontend";
-46
View File
@@ -1,46 +0,0 @@
{
callPackage,
stdenv,
fetchFromGitHub,
lib,
writableTmpDirAsHomeHook,
nix-update-script,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "microhs";
version = "0.15.4.0";
src = fetchFromGitHub {
owner = "augustss";
repo = "MicroHs";
tag = "v${finalAttrs.version}";
hash = "sha256-V3Of72rpXvImV90sSoYz02H06o1J3FqHDQNbB+M6/8A=";
};
# mcabal doesn't seem to respect the make flag and fails with /homeless-shelter
# This works around the issue
nativeBuildInputs = [ writableTmpDirAsHomeHook ];
makeFlags = [ "MCABAL=$(out)" ];
buildFlags = [ "bootstrap" ];
# MicroCabal is a separate repository, which should be packaged separately
# The MicroCabal that is installed by `make install` is pregenerated, does not respect MCABAL above, and so is not useable
postInstall = "rm $out/bin/mcabal";
passthru = {
updateScript = nix-update-script { };
tests = {
hello-world = callPackage ./test-hello-world.nix { microhs = finalAttrs.finalPackage; };
};
};
meta = {
description = "Haskell implemented with combinators";
homepage = "https://github.com/augustss/MicroHs";
license = lib.licenses.asl20;
maintainers = [ lib.maintainers.steeleduncan ];
platforms = lib.platforms.all;
};
})
+3 -3
View File
@@ -7,16 +7,16 @@
buildGoModule (finalAttrs: {
pname = "mkbrr";
version = "1.20.0";
version = "1.22.0";
src = fetchFromGitHub {
owner = "autobrr";
repo = "mkbrr";
tag = "v${finalAttrs.version}";
hash = "sha256-5oyzeinRjR09GEvLMGdCDH+UGYWPu1Qs8dXs/nIlwjs=";
hash = "sha256-M4lulMYb6jomS2sZ4E5nA6rP1KmuGiMjQEyuXqyl2vQ=";
};
vendorHash = "sha256-mbcbACOKMohBw0SH5gH06CTkHtJk3WmbAqpcO0qMFOs=";
vendorHash = "sha256-BNswyeGBhm0CY6D9HcJHTDKIGCJ5QotiwRnr22HltMo=";
ldflags = [
"-s"
+3 -3
View File
@@ -9,16 +9,16 @@
buildNpmPackage (finalAttrs: {
pname = "nest-cli";
version = "11.0.17";
version = "11.0.18";
src = fetchFromGitHub {
owner = "nestjs";
repo = "nest-cli";
tag = finalAttrs.version;
hash = "sha256-TolI/HpC5kEvXrqkIcjcVny2yY96Jz37f5+mw4fHt1M=";
hash = "sha256-fqVsvox7c50bZ5jqGrpu3QiQG+ghY3eh8SETrdKnRCY=";
};
npmDepsHash = "sha256-y9yjZT7AhXPrKEQo81k5KjX9voIWY7VcuUGY6QuiLcw=";
npmDepsHash = "sha256-1M53H0tLD3+9To4kxt136P7kOvzo3gfWEFkFlcUSy6g=";
npmFlags = [ "--legacy-peer-deps" ];
env = {
+2 -2
View File
@@ -10,14 +10,14 @@
python3Packages.buildPythonApplication (finalAttrs: {
pname = "nwg-hello";
version = "0.4.3";
version = "0.4.4";
pyproject = true;
src = fetchFromGitHub {
owner = "nwg-piotr";
repo = "nwg-hello";
tag = "v${finalAttrs.version}";
hash = "sha256-sWp9fSCPb2MrHdvTBnmsvf3idrRPcqmBFsFbRXGjFB0=";
hash = "sha256-XJVUEuSu24NozFjted4pujo4A83cpF7KmfDSpc8/JzY=";
};
nativeBuildInputs = [
+3 -3
View File
@@ -26,13 +26,13 @@
rustPlatform.buildRustPackage (finalAttrs: {
pname = "open-scq30";
version = "2.5.1";
version = "2.6.2";
src = fetchFromGitHub {
owner = "Oppzippy";
repo = "OpenSCQ30";
rev = "v${finalAttrs.version}";
hash = "sha256-XBK7KxuksQoYZs/uVkh6+8S20G05W9ftK9pviUFNJ8s=";
hash = "sha256-4K/3kulUbUa21YbWh1nYXeeHAIVD/FX8VtWArpij0JQ=";
};
nativeBuildInputs = [
@@ -65,7 +65,7 @@ rustPlatform.buildRustPackage (finalAttrs: {
libxi
];
cargoHash = "sha256-P4r1MoFCkG80X0dJ1MpmjgedcpQ/HDTC3XikNUDKRaQ=";
cargoHash = "sha256-1Ccbi/21jTyTPt9WqhnwpBFuD0f90PabwyVRwZI1l0k=";
env.INSTALL_PREFIX = placeholder "out";
+2 -2
View File
@@ -17,13 +17,13 @@ buildGoModule (finalAttrs: {
webkitgtk_4_1
];
pname = "paretosecurity";
version = "0.3.15";
version = "0.3.16";
src = fetchFromGitHub {
owner = "ParetoSecurity";
repo = "agent";
rev = finalAttrs.version;
hash = "sha256-2oGDxnbxuyAMWjEUFKzwYz72/FYUbUZHSFoZk2pMfeY=";
hash = "sha256-93+8r7GOdaQ5HnPEvJ0L2DDStHT6HvH1tuDsCSoDU0E=";
};
vendorHash = "sha256-jAcUf4VjtKB/Q2wHOVnCgcmPp5XNMqV8Ei9kpWoGO4Q=";
@@ -10,13 +10,13 @@
stdenv.mkDerivation (finalAttrs: {
pname = "plasma-panel-spacer-extended";
version = "1.14.0";
version = "1.15.0";
src = fetchFromGitHub {
owner = "luisbocanegra";
repo = "plasma-panel-spacer-extended";
tag = "v${finalAttrs.version}";
hash = "sha256-zqdELL7A4pZpPfbgBgyqZnP6HY200rYxRFl3/aIE3Eo=";
hash = "sha256-ivfIlZvr7OOXa/zyrorcUPaaFU6IcS2L3yFiX29jnd4=";
};
nativeBuildInputs = [
+3 -3
View File
@@ -14,16 +14,16 @@ let
in
buildGoModule (finalAttrs: {
pname = "pomerium-cli";
version = "0.32.0";
version = "0.32.2";
src = fetchFromGitHub {
owner = "pomerium";
repo = "cli";
rev = "v${finalAttrs.version}";
sha256 = "sha256-dxN3pVDt6v/xEnBwvmOFf8gf6YZWv23a4K6mTRovv+k=";
sha256 = "sha256-t2Sp4zAIybUsxaBdQ9ev+EJsFpWqM8KWaE2UOI4xw5A=";
};
vendorHash = "sha256-pDoV7CzQFiAi6OAqqW8b6/Sl9PSQou9pU2c5nU7Rt0A=";
vendorHash = "sha256-LzXcHGRBn99WhDsxLQKY3t8Zp4sw9Ec5CbA/rU/3SQ0=";
subPackages = [
"cmd/pomerium-cli"
+5 -5
View File
@@ -8,7 +8,7 @@
let
pname = "postman";
version = "11.88.3";
version = "11.89.0";
src =
let
@@ -27,10 +27,10 @@ let
name = "postman-${version}.${if stdenvNoCC.hostPlatform.isLinux then "tar.gz" else "zip"}";
url = "https://dl.pstmn.io/download/version/${version}/${system}";
hash = selectSystem {
aarch64-darwin = "sha256-BYdEwE96SdxPwn8bTcIZcHcClAjPgrFd2rSO1zs/X5Y=";
aarch64-linux = "sha256-nWS4cPV6m/h1+RLkl1i9FZxCol/GPxFb2S+GRoL87QM=";
x86_64-darwin = "sha256-8lDFOysRuJMEJ5Ff2mkTZx+Mu+duiDq8EAdibi7yYL8=";
x86_64-linux = "sha256-98NRSIOpgsDZ9tehbgQi1Ms5U04ylWIh4A2qY0yasPA=";
aarch64-darwin = "sha256-NGiQPg4oVr2zin0NT8/2Y5HTrBZeA7Oboue2zYPHJWc=";
aarch64-linux = "sha256-dGV1JzNsHo8lKZplBX5sp1BRgGovVY+UM+6BumXLK2E=";
x86_64-darwin = "sha256-kpl5x+uCR76dSwG+5xk4aA0lLiKXWOhJTtco2+S5c5g=";
x86_64-linux = "sha256-9hRBh1zUIL5JctHhdtAeWgR8/QqftRNqAGghI7BgdsI=";
};
};
+60
View File
@@ -0,0 +1,60 @@
{
lib,
stdenv,
fetchFromGitHub,
autoreconfHook,
bison,
flex,
gfortran,
blas,
bzip2,
fftw,
lapack,
libxml2,
protobuf_21,
zlib,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "qdng";
version = "1.0.0";
src = fetchFromGitHub {
owner = "quantum-dynamics-ng";
repo = "QDng";
tag = "v${finalAttrs.version}";
hash = "sha256-T59Bb014KSUOOFTFjPOrWmbF6GqIqAIyrb3Xe5TwU88=";
};
configureFlags = [
"--enable-openmp"
"--disable-gccopt"
];
enableParallelBuilding = true;
nativeBuildInputs = [
autoreconfHook
bison
flex
gfortran
];
buildInputs = [
blas
bzip2
fftw
lapack
libxml2
protobuf_21
zlib
];
meta = {
description = "Molecular wavepacket dynamics package";
homepage = "https://github.com/quantum-dynamics-ng/QDng";
platforms = lib.platforms.linux;
maintainers = [ lib.maintainers.markuskowa ];
license = lib.licenses.gpl3Only;
};
})
+2 -2
View File
@@ -18,11 +18,11 @@ let
in
stdenv.mkDerivation (finalAttrs: {
pname = "rundeck-cli";
version = "2.0.9";
version = "2.0.10";
src = fetchurl {
url = "https://github.com/rundeck/rundeck-cli/releases/download/v${finalAttrs.version}/rundeck-cli-${finalAttrs.version}-all.jar";
hash = "sha256-c6QAgwyRCtoOlS7DEmjyK3BwHV122bilL6H+Hzrv2dQ=";
hash = "sha256-RiGWsscenvNpKr+yOHpy2F7dPZ3M/R9SWD+EKF7nq18=";
};
nativeBuildInputs = [ makeBinaryWrapper ];
+2 -2
View File
@@ -6,13 +6,13 @@
buildGoModule (finalAttrs: {
pname = "scalr-cli";
version = "0.17.7";
version = "0.17.8";
src = fetchFromGitHub {
owner = "Scalr";
repo = "scalr-cli";
rev = "v${finalAttrs.version}";
hash = "sha256-ZGq76TPMNrlyuHs5yUgw3pJ+a2wVNwBTTSgzIofD4io=";
hash = "sha256-hJvIVSv40Wlua1nOWJb5pu4OSfsATiwMoqNrZsWCBNA=";
};
vendorHash = "sha256-TUf+0Z0yBDOpzMuETn+FCAPXWvQltjRhwQ3Xz0X6YOI=";
+2 -2
View File
@@ -20,7 +20,7 @@
stdenv.mkDerivation (finalAttrs: {
pname = "sdl3-image";
version = "3.4.0";
version = "3.4.2";
outputs = [
"lib"
@@ -32,7 +32,7 @@ stdenv.mkDerivation (finalAttrs: {
owner = "libsdl-org";
repo = "SDL_image";
tag = "release-${finalAttrs.version}";
hash = "sha256-XRPHDcJ49sZa7y8TCWfS2gPOhpGyUnMMXVqvjV9f8E0=";
hash = "sha256-LNEbXhUDB6OKk3HxwV+jANnskS82ewhQe8pDy+P6L40=";
};
strictDeps = true;
@@ -14,13 +14,13 @@
stdenv.mkDerivation (finalAttrs: {
pname = "signalbackup-tools";
version = "20260325";
version = "20260407";
src = fetchFromGitHub {
owner = "bepaald";
repo = "signalbackup-tools";
tag = finalAttrs.version;
hash = "sha256-5Tb9bY0sZvCUlYkGpmu6hVi7EOEMaygEH9x3tbyo2T4=";
hash = "sha256-rkIhaYLRBpqMLpwOHhTAEpgqrKRc3UBMwhS1oiCcbvc=";
};
nativeBuildInputs = [
+3 -3
View File
@@ -15,13 +15,13 @@
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sioyek";
version = "2.0.0-unstable-2026-03-13";
version = "2.0.0-unstable-2026-04-08";
src = fetchFromGitHub {
owner = "ahrm";
repo = "sioyek";
rev = "13a37e0e0ab77a76f8dbe3adf599ee916615b3db";
hash = "sha256-3bMVoF4f1+pZV3tdti8KNS17wWK1tmIgjKQUQS+Rzt8=";
rev = "a0650b5a71c15692c4797fec2908cc55c5aafd12";
hash = "sha256-9g1JhZEqBz6x2gv690efXaV7TNggyRvOq1xn8phubEY=";
};
buildInputs = [
+2 -2
View File
@@ -19,13 +19,13 @@
buildGoModule rec {
pname = "skopeo";
version = "1.22.0";
version = "1.22.1";
src = fetchFromGitHub {
rev = "v${version}";
owner = "containers";
repo = "skopeo";
hash = "sha256-ERMOquT8ke/4urC6V0To+jJPeBICohHXL9YcCmGLST4=";
hash = "sha256-MS91KzOxcVhmH420zdUcSUw0UggRt3hQ6c3A3QSAYkA=";
};
outputs = [
+2 -2
View File
@@ -17,13 +17,13 @@
stdenv.mkDerivation (finalAttrs: {
pname = "spedread";
version = "2.7.0";
version = "2.8.0";
src = fetchFromGitHub {
owner = "Darazaki";
repo = "Spedread";
tag = "v${finalAttrs.version}";
hash = "sha256-3Ykucgw2LkW22gn4nroCO22CbfLB9DGeyyv+PS3fv2U=";
hash = "sha256-IZhvKZ4kllL6ItUn47+EnUwVPKXC0mz2Mvsg/7CT5Qw=";
};
postPatch = ''
+2 -2
View File
@@ -8,13 +8,13 @@
buildGoModule (finalAttrs: {
pname = "spirit";
version = "0.11.3";
version = "0.12.0";
src = fetchFromGitHub {
owner = "block";
repo = "spirit";
tag = "v${finalAttrs.version}";
hash = "sha256-gQ4DeiUWqOy1Qg1+F2hjxhI6578MXvuNlTB5djN1zD4=";
hash = "sha256-5H/yDujoxzeslZ4rm6qrBIy9pM3F6o/XmqPyG960M/0=";
};
vendorHash = "sha256-dC+qryYDiYPuMlgkHsXYOsqHxl1O5QtGUFbNnkRE3eU=";
+5 -5
View File
@@ -8,7 +8,7 @@
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sprite";
version = "0.0.1-rc42";
version = "0.0.1-rc43";
src = fetchurl {
url = "https://sprites-binaries.t3.storage.dev/client/v${finalAttrs.version}/sprite-${
@@ -16,10 +16,10 @@ stdenv.mkDerivation (finalAttrs: {
}-${if stdenv.hostPlatform.isx86_64 then "amd64" else "arm64"}.tar.gz";
hash =
{
aarch64-darwin = "sha256-ih0RonsNu7ZHUWbQcMqHmm7RXg0VvekDvq6WpnKvSjY=";
x86_64-darwin = "sha256-p3Tpf2Mg0rfOaw/y7cKI2Q7SvEpm+a1ykYVrr/dzVLc=";
aarch64-linux = "sha256-vMhkzX9noNL8Aw6MWhEAYmufCRpLsY/FbveBP3PYrQQ=";
x86_64-linux = "sha256-Jmym6yg0Wl83KTn840jWF3md5+r4NBh8czQudY5Iomk=";
aarch64-darwin = "sha256-6ztxc59b2H76+o7k7zMOvA/PAOib4m7WRXo1XsigL04=";
x86_64-darwin = "sha256-Ni779eJIFbZQ/zrAA3zQyYFFQ7ikEU9UYL9GeO1OcKA=";
aarch64-linux = "sha256-YTNHlVknlVkyUsiI422Quo04CyIMxCbrjhPvGADHw2s=";
x86_64-linux = "sha256-wEClvx4Kv7WK4uMYwNJqvsvjyQsonI01xlCo3z7CuwQ=";
}
.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
};
+3 -3
View File
@@ -6,18 +6,18 @@
buildGoModule (finalAttrs: {
pname = "sqldef";
version = "3.10.1";
version = "3.11.0";
src = fetchFromGitHub {
owner = "sqldef";
repo = "sqldef";
rev = "v${finalAttrs.version}";
hash = "sha256-6z73BmddtPrqbaWnDSTMeyECMomwHFtLRqIS08UfaLY=";
hash = "sha256-//wAzWGgNIYp/uajrhX2GexIsdYRjRAOPcHXZuSdj+E=";
};
proxyVendor = true;
vendorHash = "sha256-XSb3nMUv2JngkvvjpqfStFXJQFrCaSSTkYaKDGaFfuE=";
vendorHash = "sha256-xX4ZrhIdHvNFRTXHkZfEbevauuv4x9IYfDVfq7IFDg8=";
ldflags = [
"-s"
+2 -2
View File
@@ -18,13 +18,13 @@
stdenv.mkDerivation (finalAttrs: {
pname = "stress-ng";
version = "0.20.01";
version = "0.21.00";
src = fetchFromGitHub {
owner = "ColinIanKing";
repo = "stress-ng";
tag = "V${finalAttrs.version}";
hash = "sha256-C9TpUM18W+ARFAFLSqTl6RjRrI60pxhdP/veBHu2cco=";
hash = "sha256-kFIrbt/jJuQnuWmQUBuiFGuAfBb2pUtujhj6bwpDF4k=";
};
postPatch = ''
+2 -2
View File
@@ -6,13 +6,13 @@
buildGoModule (finalAttrs: {
pname = "tar2ext4";
version = "0.14.0";
version = "0.14.1";
src = fetchFromGitHub {
owner = "microsoft";
repo = "hcsshim";
rev = "v${finalAttrs.version}";
sha256 = "sha256-8FPEGQ6DBYYnT6mIjYmSTRfHMloS42oB8xPU5wmFLwI=";
sha256 = "sha256-n/YYajbQo+s1ssPAbS4gUdFYBHNmoNBKcEM/kcAZR94=";
};
sourceRoot = "${finalAttrs.src.name}/cmd/tar2ext4";
@@ -16,13 +16,13 @@
libsm,
libxfixes,
coreutils,
wrapQtAppsHook,
libsForQt5,
icu63,
nss,
minizip,
}:
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "teamviewer";
# teamviewer itself has not development files but the dev output removes propagated other dev outputs from runtime
outputs = [
@@ -33,15 +33,15 @@ stdenv.mkDerivation rec {
src =
let
base_url = "https://dl.teamviewer.com/download/linux/version_${lib.versions.major version}x";
base_url = "https://dl.teamviewer.com/download/linux/version_${lib.versions.major finalAttrs.version}x";
in
{
x86_64-linux = fetchurl {
url = "${base_url}/teamviewer_${version}_amd64.deb";
url = "${base_url}/teamviewer_${finalAttrs.version}_amd64.deb";
hash = "sha256-7QQlGzIr3BBFaur8ycGY0VuYz21cJI+EfCsRuCAr8XA=";
};
aarch64-linux = fetchurl {
url = "${base_url}/teamviewer_${version}_arm64.deb";
url = "${base_url}/teamviewer_${finalAttrs.version}_arm64.deb";
hash = "sha256-prz3RaeMykgLrK9ai3/ivzRsUFT1dyWP1xymEl3s4eA=";
};
}
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [
autoPatchelfHook
makeWrapper
wrapQtAppsHook
libsForQt5.wrapQtAppsHook
];
buildInputs = [
minizip
@@ -164,4 +164,4 @@ stdenv.mkDerivation rec {
c4patino
];
};
}
})
+3 -3
View File
@@ -6,16 +6,16 @@
rustPlatform.buildRustPackage (finalAttrs: {
pname = "tuckr";
version = "0.13.0";
version = "0.13.1";
src = fetchFromGitHub {
owner = "RaphGL";
repo = "Tuckr";
rev = finalAttrs.version;
hash = "sha256-1fiz45x7XgVJtzxF+cxe6W203oIs3wytjh3V/IGk4XA=";
hash = "sha256-QFGT032gpyzdobGdICEyvgbAMDGbBSNhIH16AlGPK4s=";
};
cargoHash = "sha256-q64BgL/UOWd/WNTyG8D1pwfa5ca1mKN79BI+W15ooMQ=";
cargoHash = "sha256-ffAp+1kkLTaKYPhfwQt4ieR3d/w8SeJPfeaFh0Vzc1w=";
doCheck = false; # test result: FAILED. 5 passed; 3 failed;
+11 -25
View File
@@ -16,46 +16,32 @@
m17n_db,
expat,
withAnthy ? true,
anthy ? null,
anthy,
withGtk ? true,
withGtk2 ? withGtk,
gtk2 ? null,
gtk2,
withGtk3 ? withGtk,
gtk3 ? null,
gtk3,
# Was never enabled in the history of this package and is not needed by any
# dependent package, hence disabled to save up closure size.
withQt ? false,
withQt5 ? withQt,
qt5 ? null,
qt5,
withLibnotify ? true,
libnotify ? null,
libnotify,
withSqlite ? true,
sqlite ? null,
sqlite,
withNetworking ? true,
curl ? null,
openssl ? null,
curl,
openssl,
withFFI ? true,
libffi ? null,
libffi,
# Things that are clearly an overkill to be enabled by default
withMisc ? false,
libeb ? null,
libeb,
}:
let
automake = automake116x;
in
assert withGtk2 -> gtk2 != null;
assert withGtk3 -> gtk3 != null;
assert withAnthy -> anthy != null;
assert withLibnotify -> libnotify != null;
assert withSqlite -> sqlite != null;
assert withNetworking -> curl != null && openssl != null;
assert withFFI -> libffi != null;
assert withMisc -> libeb != null;
stdenv.mkDerivation (finalAttrs: {
version = "1.9.6";
pname = "uim";
@@ -70,7 +56,7 @@ stdenv.mkDerivation (finalAttrs: {
nativeBuildInputs = [
autoconf
automake
automake116x
intltool
libtool
pkg-config
+3 -3
View File
@@ -10,16 +10,16 @@
buildGoModule (finalAttrs: {
pname = "wakatime-cli";
version = "2.0.8";
version = "2.2.0";
src = fetchFromGitHub {
owner = "wakatime";
repo = "wakatime-cli";
tag = "v${finalAttrs.version}";
hash = "sha256-VBlERyaoRmOO7CGPmF9R2f6sU+8BNJ3Ze4AX2mxezCo=";
hash = "sha256-TOdAcT+IS6XONIfkASRvd7oTSSW5VX8w5q5ASvJlQb8=";
};
vendorHash = "sha256-1BtTtR8wPVzzOEGv3te3hOeKakZX7cS+HYvoCLnuZ/c=";
vendorHash = "sha256-HngszNLX2b2EVvh8ovouIEvjBOJL1jA5AhA6Y11ke9Y=";
ldflags = [
"-s"
+3 -3
View File
@@ -58,13 +58,13 @@ assert (
);
rustPlatform.buildRustPackage (finalAttrs: {
pname = "xremap${variant.suffix or ""}";
version = "0.14.19";
version = "0.15.0";
src = fetchFromGitHub {
owner = "xremap";
repo = "xremap";
tag = "v${finalAttrs.version}";
hash = "sha256-t/eSUFYTZ41uJJLjmMOWiV9ffYJjDVw+fy0P3XnvJ40=";
hash = "sha256-8IryQGSAxIVQiGGiY3trDvvJ50c19LHP4KvIa3P0zII=";
};
nativeBuildInputs = [ pkg-config ];
@@ -72,7 +72,7 @@ rustPlatform.buildRustPackage (finalAttrs: {
buildNoDefaultFeatures = true;
buildFeatures = variant.features;
cargoHash = "sha256-Ypujuqz8TNLNfNB1NizjZoOK2VL+a4MY7c/aGIcCjns=";
cargoHash = "sha256-5vDKb6S4G+oNm//WtGsr4kEthozoznzn2N8ajtiMIeY=";
passthru = lib.mapAttrs (name: lib.const (xremap.override { withVariant = name; })) variants;
@@ -0,0 +1,4 @@
import ./common.nix {
version = "0.15.4.0";
hash = "sha256-FUr2EA3zbmt2Tr2F8zT1wHnB8GDlUVb2W1fP4IqNd80=";
}
@@ -0,0 +1,40 @@
{
stdenvNoCC,
hugs,
makeWrapper,
microhs-src,
}:
stdenvNoCC.mkDerivation {
pname = "microhs";
version = "${microhs-src.version}-hugs";
inherit (microhs-src)
src
patches
postPatch
meta
;
nativeBuildInputs = [ makeWrapper ];
dontBuild = true;
installPhase = ''
runHook preInstall
mkdir -p "$out/bin" "$out/share/microhs-hugs"
s="$out/share/microhs-hugs/src"
cp -r . "$s"
makeWrapper ${hugs}/bin/runhugs "$out/bin/mhs" \
--add-flags "'+P$s/hugs:$s/src:$s/paths:{Hugs}/packages/*:hugs/obj' -98 +o +w -h100m '$s/hugs/Main.hs'"
runHook postInstall
'';
passthru = {
isMhs = true;
usesHugs = true;
};
}
@@ -0,0 +1,94 @@
{
version,
mcabalVersion ? "0.5.3.0-31f1b5dec81561a1b1d36b8e3065ce091dce2ec6",
rev ? "refs/tags/v${version}",
hash,
}:
{
lib,
buildPackages,
pkgsBuildBuild,
callPackage,
fetchFromGitHub,
fetchpatch,
microhs-boot,
stdenv,
versionCheckHook,
writeShellScript,
}:
let
args = finalAttrs: {
inherit version;
src = fetchFromGitHub {
owner = "augustss";
repo = "MicroHs";
fetchSubmodules = true;
inherit rev hash;
};
patches = [
patches/hugs.patch
patches/hugs-viewpatterns.patch
]
++ lib.optional stdenv.hostPlatform.isGnu patches/link-math.patch;
# The source contains pre-compiled files
# We delete them to be certain we are building from source
postPatch = ''
rm -r generated
'';
doInstallCheck = true;
nativeInstallCheckInputs = [
versionCheckHook
];
meta = {
description = "Small compiler for Haskell";
longDescription = ''
A compiler for an extended subset of Haskell 2010.
The compiler translates to combinators and can compile itself.
'';
homepage = "https://github.com/augustss/MicroHs";
license = lib.licensesSpdx."Apache-2.0";
mainProgram = "mhs";
maintainers = with lib.maintainers; [
AlexandreTunstall
steeleduncan
];
platforms = lib.platforms.all;
};
};
microhs-stage1-build = pkgsBuildBuild.callPackage ./stage1.nix {
inherit args microhs-boot;
};
microhs-stage1 = buildPackages.callPackage ./stage1.nix {
inherit args microhs-boot;
};
microhs-stage2 = callPackage ./stage2.nix {
inherit
args
microcabal-stage1
microhs-stage1
cpphs
;
};
microcabal-stage1 = buildPackages.callPackage ../../tools/haskell/microcabal/${mcabalVersion}.nix {
microhs = microhs-stage1-build;
};
cpphs = buildPackages.callPackage ./cpphs.nix {
inherit args;
microhs = microhs-stage2;
};
in
microhs-stage2
@@ -0,0 +1,50 @@
{
args,
hugs,
microhs,
stdenv,
}:
stdenv.mkDerivation (
finalAttrs:
let
args' = args finalAttrs;
in
args'
// {
pname = "microhs-cpphs";
nativeBuildInputs = [ hugs ];
makeFlags = [ "USECPPHS=$(TMP)/cpphs-boot" ];
buildFlags = [
"bootstrapcpphs"
"bin/cpphs"
];
# Generate cpphs-boot and populate paths that the target uses
# We can't use cpphs-hugs directly because it's too primitive
preBuild = ''
mkdir -p $TMP/cpphs-hugs/src
cp -r hugs/* cpphscompat/* cpphssrc/malcolm-wallace-universe/{polyparse-*/src,cpphs-*}/* $TMP/cpphs-hugs/src/
find $TMP/cpphs-hugs/src -type f -name '*.hs' -exec ${hugs}/bin/cpphs-hugs --noline '{}' '-O{}.tmp' \;
find $TMP/cpphs-hugs/src -type f -name '*.hs' -exec mv '{}.tmp' '{}' \;
sed -i -e '/fail *= *Fail\.fail/d' $TMP/cpphs-hugs/src/Text/ParserCombinators/Poly/Parser.hs
${microhs}/bin/mhs -l -i$TMP/cpphs-hugs/src $TMP/cpphs-hugs/src/cpphs.hs -o$TMP/cpphs-boot
mkdir -p bin generated
touch cpphssrc/malcolm-wallace-universe/.git targets.conf
cp ${microhs}/bin/mhs bin/mhs
'';
installPhase = ''
runHook preInstall
install -m755 -d $out/bin
install -m755 bin/cpphs $out/bin/cpphs
runHook postInstall
'';
doInstallCheck = false;
}
)
@@ -0,0 +1,406 @@
If you need to update this patch, apply it to the old version, then use Git to
rebase it onto the new version.
diff --git a/src/MicroHs/ExpPrint.hs b/src/MicroHs/ExpPrint.hs
index 59afc0d0..bada27d2 100644
--- a/src/MicroHs/ExpPrint.hs
+++ b/src/MicroHs/ExpPrint.hs
@@ -30,7 +30,7 @@ removeUnused (ds, emain) = dfs roots M.empty
dMap = M.fromList ds
dfs :: [Ident] -> M.Map Exp -> [LDef]
dfs [] done = M.toList done
- dfs (i:is) done | Just _ <- M.lookup i done = dfs is done
+ dfs (i:is) done | isJust (M.lookup i done) = dfs is done
| otherwise = dfs (freeVars e ++ is) (M.insert i e done)
where e = fromMaybe (error $ "removeUnused: undef " ++ show i) $ M.lookup i dMap
@@ -81,7 +81,7 @@ toStringCMdl :: CMdl -> String
toStringCMdl (ds, emain) =
let
def :: (Ident, Exp) -> (String -> String) -> (String -> String)
- def (i, e) r | Just (e', _) <- getForExp e = def (i, e') r
+ def (i, e) r | isJust (getForExp e) = let Just (e', _) = getForExp e in def (i, e') r
def (i, e) r =
("A " ++) . toStringP e . ((":" ++ showIdent i ++ " @\n") ++) . r . ("@" ++)
diff --git a/src/MicroHs/Expr.hs b/src/MicroHs/Expr.hs
index bd05f1bc..14225927 100644
--- a/src/MicroHs/Expr.hs
+++ b/src/MicroHs/Expr.hs
@@ -514,7 +514,7 @@ getTupleConstr i =
getExprTuple :: EType -> Maybe [EType]
getExprTuple = loop []
where loop ts (EApp f a) = loop (a:ts) f
- loop ts (EVar i) | Just n <- getTupleConstr i, length ts == n = Just ts
+ loop ts (EVar i) | isJust (getTupleConstr i) && length ts == fromJust (getTupleConstr i) = Just ts
loop _ _ = Nothing
-- Create a tuple selector, component i (0 based) of n
@@ -1015,13 +1015,13 @@ ppExprR raw = ppE
ppApp :: [Expr] -> Expr -> Doc
ppApp as (EApp f a) = ppApp (a:as) f
ppApp as f | raw = ppApply f as
- ppApp as (EVar i) | isOperChar cop, [a, b] <- as = parens $ ppE a <+> text op <+> ppExpr b
- | isOperChar cop, [a] <- as = parens $ ppE a <+> text op
- | cop == ',' && length op + 1 == length as
- = ppE (ETuple as)
- | op == "[]", length as == 1 = ppE (EListish (LList as))
- where op = unIdent (unQualIdent i)
- cop = head op
+ ppApp as (EVar i) = case as of
+ [a, b] | isOperChar cop -> parens $ ppE a <+> text op <+> ppExpr b
+ [a] | isOperChar cop -> parens $ ppE a <+> text op
+ _ | cop == ',' && length op + 1 == length as -> ppE (ETuple as)
+ | op == "[]" && length as == 1 -> ppE (EListish (LList as))
+ where op = unIdent (unQualIdent i)
+ cop = head op
ppApp as f = ppApply f as
ppApply f as = parens $ hsep (map ppE (f:as))
@@ -1212,5 +1212,5 @@ getImplies _ = Nothing
dropForallContext :: EType -> EType
dropForallContext (EForall _ _ t) = dropForallContext t
-dropForallContext t | Just (_, t') <- getImplies t = dropForallContext t'
+dropForallContext t | isJust (getImplies t) = let Just (_, t') = getImplies t in dropForallContext t'
| otherwise = t
diff --git a/src/MicroHs/FFI.hs b/src/MicroHs/FFI.hs
index 4e79ab18..292a28fb 100644
--- a/src/MicroHs/FFI.hs
+++ b/src/MicroHs/FFI.hs
@@ -1,6 +1,7 @@
module MicroHs.FFI(makeFFI) where
import qualified Prelude(); import MHSPrelude
import Data.List
+import Data.Maybe(fromJust, isJust)
import MicroHs.Desugar(LDef)
import MicroHs.Exp
import MicroHs.Expr
@@ -175,7 +176,8 @@ arity = length . fst . getArrows
cTypeHsName :: HasCallStack => EType -> String
cTypeHsName (EApp (EVar ptr) _t) | ptr == identPtr = "Ptr"
| ptr == identFunPtr = "FunPtr"
-cTypeHsName (EVar i) | Just c <- lookup (unIdent i) cHsTypes = c
+cTypeHsName (EVar i) | isJust mc = fromJust mc
+ where mc = lookup (unIdent i) cHsTypes
cTypeHsName t = errorMessage (getSLoc t) $ "Not a valid C type: " ++ showEType t
cHsTypes :: [(String, String)]
@@ -193,7 +195,8 @@ cHsTypes =
-- Use to construct 'foreign export ccall' signature.
cTypeName :: EType -> String
cTypeName (EApp (EVar ptr) _t) | ptr == identPtr = "void*"
-cTypeName (EVar i) | Just c <- lookup (unIdent i) cTypes = c
+cTypeName (EVar i) | isJust mc = fromJust mc
+ where mc = lookup (unIdent i) cTypes
cTypeName t = errorMessage (getSLoc t) $ "Not a valid C type: " ++ showEType t
cTypes :: [(String, String)]
@@ -211,7 +214,8 @@ cTypes =
-- Use to construct 'foreign import javascript' return value wrapper.
jsTypeNameR :: EType -> String
jsTypeNameR (EApp (EVar ptr) _) | ptr == identPtr = "PTR"
-jsTypeNameR (EVar i) | Just c <- lookup (unIdent i) jsTypesR = c
+jsTypeNameR (EVar i) | isJust mc = fromJust mc
+ where mc = lookup (unIdent i) jsTypesR
jsTypeNameR t = errorMessage (getSLoc t) $ "Not a valid Javascript return type: " ++ showEType t
jsTypesR :: [(String, String)]
@@ -224,7 +228,8 @@ jsTypesR =
-- Use to construct 'foreign import javascript' argument wrapper.
jsTypeName :: EType -> String
jsTypeName (EApp (EVar ptr) _) | ptr == identPtr = "Ptr"
-jsTypeName (EVar i) | Just c <- lookup (unIdent i) jsTypes = c
+jsTypeName (EVar i) | isJust mc = fromJust mc
+ where mc = lookup (unIdent i) jsTypes
jsTypeName t = errorMessage (getSLoc t) $ "Not a valid Javascript argument type: " ++ showEType t
jsTypes :: [(String, String)]
diff --git a/src/MicroHs/Lex.hs b/src/MicroHs/Lex.hs
index 12e0213f..ebe591df 100644
--- a/src/MicroHs/Lex.hs
+++ b/src/MicroHs/Lex.hs
@@ -8,7 +8,7 @@ module MicroHs.Lex(
import qualified Prelude(); import MHSPrelude hiding(lex)
import Data.Char
import Data.List
-import Data.Maybe (fromJust)
+import Data.Maybe (fromJust, isJust)
import MicroHs.Ident
import Text.ParserComb(TokenMachine(..))
@@ -101,14 +101,14 @@ lex loc ('(':dcs@(d:cs)) | d == '#' = TSpec loc 'L' : lex (addCol loc 2) cs
| otherwise = TSpec loc '(' : lex (addCol loc 1) dcs
lex loc ('#':')':cs) = TSpec loc 'R' : lex (addCol loc 2) cs
-- Recognize #line 123 "file/name.hs"
-lex loc ('#':xcs) | (SLoc _ _ 1) <- loc, Just cs <- stripPrefix "line " xcs =
+lex (SLoc _ _ 1) ('#':'l':'i':'n':'e':' ':cs) =
case span (/= '\n') cs of
(line, rs) -> -- rs will contain the '\n', so subtract 1 below
let ws = words line
file = tail $ init $ ws!!1 -- strip the initial and final '"'
loc' = SLoc file (readInt (ws!!0) - 1) 1
in lex loc' rs
- | (SLoc _ 1 1) <- loc, take 1 xcs == "!" =
+lex loc@(SLoc _ 1 1) ('#':xcs@('!':cs)) =
-- It's a shebang (#!), ignore the rest of the line
skipLine loc xcs
lex loc ('!':' ':cs) = -- ! followed by a space is always an operator
@@ -231,7 +231,7 @@ tIndent ts = TIndent (tokensLoc ts) : ts
lexLitStr :: SLoc -> SLoc -> (String -> Token) -> (String -> Maybe Int) -> (String -> String) -> String -> [Token]
lexLitStr oloc loc mk end post acs = loop loc [] acs
- where loop l rs cs | Just k <- end cs = mk (decodeEscs $ post $ reverse rs) : lex (addCol l k) (drop k cs)
+ where loop l rs cs | isJust (end cs) = let Just k = end cs in mk (decodeEscs $ post $ reverse rs) : lex (addCol l k) (drop k cs)
loop l rs ('\\':c:cs) | isSpace c = remGap l rs cs
loop l rs ('\\':'^':'\\':cs) = loop (addCol l 3) ('\\':'^':'\\':rs) cs -- special hack for unescaped \
loop l rs ('\\':cs) = loop' (addCol l 1) ('\\':rs) cs
@@ -270,8 +270,10 @@ decodeEsc ('x':cs) = conv 16 0 cs
decodeEsc ('o':cs) = conv 8 0 cs
decodeEsc ('^':c:cs) | '@' <= c && c <= '_' = chr (ord c - ord '@') : decodeEscs cs
decodeEsc cs@(c:_) | isDigit c = conv 10 0 cs
-decodeEsc (c1:c2:c3:cs) | Just c <- lookup [c1,c2,c3] ctlCodes = c : decodeEscs cs
-decodeEsc (c1:c2:cs) | Just c <- lookup [c1,c2] ctlCodes = c : decodeEscs cs
+decodeEsc (c1:c2:c3:cs) | isJust mc = let Just c = mc in c : decodeEscs cs
+ where mc = lookup [c1,c2,c3] ctlCodes
+decodeEsc (c1:c2:cs) | isJust mc = let Just c = mc in c : decodeEscs cs
+ where mc = lookup [c1,c2] ctlCodes
decodeEsc (c :cs) = c : decodeEscs cs
decodeEsc [] = mhsError "Bad \\ escape"
@@ -417,7 +419,7 @@ pragma loc cs =
in case words cs of
p : _ | map toUpper p == "SOURCE" -> TPragma loc p : skip
-- hsc2hs generates LINE pragmas
- p : ln@(_:_) : fn : _ | map toUpper p == "LINE", all isDigit ln ->
+ p : ln@(_:_) : fn : _ | map toUpper p == "LINE" && all isDigit ln ->
let f = tail (init fn)
l = readInt ln - 1
in seq l $ skipNest (SLoc f l 1) 1 ('#':cs)
diff --git a/src/MicroHs/Main.hs b/src/MicroHs/Main.hs
index 913c197b..7f17e313 100644
--- a/src/MicroHs/Main.hs
+++ b/src/MicroHs/Main.hs
@@ -141,16 +141,16 @@ decodeArgs f mdls (arg:args) =
"-z" -> decodeArgs f{compress = True} mdls args
"-b64" -> decodeArgs f{base64 = True} mdls args
"-Q" -> decodeArgs f{installPkg = True} mdls args
- "-o" | s : args' <- args
- -> decodeArgs f{output = s} mdls args'
- "-optc" | s : args' <- args
- -> decodeArgs f{cArgs = cArgs f ++ [s]} mdls args'
- "-optl" | s : args' <- args
- -> decodeArgs f{lArgs = lArgs f ++ [s]} mdls args'
- "-optF" | s : args' <- args
- -> decodeArgs f{fArgs = fArgs f ++ [s]} mdls args'
- "-pgmF" | s : args' <- args
- -> decodeArgs f{fPgm = Just s} mdls args'
+ "-o" | not (null args)
+ -> let s : args' = args in decodeArgs f{output = s} mdls args'
+ "-optc" | not (null args)
+ -> let s : args' = args in decodeArgs f{cArgs = cArgs f ++ [s]} mdls args'
+ "-optl" | not (null args)
+ -> let s : args' = args in decodeArgs f{lArgs = lArgs f ++ [s]} mdls args'
+ "-optF" | not (null args)
+ -> let s : args' = args in decodeArgs f{fArgs = fArgs f ++ [s]} mdls args'
+ "-pgmF" | not (null args)
+ -> let s : args' = args in decodeArgs f{fPgm = Just s} mdls args'
"-F" -> decodeArgs f{doF = True} mdls args
'-':'i':[] -> decodeArgs f{paths = []} mdls args
'-':'i':s -> decodeArgs f{paths = paths f ++ [s]} mdls args
@@ -163,7 +163,7 @@ decodeArgs f mdls (arg:args) =
'-':'a':s -> decodeArgs f{pkgPath = pkgPath f ++ [s]} mdls args
'-':'L':s -> decodeArgs f{listPkg = Just s} mdls args
'-':'p':s -> decodeArgs f{preload = preload f ++ [s]} mdls args
- '-':'d':'d':'u':'m':'p':'-':r | Just d <- lookup r dumpFlagTable ->
+ '-':'d':'d':'u':'m':'p':'-':r | isJust (lookup r dumpFlagTable) -> let Just d = lookup r dumpFlagTable in
decodeArgs f{dumpFlags = d : dumpFlags f} mdls args
"--stdin" -> decodeArgs f{useStdin = True} mdls args
'-':_ -> mhsError $ "Unknown flag: " ++ arg ++ "\n" ++ usage
diff --git a/src/MicroHs/TypeCheck.hs b/src/MicroHs/TypeCheck.hs
index db7f3527..b006e8f9 100644
--- a/src/MicroHs/TypeCheck.hs
+++ b/src/MicroHs/TypeCheck.hs
@@ -824,7 +824,7 @@ tInst :: HasCallStack => Expr -> EType -> T (Expr, EType)
tInst ae (EForall _ vks t) = do
t' <- tInstForall vks t
tInst ae t'
-tInst ae at | Just (ctx, t) <- getImplies at = do
+tInst ae at | isJust (getImplies at) = let Just (ctx, t) = getImplies at in do
--tcTrace $ "tInst: addConstraint: " ++ show ae ++ ", " ++ show d ++ " :: " ++ show ctx
{-
if eqExpr ae eCannotHappen then
@@ -1326,7 +1326,7 @@ expandClass d = return [d]
-- Ignoring initial quantifiers and context, how many arrows does the type have?
countArrows :: EType -> Int
countArrows (EForall _ _ t) = countArrows t
-countArrows t | Just (_, t') <- getImplies t = countArrows t'
+countArrows t | isJust (getImplies t) = let Just (_, t') = getImplies t in countArrows t'
| otherwise = length . fst . getArrows $ t
simpleEqn :: Expr -> [Eqn]
@@ -1772,7 +1772,7 @@ tInferExpr = tInfer tcExpr
tCheckExpr :: HasCallStack =>
EType -> Expr -> T Expr
-tCheckExpr t e | Just (ctx, t') <- getImplies t = do
+tCheckExpr t e | isJust (getImplies t) = let Just (ctx, t') = getImplies t in do
-- tcTrace $ "tCheckExpr: " ++ show (e, ctx, t')
xt <- expandSyn t
unless (eqEType t xt) undefined
@@ -2125,7 +2125,7 @@ needDsCase ex lbls ae =
vt <- gets valueTable
case stLookupGlbUnqMany lbl vt of
-- check the return type of an unambiguous label
- Just [Entry _ t] | (t':_, _) <- getArrows (dropForallContext t) -> needT t'
+ Just [Entry _ t] | not $ null $ fst $ getArrows (dropForallContext t) -> needT $ head $ fst $ getArrows $ dropForallContext t
_ -> return Nothing
-- Do a record update using case.
@@ -2184,8 +2184,8 @@ tcExprAp mt ae args = do
EUVar r -> fmap (fromMaybe t) (getUVar r)
_ -> return t
-- tcTrace $ "exExprAp: EVar " ++ showIdent i ++ " :: " ++ showExpr t ++ " = " ++ showExpr t' ++ " mt=" ++ show mt
- case fn of
- EVar ii | ii == mkIdent "Data.Function.$", f:as <- args -> tcExprAp mt f as
+ case (fn, args) of
+ (EVar ii, f:as) | ii == mkIdent "Data.Function.$" -> tcExprAp mt f as
_ -> tcExprApFn mt fn t' args
EQVar f t -> -- already resolved
tcExprApFn mt f t args
@@ -2216,17 +2216,17 @@ tcExprApFn mt fn atfn aargs = do
let -- loop _ats aas ft | trace ("loop: " ++ show (aas, ft)) False = undefined
loop ats [] ft = final (reverse ats) ft
loop ats aas@(a:as) aft = do
- case nextArg aft of
- AReqd (IdKind i k) ft -> useType i k a ft
- AForall _ (IdKind i k:iks) ft | ETypeArg t <- a -> do
+ case (nextArg aft, a) of
+ (AReqd (IdKind i k) ft, _) -> useType i k a ft
+ (AForall _ (IdKind i k:iks) ft, ETypeArg t) -> do
-- traceM ("AForall " ++ show (i, t))
useType i k t (EForall QExpl iks ft)
- AForall _ iks ft -> do
+ (AForall _ iks ft, _) -> do
ft' <- tInstForall iks ft
loop ats aas ft'
- AConstaint ctx ft ->
+ (AConstaint ctx ft, _) ->
loop (ArgCtx ctx : ats) aas ft
- ARet aft' -> do
+ (ARet aft', _) -> do
(at, rt) <- unArrow loc aft'
--traceM ("ARet " ++ show (at, rt))
loop (ArgExpr a at : ats) as rt
@@ -2543,7 +2543,7 @@ nextArg :: EType -> Arg
nextArg (EForall _ [] t) = nextArg t
nextArg (EForall QReqd (ik:iks) t) = AReqd ik (EForall QReqd iks t)
nextArg (EForall q iks t) = AForall q iks t
-nextArg t | Just (ctx, t') <- getImplies t = AConstaint ctx t'
+nextArg t | isJust (getImplies t) = let Just (ctx, t') = getImplies t in AConstaint ctx t'
| otherwise = ARet t
tcExprLam :: HasCallStack => Expected -> SLoc -> [Eqn] -> T Expr
@@ -2559,7 +2559,7 @@ tcEqns' top at eqns =
case at of
EForall QExpl iks t -> withExtTyps iks $ tcEqns' top t eqns
EForall QImpl _ t -> tcEqns' top t eqns
- _ | Just (ctx, t') <- getImplies at -> do
+ _ | isJust (getImplies at) -> let Just (ctx, t') = getImplies at in do
let loc = getSLoc eqns
d <- newADictIdent loc
f <- newIdent loc "fcnD"
@@ -3109,7 +3109,7 @@ skolemise (EForall _ tvs ty) = do -- Rule PRPOLY
(sks1, ty') <- shallowSkolemise tvs ty
(sks2, ty'') <- skolemise ty'
return (sks1 ++ sks2, ty'')
-skolemise t@(EApp _ _) | Just (arg_ty, res_ty) <- getArrow t = do
+skolemise t@(EApp _ _) | isJust (getArrow t) = let Just (arg_ty, res_ty) = getArrow t in do
(sks, res_ty') <- skolemise res_ty
return (sks, arg_ty `tArrow` res_ty')
skolemise (EApp f a) = do
@@ -3178,13 +3178,13 @@ subsCheckRho loc exp1 (EForall _ vs1 t1) (EForall _ vs2 t2) | length vs1 == leng
subsCheckRho loc exp1 sigma1@EForall{} rho2 = do -- Rule SPEC
(exp1', rho1) <- tInst exp1 sigma1
subsCheckRho loc exp1' rho1 rho2
-subsCheckRho loc exp1 arho1 rho2 | Just _ <- getImplies arho1 = do
+subsCheckRho loc exp1 arho1 rho2 | isJust (getImplies arho1) = do
(exp1', rho1) <- tInst exp1 arho1
subsCheckRho loc exp1' rho1 rho2
-subsCheckRho loc exp1 rho1 rho2 | Just (a2, r2) <- getArrow rho2 = do -- Rule FUN
+subsCheckRho loc exp1 rho1 rho2 | isJust (getArrow rho2) = let Just (a2, r2) = getArrow rho2 in do -- Rule FUN
(a1, r1) <- unArrow loc rho1
subsCheckFun loc exp1 a1 r1 a2 r2
-subsCheckRho loc exp1 rho1 rho2 | Just (a1, r1) <- getArrow rho1 = do -- Rule FUN
+subsCheckRho loc exp1 rho1 rho2 | isJust (getArrow rho1) = let Just (a1, r1) = getArrow rho1 in do -- Rule FUN
(a2,r2) <- unArrow loc rho2
subsCheckFun loc exp1 a1 r1 a2 r2
subsCheckRho loc exp1 tau1 tau2 = do -- Rule MONO
@@ -3366,10 +3366,12 @@ canonPatSynType at = do
pure $ mkTyp [] emptyCtx [] emptyCtx ty
splitPatSynType :: EType -> ([IdKind], EConstraint, [IdKind], EConstraint, EType)
-splitPatSynType (EForall _ vks1 t0)
- | Just (ctx1, EForall _ vks2 t1) <- getImplies t0
- , Just (ctx2, ty) <- getImplies t1
- = (vks1, ctx1, vks2, ctx2, ty)
+splitPatSynType (EForall _ vks1 t0) | isJust x = fromJust x
+ where
+ x = do
+ (ctx1, EForall _ vks2 t1) <- getImplies t0
+ (ctx2, ty) <- getImplies t1
+ Just (vks1, ctx1, vks2, ctx2, ty)
splitPatSynType t = impossibleShow t
-----
@@ -3465,7 +3467,7 @@ defaultOneTyVar tv = do
-- traceM $ "defaultOneTyVar: cvs = " ++ show cvs
dvs <- getSuperClasses cvs -- add superclasses
-- traceM $ "defaultOneTyVar: dvs = " ++ show dvs
- let oneCls c | Just ts <- M.lookup c (defaults old) =
+ let oneCls c | isJust (M.lookup c $ defaults old) = let Just ts = M.lookup c (defaults old) in
take 1 $ filter (\ t -> all (\ cc -> soluble cc t) cvs) ts
| otherwise = []
soluble c t = fst $ flip tcRun old $ do
@@ -3571,7 +3573,7 @@ solvers =
-- Examine each goal, either solve it (possibly producing new goals) or let it remain unsolved.
solveMany :: [Goal] -> [UGoal] -> [(EType, Soln)] -> [Improve] -> T ([UGoal], [Soln], [Improve])
solveMany [] uns sol imp = return (uns, map snd sol, imp)
-solveMany ((di, ct) : cnss) uns sol imp | Just (_, (dd, _)) <- find (eqEType ct . fst) sol =
+solveMany ((di, ct) : cnss) uns sol imp | isJust (find (eqEType ct . fst) sol) = let Just (_, (dd, _)) = find (eqEType ct . fst) sol in
solveMany cnss uns ((ct, (di, EVar dd)) : sol) imp
-- Need to handle ct of the form C => T, and forall a . T
solveMany (cns@(di, ct) : cnss) uns sol imp = do
@@ -3889,7 +3891,7 @@ solveEq eqs t1 t2 | normTypeEq eqs t1 `eqEType` normTypeEq eqs t2 = Just []
-- XXX This guaranteed by how it's called, but I'm not sure it always works properly.
addTypeEq :: EType -> EType -> TypeEqTable -> TypeEqTable
addTypeEq t1 t2 aeqs =
- let deref (EVar i) | Just t <- lookup i aeqs = t
+ let deref (EVar i) | isJust (lookup i aeqs) = fromJust $ lookup i aeqs
deref (ESign t _) = t
deref t = t
t1' = deref t1
@@ -3990,7 +3992,7 @@ standaloneDeriving str narg act = do
-- traceM ("standaloneDeriving 1 " ++ show (_vks, _ctx, cc))
(cls, ts, tname) <-
case getAppM cc of
- Just (c, ts@(_:_)) | Just (n, _) <- getAppM (last ts) -> return (c, init ts, n)
+ Just (c, ts@(_:_)) | isJust (getAppM $ last ts) -> let Just (n, _) = getAppM (last ts) in return (c, init ts, n)
_ -> tcError (getSLoc act) "malformed standalone deriving"
-- traceM ("standaloneDeriving 2 " ++ show (act, cls, tname))
dtable <- gets dataTable
diff --git a/src/Text/ParserComb.hs b/src/Text/ParserComb.hs
index 6efd5a3f..8ab72759 100644
--- a/src/Text/ParserComb.hs
+++ b/src/Text/ParserComb.hs
@@ -127,7 +127,9 @@ satisfy msg f = P $ \ acs ->
satisfyM :: forall tm t a . TokenMachine tm t => String -> (t -> Maybe a) -> Prsr tm t a
satisfyM msg f = P $ \ acs ->
case tmNextToken acs of
- (c, cs) | Just a <- f c -> Success a cs noFail
+ (c, cs) -> case f c of
+ Just a -> Success a cs noFail
+ _ -> Failure (LastFail (tmLeft acs) (firstToken acs) [msg])
_ -> Failure (LastFail (tmLeft acs) (firstToken acs) [msg])
infixl 9 <?>
@@ -0,0 +1,365 @@
This patch is based on https://github.com/augustss/MicroHs/pull/429
If you need to update it, rebase the above PR onto the new version's tag.
diff --git a/hugs/Data/Semigroup.hs b/hugs/Data/Semigroup.hs
index b7360013..eab8c48d 100644
--- a/hugs/Data/Semigroup.hs
+++ b/hugs/Data/Semigroup.hs
@@ -18,11 +18,11 @@ class Semigroup a where
| otherwise = f x0 y0
where
f x y
- | even y == 0 = f (x <> x) (y `quot` 2)
+ | even y = f (x <> x) (y `quot` 2)
| y == 1 = x
| otherwise = g (x <> x) (y `quot` 2) x
g x y z
- | even y == 0 = g (x <> x) (y `quot` 2) z
+ | even y = g (x <> x) (y `quot` 2) z
| y == 1 = x <> z
| otherwise = g (x <> x) (y `quot` 2) (x <> z)
diff --git a/hugs/Data/String.hs b/hugs/Data/String.hs
new file mode 100644
index 00000000..1de782d3
--- /dev/null
+++ b/hugs/Data/String.hs
@@ -0,0 +1,17 @@
+module Data.String(
+ IsString(..),
+ String,
+ lines, unlines,
+ words, unwords,
+ ) where
+
+import qualified Data.ByteString.Char8 as BS8
+
+class IsString a where
+ fromString :: String -> a
+
+instance IsString [Char] where
+ fromString s = s
+
+instance IsString BS8.ByteString where
+ fromString = BS8.pack
diff --git a/hugs/Data/Text.hs b/hugs/Data/Text.hs
index fbd1c731..75f8e829 100644
--- a/hugs/Data/Text.hs
+++ b/hugs/Data/Text.hs
@@ -8,6 +8,7 @@ module Data.Text(
null,
head,
tail,
+ cons,
uncons,
) where
import Prelude hiding(head, tail, null)
@@ -64,6 +65,9 @@ head (T t) = Prelude.head t
tail :: Text -> Text
tail (T t) = T (Prelude.tail t)
+cons :: Char -> Text -> Text
+cons c (T t) = T (c : t)
+
uncons :: Text -> Maybe (Char, Text)
uncons t | null t = Nothing
| otherwise = Just (head t, tail t)
diff --git a/hugs/MHSPrelude.hs b/hugs/MHSPrelude.hs
index cb6b36f6..cb47e041 100644
--- a/hugs/MHSPrelude.hs
+++ b/hugs/MHSPrelude.hs
@@ -4,10 +4,11 @@ module MHSPrelude(
module Prelude,
module MHSPrelude,
-- module Control.Monad.Fail,
- module Control.Arrow,
+ -- Exporting these with 'module Control.Arrow' does not work
+ first, second,
module Data.Monoid,
module Data.Semigroup,
- (<$>), Applicative(..), (*>),
+ (<$>), Applicative(..), (*>), (<*), (>=>), (<=<)
) where
import Hugs.Prelude()
import Prelude hiding(fail)
@@ -16,6 +17,7 @@ import Control.Arrow(first, second)
import Control.Applicative
import Control.Exception(Exception, try)
--import Control.Monad.Fail
+import Data.Int
import Data.List
import Data.Maybe
import Data.Monoid
@@ -55,6 +57,12 @@ spanEnd p xs = (dropWhileEnd p xs, takeWhileEnd p xs)
breakEnd :: (a -> Bool) -> [a] -> ([a], [a])
breakEnd p = spanEnd (not . p)
+subsequences :: [a] -> [[a]]
+subsequences xs = [] : sub xs
+ where sub [] = []
+ sub (x:xs) = [x] : foldr f [] (sub xs)
+ where f ys r = ys : (x : ys) : r
+
------- Version --------
makeVersion :: [Int] -> Version
@@ -193,6 +201,7 @@ force :: (NFData a) => a -> a
force x = x `deepseq` x
instance NFData Int
+instance NFData Int64
instance NFData Word
instance NFData Float
instance NFData Double
@@ -229,3 +238,11 @@ instance NFData MD5CheckSum
class HasCallStack
instance HasCallStack
+
+(<=<) :: forall m a b c . Monad m => (b -> m c) -> (a -> m b) -> (a -> m c)
+f <=< g = \ a -> do
+ b <- g a
+ f b
+
+(>=>) :: forall m a b c . Monad m => (a -> m b) -> (b -> m c) -> (a -> m c)
+(>=>) = flip (<=<)
diff --git a/src/MicroHs/Compile.hs b/src/MicroHs/Compile.hs
index ddec7993..643319aa 100644
--- a/src/MicroHs/Compile.hs
+++ b/src/MicroHs/Compile.hs
@@ -123,12 +123,17 @@ compile flags nm ach = do
return ((tModuleName cm, concatMap tBindingsOf $ cachedModules ch), syms, ch)
-- Compile a module for the interactive system
-compileInteractive :: Flags -> EModule -> CM (TModule [LDef], Symbols, TCState)
-compileInteractive flags mdl = do
- ((dmdl, syms, _, _, _), tcstate) <- compileModuleP flags ImpNormal mdl
+compileInteractive :: Flags -> EModule -> Maybe TCState -> CM (TModule [LDef], Symbols, TCState)
+compileInteractive flags mdl mtcstate = do
+ ((dmdl, syms, _, _, _), tcstate') <- compile
+ flags ImpNormal mdl
loadBoots flags
loadDependencies flags
- return (dmdl, syms, tcstate)
+ return (dmdl, syms, tcstate')
+ where
+ compile = case mtcstate of
+ Nothing -> compileModuleP
+ Just tcstate -> compileModuleP' (\flags _ impt aimps mdl -> typeCheck' flags impt (map filterImports aimps) mdl tcstate)
-- Compile a module with the given name.
-- If the module has already been compiled, return the cached result.
@@ -233,7 +238,12 @@ compileModule flags impt mn pathfn file = do
return (cmdl, syms, tThis + tImp)
compileModuleP :: Flags -> ImpType -> EModule -> CM ((TModule [LDef], Symbols, [(ImpType, IdentModule)], Time, Time), TCState)
-compileModuleP flags impt mdl@(EModule _ _ defs) = do
+compileModuleP = compileModuleP' typeCheck
+
+compileModuleP'
+ :: (Flags -> GlobTables -> ImpType -> [(ImportSpec, TModule [LDef])] -> EModule -> (TModule [EDef], GlobTables, Symbols, TCState))
+ -> Flags -> ImpType -> EModule -> CM ((TModule [LDef], Symbols, [(ImpType, IdentModule)], Time, Time), TCState)
+compileModuleP' tc flags impt mdl@(EModule _ _ defs) = do
-- liftIO $ putStrLn $ showEModule mdl
-- liftIO $ putStrLn $ showEDefs defs
let
@@ -244,7 +254,7 @@ compileModuleP flags impt mdl@(EModule _ _ defs) = do
t3 <- liftIO getTimeMilli
glob <- gets getCacheTables
let
- (tmdl, glob', syms, tcstate) = typeCheck flags glob impt (zip specs impMdls) mdl
+ (tmdl, glob', syms, tcstate) = tc flags glob impt (zip specs impMdls) mdl
modify $ setCacheTables glob'
dumpIf flags Dtypecheck $
liftIO $ putStrLn $ "type checked:\n" ++ showTModule showEDefs tmdl ++ "-----\n"
@@ -258,9 +268,9 @@ compileModuleP flags impt mdl@(EModule _ _ defs) = do
return ((dmdl, syms, imported, tThis, tImp), tcstate)
compileToCombinators :: TModule [LDef] -> TModule [LDef]
-compileToCombinators dmdl = do
+compileToCombinators dmdl =
let cmdl = setBindings dmdl [ (i, compileOpt e) | (i, e) <- tBindingsOf dmdl ]
- seq (rnf cmdl) cmdl -- This makes execution slower, but speeds up GC
+ in seq (rnf cmdl) cmdl -- This makes execution slower, but speeds up GC
-- Add implicit imports:
-- import Prelude
diff --git a/src/MicroHs/Expr.hs b/src/MicroHs/Expr.hs
index 84578594..bd05f1bc 100644
--- a/src/MicroHs/Expr.hs
+++ b/src/MicroHs/Expr.hs
@@ -57,11 +57,11 @@ module MicroHs.Expr(
dropForallContext,
) where
import qualified Prelude(); import MHSPrelude hiding ((<>))
+import Data.Int
import Data.List
import Data.Maybe
import MicroHs.Builtin
import MicroHs.Ident
-import {-# SOURCE #-} MicroHs.TCMonad(TCState)
import Text.PrettyPrint.HughesPJLite
type IdentModule = Ident
@@ -96,8 +96,6 @@ data EDef
| Pattern LHS EPat (Maybe [Eqn])
| StandDeriving DerStrategy Int EConstraint
| DfltSign Ident EType -- only in class declarations
- -- Only used by interactive system to load a cached TCState to avoid import processing
- | SetTCState TCState
--DEBUG deriving (Show)
instance NFData EDef where
@@ -118,7 +116,6 @@ instance NFData EDef where
rnf (Pattern a b c) = rnf a `seq` rnf b `seq` rnf c
rnf (StandDeriving a b c) = rnf a `seq` rnf b `seq` rnf c
rnf (DfltSign a b) = rnf a `seq` rnf b
- rnf (SetTCState a) = seq a ()
data ImpType = ImpNormal | ImpBoot
deriving (Eq)
@@ -900,7 +897,6 @@ ppEDef def =
Pattern lhs@(i,_) p meqns -> text "pattern" <+> ppLHS lhs <+> text "=" <+> ppExpr p <+> maybe empty (ppWhere (text ";") . (:[]) . Fcn i) meqns
StandDeriving _s _narg ct -> text "deriving instance" <+> ppEType ct
DfltSign i t -> text "default" <+> ppIdent i <+> text "::" <+> ppEType t
- SetTCState _ -> text "SetTCState ..."
ppDerivings :: [Deriving] -> Doc
ppDerivings = sep . map ppDeriving
diff --git a/src/MicroHs/Interactive.hs b/src/MicroHs/Interactive.hs
index ebb33b43..7b70064a 100644
--- a/src/MicroHs/Interactive.hs
+++ b/src/MicroHs/Interactive.hs
@@ -295,11 +295,11 @@ compile file = do
let mdl@(EModule mn es _) = parseDie pTopModule "" file
defs <- updateTCStateCache mdl
(_, tcstate, _) <- gets isCComp
- let mdl' = EModule mn es (SetTCState tcstate : defs)
+ let mdl' = EModule mn es defs
flgs <- gets isFlags
cash <- gets isCache
-- putStrLnI $ " tryCompile compile " ++ show mdl'
- ((dmdl, _, tcstate'), _) <- liftIO $ runStateIO (compileInteractive flgs mdl') cash
+ ((dmdl, _, tcstate'), _) <- liftIO $ runStateIO (compileInteractive flgs mdl' $ Just tcstate) cash
cmdl <- liftIO $ evaluate $ compileToCombinators dmdl
-- putStrLnI $ " tryCompile dmdl = " ++ (show $ tBindingsOf dmdl)
return (tBindingsOf cmdl, tcstate')
@@ -398,7 +398,7 @@ updateTCStateCache (EModule mn es ds) = do
cash <- gets isCache
-- putStrLnI "*** update tcstate"
let mdl' = addPreludeImport mdl
- ((_, syms, tcstate), ch) <- liftIO $ runStateIO (compileInteractive flgs mdl') cash
+ ((_, syms, tcstate), ch) <- liftIO $ runStateIO (compileInteractive flgs mdl' Nothing) cash
let idmap = translateMap $ concatMap tBindingsOf $ cachedModules ch
-- putStrLnI $ "*** update isFast " ++ show nImps
modify $ \ is -> is{ isCComp = (nImps, tcstate, idmap), isCache = ch, isSymbols = syms }
diff --git a/src/MicroHs/Parse.hs b/src/MicroHs/Parse.hs
index 821718a7..6a68a01a 100644
--- a/src/MicroHs/Parse.hs
+++ b/src/MicroHs/Parse.hs
@@ -791,7 +791,7 @@ pDo = do
case last ss of
SThen e ->
pure $ EDo q [SRec (init ss), SThen e]
- _ -> fail "mdo"
+ _ -> Control.Monad.Fail.fail "mdo"
else
pure (EDo q ss)
diff --git a/src/MicroHs/TCMonad.hs-boot b/src/MicroHs/TCMonad.hs-boot
deleted file mode 100644
index f88ad533..00000000
--- a/src/MicroHs/TCMonad.hs-boot
+++ /dev/null
@@ -1,2 +0,0 @@
-module MicroHs.TCMonad where
-data TCState
diff --git a/src/MicroHs/TypeCheck.hs b/src/MicroHs/TypeCheck.hs
index 47f2b461..db7f3527 100644
--- a/src/MicroHs/TypeCheck.hs
+++ b/src/MicroHs/TypeCheck.hs
@@ -2,7 +2,7 @@
-- See LICENSE file for full license.
{-# OPTIONS_GHC -Wno-incomplete-uni-patterns -Wno-unused-imports -Wno-unused-do-bind #-}
module MicroHs.TypeCheck(
- typeCheck,
+ typeCheck, typeCheck', filterImports,
TModule(..), showTModule,
GlobTables, emptyGlobTables, mergeGlobTables,
impossible, impossibleShow,
@@ -102,35 +102,34 @@ type Sigma = EType
type Rho = EType
typeCheck :: Flags -> GlobTables -> ImpType -> [(ImportSpec, TModule a)] -> EModule -> (TModule [EDef], GlobTables, Symbols, TCState)
-typeCheck flags globs impt aimps (EModule mn exps defs) =
+typeCheck flags globs impt aimps mdl@(EModule mn exps defs) =
-- trace (unlines $ map (showTModuleExps . snd) aimps) $
- let
- imps = map filterImports aimps
- tc =
- case defs of
- SetTCState tcs : _ -> tcs -- hack to set the saved TCState
- _ -> mkTCState mn globs imps
- in case tcRun (tcDefs flags impt defs) tc of
- (tds, tcs) ->
- let
- thisMdl = (mn, mkTModule tds tcs)
- impMdls = [(fromMaybe m mm, tm) | (ImportSpec _ _ m mm _, tm) <- imps]
- allMdls = thisMdl : impMdls
- (texps, vexps) =
- unzip $ map (getTVExps impMap (typeTable tcs) (valueTable tcs) (assocTable tcs)) exps
- where impMap = M.fromListWith (++) [(i, [m]) | (i, m) <- allMdls]
- fexps = map (tFixDefs . snd) allMdls
- sexps = synTable tcs
- dexps = dataTable tcs
- iexps = instTable tcs
- ctbl = classTable tcs
- dflts = M.fromList $ filter ((`elem` ds) . fst) $ M.toList $ defaults tcs
- where ds = [ tyQIdent $ expLookup ti (typeTable tcs) | ExpDefault ti <- exps ]
- in ( tModule mn (nubBy ((==) `on` fst) (concat fexps)) (concat texps) (concat vexps) dflts tds
- , GlobTables { gSynTable = sexps, gDataTable = dexps, gClassTable = ctbl, gInstInfo = iexps }
- , (typeTable tcs, valueTable tcs)
- , tcs
- )
+ let imps = map filterImports aimps
+ in typeCheck' flags impt imps mdl $ mkTCState mn globs imps
+
+typeCheck' :: Flags -> ImpType -> [(ImportSpec, TModule a)] -> EModule -> TCState -> (TModule [EDef], GlobTables, Symbols, TCState)
+typeCheck' flags impt imps (EModule mn exps defs) tc =
+ case tcRun (tcDefs flags impt defs) tc of
+ (tds, tcs) ->
+ let
+ thisMdl = (mn, mkTModule tds tcs)
+ impMdls = [(fromMaybe m mm, tm) | (ImportSpec _ _ m mm _, tm) <- imps]
+ allMdls = thisMdl : impMdls
+ (texps, vexps) =
+ unzip $ map (getTVExps impMap (typeTable tcs) (valueTable tcs) (assocTable tcs)) exps
+ where impMap = M.fromListWith (++) [(i, [m]) | (i, m) <- allMdls]
+ fexps = map (tFixDefs . snd) allMdls
+ sexps = synTable tcs
+ dexps = dataTable tcs
+ iexps = instTable tcs
+ ctbl = classTable tcs
+ dflts = M.fromList $ filter ((`elem` ds) . fst) $ M.toList $ defaults tcs
+ where ds = [ tyQIdent $ expLookup ti (typeTable tcs) | ExpDefault ti <- exps ]
+ in ( tModule mn (nubBy ((==) `on` fst) (concat fexps)) (concat texps) (concat vexps) dflts tds
+ , GlobTables { gSynTable = sexps, gDataTable = dexps, gClassTable = ctbl, gInstInfo = iexps }
+ , (typeTable tcs, valueTable tcs)
+ , tcs
+ )
-- A hack to force evaluation of errors.
-- This should be redone to all happen in the T monad.
diff --git a/src/Text/ParserComb.hs b/src/Text/ParserComb.hs
index 5b0e8753..6efd5a3f 100644
--- a/src/Text/ParserComb.hs
+++ b/src/Text/ParserComb.hs
@@ -115,7 +115,7 @@ instance TokenMachine tm t => Alternative (Prsr tm t) where
r -> r
instance TokenMachine tm t => MonadPlus (Prsr tm t) where
- mzero = fail "mzero"
+ mzero = F.fail "mzero"
mplus = (<|>)
satisfy :: forall tm t . TokenMachine tm t => String -> (t -> Bool) -> Prsr tm t t
@@ -0,0 +1,21 @@
commit beaea6f66e4f53d617418a4c155b9a14e2c9327e
Author: Alex Tunstall <alex@tunstall.xyz>
Date: Fri Mar 20 06:52:08 2026 +0000
Add -lm to default link flags
MicroHs should always link with -lm because its RTS requires it.
diff --git a/src/MicroHs/Flags.hs b/src/MicroHs/Flags.hs
index e20797c6..df89730e 100644
--- a/src/MicroHs/Flags.hs
+++ b/src/MicroHs/Flags.hs
@@ -54,7 +54,7 @@ defaultFlags dir = Flags {
doCPP = False,
cppArgs = [],
cArgs = [],
- lArgs = [],
+ lArgs = ["-lm"],
compress = False,
base64 = False,
buildPkg = Nothing,
File diff suppressed because one or more lines are too long
@@ -0,0 +1,36 @@
{
lib,
args,
microhs-boot,
stdenv,
}:
stdenv.mkDerivation (
finalAttrs:
let
args' = args finalAttrs;
in
args'
// {
pname = "microhs-stage1";
patches =
(args'.patches or [ ])
++ lib.optionals microhs-boot.usesHugs [
patches/simple-unicode.patch
];
makeFlags = [ "PREFIX=${placeholder "out"}" ];
installTargets = [
"targets.conf"
"oldinstall"
];
buildPhase = ''
runHook preBuild
mkdir -p bin
printf 'Building bin/mhs using ${microhs-boot}/bin/mhs\n'
${microhs-boot}/bin/mhs -l -imhs -isrc -ipaths MicroHs.Main -o bin/mhs
runHook postBuild
'';
}
)
@@ -0,0 +1,61 @@
{
args,
cpphs,
microcabal-stage1,
microhs-stage1,
stdenv,
callPackage,
}:
stdenv.mkDerivation (
finalAttrs:
let
args' = args finalAttrs;
haskellCompilerName = "mhs-${args'.version}";
in
args'
// {
pname = "microhs";
nativeBuildInputs = [
microcabal-stage1
microhs-stage1
];
env = {
CABALDIR = "${placeholder "out"}/lib/mcabal";
};
dontBuild = true;
installPhase = ''
runHook preInstall
pushd lib
mcabal -v install
popd
mcabal -v install
mkdir -p $out/bin
ln -s ../lib/mcabal/bin/mhs $out/bin/mhs
runHook postInstall
'';
passthru = {
inherit
haskellCompilerName
cpphs
microcabal-stage1
microhs-stage1
;
targetPrefix = "";
isMhs = true;
usesHugs = false;
tests = {
hello-world = callPackage ./test-hello-world.nix { microhs = finalAttrs.finalPackage; };
};
};
}
)
@@ -0,0 +1,52 @@
{
lib,
runCommand,
runtimeShell,
writeShellScript,
}:
{
microhs,
packages,
}:
let
packages' = [ microhs ] ++ lib.filter (p: p != null) packages;
extraFlags = lib.concatMapStringsSep " " (
p: "-a${p}/lib/mcabal/${microhs.haskellCompilerName}"
) packages';
wrapper = writeShellScript "mhs-wrapper" ''
args=("$@")
noExtra=0
for ((i=0; i<"''${#args[@]}"; ++i)); do
case "''${args[i]}" in
--version | --numeric-version)
noExtra=1
;;
*)
;;
esac
done
if test "$noExtra" -eq 0; then
for arg in ${extraFlags}; do
args[i++]="$arg"
done
fi
if (( "''${NIX_DEBUG:-0}" >= 1 )); then
printf 'mhs-wrapper: mhs %s\n' "''${args[*]}" >&2
fi
exec ${microhs}/bin/mhs "''${args[@]}"
'';
in
runCommand "${microhs.name}-wrapped"
{
inherit (microhs) passthru;
}
''
mkdir -p $out/bin
cp -rs ${microhs}/bin/* $out/bin/
rm $out/bin/mhs 2>/dev/null || true
cp ${wrapper} $out/bin/mhs
''
@@ -0,0 +1,78 @@
{ pkgs, haskellLib }:
with haskellLib;
self: super: {
# Disable MicroHs core libraries
base = null;
bytestring = null;
deepseq = null;
directory = null;
process = null;
text = null;
MicroHs = null;
# External MicroHs core libraries
ghc-compat = doDistribute (markUnbroken super.ghc-compat);
# Bootstrap MicroCabal
MicroCabal = self.mkDerivation {
pname = "MicroCabal";
version = self.ghc.microcabal-stage1.version;
src = self.ghc.microcabal-stage1.src;
isLibrary = false;
isExecutable = true;
executableHaskellDepends = with self; [ base ];
inherit (self.ghc.microcabal-stage1.meta)
description
homepage
license
mainProgram
maintainers
;
};
# hackage-packages does not include GHC core libraries
binary = markBroken self.binary_0_8_9_3;
Cabal = doDistribute self.Cabal_3_16_1_0;
Cabal-syntax = doDistribute self.Cabal-syntax_3_16_1_0;
containers = doDistribute self.containers_0_8;
exceptions = doDistribute self.exceptions_0_10_12;
filepath = doDistribute self.filepath_1_5_5_0;
ghc-bignum = null;
ghc-boot = null;
ghc-boot-th = null;
ghc-compact = null;
ghc-heap = null;
ghc-internal = null;
ghc-platform = null;
ghc-prim = null;
ghci = null;
haskeline = doDistribute self.haskeline_0_8_4_1;
hpc = markBroken self.hpc_0_7_0_2;
integer-gmp = markBroken self.integer-gmp_1_1;
libiserv = null;
mtl = doDistribute self.mtl_2_3_2;
os-string = doDistribute self.os-string_2_0_10;
parsec = doDistribute self.parsec_3_1_18_0;
pretty = markBroken self.pretty_1_1_3_6;
rts = null;
semaphore-compat = null;
stm = null;
system-cxx-std-lib = null;
template-haskell = null;
terminfo = doDistribute self.terminfo_0_4_1_7;
time = doDistribute self.time_1_15;
transformers = doDistribute self.transformers_0_6_3_0;
unix = markBroken self.unix_2_8_8_0;
xhtml = markBroken self.xhtml_3000_4_0_0;
# MicroHs replacements for widely used libraries
array = self.array-mhs;
array-mhs = doDistribute (markUnbroken super.array-mhs);
random = self.random-mhs;
random-mhs = doDistribute (markUnbroken super.random-mhs);
# Depends on time when not using GHC
splitmix = addBuildDepends [ self.time ] super.splitmix;
}
@@ -48,50 +48,64 @@ let
inherit (lib) fix' extends makeOverridable;
inherit (haskellLib) overrideCabal;
mkDerivationImpl = pkgs.callPackage ./generic-builder.nix {
inherit stdenv haskellLib;
nodejs = buildPackages.nodejs-slim;
inherit (self)
buildHaskellPackages
ghc
ghcWithHoogle
ghcWithPackages
;
iserv-proxy = {
build = buildHaskellPackages.iserv-proxy;
host = self.iserv-proxy;
};
inherit (self.buildHaskellPackages) jailbreak-cabal;
hscolour = overrideCabal (drv: {
isLibrary = false;
doHaddock = false;
hyperlinkSource = false; # Avoid depending on hscolour for this build.
postFixup = "rm -rf $out/lib $out/share $out/nix-support";
}) self.buildHaskellPackages.hscolour;
cpphs =
overrideCabal
(drv: {
isLibrary = false;
postFixup = "rm -rf $out/lib $out/share $out/nix-support";
})
(
self.cpphs.overrideScope (
self: super: {
mkDerivation =
drv:
super.mkDerivation (
drv
// {
enableSharedExecutables = false;
enableSharedLibraries = false;
doHaddock = false;
useCpphs = false;
}
);
}
)
);
};
builder = if !(ghc.isMhs or false) then ./generic-builder.nix else ./microhs-builder.nix;
mkDerivationImpl = pkgs.callPackage builder (
{
inherit stdenv;
inherit (self)
buildHaskellPackages
ghc
;
inherit (self.buildHaskellPackages) jailbreak-cabal;
}
// lib.optionalAttrs (!(ghc.isMhs or false)) {
inherit haskellLib;
inherit (self)
ghcWithHoogle
ghcWithPackages
;
nodejs = buildPackages.nodejs-slim;
iserv-proxy = {
build = buildHaskellPackages.iserv-proxy;
host = self.iserv-proxy;
};
hscolour = overrideCabal (drv: {
isLibrary = false;
doHaddock = false;
hyperlinkSource = false; # Avoid depending on hscolour for this build.
postFixup = "rm -rf $out/lib $out/share $out/nix-support";
}) self.buildHaskellPackages.hscolour;
cpphs =
overrideCabal
(drv: {
isLibrary = false;
postFixup = "rm -rf $out/lib $out/share $out/nix-support";
})
(
self.cpphs.overrideScope (
self: super: {
mkDerivation =
drv:
super.mkDerivation (
drv
// {
enableSharedExecutables = false;
enableSharedLibraries = false;
doHaddock = false;
useCpphs = false;
}
);
}
)
);
}
// lib.optionalAttrs (ghc.isMhs or false) {
inherit (self) wrapMhs ghc-compat;
MicroCabal = self.ghc.microcabal-stage1;
cpphs = self.ghc.cpphs;
}
);
mkDerivation = makeOverridable mkDerivationImpl;
@@ -663,6 +677,8 @@ package-set { inherit pkgs lib callPackage; } self
withHoogle = self.ghcWithHoogle;
};
wrapMhs = pkgs.callPackage ../compilers/microhs/wrapper.nix { };
/*
Run `cabal sdist` on a source.
@@ -0,0 +1,420 @@
{
buildHaskellPackages,
buildPackages,
fetchurl,
ghc,
jailbreak-cabal,
lib,
MicroCabal,
cpphs,
ghc-compat,
pkg-config,
runCommandCC,
stdenv,
wrapMhs,
}:
let
# make-package-set always names the compiler ghc
compiler = ghc;
isCross = stdenv.buildPlatform != stdenv.hostPlatform;
in
{
pname,
version,
revision ? null,
sha256 ? null,
src ? fetchurl {
url = "mirror://hackage/${pname}-${version}.tar.gz";
inherit sha256;
},
# Extra environment variables to set during the build.
# See: `../../../doc/languages-frameworks/haskell.section.md`
env ? { },
buildDepends ? [ ],
setupHaskellDepends ? [ ],
libraryHaskellDepends ? [ ],
executableHaskellDepends ? [ ],
buildTools ? [ ],
libraryToolDepends ? [ ],
executableToolDepends ? [ ],
testToolDepends ? [ ],
benchmarkToolDepends ? [ ],
configureFlags ? [ ],
description ? null,
doCheck ? !isCross,
doBenchmark ? false,
editedCabalFile ? null,
extraLibraries ? [ ],
librarySystemDepends ? [ ],
executableSystemDepends ? [ ],
# On macOS, statically linking against system frameworks is not supported;
# see https://developer.apple.com/library/content/qa/qa1118/_index.html
# They must be propagated to the environment of any executable linking with the library
libraryFrameworkDepends ? [ ],
executableFrameworkDepends ? [ ],
homepage ? "https://hackage.haskell.org/package/${pname}",
platforms ? with lib.platforms; all, # GHC can cross-compile
badPlatforms ? lib.platforms.none,
hydraPlatforms ? null,
isExecutable ? false,
isLibrary ? !isExecutable,
jailbreak ? false,
license,
maintainers ? null,
teams ? null,
changelog ? null,
mainProgram ? null,
passthru ? { },
pkg-configDepends ? [ ],
libraryPkgconfigDepends ? [ ],
executablePkgconfigDepends ? [ ],
testPkgconfigDepends ? [ ],
benchmarkPkgconfigDepends ? [ ],
testDepends ? [ ],
testHaskellDepends ? [ ],
testSystemDepends ? [ ],
testFrameworkDepends ? [ ],
benchmarkDepends ? [ ],
benchmarkHaskellDepends ? [ ],
benchmarkSystemDepends ? [ ],
benchmarkFrameworkDepends ? [ ],
broken ? false,
preCompileBuildDriver ? null,
postCompileBuildDriver ? null,
preUnpack ? null,
postUnpack ? null,
patches ? null,
patchPhase ? null,
prePatch ? "",
postPatch ? "",
preConfigure ? null,
postConfigure ? null,
preBuild ? null,
postBuild ? null,
preHaddock ? null,
postHaddock ? null,
installPhase ? null,
preInstall ? null,
postInstall ? null,
checkPhase ? null,
preCheck ? null,
postCheck ? null,
preFixup ? null,
postFixup ? null,
shellHook ? "",
...
}@args:
assert editedCabalFile != null -> revision != null;
let
allPkgconfigDepends =
pkg-configDepends
++ libraryPkgconfigDepends
++ executablePkgconfigDepends
++ lib.optionals doCheck testPkgconfigDepends
++ lib.optionals doBenchmark benchmarkPkgconfigDepends;
# MicroCabal adds a dependency on ghc-compat unless the package name is one of the following
isCorePkg = pname == "base" || pname == "ghc-compat" || pname == "MicroHs" || pname == "MicroCabal";
buildDepends' = buildDepends ++ lib.optional (!isCorePkg) ghc-compat;
depsBuildBuild = lib.optionals (!stdenv.hasCC) [ buildPackages.stdenv.cc ];
collectedToolDepends =
buildTools
++ libraryToolDepends
++ executableToolDepends
++ lib.optionals doCheck testToolDepends
++ lib.optionals doBenchmark benchmarkToolDepends;
nativeBuildInputs = [
MicroCabal
cpphs
compilerWithPkgs
buildPackages.removeReferencesTo
];
propagatedBuildInputs =
buildDepends' ++ libraryHaskellDepends ++ executableHaskellDepends ++ libraryFrameworkDepends;
otherBuildInputsHaskell =
lib.optionals doCheck (testDepends ++ testHaskellDepends)
++ lib.optionals doBenchmark (benchmarkDepends ++ benchmarkHaskellDepends);
otherBuildInputsSystem =
extraLibraries
++ librarySystemDepends
++ executableSystemDepends
++ executableFrameworkDepends
++ allPkgconfigDepends
++ lib.optionals doCheck (testSystemDepends ++ testFrameworkDepends)
++ lib.optionals doBenchmark (benchmarkSystemDepends ++ benchmarkFrameworkDepends);
otherBuildInputs = otherBuildInputsHaskell ++ otherBuildInputsSystem;
newCabalFileUrl = "mirror://hackage/${pname}-${version}/revision/${revision}.cabal";
newCabalFile = fetchurl {
url = newCabalFileUrl;
sha256 = editedCabalFile;
name = "${pname}-${version}-r${revision}.cabal";
};
hsLibBuildInputs = lib.filter (p: p ? isHaskellLibrary && p.isHaskellLibrary) propagatedBuildInputs;
compilerWithPkgs = wrapMhs {
microhs = compiler;
packages = hsLibBuildInputs;
};
compilerCommand' = "mhs";
compilerCommand = "${compiler.targetPrefix}${compilerCommand'}";
compilerLibdir = "lib/mcabal/${compiler.haskellCompilerName}";
env' = {
CABALDIR = "${placeholder "out"}/lib/mcabal";
}
// env;
in
stdenv.mkDerivation {
inherit pname version;
pos = builtins.unsafeGetAttrPos "pname" args;
prePhases = [ "setupCompilerEnvironmentPhase" ];
preConfigurePhases = [ "compileBuildDriverPhase" ];
preInstallPhases = [ "haddockPhase" ];
inherit src patches;
inherit depsBuildBuild nativeBuildInputs;
buildInputs = lib.optionals (!isLibrary) propagatedBuildInputs;
propagatedBuildInputs = lib.optionals isLibrary propagatedBuildInputs;
env = env';
prePatch =
lib.optionalString (editedCabalFile != null) ''
echo "Replace Cabal file with edited version from ${newCabalFileUrl}."
cp ${newCabalFile} ${pname}.cabal
''
+ prePatch;
postPatch =
lib.optionalString jailbreak ''
echo "Run jailbreak-cabal to lift version restrictions on build inputs."
${jailbreak-cabal}/bin/jailbreak-cabal ${pname}.cabal
''
+ postPatch;
setupCompilerEnvironmentPhase = ''
runHook preSetupCompilerEnvironment
echo "Building with ${compilerWithPkgs}"
mkdir -p "$CABALDIR/${compiler.haskellCompilerName}/packages"
${lib.concatMapStrings (p: ''
ln -s ${p}/${compilerLibdir}/packages/${p.name}.pkg $CABALDIR/${compiler.haskellCompilerName}/packages/${p.name}.pkg
'') (lib.closePropagation hsLibBuildInputs)}
runHook postSetupCompilerEnvironment
'';
compileBuildDriverPhase = ''
runHook preCompileBuildDriver
runHook postCompileBuildDriver
'';
buildPhase = ''
runHook preBuild
echo "Skipping buildPhase because MicroCabal always builds on install"
runHook postBuild
'';
inherit doCheck;
checkPhase = ''
runHook preCheck
echo "Skipping checkPhase because MicroCabal doesn't support test suites"
runHook postCheck
'';
haddockPhase = ''
runHook preHaddock
echo "Skipping haddockPhase because MicroCabal doesn't support Haddock"
runHook postHaddock
'';
installPhase = ''
runHook preInstall
mcabal -v ${lib.concatStringsSep " " configureFlags} install
mkdir -p $out/bin
find "$CABALDIR/bin" -type f -exec ln -s '{}' "$out/bin/" \; || true
find "$CABALDIR/${compiler.haskellCompilerName}/packages" -type l -delete
runHook postInstall
'';
inherit
preCompileBuildDriver
postCompileBuildDriver
preUnpack
postUnpack
preConfigure
postConfigure
preBuild
postBuild
preHaddock
postHaddock
preInstall
postInstall
preCheck
postCheck
preFixup
postFixup
;
passthru = passthru // rec {
inherit pname version;
compiler = ghc;
# All this information is intended just for `shellFor`. It should be
# considered unstable and indeed we knew how to keep it private we would.
getCabalDeps = {
inherit
buildDepends'
buildTools
executableFrameworkDepends
executableHaskellDepends
executablePkgconfigDepends
executableSystemDepends
executableToolDepends
extraLibraries
libraryFrameworkDepends
libraryHaskellDepends
libraryPkgconfigDepends
librarySystemDepends
libraryToolDepends
pkg-configDepends
setupHaskellDepends
;
}
// lib.optionalAttrs doCheck {
inherit
testDepends
testFrameworkDepends
testHaskellDepends
testPkgconfigDepends
testSystemDepends
testToolDepends
;
}
// lib.optionalAttrs doBenchmark {
inherit
benchmarkDepends
benchmarkFrameworkDepends
benchmarkHaskellDepends
benchmarkPkgconfigDepends
benchmarkSystemDepends
benchmarkToolDepends
;
};
# Attributes for the old definition of `shellFor`. Should be removed but
# this predates the warning at the top of `getCabalDeps`.
getBuildInputs = rec {
inherit propagatedBuildInputs otherBuildInputs allPkgconfigDepends;
haskellBuildInputs = isHaskellPartition.right;
systemBuildInputs = isHaskellPartition.wrong;
isHaskellPartition = lib.partition (x: x ? isHaskellLibrary) (
propagatedBuildInputs ++ otherBuildInputs ++ depsBuildBuild ++ nativeBuildInputs
);
};
isHaskellLibrary = isLibrary;
haddockDir = null;
# Creates a derivation containing all of the necessary dependencies for building the
# parent derivation. The attribute set that it takes as input can be viewed as:
#
# { withHoogle }
#
# The derivation that it builds contains no outpaths because it is meant for use
# as an environment
#
# # Example use
# # Creates a shell with all of the dependencies required to build the "hello" package,
# # and with python:
#
# > nix-shell -E 'with (import <nixpkgs> {}); \
# > haskellPackages.hello.envFunc { buildInputs = [ python ]; }'
envFunc =
{
# Unsupported
withHoogle ? false,
}:
let
name = "microhs-shell-for-${pname}";
compilerCommandCaps = lib.toUpper compilerCommand';
in
runCommandCC name {
inherit shellHook;
nativeBuildInputs = [
compilerWithPkgs
]
++ lib.optional (allPkgconfigDepends != [ ]) pkg-config
++ collectedToolDepends;
buildInputs = otherBuildInputsSystem;
env = {
"NIX_${compilerCommandCaps}" = "${compiler}/bin/${compilerCommand}";
# TODO: is this still valid?
"NIX_${compilerCommandCaps}_LIBDIR" = "${compiler}/${compilerLibdir}";
}
// lib.optionalAttrs (stdenv.buildPlatform.libc == "glibc") {
# TODO: Why is this written in terms of `buildPackages`, unlike
# the outer `env`?
#
# According to @sternenseemann [1]:
#
# > The condition is based on `buildPlatform`, so it needs to
# > match. `LOCALE_ARCHIVE` is set to accompany `LANG` which
# > concerns things we execute on the build platform like
# > `haddock`.
# >
# > Arguably the outer non `buildPackages` one is incorrect and
# > probably works by accident in most cases since the locale
# > archive is not platform specific (the trouble is that it
# > may sometimes be impossible to cross-compile). At least
# > that would be my assumption.
#
# [1]: https://github.com/NixOS/nixpkgs/pull/424368#discussion_r2202683378
LOCALE_ARCHIVE = "${buildPackages.glibcLocales}/lib/locale/locale-archive";
}
// env';
} "echo $nativeBuildInputs $buildInputs > $out";
env = envFunc { };
};
meta = {
inherit homepage license platforms;
}
// lib.optionalAttrs (args ? broken) { inherit broken; }
// lib.optionalAttrs (args ? description) { inherit description; }
// lib.optionalAttrs (args ? maintainers) { inherit maintainers; }
// lib.optionalAttrs (args ? teams) { inherit teams; }
// lib.optionalAttrs (args ? hydraPlatforms) { inherit hydraPlatforms; }
// lib.optionalAttrs (args ? badPlatforms) { inherit badPlatforms; }
// lib.optionalAttrs (args ? changelog) { inherit changelog; }
// lib.optionalAttrs (args ? mainProgram) { inherit mainProgram; };
}
@@ -836,24 +836,6 @@ in
];
};
lze = prev.lze.overrideAttrs {
doCheck = lua.luaversion == "5.1";
nativeCheckInputs = [
final.nlua
final.bustedCheckHook
writableTmpDirAsHomeHook
];
};
lzextras = prev.lzextras.overrideAttrs {
doCheck = lua.luaversion == "5.1";
nativeCheckInputs = [
final.nlua
lua.pkgs.bustedCheckHook
final.lze
];
};
magick = prev.magick.overrideAttrs (old: {
buildInputs = old.buildInputs ++ [
imagemagick
@@ -8,23 +8,21 @@
yarl,
}:
buildPythonPackage rec {
buildPythonPackage (finalAttrs: {
pname = "aiotractive";
version = "1.0.1";
version = "1.0.2";
pyproject = true;
src = fetchFromGitHub {
owner = "zhulik";
repo = "aiotractive";
tag = "v${version}";
hash = "sha256-DP0dFDXaa0PyaERmhL6dNCOpiNs+N7ojMIapcajfMrk=";
tag = "v${finalAttrs.version}";
hash = "sha256-Tr8USF7GF9CMOcjy62e+oTu4k/1jIAOsZmWTFWEzJvk=";
};
build-system = [ setuptools ];
pythonRelaxDeps = [
"orjson"
];
pythonRelaxDeps = [ "orjson" ];
dependencies = [
aiohttp
@@ -40,8 +38,8 @@ buildPythonPackage rec {
meta = {
description = "Python client for the Tractive REST API";
homepage = "https://github.com/zhulik/aiotractive";
changelog = "https://github.com/zhulik/aiotractive/releases/tag/${src.tag}";
changelog = "https://github.com/zhulik/aiotractive/releases/tag/${finalAttrs.src.tag}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ fab ];
};
}
})
@@ -22,14 +22,14 @@
buildPythonPackage (finalAttrs: {
pname = "cyclopts";
version = "4.10.1";
version = "4.10.2";
pyproject = true;
src = fetchFromGitHub {
owner = "BrianPugh";
repo = "cyclopts";
tag = "v${finalAttrs.version}";
hash = "sha256-LgpnpE1Hyx4o2Pi9zXmPLlV7K2wTX5PiNlYD+7333dQ=";
hash = "sha256-vlsjhBfI08QMQ8FzM+BogAXbukHhnr4aD8ZmZVicCv0=";
};
build-system = [

Some files were not shown because too many files have changed in this diff Show More