This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Pull in the wezterm API | |
local wezterm = require("wezterm") | |
local act = wezterm.action | |
-- This table will hold the configuration. | |
local config = {} | |
-- In newer versions of wezterm, use the config_builder which will | |
-- help provide clearer error messages | |
if wezterm.config_builder then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /bin/bash | |
# run from inside a neovim clone, eg: | |
# git clone https://github.com/neovim/neovim.git | |
set -euo | |
echo building latest stable neovim | |
# update all remote data | |
git fetch origin --tags --force | |
# switch to latest remote/stable tag | |
git checkout tags/stable | |
# build all things |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From: https://unix.stackexchange.com/questions/437468/bluetooth-headset-volume-too-low-only-in-arch/562381#562381 | |
> For those who don't want to compile the whole thing, the hex code of that method (in Ubuntu 20.04) is | |
> `48 8b 46 70 66 83 78 0a 7f` and if you replace the `7f` with `ff`, that method basically always returns TRUE. | |
> Just hexedit your /var/lib/bluetooth/bluetoothd and restart bluetooth. | |
`sudo vi /usr/lib/bluetooth/bluetoothd` (old: `sudo vi /var/lib/bluetooth/bluetoothd`) | |
-> `:%!xxd` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ sudo vi /etc/udev/hwdb.d/70-keyboard.hwdb | |
# evdev:input:b<bus_id>v<vendor_id>p<product_id>e<version_id>-<modalias> | |
# use `lsusb` and `sudo udevadm info /dev/input/by-id/usb-*` to get values for bus, vendor, product, revision | |
# use `sudo evtest` to get scan code for lhs to rhs key mapping from /usr/include/linux/input.h | |
# Metadot Das Keyboard Pro 4 (MAC) | |
evdev:input:b0003v24F0* | |
KEYBOARD_KEY_700e2=leftmeta | |
KEYBOARD_KEY_700e3=leftalt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def user = User.get("<your user id>") | |
user.getProperty(hudson.plugins.favorite.user.FavoriteUserProperty.class).data.clear() | |
user.save() | |
// Execute here: | |
http://lfbuild.corp.adobe.com:8080/script |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git rebase --onto <target> <common-forkpoint> <feature> | |
will detach <feature> from <common-forkpoint> and reattach on top of <target> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import MockEventFactory | |
import javax.enterprise.event.Event | |
import org.junit.runner.RunWith | |
import org.scalamock.scalatest.MockFactory | |
import org.scalatest.junit.JUnitRunner | |
import org.scalatest.FlatSpec | |
@RunWith(classOf[JUnitRunner]) | |
class ExampleSpec extends FlatSpec with MockFactory with MockEventFactory { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on run {input, parameters} | |
tell application "System Events" | |
set activeApp to name of first application process whose frontmost is true | |
if "Mail" is in activeApp then | |
tell application "Mail" | |
-- Collect the rules that already exist | |
set ruleNames to {} | |
repeat with ruleNumber from 1 to count rules |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
import sys | |
import subprocess | |
from collections import defaultdict | |
def move_tail(topic, groups, path="/opt/kafka/bin/", env="staging"): | |
command = r"%skafka-run-class.sh kafka.tools.GetOffsetShell --broker-list kafka-seed-1.%s.livefyre.com:9092 --topic %s --time -1 " | |
cli = command % (path, env, topic) | |
proc = subprocess.Popen(cli, stdout=subprocess.PIPE, shell=True) | |
(out, err) = proc.communicate() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pbpaste | highlight -O rtf /dev/stdin --font-size 34 --font Menlo --style molokai -W -J 80 -j 3 --src-lang java | pbcopy |
NewerOlder