From b5f1d4cce990ca2bce52af9757235f60edbddc5a Mon Sep 17 00:00:00 2001 From: Robert Hensing Date: Sun, 21 Apr 2024 13:52:56 +0200 Subject: [PATCH] Edit docs --- doc/manual/src/contributing/hacking.md | 8 ++++---- flake.nix | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/doc/manual/src/contributing/hacking.md b/doc/manual/src/contributing/hacking.md index 61c513a15..08ba84faa 100644 --- a/doc/manual/src/contributing/hacking.md +++ b/doc/manual/src/contributing/hacking.md @@ -273,7 +273,7 @@ Configure your editor to use the `clangd` from the `.#native-clangStdenvPackages > Some other editors (e.g. Emacs, Vim) need a plugin to support LSP servers in general (e.g. [lsp-mode](https://github.com/emacs-lsp/lsp-mode) for Emacs and [vim-lsp](https://github.com/prabirshrestha/vim-lsp) for vim). > Editor-specific setup is typically opinionated, so we will not cover it here in more detail. -## Formatting and pre-commit +## Formatting and pre-commit hooks You may run the formatters as a one-off using: @@ -292,9 +292,9 @@ This installs [pre-commit](https://pre-commit.com) using [cachix/git-hooks.nix]( When making a commit, pay attention to the console output. If it fails, run `git add --patch` to approve the suggestions _and commit again_. -To refresh the config, do the following: -- if you use `make format`: stop and start your `nix develop` shell. -- if you use the pre-commit hook: stop and start, and run `pre-commit-hooks-install` again. +To refresh pre-commit hook's config file, do the following: +1. Exit the development shell and start it again by running `nix develop`. +2. If you also use the pre-commit hook, also run `pre-commit-hooks-install` again. ## Add a release note diff --git a/flake.nix b/flake.nix index d9b0c63b5..2795172bb 100644 --- a/flake.nix +++ b/flake.nix @@ -209,7 +209,8 @@ inherit fileset stdenv; }; - # https://github.com/NixOS/nixpkgs/pull/214409 + # See https://github.com/NixOS/nixpkgs/pull/214409 + # Remove when fixed in this flake's nixpkgs pre-commit = if prev.stdenv.hostPlatform.system == "i686-linux" then (prev.pre-commit.override (o: { dotnet-sdk = ""; })).overridePythonAttrs (o: { doCheck = false; })