Giter Site home page Giter Site logo

Comments (3)

dmd avatar dmd commented on May 26, 2024

I'm not sure what the correct behavior for an ambiguous prefix is. I think the correct thing would be to say, for example:

$ goto fo
goto error: ambiguous alias fo
foodata /u/ddrucker/dmdenv/data/serial/foo/main
foo /u/ddrucker/dmdenv/private_sand/foo/mp
$

rather than just guessing.

from goto.

iridakos avatar iridakos commented on May 26, 2024

Hi @dmd

goto expects the exact alias literal to be passed in order to navigate to the underlying directory.

If user executes:

goto fo

and there is an alias named fo then nothing should be displayed and user should be navigated to fo's registered directory regardless of the existence of other aliases starting with fo or not.

If there is no fo alias then the default error message for unregistered alias will be displayed.

Regarding autocompletion, executing goto fo will take user to the underlying directory. If instead of executing the command, user presses the <tab> key then the completion mechanism will display all options (including fo, foodata) which is the default completion behaviour.

I'm closing this issue but feel free to re-open it if you need more clarifications.

Thank you for reporting

from goto.

dmd avatar dmd commented on May 26, 2024

Right. That's the behavior modification I was thinking would be nice - to be able to just say "goto fo", and if and only if there was exactly one alias matching /^fo.*$/, then navigate to that alias without the need to hit tab for autocomplete.

But if you don't think that's a good idea, that's fine.

from goto.

Related Issues (20)

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.