From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id CHYLEsV1VmPJaQAAbAwnHQ (envelope-from ) for ; Mon, 24 Oct 2022 13:23:49 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 4GQIEsV1VmPhQQAA9RJhRA (envelope-from ) for ; Mon, 24 Oct 2022 13:23:49 +0200 Received: from mail.notmuchmail.org (yantan.tethera.net [135.181.149.255]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 189B8585D for ; Mon, 24 Oct 2022 13:23:49 +0200 (CEST) Received: from yantan.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 3353B5F84D; Mon, 24 Oct 2022 11:18:03 +0000 (UTC) Received: from mail-ed1-x52a.google.com (mail-ed1-x52a.google.com [IPv6:2a00:1450:4864:20::52a]) by mail.notmuchmail.org (Postfix) with ESMTPS id E32E25F3CF for ; Mon, 24 Oct 2022 09:10:01 +0000 (UTC) Received: by mail-ed1-x52a.google.com with SMTP id b12so28759640edd.6 for ; Mon, 24 Oct 2022 02:10:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-disposition:mime-version:message-id:subject:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=ZSV3Fd4o8aTu9XQcI8YOcCSG/57FFXYDR0sJbM9FXh8=; b=VBflKyXLZYCYWIPHZxpfMIAUA6coV/pBAmMR1pLCph+OaSFKoepfzXbP+ywqbgUn2P jP5jewAIsivvJjODPrVvEcwBytdykvO1I/65c+UNpLHaa7cPqxsIcfYK3kFGEPz4VNG0 a+65Qe8u8C8L5DotUVV+MOagzhPV9vSrTg30IkaC1RTxRHIucd5O+6YfhNVfOeRuKjjH NcBLU9IJAYTx1i0rpGC2qd65B0gnWEuWkZxQGU6g15TQ6nHUeNZflmj52YzX+yg7CshD Eq40+K+WvfpLT8i3iVIv3FeTIun6pNC7oXL9GGy3QQK1wpAnZog8nxRSUBY9mlIEbUd2 dY8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-disposition:mime-version:message-id:subject:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ZSV3Fd4o8aTu9XQcI8YOcCSG/57FFXYDR0sJbM9FXh8=; b=352rE+Rm6uFzO+92fcdIS9rzdg8JuR07HmFA3y7hQkGiIghG/kfGkj3bTbawvlHvfk 9uZVs0VTXJKhzEM3o4wOrUhHNIvbzpGeQrsSnOex2EsFw1lHkItREPPI0JeEfXs/hC5C nusTL/rDUnOku3bMufjPyx2hZxfC/67UBbw4AVFNaMhZKMB4PMCCLmtqlgju4ELrtrt3 vWSu1gjSAUsZM0VyDWO+WcQZkrBshw4KvrhuC30E1jSsAOoyc6oyC1+t5tevnbOzAKgf R0FTG8Hoj4peXSbF9plMlzlaI0I3XPEP80oX04QUqN8DapxvJSINRUhdmeynmhO4yxFq NExw== X-Gm-Message-State: ACrzQf32LNR2UjiICvepMnp+uIVG3EhgwSRMerOcO5PitsKJ75hVRfzX jkR33cHKCp4nmoAEgbbD6Wuj9IkGbMc= X-Google-Smtp-Source: AMsMyM49HG6+VVWjKfRNABs0AOK4xc5HfhvVq3Bd20meh0YVzKclAR5dqnLka2qsX/0pYx6L+gvEUA== X-Received: by 2002:a17:907:3181:b0:787:d81c:a6ad with SMTP id xe1-20020a170907318100b00787d81ca6admr26763905ejb.769.1666602601019; Mon, 24 Oct 2022 02:10:01 -0700 (PDT) Received: from localhost ([147.161.245.71]) by smtp.gmail.com with ESMTPSA id kx22-20020a170907775600b00738795e7d9bsm15387850ejc.2.2022.10.24.02.09.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 24 Oct 2022 02:09:59 -0700 (PDT) Date: Mon, 24 Oct 2022 11:09:57 +0200 From: Dario To: notmuch@notmuchmail.org Subject: Consider following XDG base directory specification Message-ID: <20221024090957.ekvfaob3bfmpc4ow@dario-arch3> MIME-Version: 1.0 Content-Disposition: inline X-MailFrom: piombo.dario@gmail.com X-Mailman-Rule-Hits: nonmember-moderation X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0 Message-ID-Hash: XQYIGN5L6DJ36I7NBPHVF6AWGPZ5HH5S X-Message-ID-Hash: XQYIGN5L6DJ36I7NBPHVF6AWGPZ5HH5S X-Mailman-Approved-At: Mon, 24 Oct 2022 11:18:01 +0000 X-Mailman-Version: 3.3.3 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN X-Migadu-Country: DE ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1666610629; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-owner:list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=LyCg5eIMxrRXkqmpql7YpmcjIGS8twRSgAVb3H3mAQ0=; b=LRHqY+8vrOxDi0wnfH/l8c/kbcPDB1hi0nMG9in1odOtfY1D/dA4pDBfyG/hCDCPTkbCfi VHwxEXUv7Onb5/RcT5h1BSiBRJHPPoj0asi8HjMsprttklz3/2lE8spQP0JY/sxC+v7A32 LhG3uCpjMvcCgB8g1dhLblezemZXGYO756nPoIYHfDslFh27QJMa5yW3gv0YQg7UbzHggs cvoqgTpX/bAOblAPmssKHxuU621IbE4T5SGdtGu9risYFt73Ge/SQCh/NKBjr1SrsY9aod YwWjDyVaka08IYPXQXJ4QKJr7FsiP/0FEEwdT7jsyq2RW1PsHet7lxrX8RTzLg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1666610629; a=rsa-sha256; cv=none; b=tYdRz8UuChZ5kX8Cf0CzwXtGTiOl9HjoUS9enMpuk3JNqvehjbbkET9PHyJLyMePFPdJGC 9GPu72mZPo8zceAjPRhImHFXePIVcaThOkw8KRrgOFhaljn7+hYZkLJv71hgkz+fnG/LpA ZV2849v89aM04kPeJQJLvdrU5fLMAQrTdkUDgCqc7YXEkzfuMAyIiAf1+BGDrB8NbRuhCG SNxRSjDSzrubVc2AlQodnmvMRTDVGhixuc++zf4OuDeBqkTHYLy6+RT9b6AYz6Cp4C+aKe hcRn3uxTw0GMVNTfhdaBBDnrRJ0eB7KMZYC4qfadkHdKDnu9QAFswBrsNAHIbQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20210112 header.b=VBflKyXL; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: 8.33 X-Spam: Yes Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20210112 header.b=VBflKyXL; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: 189B8585D X-Spam-Score: 8.33 X-Migadu-Spam: Yes X-Migadu-Scanner: scn1.migadu.com X-TUID: 5SrkaPCpQeO3 I apologize in advance if the issue has already been raised by somebody else but I couldn't find anything on the bug tracker and furthermore I'm one of those freaks who prefer a de-cluttered home directory. ;-) Instead of saving config file in $HOME/.notmuch-config, ${XDG_CONFIG_HOME:-$HOME/notmuch}/notmuch-config (notmuchrc is a nice name too) should be used for unix-based operating systems according to the XDG Base Directory Specification. As well as keeping the home directory clean, the semantic separation of config, runtime data, cache data and user-local software by the spec is helpful to users and other tools (e.g. backup software). In terms of migration, I would suggest using the xdg-compilant config location if it exists and falling back to the current default location. I know someone could decide to run notmuch with the --config switch in order to read from a different configuration file but I feel the XDG base directory specification is a nice default behavior.