-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
Add action for opening settings directory in file explorer #17690
base: main
Are you sure you want to change the base?
Add action for opening settings directory in file explorer #17690
Conversation
directory and copy settings file path to clipboard)
Sorry for the delay! We've been understaffed this week 🙂 |
No worries, no rush on my end. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apart from the .c_str()
call the PR seems fine to me. I'll approve in advance because it'll have to wait for a 2nd approval anyway.
However, I'm not quite sure if we should introduce the 2 additional options just yet.
openFolder(CascadiaSettings::SettingsDirectory()); | ||
break; | ||
case SettingsTarget::Clipboard: | ||
copyToClipboard(CascadiaSettings::SettingsPath().c_str()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The .c_str()
is unnecessary, if not detrimental, because constructing a string-view from a nullptr is UB.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated. (Sorry, I should have thought that through)
Let me know if I should remove the other 2 actions. Fwiw, the send input one is what I have found most useful, I don't think I have ever actually used the other 2 outside of testing. But that is probably just because of my personal workflows.
_copyToClipboard when copying settings file path to clipboard
Most of the logic is taken from the original PR (#15417) and adapted to work with the palette.
I added 2 additional actions, send settings file path as input and copy settings file path to clipboard. (Totally understand if these should be removed)
Summary of the Pull Request
References and Relevant Issues
#12382
Detailed Description of the Pull Request / Additional comments
Validation Steps Performed
PR Checklist