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

Feature request: Parsing option for mods --dirs #251

Closed
vlermandac opened this issue Apr 30, 2024 · 0 comments · Fixed by #280
Closed

Feature request: Parsing option for mods --dirs #251

vlermandac opened this issue Apr 30, 2024 · 0 comments · Fixed by #280
Labels
enhancement New feature or request

Comments

@vlermandac
Copy link

vlermandac commented Apr 30, 2024

Hi, ty for all your work. I love the charm projects :)

I've been using mods within scripts and alongside other programs, and it doesn't feel right for me that when I have to get the chat histories, I write the full path just because I know it through 'mods --dirs'. I think it would be useful (and elegant) to have the option to get the paths already parsed.

A solution is to accept an extra argument when using --dirs, e.g., 'mods --dirs config', 'mods --dirs cache', or to split the option in two. e.g. 'mods --config', 'mods --cache'. I know there is the --settings option, idk, I don't quite like that opens an editor by itself (it might just be me).

A workaround is just to parse it yourself like:
'cd $(mods --dirs | grep "Cache" | sed 's/Cache://')',
'nvim $(mods --dirs | grep "Configuration" | sed 's/Configuration://')'

I know this FR might be a little picky, and that there is not a correct way to make such an option, but at least I wanted to discuss it.

@vlermandac vlermandac added the enhancement New feature or request label Apr 30, 2024
@vlermandac vlermandac changed the title Parsing option for mods --dirs Feature request: Parsing option for mods --dirs Apr 30, 2024
caarlos0 added a commit that referenced this issue Jun 3, 2024
closes #251

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
caarlos0 added a commit that referenced this issue Jun 3, 2024
* feat: allow --dirs config|cache

closes #251

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

* fix: typo

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

---------

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant