From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jethro Kuan Newsgroups: gmane.emacs.devel Subject: Upstreaming filenotify-recursive Date: Sat, 21 Aug 2021 15:18:07 +0800 Message-ID: <871r6n8dw0.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28251"; mail-complaints-to="usenet@ciao.gmane.io" To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Aug 21 16:07:20 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mHRea-0007A9-MR for ged-emacs-devel@m.gmane-mx.org; Sat, 21 Aug 2021 16:07:20 +0200 Original-Received: from localhost ([::1]:60344 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mHReZ-0003rb-GB for ged-emacs-devel@m.gmane-mx.org; Sat, 21 Aug 2021 10:07:19 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34404) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mHLH0-0005Tl-HP for emacs-devel@gnu.org; Sat, 21 Aug 2021 03:18:34 -0400 Original-Received: from mail-pf1-x42e.google.com ([2607:f8b0:4864:20::42e]:36797) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mHLGs-0001LQ-VS for emacs-devel@gnu.org; Sat, 21 Aug 2021 03:18:34 -0400 Original-Received: by mail-pf1-x42e.google.com with SMTP id m26so10612015pff.3 for ; Sat, 21 Aug 2021 00:18:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:mime-version; bh=TTXPF/ZKPs9D+ba8i36c4WSM2KltVYUpqnHheAbH87Q=; b=G64rVpHPguH1OnUaub8k2Scv6n7v6EPlQ4kiiXEDFo7r+OJkOEifbfQUjjckCmKwJV uHXyRK44lT27K4LA+ZLgDgTuNBcjxqhoHiOzE2fIvoMOge6JC+GTD1TtY8RBwhUVIyGQ yJ8eC0O9BKAWk3iFP6HylqFxATC/98CXPlDeR4T4p5Qsr3v6mUSv/l0A9oMcRxt+3rZQ jchnfzpwFAVDIctxMQfcdRmehLYz7ZBH0tcnhNC/PnB2SI7PiCS6FVCjwXdRAo5VPSAo 2EPwjAWtHA1kbY3KX5mksNs9MxdA/QoSPwQd9qAw/pRLYBkYSQDJWmVOkF51f5WjS971 9lpA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=TTXPF/ZKPs9D+ba8i36c4WSM2KltVYUpqnHheAbH87Q=; b=H/AnjSSAG66FV/jD52CmCq+NCQQoYka7aHwfkfjuxNca5ifuY+ijdWtYa3MtIOUni7 ON7Mmb/CDDZ4CAGodqlFr9iFypADuzIy6+yPX9dKhQbYDAh4IvFMzxIbFYBJA8VcKY0D UkW8JVZmjjwQjBeHnJ1kYQDsi5qJnBD+7actgB3dRT/sz8WFaiDaCPk/W/UDKYNu1mnK udDaSPjvYbEVK4wpQXAA+lQOYVO5u6jmbhDdf5mHOXHsiCfVhLFeZvR52Cb6eXoh/Gmf 9shkfNplG5Oj9HIAtP9NbzzjEVTj0pqkoX4j+Wm9ZzbEuDrFKCOOPQkMt9741D3ATaQv UBJA== X-Gm-Message-State: AOAM530Xyw6p/mbC7lCq8widfuD7+03Z93qcpRikIsTGm1GUMN33KXhA EZVdbVSRw/GKxbudq8hC1ydzryNdJzQeyvtA X-Google-Smtp-Source: ABdhPJzh35rlfwfWHW9vb5IMsUki8jFwj2SmLYq5+nQSB/TRSsbRijC7erC9assH4+XJVIdszK9iPQ== X-Received: by 2002:a62:ae11:0:b029:3e0:71dc:70fa with SMTP id q17-20020a62ae110000b02903e071dc70famr23587320pff.50.1629530304325; Sat, 21 Aug 2021 00:18:24 -0700 (PDT) Original-Received: from localhost ([116.87.73.89]) by smtp.gmail.com with ESMTPSA id 138sm3305524pfz.187.2021.08.21.00.18.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Aug 2021 00:18:23 -0700 (PDT) Received-SPF: pass client-ip=2607:f8b0:4864:20::42e; envelope-from=jethrokuan95@gmail.com; helo=mail-pf1-x42e.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Sat, 21 Aug 2021 10:05:47 -0400 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:272786 Archived-At: Hello! I'd recently written a package that wraps filenotify somewhat transparently, providing a similar API to the built-in filenotify but it watches the directory recursively, spawning and destroying watchers as appropriately. It was suggested to me that this could be upstreamed to Emacs. The code is here: https://github.com/jethrokuan/filenotify-recursive I don't mind doing the work in getting this upstreamed, but I have a few concerns. Because of how filenotify works, filenotify-recursive uses own its global variables to keep track of the descriptors. It's best to think of a way to merge this functionality into filenotify.el itself, but I can't think of a good way right now. I'm open to any thoughts and suggestions here. Jethro