Add bootcommand mappings for left/right command and option keys#293
Conversation
|
I see there's a copy of the docs in |
f896caa to
c4c5259
Compare
|
@anshulsharma-hashicorp, @anurag5sh, @JenGoldstrich, would one of you have time to review this PR, or suggest someone else who could? I'd love to get this one merged in. It would make working with macOS VMs nicer. |
|
@anshulsharma-hashicorp, @anurag5sh, @JenGoldstrich is there any feedback on this PR? How do we proceed? Thanks 😊 |
|
@anshulsharma-hashicorp, @anurag5sh, @JenGoldstrich Can you please comment on this PR? Thanks |
c4c5259 to
81531cc
Compare
Awaiting the merge of the feature in the upstream Packer SDK repo, let's override the plugin SDK with a branch that has the feature. See hashicorp/packer-plugin-sdk#293
Awaiting the merge of the feature in the upstream Packer SDK repo. See hashicorp/packer-plugin-sdk#293
Awaiting the merge of the feature in the upstream Packer SDK repo. See hashicorp/packer-plugin-sdk#293
Awaiting the merge of the feature in the upstream Packer SDK repo. See hashicorp/packer-plugin-sdk#293
|
@tanmay-hc Is Packer maintained still? |
Awaiting the merge of the feature in the upstream Packer SDK repo. See hashicorp/packer-plugin-sdk#293
|
@devashish-patel @taru-garg-hashicorp @kp2099 Would appreciate a review of this PR, thanks! |
There was a problem hiding this comment.
Pull request overview
This PR expands the boot command special-key vocabulary so macOS automation can refer to Command/Option by their natural names, including left/right variants, across the boot command parser and relevant drivers.
Changes:
- Added
<leftCommand>/<rightCommand>and<leftOption>/<rightOption>to the boot command grammar and regenerated the parser. - Added corresponding key mappings for the VNC and USB bootcommand drivers.
- Updated boot command documentation to mention the new special keys.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
bootcommand/vnc_driver.go |
Adds VNC keysym mappings for left/right Command and Option. |
bootcommand/usb_driver.go |
Adds USB scancode mappings for left/right Command and Option. |
bootcommand/config.go |
Documents the new special keys. |
bootcommand/boot_command.pigeon |
Extends the grammar to recognize the new special keys. |
bootcommand/boot_command.go |
Regenerated parser output reflecting the grammar changes. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Hey @torarnv |
The super key maps to ⌘ for the USB driver, but for the VNC driver ⌘ is produced by left/right Alt, so we can't promise that leftSuper/rightSuper produces ⌘.
81531cc to
1d2cee7
Compare
|
@tanmay-hc Thanks, updated PR per review suggestions :) |
When automating macOS systems it's convenient to refer to the keys by their natural names, and for the VNC driver none of the existing special keys mapped to option, so this enables boot commands using the option key.
1d2cee7 to
5787050
Compare
|
Update generated files to fix test. |
tanmay-hc
left a comment
There was a problem hiding this comment.
Thanks for the changes. Looks good to me.
When automating macOS systems it's convenient to refer to the keys by their natural names, and for the VNC driver none of the existing special keys mapped to option, so this enables boot commands using the option key.