Giter Club home page Giter Club logo

Comments (6)

princejoogie avatar princejoogie commented on September 23, 2024 1

currently working on making this async and be able to cancel to not freeze neovim while performing scan_dir. related to #2.

from dir-telescope.nvim.

princejoogie avatar princejoogie commented on September 23, 2024

@dlvhdr i did a few benchmarks with the new method in this PR: #4
mind if you could checkout to that branch and test it? thanks

782 files time (s) blocking?
new method 0.032537 false
old method 0.563939 true
1268 files time (s) blocking?
new method 0.032654 false
old method 0.591894 true
373769 files time (s) blocking?
new method 0.226896 false
old method 9.076255 true

for context: i swapped plenary.scandir with fd or find or a custom search command by the user. i also used vim.fn.jobstart to make it non-blocking

from dir-telescope.nvim.

princejoogie avatar princejoogie commented on September 23, 2024

its currently in dev branch

use({
  "princejoogie/dir-telescope.nvim",
  requires = { "nvim-telescope/telescope.nvim" },
  branch = "dev",
  config = function()
    require("dir-telescope").setup({
      debug = true,
    })
  end,
})

:GrepInDirectory or :FileInDirectory for the new method
:GrepInDirectorySlow or :FileInDirectorySlow for the old method

:messages will contain the output of benchmark for each command (if debug is true in setup)

from dir-telescope.nvim.

dlvhdr avatar dlvhdr commented on September 23, 2024

Yeah checking it!

from dir-telescope.nvim.

dlvhdr avatar dlvhdr commented on September 23, 2024

Hmm it's still quite slow but I noticed it searches my node_modules which is in my .gitignore.
Sometimes it shows entries under .git, but I can't get it to be consistent.
I'm using the telescope extension.

If I run the command directly, it opens in telescope still, reports it takes:

get_dirs took 0.24017 seconds
get_dirs took 0.22629 seconds

But it feels a lot slower. Something like 1 second.

from dir-telescope.nvim.

princejoogie avatar princejoogie commented on September 23, 2024

hmm, seems consistent in my tests. may i know what OS you're using? and for sanity sakes, double check you're on dev branch for the plugin and ran :PackerSync

from dir-telescope.nvim.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.