Same article on dev.to
Here's my configuraiton (in data.json
):
"censorText": [
{
"entry": "/ (\\^\\w+)$/gm",
/* same article on [dev.to](https://dev.to/somidad/stop-obsidian-wrapping-code-and-enable-scrolling-47oo) */ | |
/* it only works on Reading view */ | |
/* https://forum.obsidian.md/t/horizontal-scrolling-in-the-code-block/55789/2 */ | |
.markdown-rendered code { | |
white-space: pre; | |
} |
Same article on dev.to
Here's my configuraiton (in data.json
):
"censorText": [
{
"entry": "/ (\\^\\w+)$/gm",
const { readFileSync, writeFileSync } = require("fs"); | |
function indexOfUnicode(s, u) { | |
let i = -1; | |
for (i = 0; i < s.length; i++) { | |
if (s.charCodeAt(i) === u) { | |
break; | |
} | |
} | |
return i; |
# https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#environment-files | |
- name: Check if there is any change | |
id: get_changes | |
# deprecated. see https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/ | |
#run: echo "::set-output name=changed::$(git status --porcelain | wc -l)" | |
run: echo "changed=$(git status --porcelain | wc -l)" >> $GITHUB_OUTPUT | |
- name: Do something if there is any change | |
if: steps.get_changes.outputs.changed != 0 | |
run: do something |
const [header, payload, signature] = jwt.split('.'); | |
const buffer = Buffer.from(payload, 'base64'); | |
const decoded = JSON.parse(buffer); |
function rectCollide() { | |
var nodes,sizes,masses; | |
var strength = 1; | |
var iterations = 1; | |
var nodeCenterX; | |
var nodeMass; | |
var nodeCenterY; | |
function force() { |
# it turns out that puttygen can do almost all conversions anyway | |
: ' | |
ssh-private-public - Convert an openssh private key to an openssh public key | |
Usage: ssh-private-public <path-to-key> <path-to-key.pub> | |
' | |
ssh-private-public () { | |
ssh-keygen -f "$1" -y >"$2" | |
} |
Microsoft Office 2007 and 2010 include a tool that can convert .doc-files to .docx-files from the command line.
This will not get rid of the compatibility-mode message -- that requires opening the file and saving it as a new format -- but it does help with reducing file sizes and cross-platform compatibilities.
The tool is called Wordconv.exe
and is located in the root Office folder,
e.g. Office14
.
cd /usr/src
curl -L https://www.rtai.org/userfiles/downloads/RTAI/rtai-4.1.tar.bz2 | tar xj
curl -L https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.10.32.tar.xz | tar xJ
curl -L http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10.32-saucy/linux-image-3.10.32-031032-generic_3.10.32-031032.201402221635_amd64.deb -o linux-image-3.10.32-generic-amd64.deb
@echo off | |
SET st3Path=C:\Program Files\Sublime Text 3\sublime_text.exe | |
rem add it for all file types | |
@reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3" /t REG_SZ /v "" /d "Open with Sublime Text 3" /f | |
@reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3" /t REG_EXPAND_SZ /v "Icon" /d "%st3Path%,0" /f | |
@reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3\command" /t REG_SZ /v "" /d "%st3Path% \"%%1\"" /f | |
rem add it for folders | |
@reg add "HKEY_CLASSES_ROOT\Folder\shell\Open with Sublime Text 3" /t REG_SZ /v "" /d "Open with Sublime Text 3" /f |