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

Hiding certain custom commands #1754

Open
mike-potter opened this issue Feb 6, 2023 · 3 comments
Open

Hiding certain custom commands #1754

mike-potter opened this issue Feb 6, 2023 · 3 comments

Comments

@mike-potter
Copy link

When adding custom commands to Docksal, we have some common "helper" functions we want to share between commands. For various reasons (the way we package projects) we'd like those helper functions defined in a script file in the same folder as the commands that use them.

Thus, we end up with a .helper script in the .docksa/commands folder, and this shows up in the fin help output as another custom command.

I'd like to request a feature where "dot files" (or some other pattern you think is better) are not shown in fin help. This would allow some custom commands to be hidden and not pollute the help listing.

@shelane
Copy link
Member

shelane commented Feb 6, 2023

I have helper functions also. I put them in the .docksal folder, but not in the commands folder and then reference them like:

source "${PROJECT_ROOT}/.docksal/includes/helpers.sh"

@mike-potter
Copy link
Author

Yep. In our case the .docksal/commands is actually symlinked to another location so we really need them in the same folder.

@mike-potter
Copy link
Author

If worried about backward compatibility with existing projects that have their commands starting with a dot for some reason, it would be fine if it just excluded subfolders that start with a dot. After all, dot files/folders are supposed to be "hidden" so seems like it would make sense to not show them as commands in the fin help.

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

No branches or pull requests

2 participants