This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch master
in repository efm2.

View the commit online.

commit 98c3e435207a3056c7d45b426021d55944154dbd
Author: Carsten Haitzler (Rasterman) <[email protected]>
AuthorDate: Wed May 13 18:21:51 2026 +0100

    front end backend - tell backend if we look at all files or not
    
    pretty big optimization to avoid looking at dot files in the backend
    when the front end filters out anyway. allows a lot of i/o to be
    skipped. great for slow fs's
---
 src/backends/default/open.c | 15 +++++++++++++++
 src/backends/table/open     |  6 +++++-
 src/efm/efm.c               |  3 +++
 3 files changed, 23 insertions(+), 1 deletion(-)

diff --git a/src/backends/default/open.c b/src/backends/default/open.c
index 51fe229..a2c5be9 100644
--- a/src/backends/default/open.c
+++ b/src/backends/default/open.c
@@ -64,6 +64,7 @@ static Eina_List          *sub_queue  = NULL;
 static int                 child_exes = 0;
 static Eina_Bool           auto_exit  = EINA_FALSE;
 static Eina_Bool           can_write  = EINA_FALSE;
+static Eina_Bool           files_all = EINA_FALSE;
 // static Eina_List          *op_queue   = NULL;
 
 static Sub       *_sub_open(const char *path, const char *backend);
@@ -1175,7 +1176,9 @@ static void
 _file_add(const char *path)
 {
   Eina_Strbuf *strbuf;
+  const char  *file = ecore_file_file_get(path);
 
+  if ((file) && (file[0] == '.') && (!files_all)) return;
   strbuf = cmd_strbuf_new("file-add");
   cmd_strbuf_append(strbuf, "path", path);
   meta_path_sync(path);
@@ -1209,7 +1212,9 @@ static void
 _file_del(const char *path)
 {
   Eina_Strbuf *strbuf;
+  const char  *file = ecore_file_file_get(path);
 
+  if ((file) && (file[0] == '.') && (!files_all)) return;
   strbuf = cmd_strbuf_new("file-del");
   cmd_strbuf_append(strbuf, "path", path);
   cmd_strbuf_print_consume(strbuf);
@@ -1219,7 +1224,9 @@ static void
 _file_mod(const char *path)
 {
   Eina_Strbuf *strbuf;
+  const char  *file = ecore_file_file_get(path);
 
+  if ((file) && (file[0] == '.') && (!files_all)) return;
   strbuf = cmd_strbuf_new("file-mod");
   cmd_strbuf_append(strbuf, "path", path);
   if (!_file_add_mod_info(strbuf, path, EINA_TRUE)) eina_strbuf_free(strbuf);
@@ -1522,6 +1529,14 @@ do_handle_cmd(Cmd *c)
       }
       KEY_WALK_END
     }
+  else if (!strcmp(c->command, "dir-files-all"))
+    {
+      files_all = EINA_TRUE;
+    }
+  else if (!strcmp(c->command, "dir-files-normal"))
+    {
+      files_all = EINA_FALSE;
+    }
   else if (!strcmp(c->command, "file-run"))
     {
       const char *open_with_desktop = cmd_key_find(c, "open-with");
diff --git a/src/backends/table/open b/src/backends/table/open
index 5f12ac0..03a3881 100755
--- a/src/backends/table/open
+++ b/src/backends/table/open
@@ -228,7 +228,11 @@ function handle_cmd() {
         fi
       fi
       ;;
-    # commands this fs doesn;'t handle (yet?)
+    # commands this fs doesn't handle (yet?)
+    dir-files-all )
+      ;;
+    dir-files-normal )
+      ;;
     meta-set )
       ;;
     cnp-cut )
diff --git a/src/efm/efm.c b/src/efm/efm.c
index fde35e1..e96d6c9 100644
--- a/src/efm/efm.c
+++ b/src/efm/efm.c
@@ -1210,6 +1210,9 @@ _reset(Smart_Data *sd)
     {
       printf("XXX: OPEN [ %s ]\n", sd->config.path);
       _listing_do(sd);
+      if (sd->config.all_files) buf = cmd_strbuf_new("dir-files-all");
+      else buf = cmd_strbuf_new("dir-files-normal");
+      cmd_strbuf_exe_consume(buf, sd->exe_open);
       buf = cmd_strbuf_new("dir-set");
       cmd_strbuf_append(buf, "path", sd->config.path);
       cmd_strbuf_exe_consume(buf, sd->exe_open);

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to