Skip to content

Instantly share code, notes, and snippets.

@rbika
rbika / karabiner-3.json
Created July 15, 2025 01:40
Karabiner - Maps Left Ctrl + a/s/d to modifiers
{
"description": "Maps Left Ctrl + a/s/d to modifiers",
"manipulators": [
{
"from": {
"key_code": "a",
"modifiers": {
"mandatory": ["left_control"],
"optional": ["any"]
}
@rbika
rbika / karabiner-2.json
Created July 15, 2025 01:38
Karabiner - Maps Left Ctrl + h/j/k/l to arrow keys
{
"description": "Maps Left Ctrl + h/j/k/l to arrow keys",
"manipulators": [
{
"from": {
"key_code": "h",
"modifiers": {
"mandatory": ["left_control"],
"optional": ["any"]
}
@rbika
rbika / karabiner-1.json
Created July 15, 2025 01:37
Karabiner - Maps Caps Lock to Left Ctrl
{
"description": "Maps Caps Lock to Left Ctrl",
"manipulators": [
{
"from": {
"key_code": "caps_lock",
"modifiers": { "optional": ["any"] }
},
"to": [{ "key_code": "left_control" }],
"type": "basic"
@rbika
rbika / settings.json
Created May 17, 2025 20:35
VSCode settings
{
"editor.formatOnSave": true,
"files.insertFinalNewline": true,
"editor.defaultFormatter": "esbenp.prettier-vscode"
}
@rbika
rbika / eslint.config.mjs
Created May 17, 2025 20:10
ESLint config - Nextjs
import { dirname } from "path";
import { fileURLToPath } from "url";
import { FlatCompat } from "@eslint/eslintrc";
import prettier from "eslint-config-prettier";
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename)
const compat = new FlatCompat({
baseDirectory: __dirname,
@rbika
rbika / prettier.config.mjs
Last active November 5, 2025 02:17
Prettier config - frontend
/**
* @see https://prettier.io/docs/configuration
* @type {import("prettier").Config}
*/
const config = {
plugins: [
'@ianvs/prettier-plugin-sort-imports',
'prettier-plugin-tailwindcss',
],
@rbika
rbika / macos-accentuation.ahk
Last active October 17, 2021 13:34
AutoHotKey script to simulate macOS accentuation system
; macOS accentuation system
; source: https://gist.github.com/rbika/111bde86fb3315eca00f841ccdedd261
#NoEnv
SendMode Input
SetWorkingDir %A_ScriptDir%
#`::previewAccent("``")
#e::previewAccent("´")
#i::previewAccent("ˆ")
@rbika
rbika / macos-same-app-cycle.ahk
Last active June 24, 2025 17:39
AutoHotKey script to cycle between windows of the same app
; Cycle between windows of the same app like in macOS - Alt+backtick.
; Source: https://gist.github.com/rbika/014fb3570beaef195db0bd53fa681037
#NoEnv
SendMode Input
SetWorkingDir %A_ScriptDir%
!`::
WinGet, activeProcess, ProcessName, A ; Retrieves the name of the process that owns the active window
WinGet, winList, List, ahk_exe %activeProcess% ; Retrieves a pseudo-list of windows belonging to this process
var foobar = function() {
console.log(‘A’);
console.log(‘B’);
console.log(‘C’);
}
foobar();