Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: name/path transforms using custom user functions #127

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

keevan
Copy link

@keevan keevan commented Jul 9, 2023

Examples of what it might look like after:

image

Config:

lvim.builtin.project.transform_path = function(path)
	return vim.fn.fnamemodify(path, ":~")
end

lvim.builtin.project.transform_name = function(path)
	return "[client] " .. vim.fn.fnamemodify(path, ":t")
end

Ideally, "client" would match on some base known path (e.g. a base project name or client name if there are nested projects under that), and the name would point to a submodule for that project. Sometimes I need to switch from the base project CWD to the submodule, for various reasons, and it would be nice to have that clear separation, and to reduce the noise potentially shown in the path.

[client A] submodule X     ~/projects/client A/some/path/to/submodule X
[client B] submodule X     ~/projects/client B/some/path/to/submodule X

Closes #124

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Recent projects, display options for the table
1 participant