<%*
var yaml = '';
var tArr = tp.file.tags;
tArr.sort();
var tStr = tArr.join(', ').replace(/#/g,'');
if (tStr.length) {
yaml = '---\ntags: [' + tStr + ']\n---\n';
}
%><%* tR += yaml %>
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
| <%* | |
| 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) + ')'; |
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
| #!/usr/bin/env bash | |
| _realpath() { | |
| if [[ -x $(command -v realpath) ]]; then | |
| realpath "$1" | |
| else | |
| $(brew --prefix)/bin/python3 -c 'import sys,os; print(os.path.realpath(sys.argv[1]));' "$1" | |
| fi | |
| } |
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
| 'use strict'; | |
| var obsidian = require('obsidian'); | |
| /*! ***************************************************************************** | |
| Copyright (c) Microsoft Corporation. | |
| Permission to use, copy, modify, and/or distribute this software for any | |
| purpose with or without fee is hereby granted. |
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/sh | |
| # put the line below at the end of /etc/rc.gatway_alarm, just above the final `exit`: | |
| # /root/wgfix.sh "${GW}" "${alarm_flag}" | |
| # set the 2 variables below to match the interface name and public key | |
| # of the wg tunnel that you want to "fail back" when your default gateway changes | |
| # WG_PEER_PUBLIC_KEY should be the public key from the FAR side (i.e the one from the PEERS tab) | |
| WG_IFNAME='tun_wg0' | |
| WG_PEER_PUBLIC_KEY='Vh+y3uVDnbmJtL7O4tgjaInRmerV3dWq/dM8LeSqbFY=' |
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
| /* | |
| THIS IS A GENERATED/BUNDLED FILE BY ROLLUP | |
| if you want to view the source visit the plugins github repository | |
| */ | |
| 'use strict'; | |
| var obsidian = require('obsidian'); | |
| /*! ***************************************************************************** |
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/sh | |
| c='https://github.com/pfsense/pfsense/commit' | |
| retval=0 | |
| if [ "$1" = "-r" ]; then | |
| verb='reverted' | |
| shift | |
| else | |
| verb='applied' |
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
| #!/usr/bin/env bash | |
| # https://apple.stackexchange.com/questions/304345/show-installation-date-of-packages-installed-with-homebrew/432218#432218 | |
| # https://apple.stackexchange.com/questions/373442/how-to-generate-list-of-homebrew-formulas-packages-sorted-by-most-recently-upda/ | |
| #default timeframe | |
| tf=1d | |
| case $1 in | |
| -h|--help) echo "usage: ${0##*/} [time] e.g. 90m, 1h, 3d (default: $tf)"; exit;; |
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
| --[[ Live-updating floating previews | |
| 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) |