Skip to content

Allow creating project based on file location of buffer opened in #151

@hardenedapple

Description

@hardenedapple

My use case is that I sometimes open up a few files in some other project to make a small change or view what's going on, then after a while decide I want to create a project for the repo that file is in.
AFAICS there is no way to request "create a project based on current buffer directory".

I could use :lcd %:h before opening telescope-project, but would appreciate the more streamlined approach.
That said, I recognise that creating a project is not the most common operation.

N.b. an alternative that would also work for me would be to be able to start telescope-project in a specified directory.
E.g. for the find_files picker I can map to builtin.find_files({ cwd = vim.fn.expand('%:p:h') }) in order to open up telescope searching from the directory of the current buffer.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions