bundle.syvl.org
If setting this up again, use C-c C-c
on the results of the emacs-lisp
code block; taken from mankoff’s answer here:
#+property: header-args -n -r -l "[{(<%s>)}]" :noweb yes :mkdirp yes :cache yes
# #+property: header-args -n -r -l "[{(<%s>)}]" :tangle-mode (identity #o444) :noweb yes :mkdirp yes :cache yes
# #+property: header-args:emacs-lisp+ :comments both
Adapted from Whil’s answer here:
#+startup: show3levels
More options can be found on the orgmode website:
#+options: num:nil html-style:nil pri:t
More mathjax
options can be found on the orgmode website and doc.endlessparentheses.com:
#+html_mathjax: align: left indent: 5%
More html
options can be found on the orgmode website:
- https://orgmode.org/manual/HTML-specific-export-settings.html
- https://orgmode.org/manual/Publishing-options.html#:~:text=HTML%20specific%20properties
- https://orgmode.org/worg/org-tutorials/org-publish-html-tutorial.html#org2656e9f
- https://orgmode.org/guide/HTML-Export.html
- https://orgmode.org/manual/Quoting-HTML-tags.html
Adapted from here:
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/gh/sylvorg/bundle@main/src/styles/primary/syvl.css" />
<link rel="icon" href="https://cdn.jsdelivr.net/gh/sylvorg/bundle@main/src/icons/favicons/shiny-zigzagoon-galar.ico" sizes="any" />
<link rel="icon" href="https://cdn.jsdelivr.net/gh/sylvorg/bundle@main/src/icons/favicons/shiny-zigzagoon-galar.svg" />
<link rel="manifest" href="https://cdn.jsdelivr.net/gh/sylvorg/bundle@main/manifest.json" />
Check out more styles here: https://highlightjs.org/static/demo/ Favorites include:
- https://cdn.jsdelivr.net/gh/highlightjs/[email protected]/build/styles/gradient-dark.min.css
- https://cdn.jsdelivr.net/gh/highlightjs/[email protected]/build/styles/kimbie-dark.min.css
- https://cdn.jsdelivr.net/gh/highlightjs/[email protected]/build/styles/paraiso-dark.min.css
- https://cdn.jsdelivr.net/gh/highlightjs/[email protected]/build/styles/base16/gruvbox-dark-hard.min.css
Unminify using this.
Note:
If just rel="stylesheet"
and the href
don’t work, add type="text/css"
as well.
Highlightjs theme for development:
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/gh/highlightjs/[email protected]/build/styles/paraiso-dark.min.css" />
Custom bundle of languages, built using the instructions from here:
node tools/build.js -t browser bash css diff dockerfile hy ini json lisp makefile nim nix plaintext python xml yaml
Highlightjs for development:
<script src="https://cdn.jsdelivr.net/gh/sylvorg/bundle@main/src/scripts/highlight/highlight.min.js"></script>
<script>hljs.highlightAll();</script>
<div class="header">
<h1>We Are Syvlorg.</h1>
<a href="">About Me</a>
<a href="">About This Website</a>
<a href="">About Syvlorg</a>
<a href="https://resume.syvl.org">Résumé</a>
<a href="https://index.syvl.org">Index</a>
</div>
{
"$schema": "https://json.schemastore.org/web-manifest-combined.json",
"name": "Syvl",
"short_name": "Syvl",
"start_url": ".",
"display": "standalone",
"description": "A readable Syvlorg.",
"icons": [
{ "src": "https://cdn.jsdelivr.net/gh/sylvorg/bundle@main/src/icons/favicons/shiny-zigzagoon-galar-192.png", "type": "image/png", "sizes": "192x192" },
{ "src": "https://cdn.jsdelivr.net/gh/sylvorg/bundle@main/src/icons/favicons/shiny-zigzagoon-galar-512.png", "type": "image/png", "sizes": "512x512" }
]
}
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 -0.5 68 56" shape-rendering="crispEdges">
<metadata>Made with Pixels to Svg https://codepen.io/shshaw/pen/XbxvNj</metadata>
<path stroke="#000000" d="M26 35h1M28 35h4M25 36h1M27 36h1M32 36h3M25 37h1M34 37h1M25 38h1M33 38h1M35 38h2M24 39h1M33 39h1M37 39h1M24 40h1M38 40h1M43 40h2M24 41h1M30 41h2M39 41h1M42 41h1M44 41h1M24 42h1M29 42h1M40 42h2M44 42h1M25 43h1M29 43h1M43 43h1M25 44h1M43 44h1M25 45h1M42 45h1M26 46h2M41 46h1M27 47h1M40 47h1M28 48h1M39 48h1M28 49h1M32 49h2M39 49h1M29 50h3M34 50h1M38 50h1M34 51h1M38 51h1M35 52h3" />
<path stroke="#c5e6f6" d="M26 36h1M29 36h1M27 37h4M28 38h1M31 38h1M25 39h1M30 39h1M36 39h1M34 40h1M36 40h2M33 41h3M37 41h1M25 42h1M28 42h1M33 42h1M35 42h4M42 42h1M26 43h2M34 43h2M38 43h1M40 43h2M38 44h1M41 44h2M34 45h1M38 45h2M41 45h1M34 46h2M39 46h1M38 47h1M38 48h1M34 49h1M37 49h1" />
<path stroke="#ffffff" d="M28 36h1M30 36h2M32 37h1M26 38h2M29 38h2M32 38h1M31 39h1M26 41h3M36 41h1M43 41h1M26 42h2M30 42h1M43 42h1M36 43h2M42 43h1M35 44h2M39 44h1M35 45h2M37 46h1M36 47h2M34 48h4M35 49h2M35 51h1M37 51h1" />
<path stroke="#7b94ac" d="M26 37h1M31 37h1M33 37h1M34 38h1M26 39h4M32 39h1M34 39h1M25 40h9M25 41h1M29 41h1M32 41h1M32 42h1M32 43h1M34 44h1M38 46h1M28 47h2M39 47h1M33 48h1M30 49h2M38 49h1M35 50h3" />
<path stroke="#414141" d="M35 39h1M35 40h1M38 41h1M34 42h1M39 42h1M33 43h1M39 43h1M31 44h2M37 44h1M40 44h1M29 45h2M33 45h1M37 45h1M40 45h1M28 46h2M33 46h1M36 46h1M40 46h1M30 47h1M34 47h2M29 48h3" />
<path stroke="#314183" d="M31 42h1M30 43h1" />
<path stroke="#7bbbe1" d="M28 43h1M31 43h1M26 44h5M27 45h1M31 47h3M32 48h1" />
<path stroke="#5696bc" d="M33 44h1M28 45h1M31 45h2M30 46h3" />
<path stroke="#7b7b7b" d="M26 45h1" />
<path stroke="#bdbdb4" d="M29 49h1M36 51h1" />
</svg>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 -0.5 68 56" shape-rendering="crispEdges">
<metadata>Made with Pixels to Svg https://codepen.io/shshaw/pen/XbxvNj</metadata>
<path stroke="#000000" d="M41 37h2M32 38h2M36 38h2M40 38h1M42 38h1M27 39h1M29 39h1M31 39h1M34 39h2M37 39h1M39 39h1M43 39h2M26 40h1M28 40h1M30 40h1M38 40h1M44 40h1M26 41h1M45 41h1M45 42h1M25 43h1M44 43h1M25 44h1M42 44h1M25 45h1M41 45h1M24 46h1M40 46h1M24 47h1M40 47h1M24 48h1M37 48h1M40 48h1M25 49h1M36 49h1M25 50h1M28 50h3M34 50h1M25 51h1M30 51h1M33 51h1M26 52h1M31 52h2" />
<path stroke="#d10048" d="M41 38h1M36 39h1M40 39h2M32 40h2M32 41h1M44 42h1M40 43h1M35 44h1M40 44h1M34 45h2M40 45h1" />
<path stroke="#d5004d" d="M32 39h1" />
<path stroke="#bdbebd" d="M33 39h1M38 43h1M37 44h1M36 45h2M25 48h1M36 48h1" />
<path stroke="#313031" d="M42 39h1M44 41h1M26 49h1" />
<path stroke="#ffffff" d="M27 40h1M29 40h1M35 40h1M40 40h1M27 41h1M35 41h3M41 41h2M28 42h2M33 42h1M36 42h2M27 43h4M32 43h3M36 43h1M28 44h1M30 44h4M31 45h2M25 46h2M32 46h2M26 47h1M31 47h2M26 48h2M31 48h3M39 48h1M28 49h3" />
<path stroke="#d20049" d="M31 40h1M31 41h1M38 41h2" />
<path stroke="#c0bfc0" d="M34 40h1M30 42h1M37 43h1M30 45h1" />
<path stroke="#d00047" d="M36 40h2M42 40h2M43 41h1M38 42h2M39 43h1M36 44h1" />
<path stroke="#3c3e3c" d="M39 40h1M30 41h1" />
<path stroke="#c4003b" d="M41 40h1M40 41h1M35 46h1M34 47h2M32 50h2M32 51h1" />
<path stroke="#aaaaaa" d="M28 41h1" />
<path stroke="#ca0042" d="M29 41h1M25 47h1" />
<path stroke="#424142" d="M33 41h2M31 42h2M34 42h2M40 42h2M31 43h1M35 43h1M41 43h1M34 44h1M33 45h1M34 46h1M33 47h1M32 49h2" />
<path stroke="#080808" d="M26 42h1M43 43h1" />
<path stroke="#acacac" d="M27 42h1M26 43h1" />
<path stroke="#bcc3bc" d="M42 42h1M42 43h1" />
<path stroke="#444644" d="M43 42h1" />
<path stroke="#c7003e" d="M26 44h2M26 45h2" />
<path stroke="#c6003d" d="M29 44h1M28 45h2M27 46h1M30 46h2M30 47h1M28 48h1M30 48h1" />
<path stroke="#c0bec0" d="M38 44h1" />
<path stroke="#c90040" d="M39 44h1M38 45h2" />
<path stroke="#b5b6b5" d="M41 44h1" />
<path stroke="#00afb6" d="M28 46h1M28 47h1" />
<path stroke="#ffeeff" d="M29 46h1" />
<path stroke="#bdbfbd" d="M36 46h3M39 47h1" />
<path stroke="#be0034" d="M39 46h1M36 47h3" />
<path stroke="#a8a8a8" d="M27 47h1M29 48h1" />
<path stroke="#5de4e7" d="M29 47h1" />
<path stroke="#474347" d="M34 48h2" />
<path stroke="#aaabaa" d="M38 48h1" />
<path stroke="#bababa" d="M27 49h1" />
<path stroke="#c5c5c5" d="M31 49h1" />
<path stroke="#c6c3c6" d="M34 49h1" />
<path stroke="#090409" d="M35 49h1" />
<path stroke="#000400" d="M38 49h2" />
<path stroke="#229ea4" d="M26 50h1" />
<path stroke="#6cdde3" d="M27 50h1M26 51h1" />
<path stroke="#c8003f" d="M31 50h1" />
<path stroke="#090400" d="M27 51h1" />
<path stroke="#f6fbf6" d="M31 51h1" />
</svg>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 -0.5 68 56" shape-rendering="crispEdges">
<metadata>Made with Pixels to Svg https://codepen.io/shshaw/pen/XbxvNj</metadata>
<path stroke="#000000" d="M38 33h4M37 34h1M42 34h1M36 35h1M41 35h1M36 36h1M41 36h1M37 37h1M42 37h1M28 39h1M33 39h3M44 39h1M27 40h1M29 40h1M31 40h2M44 40h1M26 41h1M30 41h1M44 41h1M26 42h1M43 42h1M25 43h1M43 43h1M24 44h1M44 44h1M24 45h1M44 45h1M23 46h1M44 46h1M23 47h1M39 47h2M43 47h1M23 48h1M28 48h1M37 48h2M41 48h2M36 49h1M24 50h1M27 50h3M34 50h1M24 51h1M26 51h1M33 51h1M25 52h1M31 52h2" />
<path stroke="#c4aab1" d="M38 34h1M38 38h1M38 39h1M28 42h2M38 44h1M38 45h2M33 47h1M31 48h1M30 49h2" />
<path stroke="#ffffff" d="M39 34h3M38 35h2M38 36h3M39 37h3M40 38h2M36 39h2M40 39h3M28 40h1M33 40h3M40 40h3M27 41h2M31 41h1M39 41h4M27 42h1M33 42h1M38 42h4M26 43h1M32 43h2M35 43h5M30 44h4M28 45h4M24 46h1M24 47h2" />
<path stroke="#c7aab3" d="M37 35h1M25 44h1M25 48h1M34 48h2" />
<path stroke="#bea1a9" d="M40 35h1M32 41h1M27 43h1" />
<path stroke="#936e79" d="M37 36h1" />
<path stroke="#d00047" d="M38 37h1M38 40h2M43 40h1M38 41h1M43 41h1M25 46h1" />
<path stroke="#181818" d="M36 38h2" />
<path stroke="#ce0046" d="M39 38h1M39 39h1M28 43h2M39 44h1M25 45h1M32 46h2M32 47h1M30 48h1" />
<path stroke="#bea2a9" d="M42 38h1" />
<path stroke="#000400" d="M43 38h1M24 49h1M35 49h1" />
<path stroke="#cb0043" d="M43 39h1" />
<path stroke="#f6fbf6" d="M36 40h1" />
<path stroke="#a27f86" d="M37 40h1" />
<path stroke="#ca0042" d="M29 41h1M33 41h1M42 42h1M42 43h1" />
<path stroke="#946d79" d="M34 41h2M27 45h1M32 50h2" />
<path stroke="#c90040" d="M36 41h2" />
<path stroke="#d10048" d="M30 42h2M30 43h1M26 44h2M40 44h3M26 45h1M40 45h3" />
<path stroke="#424142" d="M32 42h1M31 43h1M43 44h1M43 45h1M26 47h2M36 48h1M32 49h2" />
<path stroke="#be0034" d="M34 42h2M34 43h1" />
<path stroke="#d20049" d="M36 42h1M41 43h1M28 44h1M33 45h1M38 46h1M40 46h2M38 47h1" />
<path stroke="#c0a5ab" d="M37 42h1M40 43h1M29 44h1M32 45h1" />
<path stroke="#c0a5ac" d="M34 44h1M30 46h1M37 46h1M34 47h1" />
<path stroke="#d5004d" d="M35 44h1M34 45h1M31 46h1M34 46h2M31 47h1M36 47h2" />
<path stroke="#393c39" d="M36 44h1" />
<path stroke="#f7f7f7" d="M37 44h1M27 46h1" />
<path stroke="#393839" d="M35 45h1M36 46h1M30 47h1M35 47h1" />
<path stroke="#c7b0b6" d="M36 45h2" />
<path stroke="#cab2b9" d="M26 46h1" />
<path stroke="#67394a" d="M28 46h2" />
<path stroke="#3c3e3c" d="M39 46h1M41 47h1M24 48h1M25 49h1M34 49h1" />
<path stroke="#3d3e3d" d="M42 46h1" />
<path stroke="#947078" d="M43 46h1" />
<path stroke="#ffeeff" d="M28 47h1" />
<path stroke="#9b7587" d="M29 47h1" />
<path stroke="#00b0b8" d="M42 47h1" />
<path stroke="#407072" d="M26 48h1" />
<path stroke="#00d9e1" d="M27 48h1" />
<path stroke="#3f3e3f" d="M29 48h1M29 49h1" />
<path stroke="#c3a9af" d="M32 48h2" />
<path stroke="#485652" d="M26 49h2" />
<path stroke="#97707c" d="M28 49h1" />
<path stroke="#009ca4" d="M25 50h1" />
<path stroke="#00d5dd" d="M26 50h1" />
<path stroke="#413e41" d="M30 50h2" />
<path stroke="#00dbe2" d="M25 51h1" />
<path stroke="#090409" d="M30 51h1" />
<path stroke="#00e8f0" d="M31 51h1" />
<path stroke="#00767b" d="M32 51h1" />
</svg>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 -0.5 68 56" shape-rendering="crispEdges">
<metadata>Made with Pixels to Svg https://codepen.io/shshaw/pen/XbxvNj</metadata>
<path stroke="#181818" d="M30 22h3M26 23h1M28 23h2M33 23h4M24 24h2M27 24h1M37 24h1M23 25h1M36 25h1M22 26h1M37 26h2M21 27h1M39 27h1M21 28h1M40 28h1M42 28h3M21 29h1M41 29h1M45 29h1M20 30h1M46 30h1M20 31h1M46 31h1M20 32h1M46 32h1M20 33h1M25 33h1M45 33h1M46 34h1M19 35h1M46 35h1M46 36h1M19 38h1M22 38h1M26 38h2M29 38h1M44 38h1M23 39h1M28 39h1M44 39h1M25 40h1M28 40h1M43 40h1M25 41h1M29 41h1M42 41h1M22 42h1M24 42h1M30 42h1M42 42h1M23 43h1M31 43h1M43 43h1M30 44h1M35 44h3M43 44h1M30 45h1M34 45h1M44 45h1M29 46h1M34 46h1M39 46h1M45 46h1M28 47h2M34 47h1M39 47h1M45 47h1M27 48h1M33 48h1M39 48h1M46 48h1M28 49h5M40 49h1M45 49h1M40 50h1M46 50h1M40 51h1M46 51h1M41 52h5" />
<path stroke="#c52550" d="M30 23h2M28 24h2M24 25h2M28 25h2M24 26h6M32 26h4M24 27h1M26 27h4M35 27h1M22 28h5M22 29h4M21 30h4M21 31h3M21 32h2M24 32h2M21 33h1M24 33h1" />
<path stroke="#c4244f" d="M32 23h1M26 24h1M30 24h2M33 24h4M26 25h1M30 25h1M32 25h2M30 26h2M22 27h1M29 30h1M22 34h2M22 35h1" />
<path stroke="#414041" d="M32 24h1M31 25h1M23 35h1" />
<path stroke="#6f1f35" d="M27 25h1M23 26h1M23 27h1M30 32h2M32 48h1" />
<path stroke="#424142" d="M34 25h2M40 30h1M43 30h1M30 31h1M43 31h1M38 32h1M42 32h1M38 33h1M28 34h1M29 35h1M32 35h1M41 35h1M40 36h1M40 46h3M30 47h1" />
<path stroke="#a82045" d="M36 26h1M36 27h2" />
<path stroke="#d37f99" d="M25 27h1" />
<path stroke="#313031" d="M30 27h2M28 30h1M32 30h1M32 31h1M26 32h1M38 34h1M39 35h1M28 36h1M30 36h1M32 36h3M39 36h1M29 37h3M35 37h1M39 37h1M36 38h1M37 39h1M35 40h2M38 40h2M34 41h1M40 41h2M31 42h5M39 42h1M36 43h3" />
<path stroke="#ffffff" d="M32 27h3M27 28h1M30 28h2M33 28h3M26 29h2M31 29h1M34 29h2M25 30h1M24 31h2M23 32h1M22 33h2M30 33h2M21 34h1M29 34h2M20 35h1M20 36h2M42 36h1M42 37h1" />
<path stroke="#a21a3f" d="M38 27h1M38 28h2M38 29h2M34 30h3M34 31h3M28 32h2M34 32h1M28 33h2M34 33h1M27 34h1M26 35h2M31 36h1M41 36h1M43 36h1M40 37h2M43 37h1M33 38h2M34 39h2M40 39h2M43 39h1M40 40h2M40 42h2M32 43h1M40 43h3M40 44h2M40 45h2" />
<path stroke="#f7f7f7" d="M28 28h1M26 30h1M19 36h1" />
<path stroke="#292829" d="M29 28h1M28 29h1" />
<path stroke="#393839" d="M32 28h1M32 29h2M36 34h1" />
<path stroke="#f7ffff" d="M36 28h1" />
<path stroke="#a31c40" d="M37 28h1M20 37h1M39 39h1M42 44h1M42 45h1" />
<path stroke="#0c92ae" d="M29 29h1" />
<path stroke="#32b8d4" d="M30 29h1M30 30h1M39 32h1M37 34h1M36 35h1M37 36h1M32 37h1M41 47h1" />
<path stroke="#cccccc" d="M36 29h2M33 30h1M37 30h2M33 31h1M37 31h2M35 32h2M33 33h1M35 33h2M32 34h2M28 35h1M31 35h1M33 35h2M22 36h1M27 36h1M21 37h1M20 38h1M40 38h4M42 39h1M42 40h1M34 43h2M33 44h2M38 44h1M33 45h1M39 45h1" />
<path stroke="#414241" d="M40 29h1M42 29h1M42 35h2M23 38h1M41 50h5" />
<path stroke="#34bad6" d="M43 29h2M44 32h2M44 33h1M38 35h1M34 40h1M44 46h1M41 51h1M43 51h1M45 51h1" />
<path stroke="#686768" d="M27 30h1M26 31h1" />
<path stroke="#c72752" d="M31 30h1M31 31h1" />
<path stroke="#9e163b" d="M39 30h1M39 31h1M32 44h1M32 45h1" />
<path stroke="#33b9d5" d="M41 30h2M44 30h2M40 31h3M44 31h2M40 32h2M43 32h1M41 33h3M31 38h2M31 39h3M32 40h2M43 46h1M42 47h2" />
<path stroke="#212021" d="M27 31h1" />
<path stroke="#a1193d" d="M28 31h2" />
<path stroke="#34edf0" d="M27 32h1M26 33h2M26 34h1" />
<path stroke="#9e173b" d="M32 32h2M32 33h1M23 36h1M22 37h2" />
<path stroke="#c62651" d="M37 32h1" />
<path stroke="#292429" d="M37 33h1" />
<path stroke="#169cb8" d="M39 33h1M40 47h1" />
<path stroke="#1197b3" d="M40 33h1M29 36h1M28 37h1M38 37h1M30 38h1M37 38h1M30 39h1M37 40h1M32 41h2M36 41h4M36 42h3" />
<path stroke="#101410" d="M20 34h1" />
<path stroke="#4aecef" d="M24 34h1" />
<path stroke="#082821" d="M25 34h1" />
<path stroke="#393c39" d="M31 34h1M30 35h1" />
<path stroke="#c2224d" d="M34 34h2" />
<path stroke="#1399b5" d="M39 34h1M42 34h2M35 36h1M36 37h1M35 41h1M40 48h2M44 48h2" />
<path stroke="#1298b4" d="M40 34h2M44 34h2M40 35h1M44 35h2M28 38h1M29 39h1M30 40h2M30 41h1M30 46h4M31 47h3M28 48h2M42 48h2" />
<path stroke="#cc2c57" d="M21 35h1" />
<path stroke="#324d4e" d="M24 35h2" />
<path stroke="#292021" d="M35 35h1" />
<path stroke="#014d5e" d="M37 35h1M36 36h1M37 37h1M29 40h1M31 41h1M42 51h1M44 51h1" />
<path stroke="#101010" d="M18 36h1M18 37h1" />
<path stroke="#174749" d="M24 36h1" />
<path stroke="#fff7ff" d="M25 36h1M24 37h1" />
<path stroke="#9f173c" d="M26 36h1M26 37h1" />
<path stroke="#474547" d="M38 36h1" />
<path stroke="#ae0e39" d="M44 36h1M44 37h1M41 49h1M44 49h1" />
<path stroke="#0f95b1" d="M45 36h1" />
<path stroke="#c82853" d="M19 37h1" />
<path stroke="#608384" d="M25 37h1" />
<path stroke="#100c08" d="M27 37h1" />
<path stroke="#a51d42" d="M33 37h1M36 39h1M39 43h1" />
<path stroke="#ff618c" d="M34 37h1" />
<path stroke="#181418" d="M45 37h1M20 39h2M22 40h1M22 41h1M38 45h1" />
<path stroke="#4f5154" d="M21 38h1" />
<path stroke="#5bc8cc" d="M24 38h1" />
<path stroke="#44797b" d="M25 38h1" />
<path stroke="#df3f6a" d="M35 38h1" />
<path stroke="#313131" d="M38 38h1M38 39h1" />
<path stroke="#413f41" d="M39 38h1" />
<path stroke="#71f2f4" d="M24 39h1M23 41h1" />
<path stroke="#081810" d="M25 39h1" />
<path stroke="#53cbcf" d="M23 40h1" />
<path stroke="#79f2f5" d="M24 40h1M24 41h1M23 42h1" />
<path stroke="#aa3e5b" d="M33 43h1" />
<path stroke="#9c1438" d="M31 44h1M31 48h1" />
<path stroke="#b56379" d="M39 44h1" />
<path stroke="#1096b2" d="M31 45h1M30 48h1" />
<path stroke="#3e3b3e" d="M43 45h1" />
<path stroke="#0a90ac" d="M44 47h1" />
<path stroke="#a82044" d="M42 49h2" />
</svg>
Adapted from the following:
Note:
More settings can be found here.
/* @import url('https://fonts.googleapis.com/css?family=Source+Code+Pro:200,300,400'); */
:root {
--font-size-1: 2rem;
--font-size-2: 1.5rem;
--font-size-3: 1.25rem;
--font-size-4: 1rem;
--font-size-small: 0.5rem;
--font-size-xsmall: 0.25rem;
--margins: 5rem;
--smaller-margins: 2.5rem;
--padding: 1rem;
--header-padding: 0.25rem;
--background-color: #222222;
--dracula-orange: #ffb86c;
--exo-ui-red: #ff5156;
--joker-purple: #be80ff;
--acid-green: #DFFF00;
}
.header {
text-align: center;
background: var(--background-color);
font-size: var(--font-size-3);
border-bottom: 1px solid var(--dracula-orange);
padding-bottom: var(--padding);
}
/* More information [[https://developer.mozilla.org/en-US/docs/Web/CSS/:not][here]]: */
.header>a:not(:last-child)::after {
content: " |";
}
.header > a:link {
color: var(--joker-purple);
display: inline;
text-decoration: none;
}
html,
body {
background-color: var(--background-color);
font-family: "Courier New", monospace;
font-weight: 100;
color: var(--joker-purple);
}
@media only screen and (min-width: 750px) /* Large screens */
{
html,
body {
margin-left: var(--margins);
margin-right: var(--margins);
}
}
@media only screen and (max-width: 750px) /* Small screens */
{
html,
body {
margin-left: var(--smaller-margins);
margin-right: var(--smaller-margins);
}
}
::selection {
background-color: var(--dracula-orange);
color: var(--background-color);
}
h1 {
font-size: var(--font-size-1);
}
h2 {
font-size: var(--font-size-2);
}
h1>.subtitle,
h3,
h4,
h5 {
font-size: var(--font-size-3);
}
h1,
h2,
h3,
h4,
h5,
h6 {
font-weight: 300;
letter-spacing: -0.03em;
color: var(--dracula-orange);
}
h2,
h3,
h4,
h5,
h6 {
border-bottom: 1px solid var(--joker-purple);
width: fit-content;
padding-bottom: var(--header-padding);
}
#table-of-contents {
padding-bottom: var(--padding);
border-bottom: 1px solid var(--dracula-orange);
}
#table-of-contents ul,
#table-of-contents li {
list-style-type: none;
margin-top: var(--header-padding);
margin-bottom: var(--header-padding);
}
#table-of-contents .tag {
float: right;
}
#table-of-contents a:link {
text-decoration: none;
color: var(--joker-purple);
}
#table-of-contents a:hover {
color: var(--exo-ui-red);
}
img {
max-width: 100%;
}
blockquote {
border-left: 0.2rem solid var(--dracula-orange);
padding-left: 1rem;
font-style: italic;
}
/* Adapted from [[https://css-tricks.com/forums/topic/need-help-to-override-font-color-for-blockquote/#post-99908][here]], and [[https://stackoverflow.com/users/3444240/potashin][potashin's]] answer [[https://stackoverflow.com/a/23631478/10827766][here]]: */
blockquote>p {
color: var(--exo-ui-red);
}
p,
pre,
ol,
ul,
table,
code {
color: var(--dracula-orange);
}
.done,
.priority,
.tag,
.todo,
code {
color: var(--background-color);
position: relative;
bottom: .1rem;
font-size: 80%;
}
.done,
.priority,
.todo,
code {
font-weight: 400;
background-clip: padding-box;
font-family: "Courier New", monospace;
font-weight: bold;
line-height: 1
}
.done,
.priority,
.tag>span,
.todo,
code {
border-radius: 3px;
padding-top: .1rem;
padding-left: .3rem;
padding-right: .3rem;
line-height: 1;
}
.priority,
.tag>span,
.todo,
code {
background-image: linear-gradient(160deg, var(--dracula-orange), var(--exo-ui-red));
}
td > code {
background-image: linear-gradient(160deg, var(--dracula-orange), var(--joker-purple));
}
/* ~.on>code~ refers to a checkbox's checked state; ~.off>code~ refers to the opposite. */
.on>code,
.done {
background-image: linear-gradient(160deg, var(--dracula-orange), var(--joker-purple));
}
.tag {
top: .1rem;
display: block;
float: right;
font-weight: 550;
}
.tag>span {
text-transform: uppercase;
}
table,
#table-of-contents {
margin-bottom: var(--padding);
}
/* Even Table Row */
tr:nth-child(even) {
background-color: #2f1e2e;
}
.org-org-meta-line,
.org-keyword {
color: var(--dracula-orange);
}
a:link,
a:hover,
a:visited,
a:visited:hover {
text-decoration: none;
}
a:link {
color: var(--acid-green);
}
a:visited {
color: var(--joker-purple);
}
/* Adapted from [[https://stackoverflow.com/users/3246606/harry-the-mad-lurker][Harry The Mad Lurker's]] answer [[https://stackoverflow.com/a/21977877/10827766][here]]: */
a:hover,
a:visited:hover {
color: var(--exo-ui-red);
}
/* Adapted from [[https://css-tricks.com/forums/topic/need-help-to-override-font-color-for-blockquote/#post-99908][here]], and [[https://stackoverflow.com/users/3444240/potashin][potashin's]] answer [[https://stackoverflow.com/a/23631478/10827766][here]]: */
#postamble :not(:last-child)::after {
content: " |";
}
#postamble>p {
display: inline;
}
#postamble {
text-align: center;
width: 100%;
font-size: var(--font-size-4)
}
.status {
padding: var(--padding);
border-top: 1px solid var(--dracula-orange);
text-align: center;
}
.outline-text-2,
.outline-text-3,
.outline-text-4 {
max-width: 100%;
overflow-x: auto;
}
.underline {
text-decoration: var(--exo-ui-red) wavy underline;
}
del {
text-decoration: var(--joker-purple) wavy line-through;
}
Alpha levels for hex colors can be set using the guide here; alpha hex codes can be found on Jared Rummler’s answer here.
Regular expressions adapted from levik’s answer here.
Peach gradient colorscheme can be found here:
Color | HEX |
---|---|
Tulip | #F48191 |
Dark Salmon | #EF9188 |
Tumbleweed | #EDA58B |
Peach-Orange | #F2BB9B |
Apricot | #FBCCB2 |
pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}.hljs{border-radius:0.2rem;background-color:#652487;background-image:linear-gradient(160deg,#F48191,#EF9188,#EDA58B,#F2BB9B,#FBCCB2);color:#222222}.hljs-subtr{color:#e7e4eb}.hljs-comment,.hljs-doctag,.hljs-meta,.hljs-quote{color:#af8dd9}.hljs-attr,.hljs-regexp,.hljs-selector-id,.hljs-selector-tag,.hljs-tag,.hljs-template-tag{color:#aefbff}.hljs-bullet,.hljs-params,.hljs-selector-class{color:#f19fff}.hljs-keyword,.hljs-meta .hljs-keyword,.hljs-section,.hljs-symbol,.hljs-type{color:#17fc95}.hljs-addition,.hljs-link,.hljs-number{color:#c5fe00}.hljs-string{color:#38c0ff}.hljs-addition,.hljs-attribute{color:#e7ff9f}.hljs-template-variable,.hljs-variable{color:#e447ff}.hljs-built_in,.hljs-class,.hljs-formula,.hljs-function,.hljs-name,.hljs-title{color:#ffc800}.hljs-deletion,.hljs-literal,.hljs-selector-pseudo{color:#ff9e44}.hljs-emphasis,.hljs-quote{font-style:italic}.hljs-keyword,.hljs-params,.hljs-section,.hljs-selector-class,.hljs-selector-id,.hljs-selector-tag,.hljs-strong,.hljs-template-tag{font-weight:700}
diff --git a/nixos/modules/tasks/filesystems/bcachefs.nix b/nixos/modules/tasks/filesystems/bcachefs.nix
index 5fda24adb97..897ddf03927 100644
--- a/nixos/modules/tasks/filesystems/bcachefs.nix
+++ b/nixos/modules/tasks/filesystems/bcachefs.nix
@@ -45,7 +45,7 @@ in
system.fsPackages = [ pkgs.bcachefs-tools ];
# use kernel package with bcachefs support until it's in mainline
- boot.kernelPackages = pkgs.linuxPackages_testing_bcachefs;
+ # boot.kernelPackages = pkgs.linuxPackages_testing_bcachefs;
}
(mkIf ((elem "bcachefs" config.boot.initrd.supportedFilesystems) || (bootFs != {})) {
diff --git a/lib/licenses.nix b/lib/licenses.nix
index 4fa6d6abc7a..198b570e0ae 100644
--- a/lib/licenses.nix
+++ b/lib/licenses.nix
@@ -690,6 +690,11 @@ in mkLicense lset) ({
fullName = "OpenSSL License";
};
+ oreo = {
+ fullName = "Oreo Public License";
+ free = true;
+ };
+
osl2 = {
spdxId = "OSL-2.0";
fullName = "Open Software License 2.0";
diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix
index 7b9c55ee702..4c86533cad5 100644
--- a/pkgs/top-level/aliases.nix
+++ b/pkgs/top-level/aliases.nix
@@ -1154,10 +1154,10 @@ mapAliases ({
pyrex095 = throw "pyrex has been removed from nixpkgs as the project is still stuck on python2"; # Added 2022-01-12
pyrex096 = throw "pyrex has been removed from nixpkgs as the project is still stuck on python2"; # Added 2022-01-12
pyrit = throw "pyrit has been removed from nixpkgs as the project is still stuck on python2"; # Added 2022-01-01
- python = python2; # Added 2022-01-11
+ python = python3; # Added 2022-01-11
python-swiftclient = swiftclient; # Added 2021-09-09
python2nix = throw "python2nix has been removed as it is outdated. Use e.g. nixpkgs-pytools instead"; # Added 2021-03-08
- pythonFull = python2Full; # Added 2022-01-11
+ pythonFull = python3Full; # Added 2022-01-11
pythonPackages = python.pkgs; # Added 2022-01-11
### Q ###
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 1803508bdd4..da416ccaea6 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -14502,7 +14502,7 @@ with pkgs;
# available as `pythonPackages.tkinter` and can be used as any other Python package.
# When switching these sets, please update docs at ../../doc/languages-frameworks/python.md
python2 = python27;
- python3 = python39;
+ python3 = python310;
# pythonPackages further below, but assigned here because they need to be in sync
python2Packages = dontRecurseIntoAttrs python27Packages;
diff --git a/pkgs/development/python-modules/hy/default.nix b/pkgs/development/python-modules/hy/default.nix
index a962f868..a84a95ac 100644
--- a/pkgs/development/python-modules/hy/default.nix
+++ b/pkgs/development/python-modules/hy/default.nix
@@ -16,18 +16,22 @@
buildPythonPackage rec {
pname = "hy";
- version = "1.0a4";
+ version = "0.24.0";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
- owner = "hylang";
- repo = pname;
- rev = version;
- sha256 = "sha256-MBzp3jqBg/kH233wcgYYHc+Yg9GuOaBsXIfjFDihD1E=";
+ owner = "hylang";
+ repo = pname;
+ rev = version;
+ sha256 = "1s458ymd9g3s8k2ccc300jr4w66c7q3vhmhs9z3d3a4qg0xdhs9y";
};
+ postPatch = ''substituteInPlace setup.py --replace "\"funcparserlib ~= 1.0\"," ""'';
+
+ disabledTestPaths = [ "tests/test_bin.py" ];
+
# https://github.com/hylang/hy/blob/1.0a4/get_version.py#L9-L10
HY_VERSION = version;
Adapted from here:
use strict;
use File::Find;
use File::Copy;
use File::Path;
use File::Basename;
use File::Slurp;
my $var = $ARGV[0] or die;
my $static = "/var/static";
sub atomicSymlink {
my ($source, $target) = @_;
my $tmp = "$target.tmp";
unlink $tmp;
symlink $source, $tmp or return 0;
rename $tmp, $target or return 0;
return 1;
}
# Atomically update /var/static to point at the var files of the
# current configuration.
atomicSymlink $var, $static or die;
# Returns 1 if the argument points to the files in /var/static. That
# means either argument is a symlink to a file in /var/static or a
# directory with all children being static.
sub isStatic {
my $path = shift;
if (-l $path) {
my $target = readlink $path;
return substr($target, 0, length "/var/static/") eq "/var/static/";
}
if (-d $path) {
opendir DIR, "$path" or return 0;
my @names = readdir DIR or die;
closedir DIR;
foreach my $name (@names) {
next if $name eq "." || $name eq "..";
unless (isStatic("$path/$name")) {
return 0;
}
}
return 1;
}
return 0;
}
# Remove dangling symlinks that point to /var/static. These are
# configuration files that existed in a previous configuration but not
# in the current one. For efficiency, don't look under /var/nixos
# (where all the NixOS sources live).
sub cleanup {
if ($File::Find::name eq "/var/nixos") {
$File::Find::prune = 1;
return;
}
if (-l $_) {
my $target = readlink $_;
if (substr($target, 0, length $static) eq $static) {
my $x = "/var/static/" . substr($File::Find::name, length "/var/");
unless (-l $x) {
print STDERR "removing obsolete symlink ‘$File::Find::name’...\n";
unlink "$_";
}
}
}
}
find(\&cleanup, "/var");
# Use /var/.clean to keep track of copied files.
my @oldCopied = read_file("/var/.clean", chomp => 1, err_mode => 'quiet');
open CLEAN, ">>/var/.clean";
# For every file in the var tree, create a corresponding symlink in
# /var to /var/static. The indirection through /var/static is to make
# switching to a new configuration somewhat more atomic.
my %created;
my @copied;
sub link {
my $fn = substr $File::Find::name, length($var) + 1 or next;
my $target = "/var/$fn";
File::Path::make_path(dirname $target);
$created{$fn} = 1;
# Rename doesn't work if target is directory.
if (-l $_ && -d $target) {
if (isStatic $target) {
rmtree $target or warn;
} else {
warn "$target directory contains user files. Symlinking may fail.";
}
}
if (-e "$_.mode") {
my $mode = read_file("$_.mode"); chomp $mode;
if ($mode eq "direct-symlink") {
atomicSymlink readlink("$static/$fn"), $target or warn;
} else {
my $uid = read_file("$_.uid"); chomp $uid;
my $gid = read_file("$_.gid"); chomp $gid;
copy "$static/$fn", "$target.tmp" or warn;
$uid = getpwnam $uid unless $uid =~ /^\+/;
$gid = getgrnam $gid unless $gid =~ /^\+/;
chown int($uid), int($gid), "$target.tmp" or warn;
chmod oct($mode), "$target.tmp" or warn;
rename "$target.tmp", $target or warn;
}
push @copied, $fn;
print CLEAN "$fn\n";
} elsif (-l "$_") {
atomicSymlink "$static/$fn", $target or warn;
}
}
find(\&link, $var);
# Delete files that were copied in a previous version but not in the
# current.
foreach my $fn (@oldCopied) {
if (!defined $created{$fn}) {
$fn = "/var/$fn";
print STDERR "removing obsolete file ‘$fn’...\n";
unlink "$fn";
}
}
# Rewrite /var/.clean.
close CLEAN;
write_file("/var/.clean", map { "$_\n" } @copied);
# Create /var/NIXOS tag if not exists.
# When /var is not on a persistent filesystem, it will be wiped after reboot,
# so we need to check and re-create it during activation.
open TAG, ">>/var/NIXOS";
close TAG;
Note:
Deprecated
Adapted from the following places:
- https://www.systutorials.com/how-to-get-the-full-path-and-directory-of-a-makefile-itself/
- https://t-ravis.com/post/nix/nix-make/
- this answer by arielf
- this answer by MadScientist
- https://gist.github.com/weshouman/f44f330227972073371e1baa510c0d37
- this answer by RomanPerekhrest
- this answer by Eric Melski
- this answer by Maxim Egorushkin
Note:
To export an environment variable for a single, multi-command command, use this answer by 0xC0000022L.
.RECIPEPREFIX := |
.DEFAULT_GOAL := tangle
.ONESHELL:
mkfilePath := $(abspath $(lastword $(MAKEFILE_LIST)))
mkfileDir := $(dir $(mkfilePath))
realfileDir := $(realpath $(mkfileDir))
preFiles := $(mkfileDir)/nix.org $(mkfileDir)/flake.org $(mkfileDir)/tests.org $(mkfileDir)/README.org
removeTangleBackups := find $(mkfileDir) -name '.\#*.org*' -print | xargs rm &> /dev/null || :
define fallbackCommand
$(removeTangleBackups)
$1
if [ $$? -ne 0 ]; then
org-tangle -f $2 > /dev/null
$1
fi
endef
define preFallback
$(call fallbackCommand,$1,$(preFiles))
endef
define nixShell
nix-shell -E '(import $(realfileDir)).devShells.$${builtins.currentSystem}.makefile-$1' --show-trace --run
endef
define quickShell
nix-shell -E 'with (import $(realfileDir)).pkgs.$${builtins.currentSystem}; with lib; mkShell { buildInputs = flatten [ $1 ]; }' --show-trace
endef
projectName := $(subst ",,$(shell $(call preFallback,nix eval --show-trace --impure --expr '(import $(realfileDir)).pname')))
ifndef projectName
$(error Sorry; unable to get the name of the project)
endif
type := $(subst ",,$(shell $(call preFallback,nix eval --show-trace --impure --expr '(import $(realfileDir)).type')))
ifndef type
$(error Sorry; unable to get the type of project)
endif
files := $(preFiles) $(mkfileDir)/$(projectName)
define fallback
$(call fallbackCommand,$1,$(files))
endef
addCommand := git -C $(mkfileDir) add .
updateCommand := $(call fallback,nix flake update --show-trace $(realfileDir))
define tangleCommand
$(removeTangleBackups)
$(call nixShell,general) "org-tangle -f $1"
if [ $$? -ne 0 ]; then
org-tangle -f $1
fi
$(addCommand)
endef
define wildcardValue
$(shell echo $1 | cut -d "-" -f2-)
endef
add:
|$(addCommand)
commit: | add
|git -C $(mkfileDir) commit --allow-empty-message -am ""
push: | commit
|git -C $(mkfileDir) push
update: | add
ifeq ($(projectName), bundle)
|$(shell $(call fallback,nix eval --impure --expr 'with (import $(realfileDir)); with pkgs.$${builtins.currentSystem}.lib; "nix flake lock $(realfileDir) --update-input $${concatStringsSep " --update-input " (filter (input: ! ((elem input [ "nixos-master" "nixos-unstable" ]) || (hasSuffix "-small" input))) (attrNames inputs))}"' | tr -d '"'))
else
|$(updateCommand)
endif
update-%: updateInput := nix flake lock $(realfileDir) --show-trace --update-input
update-%: | add
|$(eval input := $(call wildcardValue,$@))
|if [ "$(input)" == "bundle" ] && [ "$(projectName)" != "bundle" ]; then
| $(call fallback,$(updateInput) $(input))
|elif [ "$(input)" == "all" ]; then
| $(updateCommand)
|else
| $(call fallback,$(updateInput) $(input))
|fi
pre-tangle: | bundle-up
|$(removeTangleBackups)
tangle: | pre-tangle
|$(call tangleCommand,$(files))
tangle-%: | pre-tangle
|$(eval file := $(mkfileDir)/$(call wildcardValue,$@).org)
|$(call tangleCommand,$(file))
tu: | tangle update
tu-%: | tangle update-% ;
develop: | tu
|nix develop --show-trace "$(realfileDir)#makefile-$(type)"
shell: | tu
|$(call quickShell,$(pkgs))
shell-%: | tu
|$(call quickShell,(with $(call wildcardValue,$@); [ $(pkgs) ]))
develop-%: | tu
|nix develop --show-trace "$(realfileDir)#$(call wildcardValue,$@)"
repl: | tu
|$(call nixShell,$(type)) "$(type)"
build: | tu
|nix build --show-trace "$(realfileDir)"
build-%: | tu
|nix build --show-trace "$(realfileDir)#$(call wildcardValue,$@)"
run: | tu
|cd $(mkfileDir)
|$(call nixShell,$(type)) "$(command)"
run-%: | tu
|nix run --show-trace "$(realfileDir)#$(call wildcardValue,$@)" -- $(args)
rund: | run-default
define touch-test-command
cd $(mkfileDir)
$(call nixShell,$(type)) "touch $1 && $(type) $1"
endef
touch-test: | tu
|$(call touch-test-command,$(file))
touch-test-%: | tu
|$(eval file := $(mkfileDir)/$(call wildcardValue,$@))
|$(call touch-test-command,$(file))
quick: | tangle push
super: | tu push
super-%: | tu-% push ;
nix flake lock --update-input valiant
use nix
**/__pycache__
**/_build
**/.#*
**/.cask
**/.coverage
**/.DS_Store
**/.mypy_cache
**/.pytest_cache
**/.vscode
**/.zfs/snapshot
**/*-autoloads.el
**/*-pkg.el
**/*.!sync
**/*.bts
**/*.direnv
**/*.egg-info
**/*.elc
**/*.envrc:*
**/*.swp
**/*.sync
**/*.tmp
**/*~
**/#*#
**/build
**/deprecated
**/dist
**/result
**/result-*
**/unfinished
/_gsdata_
/.boar
/.git
/.hg
/.nixstore
/etc/nixos/configuration.nix
/etc/nixos/hardware-configuration.nix
temp
#+setupfile: ./README.org
(format "* .envrc
#+begin_src shell :tangle (meq/tangle-path)
<<envrc>>
#+end_src
* shell.nix
Adapted from [[https://github.com/edolstra/flake-compat#usage][here]]:
#+begin_src nix :tangle (meq/tangle-path)
<<shell.nix(elisp='t)>>
#+end_src
* default.nix
Adapted from [[https://github.com/edolstra/flake-compat#usage][here]]:
#+begin_src nix :tangle (meq/tangle-path)
<<default.nix(elisp='t)>>
#+end_src
* flake.nix
#+begin_src nix :tangle (meq/tangle-path)
{
nixConfig = {
<<generate-nix-conf(flake='t, elisp='t)>>
};
# TODO: Change this!
description = \"\";
inputs = rec {
bundle = {
url = %s;
type = \"git\";
submodules = true;
};
valiant.follows = \"bundle/valiant\";
nixpkgs.follows = \"bundle/nixpkgs\";
%s
flake-utils.url = github:numtide/flake-utils;
flake-compat = {
url = \"github:edolstra/flake-compat\";
flake = false;
};
};
outputs = inputs@{ self, flake-utils, ... }:
with builtins;
with inputs.bundle.lib;
with flake-utils.lib;
inputs.bundle.mkOutputs.%s {
inherit inputs self;
# TODO: Change this!
pname = \"\";
# TODO: Change this!
callPackage = %s
} { %s};
}
#+end_src" (format "%sinput-path-exists(path=\"./bundle\", url=\"https://github/sylvorg/bundle\", submodule='t)>>" "<<")
(cond ((string= group "python")
(format "\n pyPkg-oreo.url = %sinput-path-exists(path=\"../oreo\", url=\"github:syvlorg/oreo\")%s;\n"
"<<"
">>"))
((string= group "emacs")
(format "\n ePkg-meq = {
url = %sinput-path-exists(path=\"../meq\", url=\"github:syvlorg/meq\")%s;\n
inputs.bundle.follows = "bundle";
inputs.valiant.follows = "valiant";
inputs.nixpkgs.follows = "nixpkgs";
inputs.flake-utils.follows = "flake-utils";
inputs.flake-compat.follows = "flake-compat";
};"
"<<"
">>"))
(t ""))
group
(cond ((string= group "python") "{ callPackage, oreo }: callPackage (iron.mkPythonPackage {
inherit self inputs;
package = rec {
# TODO: Change this!
owner = "";
src = ./.;
postPatch = ''
substituteInPlace pyproject.toml \
--replace \"oreo = { git = \\\"https://github.com/syvlorg/oreo.git\\\", branch = \\\"main\\\" }\" \"\"
substituteInPlace setup.py \
--replace \"'oreo @ git+https://github.com/syvlorg/oreo.git@main'\" \"\" || :
'';
# TODO: Change this!
meta.description = \"\";
};
})) {};")
((string= group "emacs") "{ emacs }: iron.mkEmacsPackage {
inherit self inputs;
package = rec {
src = ./.;
meta = {
# TODO: Change this!
description = \"\";
};
};
};")
(t "{ pname }: { };"))
(if (string= isApp "") "" (format "isApp = %s; " isApp))
)
<<97220a9c-af77-4056-b7f8-00e11819e210()>>
<<97220a9c-af77-4056-b7f8-00e11819e210(group="emacs")>>
Note:
Deprecated
Adapted from Joshua’s answer here, Notinlist’s answer here, and here:
<<makefile>>
poetry2setup: | tu
|cd $(mkfileDir)
|$(call nixShell,$(type)) "poetry2setup > $(mkfileDir)/setup.py"
touch-tests:
|-find $(mkfileDir)/tests -print | grep -v __pycache__ | xargs touch
tut: | tu touch-tests
define pytest
$(call nixShell,$(type)) "pytest $1 --suppress-no-test-exit-code $(mkfileDir)"
endef
test: | tut
|$(call pytest)
test-native: | tut
|$(call pytest,--tb=native)
test-%: | tut
|$(call pytest,-m $(call wildcardValue,$@))
super: | test push
#+property: header-args:py+ :shebang "#!/usr/bin/env python3"
<<58ec738d-82a0-492c-95da-c7b5211864e7>>
** Click Application
*** Imports
#+begin_src py
from addict import Dict
#+end_src
*** Main
#+begin_src py
if __name__ == "__main__":
main(obj=Dict())
#+end_src
<<a29d4c8d-f422-4bf9-8ec7-7774d935e7de>>
* Application Imports
#+begin_src hy
(import click)
#+end_src
* Click
[tool.poetry]
# Change this!
name = ""
version = "1.0.0.0"
# Change this!
description = ""
authors = ["sylvorg <[email protected]>"]
license = "MIT"
# Change this!
include = [
"[...]/**/*.py",
"[...]/**/*.hy",
]
[tool.poetry.dependencies]
python = ">=3.9,<3.11"
oreo = { git = "https://github.com/syvlorg/oreo.git", branch = "main" }
[tool.poetry.dev-dependencies]
pytest = "^3.0"
poetry = "*"
poetry2setup = "*"
pytest-custom-exit-code = "*"
pytest-drop-dup-tests = "*"
pytest-hy = { git = "https://github.com/syvlorg/pytest-hy.git", branch = "master" }
pytest-ignore = { git = "https://github.com/syvlorg/pytest-ignore.git", branch = "main" }
pytest-order = "*"
pytest-parametrized = "*"
pytest-randomly = "*"
pytest-repeat = "*"
pytest-sugar = "*"
pytest-xdist = "*"
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.pytest.ini_options]
addopts = [
"--strict-markers",
]
markers = [
]
<<97220a9c-af77-4056-b7f8-00e11819e210(group="python", isApp="true")>>
#+property: header-args:py+ :tangle yes
* Rich Traceback
#+begin_src py
import rich.traceback as RichTraceback
RichTraceback.install(show_locals = True)
#+end_src
* Imports
#+begin_src py
import hy
#+end_src
# TODO: Change this!
** Everything From [...]
Adapted from [[https://github.com/hylang/hyrule/blob/master/hyrule/__init__.py][here]],
with help from [[https://stackoverflow.com/users/1451346/kodiologist][Kodiologist's]] comment
[[https://stackoverflow.com/questions/73030667/init-py-for-hy-modules-with-relative-imports#comment128994796_73030667][here]]:
# TODO: Change this!
#+begin_src py
hy.macros.require('[...].[...]',
# The Python equivalent of `(require [...].[...] *)`
None, assignments = 'ALL', prefix = '')
hy.macros.require_reader('[...].[...]', None, assignments = 'ALL')
from [...].[...] import *
#+end_src
#+property: header-args:hy+ :tangle yes
* Rich Traceback
#+begin_src hy
(import rich.traceback)
(.install rich.traceback :show-locals True)
#+end_src
* Imports
#+begin_src hy
#+end_src
* Eval and Compile
#+begin_src hy
(eval-and-compile (import os hy))
#+end_src
** From
#+begin_src hy
(import rich [print])
(import rich.pretty [pprint])
#+end_src
*** Coconut
[[https://coconut.readthedocs.io/en/latest/index.html][Coconut]]:
#+begin_src hy
(try (import coconut *)
(except [ImportError] None))
#+end_src
*** Toolz
[[https://github.com/pytoolz/toolz][Toolz]] and [[https://github.com/pytoolz/cytoolz/][CyToolz]]:
#+begin_src hy
(try (import cytoolz [first])
(except [ImportError]
(import toolz [first])))
#+end_src
* Requires
#+begin_src hy
(require hyrule [-> assoc unless])
#+end_src
<<97220a9c-af77-4056-b7f8-00e11819e210(group="python")>>
Adapted from here:
(format-spec "with builtins;
if (builtins ? getFlake) then
(getFlake (toString ./.))
else
(import fetchTarball (let
lockExists = pathExists ./flake.lock;
lock = if lockExists then
(fromJSON (readFile ./flake.lock))
else {
nodes.flake-compat.locked.rev = %qmaster%q;
};
in {
url =
%qhttps://github.com/edolstra/flake-compat/archive/${lock.nodes.flake-compat.locked.rev}.tar.gz%q;
${if lockExists then %qsha256%q else null} =
lock.nodes.flake-compat.locked.narHash;
}) { src = ./.; }).defaultNix" `((?q . ,(if elisp "\\\"" "\""))))
<<default.nix()>>
(format-spec "with builtins;
let
this-flake = import ./.;
flake =
this-flake.inputs.valiant or this-flake.inputs.bundle.inputs.valiant or (if (builtins
? getFlake) then
(getFlake %qgithub:syvlorg/valiant%q)
else
(import fetchTarball (let
lockExists = pathExists ./flake.lock;
lock = if lockExists then
(fromJSON (readFile ./flake.lock))
else {
nodes.valiant.locked.rev = %qmain%q;
};
in {
url =
%qhttps://github.com/syvlorg/valiant/archive/${lock.nodes.valiant.locked.rev}.tar.gz%q;
${if lockExists then %qsha256%q else null} =
lock.nodes.valiant.locked.narHash;
}) { src = ./.; }).defaultNix);
inherit (flake.${currentSystem}) pkgs;
in with pkgs;
mkShell rec {
buildInputs = [ valiant ];
nativeBuildInputs = buildInputs;
}" `((?q . ,(if elisp "\\\"" "\""))))
<<shell.nix()>>
**/*.*~
**/*.direnv
**/*.envrc:*
node_modules/
package-lock.json
package.json
These are just a few blocks I use regularly in my org
files, whether in noweb
, naming, or otherwise:
sylvorg
"https://github.com/<<username>>/<<username>>.git"
/home/<<username>>
aiern
<<userhome>>/<<reponame>>
[email protected]
(system-name)
{
"primary": "<<username>>",
"secondary": "frost",
"nightingale": "curtis"
}
{
"primary": "<<userhome>>",
"secondary": "/home/frost",
"nightingale": "/home/curtis"
}
Adapted from Timo Tijhof’s answer here:
dig @ns1.google.com TXT o-o.myaddr.l.google.com +short -4 | tr -d '"' 2> /dev/null || \
dig @resolver3.opendns.com myip.opendns.com +short -4 2> /dev/null || \
dig @resolver4.opendns.com myip.opendns.com +short -4 2> /dev/null || \
dig @ns1-1.akamaitech.net ANY whoami.akamai.net +short -4 2> /dev/null
(shell-command-to-string (concat "dig @ns1.google.com TXT o-o.myaddr.l.google.com +short -4 | tr -d '\"' 2> /dev/null || "
"dig @resolver3.opendns.com myip.opendns.com +short -4 2> /dev/null || "
"dig @resolver4.opendns.com myip.opendns.com +short -4 2> /dev/null || "
"dig @ns1-1.akamaitech.net ANY whoami.akamai.net +short -4 2> /dev/null"))
(file-name-nondirectory buffer-file-name)
age137rleywjdkw7xj2aznfjnh0vf2zlcgmav0pfzgyee5hjd9v3v5ps22qr9x
age1yubikey1q22qkx8636cd0ryacyz9t0f27lg5ezd9fr98zccpqlehxwcw9dxwgg5at4p
age1dmc4aw6sgwdf2e89ej9fya9vzq7ysdynw84wr35d6fca62vngc8ssgg3cu
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDlwBJ7E2qeqw9kMW19indbeLdnEKs/Yrhn9HE0c/gZDzvXYBPQYyf5xr9I9kYxWcHlqp7XEI0LVT4DCA/mgemQtM8ulc1mxwekKtk64uWRi5wLi1E17NWKJfXWRn8XZejwi0iJa0twwVE8m8G2AuFOCSa86sYD3x5X5W+7spAuNET7kl0DLueUHu1u31c7HE1ciV2tIn/f60/bbgEJm9MPcRVZkRxkp+bouaZ1cjWRYDhvyJS30DRhBYtIIort2XVAshQs2Y58oKeCDnjt0gxotfqqWlt4nTQzKtbSN2M6/M+clFQBdT1oUJqpTUJbVxK8+xSEOJcBubupTj0USpmftDf/3WMoMwq+hNEc9C0EN1BYtKk68QWhAz8NROvnx7h6y3UKejhQOg0ueNZggmeNJLbebEs46QmA92khO8zc2pfBRsEa5yP0IgdvWpruTZ1QwjqhGQqGnCw3Oli1PK+5zgT2vXy5yHl3f3duPq8h+LOc+lSBbi2jjkC0gwTQDDDNyzFZ+U9xF7fCmL3V8DCEeO/4HqVxmLJir2TVEDo/3Ug/Q22Yp7P2EZrI2pikZIyBJc5aZJO3d7nGoDB/1BJp9Qm82wvyEpjiOnxHsL4osUqrf401XbiwNqpFkVUoRZkwGraJnrlsYkdHS2Mrrny9sr+PtgZhTjqIuW8z6iVIfQ== [email protected]
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIO8NzKV52dRBAir8ARoFJX/xQDVCNup6xe1ddX1YVXSO [email protected]
ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBGsRy6rLDzmLNISdWahFLGDo+ZZLbndj6k8Q8MUQum/mPAzy8lsAQz/0XiicJz7LlM74tWGDYSJG1Ay2Iyc/ew4= [email protected]
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICor+WXoAypnk5rkgTljAN6kk8olvKWqtnmGWVuQu8z9 [email protected]
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCs4zqEt/Fkjw0LVQTwJXlovmnqqGWC4UOVPvoLDvo0JD6WeVBDi4cFPX2mpNJYmYJsBLDXeUq5XrQ1ST3BkfVdspsragnD7O92tTEf3/VHfIC1L165pnB08FXQrtIjyLL7Ry4dloUGBYKLnHOtnXlpefKMQzRYUacc7Tr1o2wv+XRoDW9h+qDqJz1O61N68JFLgJWD3/nUkm8siTg1OLvqO9ATp+UgP/Lb08E6HfqYOiD8H+1ZJjz78mo5oZatknvgy8uJJPqEX7/aRM61YA9TG+tw/sf6wlrDtUQUik8Y4k1DLmkhE15wcgq/HF2Rqka/acA9GxA5smNGyjs6CS+H [email protected]
ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBNlVuY9reRuMloYvecJHHsOYkAPDyQwELOI3kfibslIKI5hY+o1jx5yVyAUomHynP6wulm5aziNc5kWdsRE9BE8= [email protected]
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINZ2FCMbnetAnDZ63Wzct+O3MYhtO9+BedATbtiHI9BT [email protected]
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDP8ifT/3d6L2MzZPoTh0bUjQUXuPKfPP8Tp03E5En2x+iKhv+J/U0z0xk7IdPZ4qEO+ZWI5xWbwVkDdnRnJ/5HgA0/ZwmO5Zpj3llSr4dJMUVSSyO23fFIL2WqOpHyQDeexJWMxbU5SmIi+c855VwewCbGDcPnmDo0XgR/u4LRF2pwYGNGFtJ2/GICEIob/2w0ICwi7TMUEkDbUFcP5web81OzsNu80M60VaNl870uT1rwBeKuW7CXFtImYytZ0mOc5LC6d7ugkFS1zAbLOWjt3PJ8Op2MH9ncBj5jCsIlA/OqI72jKwEPOl8evYqWeEOzlVxA7/AkRj7haQqFE8r/ [email protected]
nixos
Adapted from here;
note that substituters
, extra-substituters
, and related options do not seem to work with flakes
:
(format-spec "%caccept-flake-config = true%d
auto-optimise-store = true%d
builders-use-substitutes = true%d
cores = 0%d
extra-experimental-features = %qnix-command flakes impure-derivations recursive-nix%q%d
fallback = true%d
flake-registry = https://raw.githubusercontent.com/syvlorg/flake-registry/master/flake-registry.json%d
keep-derivations = true%d
keep-outputs = true%d
max-free = 1073741824%d
min-free = 262144000%d
show-trace = true%d
trusted-public-keys = %lcache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=%q %qnix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=%q %qnickel.cachix.org-1:ABoCOGpTJbAum7U6c+04VbjvLxG9f0gJP5kYihRRdQs=%q %qsylvorg.cachix.org-1:xd1jb7cDkzX+D+Wqt6TemzkJH9u9esXEFu1yaR9p8H8=%r%d
trusted-substituters = %lhttps://cache.nixos.org/%q %qhttps://nix-community.cachix.org%q %qhttps://nickel.cachix.org%q %qhttps://sylvorg.cachix.org%r%d
warn-dirty = false%d" `(
(?c . ,(if flake "# Adapted From: https://github.com/divnix/digga/blob/main/examples/devos/flake.nix#L4\n" ""))
(?l . ,(if flake (format "[ %s" (if elisp "\\\"" "\"")) ""))
(?r . ,(if flake (format "%s ]" (if elisp "\\\"" "\"")) ""))
(?d . ,(if flake ";" delim))
(?q . ,(if (or flake quoted)
(if elisp "\\\"" "\"") ""))))
(format-spec "nix eval --impure --expr %q((builtins.getFlake or import) (toString ./.)).inputs.bundle.outPath%q | tr -d '%q' 2> /dev/null"
`((?q . ,(if elisp "\\\"" "\""))))
(let* ((path (f-expand path)))
(if (and (f-exists? path) (not (f-empty? path)))
(concat (if submodule "" "git+") "file://" path)
(progn (message "Sorry; path \"%s\" does not exist!" path) url)))
(md5 (concat (replace-regexp-in-string "/" "" (
org-format-outline-path (org-get-outline-path))) (
nth 4 (org-heading-components)) name))
(format-time-string "%Y%m%d%H%M%S%N")
(uuidgen-5 (uuidgen-4) (uuidgen-4))