This commit is contained in:
Correl Roush 2022-07-16 21:40:28 -04:00
parent ae2156ae09
commit 0fda0c894a
7 changed files with 129 additions and 48 deletions

View file

@ -18,7 +18,7 @@ A lisp dialect of [[id:cda9c620-fec5-4549-b979-22fc06819d77][Python]].
Disassembling the above code generates the following Python equivalent.
#+begin_src hy :exports results :eval no-export :cache yes :wrap src python
#+begin_src hy :exports results :eval never :cache yes :wrap src python
(disassemble
(quote
(do

View file

@ -3,6 +3,6 @@
:END:
#+title: How I manage my projects
I keep an [[id:0567a35c-3afb-4ed5-a9ec-47425c5d6f06][Org-roam]] file dedicated to my [[id:207560cc-7700-4d06-918d-cc01ae530146][Projects]]. Each project, once it's
I keep an [[id:0567a35c-3afb-4ed5-a9ec-47425c5d6f06][Org-roam]] file dedicated to my projects. Each project, once it's
fleshed out as more than just an idea, gets its own file that its heading links
to.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.4 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 24 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 7.6 KiB

After

Width:  |  Height:  |  Size: 7.1 KiB

View file

@ -3,6 +3,87 @@
:END:
#+TITLE: Correl's Personal Knowledge Base Index
These are my notes, taken using the [[https://www.orgroam.com/][Org Roam]] tool. As such, they are a
collection of text files written in the Emacs [[https://orgmode.org/][Org]] syntax with heavy use of
hyperlinking to form an interconnected wiki. This means there is no filesystem
hierarchy, with the sole exception of the daily journal entries. Instead, it is
best navigated as a graph.
The graph below is interactive, and double-clicking on a node will browse to
that document.
#+begin_src emacs-lisp :results silent :exports results
(let ((filename "graph.json")
(nodes (org-roam-db-query
[:select [nodes:id nodes:title nodes:file (funcall count links:dest)]
:from nodes
:left-join links
:on (= nodes:id links:dest)
:group-by [nodes:id nodes:title nodes:file]]))
(edges (org-roam-db-query
[:select :distinct [source dest]
:from links
:where (= type "id")])))
(with-temp-buffer
(insert (json-encode
(list (cons 'nodes (mapcar (lambda (row) `((id . ,(nth 0 row))
(label . ,(nth 1 row))
(title . ,(nth 1 row))
(value . ,(nth 3 row))))
nodes))
(cons 'edges (mapcar (lambda (row) `((from . ,(nth 0 row))
(to . ,(nth 1 row))))
edges))
(cons 'urls (mapcar (lambda (row) (cons (nth 0 row)
(concat (string-remove-suffix
".org" (string-remove-prefix
org-roam-directory (nth 2 row)))
".html")))
nodes)))))
(write-file filename))
filename)
#+end_src
#+begin_export html
<script type="text/javascript" src="js/vis-network.min.js"></script>
<div id="network-graph" style="border: 1px solid lightgrey; height: 500px; width: 100%;"></div>
<script type="text/javascript">
var network = null;
var urls = null;
async function draw() {
// Instantiate our network object.
var container = document.getElementById("network-graph");
var options = {
nodes: {
shape: "dot",
},
physics: {
stabilization: false,
solver: "forceAtlas2Based",
},
interaction: {
navigationButtons: true,
}
};
var data = await (await fetch("graph.json")).json();
urls = data.urls;
network = new vis.Network(container, data, options);
network.on("doubleClick", params => {
var node = params.nodes[0];
if (!node) { return; }
var url = urls[node];
window.location = './' + url;
})
}
window.addEventListener("load", () => {
draw();
});
</script>
#+end_export
A collection of entry points to various interests and ideas.
- [[id:df5b2861-3838-409d-b4e4-fce7f302f778][How I Work]]

View file

@ -1,126 +1,126 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 2.48.0 (20210717.1556)
<!-- Generated by graphviz version 4.0.0 (0)
-->
<!-- Pages: 1 -->
<svg width="875pt" height="260pt"
viewBox="0.00 0.00 874.84 260.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<svg width="1069pt" height="260pt"
viewBox="0.00 0.00 1068.53 260.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 256)">
<polygon fill="white" stroke="transparent" points="-4,4 -4,-256 870.84,-256 870.84,4 -4,4"/>
<polygon fill="white" stroke="transparent" points="-4,4 -4,-256 1064.53,-256 1064.53,4 -4,4"/>
<!-- OpenAPIError -->
<g id="node1" class="node">
<title>OpenAPIError</title>
<ellipse fill="none" stroke="black" cx="181.15" cy="-234" rx="64.19" ry="18"/>
<text text-anchor="middle" x="181.15" y="-230.3" font-family="Times,serif" font-size="14.00">OpenAPIError</text>
<ellipse fill="none" stroke="black" cx="220.19" cy="-234" rx="76.89" ry="18"/>
<text text-anchor="middle" x="220.19" y="-230.3" font-family="Times,serif" font-size="14.00">OpenAPIError</text>
</g>
<!-- CastError -->
<g id="node2" class="node">
<title>CastError</title>
<ellipse fill="none" stroke="black" cx="46.15" cy="-162" rx="46.29" ry="18"/>
<text text-anchor="middle" x="46.15" y="-158.3" font-family="Times,serif" font-size="14.00">CastError</text>
<ellipse fill="none" stroke="black" cx="57.19" cy="-162" rx="57.39" ry="18"/>
<text text-anchor="middle" x="57.19" y="-158.3" font-family="Times,serif" font-size="14.00">CastError</text>
</g>
<!-- OpenAPIError&#45;&gt;CastError -->
<g id="edge1" class="edge">
<title>OpenAPIError&#45;&gt;CastError</title>
<path fill="none" stroke="black" d="M151.85,-217.81C131.36,-207.19 103.86,-192.93 82.05,-181.62"/>
<polygon fill="black" stroke="black" points="83.58,-178.47 73.09,-176.97 80.35,-184.68 83.58,-178.47"/>
<path fill="none" stroke="black" d="M184.83,-217.81C159.64,-207 125.7,-192.42 99.14,-181.01"/>
<polygon fill="black" stroke="black" points="100.29,-177.7 89.72,-176.97 97.53,-184.13 100.29,-177.7"/>
</g>
<!-- DeserializeError -->
<g id="node3" class="node">
<title>DeserializeError</title>
<ellipse fill="none" stroke="black" cx="181.15" cy="-162" rx="70.69" ry="18"/>
<text text-anchor="middle" x="181.15" y="-158.3" font-family="Times,serif" font-size="14.00">DeserializeError</text>
<ellipse fill="none" stroke="black" cx="220.19" cy="-162" rx="87.99" ry="18"/>
<text text-anchor="middle" x="220.19" y="-158.3" font-family="Times,serif" font-size="14.00">DeserializeError</text>
</g>
<!-- OpenAPIError&#45;&gt;DeserializeError -->
<g id="edge2" class="edge">
<title>OpenAPIError&#45;&gt;DeserializeError</title>
<path fill="none" stroke="black" d="M181.15,-215.7C181.15,-207.98 181.15,-198.71 181.15,-190.11"/>
<polygon fill="black" stroke="black" points="184.65,-190.1 181.15,-180.1 177.65,-190.1 184.65,-190.1"/>
<path fill="none" stroke="black" d="M220.19,-215.7C220.19,-207.98 220.19,-198.71 220.19,-190.11"/>
<polygon fill="black" stroke="black" points="223.7,-190.1 220.19,-180.1 216.7,-190.1 223.7,-190.1"/>
</g>
<!-- UnmarshalError -->
<g id="node5" class="node">
<title>UnmarshalError</title>
<ellipse fill="none" stroke="black" cx="345.15" cy="-162" rx="69.59" ry="18"/>
<text text-anchor="middle" x="345.15" y="-158.3" font-family="Times,serif" font-size="14.00">UnmarshalError</text>
<ellipse fill="none" stroke="black" cx="420.19" cy="-162" rx="87.18" ry="18"/>
<text text-anchor="middle" x="420.19" y="-158.3" font-family="Times,serif" font-size="14.00">UnmarshalError</text>
</g>
<!-- OpenAPIError&#45;&gt;UnmarshalError -->
<g id="edge4" class="edge">
<title>OpenAPIError&#45;&gt;UnmarshalError</title>
<path fill="none" stroke="black" d="M215.13,-218.5C240.14,-207.82 274.35,-193.22 301.4,-181.67"/>
<polygon fill="black" stroke="black" points="302.82,-184.87 310.64,-177.73 300.07,-178.43 302.82,-184.87"/>
<path fill="none" stroke="black" d="M261.15,-218.67C292.15,-207.82 334.93,-192.84 368.32,-181.16"/>
<polygon fill="black" stroke="black" points="369.63,-184.4 377.92,-177.8 367.32,-177.8 369.63,-184.4"/>
</g>
<!-- EmptyParameterValue -->
<g id="node4" class="node">
<title>EmptyParameterValue</title>
<ellipse fill="none" stroke="black" cx="175.15" cy="-90" rx="92.08" ry="18"/>
<text text-anchor="middle" x="175.15" y="-86.3" font-family="Times,serif" font-size="14.00">EmptyParameterValue</text>
<ellipse fill="none" stroke="black" cx="213.19" cy="-90" rx="115.88" ry="18"/>
<text text-anchor="middle" x="213.19" y="-86.3" font-family="Times,serif" font-size="14.00">EmptyParameterValue</text>
</g>
<!-- DeserializeError&#45;&gt;EmptyParameterValue -->
<g id="edge3" class="edge">
<title>DeserializeError&#45;&gt;EmptyParameterValue</title>
<path fill="none" stroke="black" d="M179.66,-143.7C179,-135.98 178.21,-126.71 177.47,-118.11"/>
<polygon fill="black" stroke="black" points="180.95,-117.77 176.61,-108.1 173.98,-118.37 180.95,-117.77"/>
<path fill="none" stroke="black" d="M218.46,-143.7C217.69,-135.98 216.77,-126.71 215.91,-118.11"/>
<polygon fill="black" stroke="black" points="219.38,-117.71 214.91,-108.1 212.42,-118.4 219.38,-117.71"/>
</g>
<!-- ValidateError -->
<g id="node6" class="node">
<title>ValidateError</title>
<ellipse fill="none" stroke="black" cx="345.15" cy="-90" rx="59.59" ry="18"/>
<text text-anchor="middle" x="345.15" y="-86.3" font-family="Times,serif" font-size="14.00">ValidateError</text>
<ellipse fill="none" stroke="black" cx="420.19" cy="-90" rx="73.39" ry="18"/>
<text text-anchor="middle" x="420.19" y="-86.3" font-family="Times,serif" font-size="14.00">ValidateError</text>
</g>
<!-- UnmarshalError&#45;&gt;ValidateError -->
<g id="edge5" class="edge">
<title>UnmarshalError&#45;&gt;ValidateError</title>
<path fill="none" stroke="black" d="M345.15,-143.7C345.15,-135.98 345.15,-126.71 345.15,-118.11"/>
<polygon fill="black" stroke="black" points="348.65,-118.1 345.15,-108.1 341.65,-118.1 348.65,-118.1"/>
<path fill="none" stroke="black" d="M420.19,-143.7C420.19,-135.98 420.19,-126.71 420.19,-118.11"/>
<polygon fill="black" stroke="black" points="423.7,-118.1 420.19,-108.1 416.7,-118.1 423.7,-118.1"/>
</g>
<!-- UnmarshallerError -->
<g id="node7" class="node">
<title>UnmarshallerError</title>
<ellipse fill="none" stroke="black" cx="531.15" cy="-90" rx="79.09" ry="18"/>
<text text-anchor="middle" x="531.15" y="-86.3" font-family="Times,serif" font-size="14.00">UnmarshallerError</text>
<ellipse fill="none" stroke="black" cx="646.19" cy="-90" rx="100.18" ry="18"/>
<text text-anchor="middle" x="646.19" y="-86.3" font-family="Times,serif" font-size="14.00">UnmarshallerError</text>
</g>
<!-- UnmarshalError&#45;&gt;UnmarshallerError -->
<g id="edge6" class="edge">
<title>UnmarshalError&#45;&gt;UnmarshallerError</title>
<path fill="none" stroke="black" d="M382.79,-146.83C411.55,-136.01 451.42,-121 482.59,-109.27"/>
<polygon fill="black" stroke="black" points="483.83,-112.55 491.96,-105.75 481.37,-105.99 483.83,-112.55"/>
<path fill="none" stroke="black" d="M466.47,-146.67C501.68,-135.76 550.35,-120.69 588.17,-108.97"/>
<polygon fill="black" stroke="black" points="589.51,-112.22 598.03,-105.92 587.44,-105.53 589.51,-112.22"/>
</g>
<!-- InvalidSchemaValue -->
<g id="node8" class="node">
<title>InvalidSchemaValue</title>
<ellipse fill="none" stroke="black" cx="315.15" cy="-18" rx="85.59" ry="18"/>
<text text-anchor="middle" x="315.15" y="-14.3" font-family="Times,serif" font-size="14.00">InvalidSchemaValue</text>
<ellipse fill="none" stroke="black" cx="386.19" cy="-18" rx="104.78" ry="18"/>
<text text-anchor="middle" x="386.19" y="-14.3" font-family="Times,serif" font-size="14.00">InvalidSchemaValue</text>
</g>
<!-- ValidateError&#45;&gt;InvalidSchemaValue -->
<g id="edge7" class="edge">
<title>ValidateError&#45;&gt;InvalidSchemaValue</title>
<path fill="none" stroke="black" d="M337.88,-72.05C334.47,-64.09 330.32,-54.41 326.51,-45.51"/>
<polygon fill="black" stroke="black" points="329.71,-44.09 322.55,-36.28 323.27,-46.85 329.71,-44.09"/>
<path fill="none" stroke="black" d="M411.96,-72.05C408.1,-64.09 403.39,-54.41 399.07,-45.51"/>
<polygon fill="black" stroke="black" points="402.1,-43.74 394.59,-36.28 395.81,-46.8 402.1,-43.74"/>
</g>
<!-- InvalidSchemaFormatValue -->
<g id="node9" class="node">
<title>InvalidSchemaFormatValue</title>
<ellipse fill="none" stroke="black" cx="531.15" cy="-18" rx="112.38" ry="18"/>
<text text-anchor="middle" x="531.15" y="-14.3" font-family="Times,serif" font-size="14.00">InvalidSchemaFormatValue</text>
<ellipse fill="none" stroke="black" cx="646.19" cy="-18" rx="137.58" ry="18"/>
<text text-anchor="middle" x="646.19" y="-14.3" font-family="Times,serif" font-size="14.00">InvalidSchemaFormatValue</text>
</g>
<!-- UnmarshallerError&#45;&gt;InvalidSchemaFormatValue -->
<g id="edge8" class="edge">
<title>UnmarshallerError&#45;&gt;InvalidSchemaFormatValue</title>
<path fill="none" stroke="black" d="M531.15,-71.7C531.15,-63.98 531.15,-54.71 531.15,-46.11"/>
<polygon fill="black" stroke="black" points="534.65,-46.1 531.15,-36.1 527.65,-46.1 534.65,-46.1"/>
<path fill="none" stroke="black" d="M646.19,-71.7C646.19,-63.98 646.19,-54.71 646.19,-46.11"/>
<polygon fill="black" stroke="black" points="649.7,-46.1 646.19,-36.1 642.7,-46.1 649.7,-46.1"/>
</g>
<!-- FormatterNotFoundError -->
<g id="node10" class="node">
<title>FormatterNotFoundError</title>
<ellipse fill="none" stroke="black" cx="764.15" cy="-18" rx="102.88" ry="18"/>
<text text-anchor="middle" x="764.15" y="-14.3" font-family="Times,serif" font-size="14.00">FormatterNotFoundError</text>
<ellipse fill="none" stroke="black" cx="931.19" cy="-18" rx="129.18" ry="18"/>
<text text-anchor="middle" x="931.19" y="-14.3" font-family="Times,serif" font-size="14.00">FormatterNotFoundError</text>
</g>
<!-- UnmarshallerError&#45;&gt;FormatterNotFoundError -->
<g id="edge9" class="edge">
<title>UnmarshallerError&#45;&gt;FormatterNotFoundError</title>
<path fill="none" stroke="black" d="M576.9,-75.25C613.63,-64.22 665.46,-48.65 705.28,-36.68"/>
<polygon fill="black" stroke="black" points="706.3,-40.03 714.87,-33.8 704.29,-33.33 706.3,-40.03"/>
<path fill="none" stroke="black" d="M702.84,-75.09C748.1,-63.97 811.78,-48.33 860.39,-36.39"/>
<polygon fill="black" stroke="black" points="861.34,-39.76 870.22,-33.98 859.67,-32.96 861.34,-39.76"/>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 6.4 KiB

After

Width:  |  Height:  |  Size: 6.3 KiB