-
Install a working (and compiled) version of virt-viewer. You may view the homebrew package's upstream source on GitHub.
brew tap jeffreywildman/homebrew-virt-manager brew install virt-viewer
-
Once that's installed should be able make a call
remote-viewer
with a pve-spice.vv file downloaded from proxmox web interface
const app = Application.currentApplication() | |
app.includeStandardAdditions = true | |
function getJSON(path) { | |
const fullPath = path.replace(/^~/, app.pathTo('home folder')) | |
const contents = app.read(fullPath) | |
return JSON.parse(contents) | |
} | |
function run() { |
<%* | |
//v0.2 - bug fix: when search results match just a file name and no line contents under it | |
//User can set the following two parameters | |
const resultFilePrefix = '## '; | |
const folderLocation = '/search'; | |
const search = app.workspace.getLeavesOfType("search")[0]; | |
const searchTerms = search.view.getQuery(); | |
const arrCount = Array.from(search.view.dom.resultDomLookup); |
<%* | |
var searchLeaf; | |
app.workspace.iterateAllLeaves(leaf => { | |
if (leaf.view.getViewType() === 'search') { | |
searchLeaf = leaf; | |
}}); | |
if (typeof(searchLeaf) !== 'undefined') { | |
var q = searchLeaf.view.getQuery(); | |
if (q !== '') { | |
var md = '[search: ' + q + '](obsidian://search?query=' + encodeURIComponent(q) + ')'; |
--[[ Live-updating floating windows at your service! | |
https://www.hammerspoon.org/docs/hs.window.html | |
https://www.hammerspoon.org/docs/hs.canvas.html | |
https://www.hammerspoon.org/docs/hs.image.html | |
https://www.hammerspoon.org/docs/hs.mouse.html | |
https://www.hammerspoon.org/docs/hs.timer.html | |
https://www.lua.org/manual/5.4/manual.html#6.2 (coroutines) | |
https://github.com/Hammerspoon/hammerspoon/issues/2710#issuecomment-788266990 (thanks @asmagill) |
This is a cheat sheet for how to perform various actions to ZSH, which can be tricky to find on the web as the syntax is not intuitive and it is generally not very well-documented.
Description | Syntax |
---|---|
Get the length of a string | ${#VARNAME} |
Get a single character | ${VARNAME[index]} |
NB: these instructions are for Ubuntu; they work under WSL on Windows 10 as well
Get the decrypt.sh
file from here: https://github.com/zhangyoufu/unifi-backup-decrypt
Make sure prerequisites are installed:
sudo apt update && sudo apt install zip unzip openssl mongo-tools
/** | |
Create pagebreaks in exported Obsidian PDFs. | |
Example: | |
# Heading 1 | |
Lorem Ipsum is simply dummy text of the printing and typesetting industry. | |
Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, | |
when an unknown printer took a galley of type and scrambled it to make a type |
I'm a user of mwan3 and contribute to its development in a small way by mainly providing feedback with my multi WAN setup and maintaining the beast of it's documentation on the OpenWrt wiki (feedback and contributors welcome).
This setup ultimately requires the use of a NAT6 firewall script. NAT6 is currently broke with fw3 and LuCI, so this is an important helper script to workaround this current limitation.
The NAT6 configuration requirements are explained in more detail on the OpenWrt wiki.
This gist is aims to document my configuration for others.
#!/bin/sh | |
CASKNAME="$1" | |
CASKROOM=$(brew --caskroom) | |
CASKDIR="$CASKROOM/$CASKNAME" | |
DATE=$(date +"%Y%m%d%H%M%S.000") | |
BACKUPDIR="$CASKDIR/.backup" | |
BLACK='\033[30m' | |
RED='\033[31m' |