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

SketchybarUpdate #44

Merged
merged 10 commits into from
Nov 27, 2024
Prev Previous commit
Next Next commit
upstream merge - need to review hyperkey config
  • Loading branch information
edheltzel committed Nov 27, 2024
commit cababe3fd548e64276be0148f9fec0e38a381e80
60 changes: 40 additions & 20 deletions config/.config/karabiner2/rules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,54 @@ import { createHyperSubLayers, app, open, rectangle, shell } from "./utils";
const rules: KarabinerRules[] = [
// Define the Hyper key itself
{
description: "Hyper Navigation",
description: "Hyper Key (⌃⌥⇧⌘)",
manipulators: [
{
description: "h = left",
description: "Caps Lock -> Hyper Key",
from: {
key_code: "h",
key_code: "caps_lock",
modifiers: {
"mandatory": ["right_command", "right_control", "right_shift", "right_option"],
optional: ["any"],
},
},
to: [{ key_code: "left_arrow" }],
to: [
{
set_variable: {
name: "hyper",
value: 1,
},
},
],
to_after_key_up: [
{
set_variable: {
name: "hyper",
value: 0,
},
},
],
to_if_alone: [
{
key_code: "escape",
},
],
type: "basic",
},
// {
// type: "basic",
// description: "Disable CMD + Tab to force Hyper Key usage",
// from: {
// key_code: "tab",
// modifiers: {
// mandatory: ["left_command"],
// },
// },
// to: [
// {
// key_code: "tab",
// },
// ],
// },
],
},
...createHyperSubLayers({
Expand Down Expand Up @@ -65,21 +100,6 @@ const rules: KarabinerRules[] = [
),
},

// TODO: This doesn't quite work yet.
// l = "Layouts" via Raycast's custom window management
// l: {
// // Coding layout
// c: shell`
// open -a "Visual Studio Code.app"
// sleep 0.2
// open -g "raycast://customWindowManagementCommand?position=topLeft&relativeWidth=0.5"

// open -a "Terminal.app"
// sleep 0.2
// open -g "raycast://customWindowManagementCommand?position=topRight&relativeWidth=0.5"
// `,
// },

// w = "Window" via rectangle.app
w: {
semicolon: {
Expand Down