- Create javascript file with code to inject.
- Add to accessible resources in manifest.json:
"web_accessible_resources": [
{
"resources": [<javascript file path>],
"matches": [...]
}
],
"web_accessible_resources": [
{
"resources": [<javascript file path>],
"matches": [...]
}
],
package main | |
import ( | |
"crypto/sha1" | |
"fmt" | |
"sync" | |
"testing" | |
) | |
var cases = []struct { |
#!/bin/bash | |
deviceID=$(bluetoothctl devices 2>&1 | grep $device | cut -d" " -f2) | |
command=$(bluetoothctl info $deviceID | grep Connected | grep -q no && echo "connect" || echo "disconnect") | |
bluetoothctl $command $deviceID |
git clone https://$GHP_KEY@github.com/$REPO_OWNER/$REPO | |
# -- OR -- | |
git remote -set-url originl https://$GHP_KEY@github.com/$REPO_OWNER/$REPO | |
# Set user | |
git config user.name $NAME | |
git config user.email $EMAIL |
#! /bin/sh | |
# Prerequisites: | |
# nativefier: | |
# sudo npm install -g nativefier | |
nativefier --name Notion --single-instance notion.so | |
cd Notion-linux-x64/ | |
chmod +x Notion |
-- Surround | |
function Surround_with(start_surround, end_surround) | |
local vstart = vim.fn.getpos("'<") | |
local vend = vim.fn.getpos("'>") | |
local start_column = vstart[3] - 1 | |
local start_line = vstart[2] | |
local end_column = vend[3] - 1 | |
local end_line = vend[2] | |
-- Skip whitespaces at the start of lines |