aboutsummaryrefslogtreecommitdiff
path: root/build/wiki/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'build/wiki/index.html')
-rw-r--r--build/wiki/index.html356
1 files changed, 212 insertions, 144 deletions
diff --git a/build/wiki/index.html b/build/wiki/index.html
index f632e31..d524345 100644
--- a/build/wiki/index.html
+++ b/build/wiki/index.html
@@ -1,61 +1,69 @@
<!doctype html>
-<html lang="en" id="top">
+<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" href="data:,">
<title>Wiki</title>
- <link href="https://bt.ht/atom.xml" type="application/atom+xml" rel="alternate" title="Atom feed for blog posts" />
- <style>*{box-sizing:border-box;}body{font-family:sans-serif;margin:0 auto;max-width:650px;padding:1rem;}img{max-width:100%;}pre{overflow:auto;}table{text-align:left;width:100%;}</style>
+ <link href="/atom.xml" type="application/atom+xml" rel="alternate" title="Atom feed for blog posts" />
+ <link href="/rss.xml" type="application/rss+xml" rel="alternate" title="RSS feed for blog posts" />
+<style>*{box-sizing:border-box;}body{font-family:sans-serif;line-height:1.33;margin:0 auto;max-width:650px;padding:1rem;}img{max-width:100%;}pre{border:1px solid;overflow:auto;padding:5px;}table{text-align:left;width:100%;}.footnotes{font-size:90%;}</style>
</head>
<nav>
- <a href="#menu">Menu &darr;</a>
+ <a href="#menu">Menu &darr;</a>
</nav>
<main>
-<h1>Wiki</h1>
-<h2>Introduction</h2>
-<p>This is a living document that will expand alongside my own personal experiences and knowledge. Topics range from device settings, computer configurations, household product serial numbers / expiry dates, and so on. Hopefully this can end up being helpful to others as well.</p>
-<h2>Open Suck</h2>
+<h1 id="wiki">Wiki</h1>
+
+<h2 id="introduction">Introduction</h2>
+
+<p>This is a living document that will expand alongside my own personal experiences and knowledge. Topics range from device settings, computer configurations, household product serial numbers &#47; expiry dates, and so on. Hopefully this can end up being helpful to others as well.</p>
+
+<h2 id="open-suck">Open Suck</h2>
+
<p>My personal, lightweight desktop installer for OpenBSD based on the suckless philosophy. Includes my own custom set of suckless tools (dwm, slstatus, dmenu, etc.)</p>
+
<ul>
-<li><a href="https://git.sr.ht/~bt/open-suck">https://git.sr.ht/~bt/open-suck</a></li>
+<li><a href="https://git.sr.ht/~bt/open-suck">https:&#47;&#47;git.sr.ht&#47;~bt&#47;open-suck</a></li>
</ul>
-<h2>vimrc</h2>
-<pre><code>&quot; Don't try to be vi compatible
+
+<h2 id="vimrc">vimrc</h2>
+
+<pre><code>" Don&#39;t try to be vi compatible
set nocompatible
-&quot; Helps force plugins to load correctly when it is turned back on below
+" Helps force plugins to load correctly when it is turned back on below
filetype off
-&quot; TODO: Load plugins here (pathogen or vundle)
+" TODO: Load plugins here (pathogen or vundle)
-&quot; Turn on syntax highlighting
+" Turn on syntax highlighting
syntax on
-&quot; For plugins to load correctly
+" For plugins to load correctly
filetype plugin indent on
-&quot; TODO: Pick a leader key
-&quot; let mapleader = &quot;,&quot;
+" TODO: Pick a leader key
+" let mapleader = ","
-&quot; Security
+" Security
set modelines=0
-&quot; Show line numbers
+" Show line numbers
set number
-&quot; Show file stats
+" Show file stats
set ruler
-&quot; Blink cursor on error instead of beeping (grr)
+" Blink cursor on error instead of beeping (grr)
set visualbell
-&quot; Encoding
+" Encoding
set encoding=utf-8
-&quot; Whitespace
+" Whitespace
set wrap
set textwidth=79
set formatoptions=tcqrn1
@@ -65,190 +73,232 @@ set softtabstop=2
set expandtab
set noshiftround
-&quot; Cursor motion
+" Cursor motion
set scrolloff=3
set backspace=indent,eol,start
-set matchpairs+=&lt;:&gt; &quot; use % to jump between pairs
-runtime! macros/matchit.vim
+set matchpairs+=&#60;:&#62; " use % to jump between pairs
+runtime! macros&#47;matchit.vim
-&quot; Move up/down editor lines
+" Move up&#47;down editor lines
nnoremap j gj
nnoremap k gk
-&quot; Allow hidden buffers
+" Allow hidden buffers
set hidden
-&quot; Rendering
+" Rendering
set ttyfast
-&quot; Status bar
+" Status bar
set laststatus=2
-&quot; Last line
+" Last line
set showmode
set showcmd
-&quot; Searching
-nnoremap / /\v
-vnoremap / /\v
+" Searching
+nnoremap &#47; &#47;\v
+vnoremap &#47; &#47;\v
set hlsearch
set incsearch
set ignorecase
set smartcase
set showmatch
-map &lt;leader&gt;&lt;space&gt; :let @/=''&lt;cr&gt; &quot; clear search
+map &#60;leader&#62;&#60;space&#62; :let @&#47;=&#39;&#39;&#60;cr&#62; " clear search
-&quot; Remap help key.
-inoremap &lt;F1&gt; &lt;ESC&gt;:set invfullscreen&lt;CR&gt;a
-nnoremap &lt;F1&gt; :set invfullscreen&lt;CR&gt;
-vnoremap &lt;F1&gt; :set invfullscreen&lt;CR&gt;
+" Remap help key.
+inoremap &#60;F1&#62; &#60;ESC&#62;:set invfullscreen&#60;CR&#62;a
+nnoremap &#60;F1&#62; :set invfullscreen&#60;CR&#62;
+vnoremap &#60;F1&#62; :set invfullscreen&#60;CR&#62;
-&quot; Textmate holdouts
+" Textmate holdouts
-&quot; Formatting
-map &lt;leader&gt;q gqip
+" Formatting
+map &#60;leader&#62;q gqip
-&quot; Visualize tabs and newlines
+" Visualize tabs and newlines
set listchars=tab:▸\ ,eol:¬
-&quot; Uncomment this to enable by default:
-&quot; set list &quot; To enable by default
-&quot; Or use your leader key + l to toggle on/off
-map &lt;leader&gt;l :set list!&lt;CR&gt; &quot; Toggle tabs and EOL
+" Uncomment this to enable by default:
+" set list " To enable by default
+" Or use your leader key + l to toggle on&#47;off
+map &#60;leader&#62;l :set list!&#60;CR&#62; " Toggle tabs and EOL
-&quot; Color scheme (terminal)
+" Color scheme (terminal)
set t_Co=256
set background=dark
let g:solarized_termcolors=256
let g:solarized_termtrans=1
-&quot; put https://raw.github.com/altercation/vim-colors-solarized/master/colors/solarized.vim
-&quot; in ~/.vim/colors/ and uncomment:
-&quot; colorscheme solarized
+" put https:&#47;&#47;raw.github.com&#47;altercation&#47;vim-colors-solarized&#47;master&#47;colors&#47;solarized.vim
+" in ~&#47;.vim&#47;colors&#47; and uncomment:
+" colorscheme solarized
</code></pre>
-<h2>.zshrc extras / aliases</h2>
-<pre><code>export EDITOR=&quot;/bin/vim&quot;
-alias suck=&quot;sudo rm -rf config.h ; sudo make install&quot;
-alias fixmonitor=&quot;xrandr --auto --output eDP1 --mode 1366x768 --below DP2-2&quot;
-alias vscode=&quot;alias vscode=&quot;ENABLE_WASM=1 chrome --enable-wasm --disable-unveil&quot;&quot;
+<h2 id=".zshrc-extras-aliases">.zshrc extras &#47; aliases</h2>
+
+<pre><code>export EDITOR="&#47;bin&#47;vim"
+
+alias suck="sudo rm -rf config.h ; sudo make install"
+alias fixmonitor="xrandr --auto --output eDP1 --mode 1366x768 --below DP2-2"
+alias vscode="alias vscode="ENABLE_WASM=1 chrome --enable-wasm --disable-unveil""
</code></pre>
-<h2>mimeapps.list</h2>
-<p>Place this file under <code>/usr/share/applications/mimeapps.list</code></p>
+
+<h2 id="mimeapps.list">mimeapps.list</h2>
+
+<p>Place this file under <code>&#47;usr&#47;share&#47;applications&#47;mimeapps.list</code></p>
+
<pre><code>[Default Applications]
-x-scheme-handler/http=org.qutebrowser.qutebrowser.desktop
-x-scheme-handler/https=org.qutebrowser.qutebrowser.desktop
-x-scheme-handler/ftp=org.qutebrowser.qutebrowser.desktop
-x-scheme-handler/chrome=org.qutebrowser.qutebrowser.desktop
-text/html=org.qutebrowser.qutebrowser.desktop
-application/x-extension-htm=org.qutebrowser.qutebrowser.desktop
-application/x-extension-html=org.qutebrowser.qutebrowser.desktop
-application/x-extension-shtml=org.qutebrowser.qutebrowser.desktop
-application/xhtml+xml=org.qutebrowser.qutebrowser.desktop
-application/x-extension-xhtml=org.qutebrowser.qutebrowser.desktop
-application/x-extension-xht=org.qutebrowser.qutebrowser.desktop
-image/jpeg=feh
-image/png=feh
-image/webp=feh
+x-scheme-handler&#47;http=org.qutebrowser.qutebrowser.desktop
+x-scheme-handler&#47;https=org.qutebrowser.qutebrowser.desktop
+x-scheme-handler&#47;ftp=org.qutebrowser.qutebrowser.desktop
+x-scheme-handler&#47;chrome=org.qutebrowser.qutebrowser.desktop
+text&#47;html=org.qutebrowser.qutebrowser.desktop
+application&#47;x-extension-htm=org.qutebrowser.qutebrowser.desktop
+application&#47;x-extension-html=org.qutebrowser.qutebrowser.desktop
+application&#47;x-extension-shtml=org.qutebrowser.qutebrowser.desktop
+application&#47;xhtml+xml=org.qutebrowser.qutebrowser.desktop
+application&#47;x-extension-xhtml=org.qutebrowser.qutebrowser.desktop
+application&#47;x-extension-xht=org.qutebrowser.qutebrowser.desktop
+image&#47;jpeg=feh
+image&#47;png=feh
+image&#47;webp=feh
</code></pre>
-<h2>qutebrowser</h2>
-<h3>Greasemonkey</h3>
-<p>All of these scripts should be added under <code>~/.local/share/qutebrowser/greasemonkey/</code>. Then be sure to run the proper command within qutebrowser: <code>:greasemonkey-reload</code></p>
-<h4>Auto Skip YouTube Ads</h4>
-<pre><code>// ==UserScript==
-// @name Auto Skip YouTube Ads
-// @version 1.0.0
-// @description Speed up and skip YouTube ads automatically
-// @author jso8910
-// @match *://*.youtube.com/*
-// @exclude *://*.youtube.com/subscribe_embed?*
-// ==/UserScript==
-setInterval(() =&gt; {
- const btn = document.querySelector('.videoAdUiSkipButton,.ytp-ad-skip-button')
+
+<h2 id="qutebrowser">qutebrowser</h2>
+
+<h3 id="greasemonkey">Greasemonkey</h3>
+
+<p>All of these scripts should be added under <code>~&#47;.local&#47;share&#47;qutebrowser&#47;greasemonkey&#47;</code>. Then be sure to run the proper command within qutebrowser: <code>:greasemonkey-reload</code></p>
+
+<h4 id="auto-skip-youtube-ads">Auto Skip YouTube Ads</h4>
+
+<pre><code>&#47;&#47; ==UserScript==
+&#47;&#47; @name Auto Skip YouTube Ads
+&#47;&#47; @version 1.0.0
+&#47;&#47; @description Speed up and skip YouTube ads automatically
+&#47;&#47; @author jso8910
+&#47;&#47; @match *:&#47;&#47;*.youtube.com&#47;*
+&#47;&#47; @exclude *:&#47;&#47;*.youtube.com&#47;subscribe_embed?*
+&#47;&#47; ==&#47;UserScript==
+setInterval(() =&#62; {
+ const btn = document.querySelector(&#39;.videoAdUiSkipButton,.ytp-ad-skip-button&#39;)
if (btn) {
btn.click()
}
- const ad = [...document.querySelectorAll('.ad-showing')][0];
+ const ad = [...document.querySelectorAll(&#39;.ad-showing&#39;)][0];
if (ad) {
- document.querySelector('video').playbackRate = 10;
+ document.querySelector(&#39;video&#39;).playbackRate = 10;
}
}, 50)
</code></pre>
-<h2><code>ffmpeg</code> to MP4</h2>
+
+<h2 id="to-mp4"><code>ffmpeg</code> to MP4</h2>
+
<pre><code>ffmpeg -i input_filename.avi -c:v copy -c:a copy -y output_filename.mp4
</code></pre>
-<h2>Mount USB HDD via CLI</h2>
-<pre><code>mkdir /media/usb-drive
-mount /dev/sdX /media/usb-drive/
+
+<h2 id="mount-usb-hdd-via-cli">Mount USB HDD via CLI</h2>
+
+<pre><code>mkdir &#47;media&#47;usb-drive
+mount &#47;dev&#47;sdX &#47;media&#47;usb-drive&#47;
</code></pre>
-<h2>Run Mullvad on Alpine Linux (Wireguard)</h2>
+
+<h2 id="run-mullvad-on-alpine-linux-wireguard">Run Mullvad on Alpine Linux (Wireguard)</h2>
+
<pre><code># Install wireguard
apk add wireguard-tools
</code></pre>
+
<p>Login into Mullvad and download the proper wireguard configuration files(s). After downloaded, place in the proper directory:</p>
-<pre><code>doas cp &lt;MULLVAD_FILENAME&gt;.conf /etc/wireguard/&quot;
+
+<pre><code>doas cp &#60;MULLVAD_FILENAME&#62;.conf &#47;etc&#47;wireguard&#47;"
</code></pre>
-<p>Then setup an aliases for easier up/down states:</p>
-<pre><code>alias vpnup=&quot;doas wg-quick up /etc/wireguard/&lt;MULLVAD_FILENAME&gt;.conf&quot;
-alias vpndown=&quot;doas wg-quick down /etc/wireguard/&lt;MULLVAD_FILENAME&gt;.conf&quot;
+
+<p>Then setup an aliases for easier up&#47;down states:</p>
+
+<pre><code>alias vpnup="doas wg-quick up &#47;etc&#47;wireguard&#47;&#60;MULLVAD_FILENAME&#62;.conf"
+alias vpndown="doas wg-quick down &#47;etc&#47;wireguard&#47;&#60;MULLVAD_FILENAME&#62;.conf"
</code></pre>
-<h2>Alpine Linux <code>mini_racer</code> Tweaks</h2>
+
+<h2 id="alpine-linux-tweaks">Alpine Linux <code>mini_racer</code> Tweaks</h2>
+
<p>Gem lockfile:</p>
+
<pre><code>PLATFORMS
ruby
x86_64-linux-musl
mini_racer (0.6.3)
- &lt;remove child dependency&gt;
+ &#60;remove child dependency&#62;
</code></pre>
+
<p>then run: <code>bundle update mini_racer</code></p>
-<h2>Docker</h2>
+
+<h2 id="docker">Docker</h2>
+
<p>Installing <code>ghost</code></p>
+
<pre><code>docker pull ghost
</code></pre>
+
<pre><code>docker run -d \
--name ghost-name \
-e NODE_ENV=development \
-p 2368:2368 \
- -v $HOME/path/to/ghost/blog:/var/lib/ghost/content \
+ -v $HOME&#47;path&#47;to&#47;ghost&#47;blog:&#47;var&#47;lib&#47;ghost&#47;content \
ghost:alpine
</code></pre>
-<h2>MongoDB 3.4 on Ubuntu 23.10</h2>
-<pre><code>wget http://launchpadlibrarian.net/668089858/libssl1.0.0_1.0.2n-1ubuntu5.13_amd64.deb
-sudo apt install ./libssl1.0.0_1.0.2n-1ubuntu5.13_amd64.deb
-sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10
-echo &quot;deb http://repo.mongodb.org/apt/ubuntu precise/mongodb-org/3.4 multiverse&quot; | sudo tee /etc/apt/sources.list.d/mongodb-org-3.4.list
+<h2 id="mongodb-3.4-on-ubuntu-23.10">MongoDB 3.4 on Ubuntu 23.10</h2>
+
+<pre><code>wget http:&#47;&#47;launchpadlibrarian.net&#47;668089858&#47;libssl1.0.0_1.0.2n-1ubuntu5.13_amd64.deb
+sudo apt install .&#47;libssl1.0.0_1.0.2n-1ubuntu5.13_amd64.deb
+sudo apt-key adv --keyserver hkp:&#47;&#47;keyserver.ubuntu.com:80 --recv 7F0CEB10
+
+echo "deb http:&#47;&#47;repo.mongodb.org&#47;apt&#47;ubuntu precise&#47;mongodb-org&#47;3.4 multiverse" | sudo tee &#47;etc&#47;apt&#47;sources.list.d&#47;mongodb-org-3.4.list
</code></pre>
-<p>Now edit <code>/etc/apt/sources.list.d/mongodb-org-3.4.list</code>:</p>
-<pre><code>deb [trusted=yes] http://repo.mongodb.org/apt/ubuntu precise/mongodb-org/3.4...
+
+<p>Now edit <code>&#47;etc&#47;apt&#47;sources.list.d&#47;mongodb-org-3.4.list</code>:</p>
+
+<pre><code>deb [trusted=yes] http:&#47;&#47;repo.mongodb.org&#47;apt&#47;ubuntu precise&#47;mongodb-org&#47;3.4...
</code></pre>
+
<p>Then finish things up:</p>
+
<pre><code>sudo apt-get update --allow-unauthenticated
sudo apt-get install -y mongodb-org
-sudo mkdir -p /data/db
-sudo chmod -R 777 /data/db
+sudo mkdir -p &#47;data&#47;db
+sudo chmod -R 777 &#47;data&#47;db
</code></pre>
-<h2>Redis 6.0.7 on Ubuntu 23.10</h2>
+
+<h2 id="redis-6.0.7-on-ubuntu-23.10">Redis 6.0.7 on Ubuntu 23.10</h2>
+
<pre><code>sudo apt-get install build-essential tcl
-cd /tmp
-curl -O http://download.redis.io/releases/redis-6.0.7.tar.gz
+cd &#47;tmp
+curl -O http:&#47;&#47;download.redis.io&#47;releases&#47;redis-6.0.7.tar.gz
tar xzvf redis-6.0.7.tar.gz
cd redis-6.0.7
</code></pre>
+
<p>Install redis:</p>
+
<pre><code>make
make test
sudo make install
-sudo mkdir /etc/redis
-sudo cp /tmp/redis-6.0.7redis.conf /etc/redis
+sudo mkdir &#47;etc&#47;redis
+sudo cp &#47;tmp&#47;redis-6.0.7redis.conf &#47;etc&#47;redis
</code></pre>
-<p>Edit <code>/etc/redis/redis.conf</code> with the following changes:</p>
+
+<p>Edit <code>&#47;etc&#47;redis&#47;redis.conf</code> with the following changes:</p>
+
<ul>
<li><code>supervised systemd</code></li>
-<li><code>dir /var/lib/redis</code></li>
+<li><code>dir &#47;var&#47;lib&#47;redis</code></li>
</ul>
-<p>Create systemd unit file for redis: <code>/etc/systemd/system/redis.service</code>:</p>
+
+<p>Create systemd unit file for redis: <code>&#47;etc&#47;systemd&#47;system&#47;redis.service</code>:</p>
+
<pre><code>[Unit]
Description=Redis In-Memory Data Store
After=network.target
@@ -256,53 +306,71 @@ After=network.target
[Service]
User=redis
Group=redis
-ExecStart=/usr/local/bin/redis-server /etc/redis/redis.conf
-ExecStop=/usr/local/bin/redis-cli shutdown
+ExecStart=&#47;usr&#47;local&#47;bin&#47;redis-server &#47;etc&#47;redis&#47;redis.conf
+ExecStop=&#47;usr&#47;local&#47;bin&#47;redis-cli shutdown
Restart=always
[Install]
WantedBy=multi-user.target
</code></pre>
+
<p>Final steps:</p>
+
<pre><code>sudo adduser --system --group --no-create-home redis
-sudo mkdir /var/lib/redis
-sudo chown redis:redis /var/lib/redis
-sudo chmod 770 /var/lib/redis
+sudo mkdir &#47;var&#47;lib&#47;redis
+sudo chown redis:redis &#47;var&#47;lib&#47;redis
+sudo chmod 770 &#47;var&#47;lib&#47;redis
</code></pre>
-<h2>Ruby 2.7.2 with rbenv on Ubuntu 23.10</h2>
-<p>Edit the <code>/etc/apt/sources.list</code> file:</p>
-<pre><code>deb [trusted=yes] http://security.ubuntu.com/ubuntu bionic-security main
+
+<h2 id="ruby-2.7.2-with-rbenv-on-ubuntu-23.10">Ruby 2.7.2 with rbenv on Ubuntu 23.10</h2>
+
+<p>Edit the <code>&#47;etc&#47;apt&#47;sources.list</code> file:</p>
+
+<pre><code>deb [trusted=yes] http:&#47;&#47;security.ubuntu.com&#47;ubuntu bionic-security main
</code></pre>
+
<p>Then run <code>sudo apt-get update</code>. After completion, install <code>libssl1.0-dev</code>:</p>
+
<pre><code>sudo apt-get install libssl1.0-dev
</code></pre>
-<h2>Fix screen tearing</h2>
-<pre><code>sudo micro /etc/X11/xorg.conf.d/20-intel.conf
+
+<h2 id="fix-screen-tearing">Fix screen tearing</h2>
+
+<pre><code>sudo micro &#47;etc&#47;X11&#47;xorg.conf.d&#47;20-intel.conf
</code></pre>
+
<p>Add the following contents to <code>20-intel.conf</code>:</p>
-<pre><code>Section &quot;OutputClass&quot;
- Identifier &quot;Intel Graphics&quot;
- MatchDriver &quot;i915&quot;
- Driver &quot;intel&quot;
- Option &quot;DRI&quot; &quot;3&quot;
- Option &quot;TearFree&quot; &quot;1&quot;
+
+<pre><code>Section "OutputClass"
+ Identifier "Intel Graphics"
+ MatchDriver "i915"
+ Driver "intel"
+ Option "DRI" "3"
+ Option "TearFree" "1"
EndSection
</code></pre>
-<h2>Enabling "tap to click"</h2>
-<pre><code>sudo micro /etc/X11/xorg.conf.d/30-touchpad.conf
+
+<h2 id="enabling-tap-to-click">Enabling &#8220;tap to click"</h2>
+
+<pre><code>sudo micro &#47;etc&#47;X11&#47;xorg.conf.d&#47;30-touchpad.conf
</code></pre>
+
<p>Add the following contents to <code>30-touchpad.conf</code>:</p>
-<pre><code>Section &quot;InputClass&quot;
- Identifier &quot;touchpad&quot;
- Driver &quot;libinput&quot;
- MatchIsTouchpad &quot;on&quot;
- Option &quot;Tapping&quot; &quot;on&quot;
- Option &quot;TappingButtonMap&quot; &quot;lmr&quot;
+
+<pre><code>Section "InputClass"
+ Identifier "touchpad"
+ Driver "libinput"
+ MatchIsTouchpad "on"
+ Option "Tapping" "on"
+ Option "TappingButtonMap" "lmr"
EndSection
</code></pre>
-<h2>Woocommerce</h2>
+
+<h2 id="woocommerce">Woocommerce</h2>
+
<p><strong>Reset all product menu_order to <code>0</code></strong></p>
-<pre><code>UPDATE wp_posts SET menu_order = 0 WHERE post_type = 'product';
+
+<pre><code>UPDATE wp_posts SET menu_order = 0 WHERE post_type = &#39;product&#39;;
</code></pre>
<footer role="contentinfo">
<h2>Menu Navigation</h2>