diff options
25 files changed, 115 insertions, 123 deletions
diff --git a/dunbar b/dunbar -Subproject eaa4cb0123bcf01056d4dc400f2c3e513f41e96 +Subproject efb7d51a645b0038e22eabbe494ddc059896245 diff --git a/src/INIT.du b/src/INIT.du index d03720a..02e6eff 100644 --- a/src/INIT.du +++ b/src/INIT.du @@ -162,19 +162,32 @@ desc - Page description 'cmdprocess code {if {LANG};highlight -O html -f -S {default {normalise {LANG}};text};cat} 'endif +'let start {unordered}default <p> +'let end {unordered}default </p> +'let start {ordered}default <p> +'let end {ordered}default </p> + ## Attention 'let start question <div class="special-par question-par"><div class="special-contents special-with-icon"><img src="/img/dialog-question.png" class="special-par-icon borderless unzoomable" alt="question"> 'let end question </div></div> +'let start {question}default <p> +'let end {question}default </p> 'let start warn <div class="special-par warn-par"><div class="special-contents special-with-icon"><img src="/img/dialog-warning.png" class="special-par-icon borderless unzoomable" alt="warn"> 'let end warn </div></div> +'let start {warn}default <p> +'let end {warn}default </p> 'let start important <div class="special-par important-par"><div class="special-contents special-with-icon"><img src="/img/dialog-important.png" class="special-par-icon borderless unzoomable" alt="important"> 'let end important </div></div> +'let start {important}default <p> +'let end {important}default </p> 'let start note <div class="special-par note-par"><div class="special-contents"> 'let end note </div></div> +'let start {note}default <p> +'let end {note}default </p> ## Headers @@ -339,6 +352,8 @@ url href # Substitutions +'def fn_ref {sup <a href="#fn{1}" title="{truncate {greplace {substrBefore {2};<};";'};200}">{1}</a>} + 'def due_for_rework {url {b {i Due for rework}};/rework.html} 'def nohtml {greplace {1};<;<\;} @@ -363,7 +378,7 @@ reading created edited -'def breadcrumb » {def x/...;{>= {count {1};/};1}}{if {x/...};{url {substrBefore {1};/};{default {2};./}};{italic {substrAfter {1};/}}} {{if {x/...};breadcrumb;none} {substrAfter {1};/};{substrAfter {2};../}} +'def breadcrumb » {def x/...;{>= {count {1};/};1}}{if {x/...};{url {substrBefore {1};/};{default {2};./}};{italic {1}}} {{if {x/...};breadcrumb;none} {substrAfter {1};/};{substrAfter {2};../}} 'def pagenav <div id="pagenav">\ <div id="pagenav-stats">\ diff --git a/src/blog/bash-is-weird/index.du b/src/blog/bash-is-weird/index.du index 8fe78cf..2a33dcc 100644 --- a/src/blog/bash-is-weird/index.du +++ b/src/blog/bash-is-weird/index.du @@ -22,12 +22,10 @@ It has 3 things which really bothered me: 1. The output of {` $(echo A B C)} is replaced "literally", and then the whole expression is evaluated. Meaning, {` myvar=($(echo A B C))} turns into {` myvar=(A B C)}, which creates an array with those three letters. - .p I thought the "returned" value of {` $(echo A B C)} would be the whole string "A B C", so the array would have one element, that string. However, {` $()} isn't really a function, which takes arguments, "creates" commands and returns their output. It's {url Command {b Substitution};https://www.gnu.org/software/bash/manual/html_node/Command-Substitution.html}, the text gets executed and it's output {b replaces} the {` $(...)} itself (slightly reminiscent of {url LISP macros;https://lispcookbook.github.io/cl-cookbook/macros.html}). - .p Side note: obviously, the original expected behaviour can happen if we use some quotes: ```bash @@ -37,7 +35,6 @@ myvar=("$(echo A B C)") {` $\{parameter:offset:length\}} returns the substring from {` parameter} from {` offset} with size {` length}, but we're giving it a "number", so it should either throw some sort of error or return something default, like 0. However it correctly returns the number 1 (and no, that isn't a default, the number is correctly parsed as a string). - .p This shows that numbers are actually strings too, and numerical operations are just weird string operations. Contrary to any dynamically-typed language, it's not like the type of a variable is inferred from it's value, {url there isn't a type at all;https://tldp.org/LDP/abs/html/untyped.html}! Which makes everything even more weird, considering you {i can} {url create variables with a specific type;https://www.gnu.org/software/bash/manual/bash.html#index-declare}. @@ -46,11 +43,9 @@ myvar=("$(echo A B C)") It doesn't matter how it is represented, at first {` myvar} was the list of values A, B, C and now it's a number, this should return nothing. Per contra, the value {` B} is returned instead! - .p Via trial and error, we find that our number will be returned when the index is 0, and with index 2 we get {` C}. So all variables are arrays, and by default for integer and string operations, the first value is used? - .p This is strange, but it cannot be the full picture, because {url names have attributes;https://linux.die.net/Bash-Beginners-Guide/sect_10_01.html}, alongside it's type, a variable (name) can be read-only, but also have the "trace" flag, which only works with functions. So, variables and functions are the same "object"? Unfortunately, I couldn't find any definitive information on the topic, so this train of thought will have to be left unresolved. diff --git a/src/blog/connect-to-mysql-in-dotnet-ef/index.du b/src/blog/connect-to-mysql-in-dotnet-ef/index.du index d1c48ab..142d398 100644 --- a/src/blog/connect-to-mysql-in-dotnet-ef/index.du +++ b/src/blog/connect-to-mysql-in-dotnet-ef/index.du @@ -32,7 +32,9 @@ There are {url a lot;https://www.connectionstrings.com/mysql/} of ways to setup If you are using {` MySQL Workbench} and you don't know your port and id, you can look at the server information from the {` MySQL Connections} page. -{img MyServer root 127.0.0.1:3306;./img/connections.png} In this example, the user id is _root_ and the port is _3306_. +{img MyServer root 127.0.0.1:3306;./img/connections.png} + +In this example, the user id is {i root} and the port is {i 3306}. ## Connecting diff --git a/src/blog/fix-no-frame-buffer-plan9/index.du b/src/blog/fix-no-frame-buffer-plan9/index.du index fe21454..6573f22 100644 --- a/src/blog/fix-no-frame-buffer-plan9/index.du +++ b/src/blog/fix-no-frame-buffer-plan9/index.du @@ -22,7 +22,6 @@ For some reason, on certain configurations, the {` xga} ({` vga}) monitor type d ``` aux/vga -m vesa -l - .p You should get a cursor and a cleared prompt. {img ./img/manual-prompt.png} diff --git a/src/blog/fix-qc-timeout/index.du b/src/blog/fix-qc-timeout/index.du index 42ee9c1..68e290d 100644 --- a/src/blog/fix-qc-timeout/index.du +++ b/src/blog/fix-qc-timeout/index.du @@ -41,21 +41,17 @@ libata.force=3.01:nodmalog :note ### Update 20 August 2025 -.p About a month ago I stumbled upon this {url mailing list;https://de.comp.hardware.laufwerke.festplatten.narkive.com/F8WstP5i/fix-frage-zu-sata-read-log-0x00-page-0x00-failed-emask-0x40} (Google-powered translation to English {url here;https://de-comp-hardware-laufwerke-festplatten-narkive-com.translate.goog/F8WstP5i/fix-frage-zu-sata-read-log-0x00-page-0x00-failed-emask-0x40?_x_tr_sl=bg&_x_tr_tl=en&_x_tr_hl=en&_x_tr_pto=wapp}). -.p A user had the same issue as outlined in this post and were discussing the situation. Their problematic SSD was a "TEAM L7 EVO SSD 60GB", which incidentally is the exact model which caused me trouble. -.p Since it is the same (and as far as I know, the only) device with this behaviour, I believe it is a hardware bug as a responder suggested: .quote They must have messed up the implementation of the ATA READ LOG DMA EXT command. This causes the firmware to freeze, and after a while, the kernel triggers a link reset, which revives it. -.p I'm leaving my original explanation, since some of it is still true. diff --git a/src/blog/fmi-i-vissheto-obrazovanie-v-programistkata-industriq/index.du b/src/blog/fmi-i-vissheto-obrazovanie-v-programistkata-industriq/index.du index 75fbcbf..3b2269a 100644 --- a/src/blog/fmi-i-vissheto-obrazovanie-v-programistkata-industriq/index.du +++ b/src/blog/fmi-i-vissheto-obrazovanie-v-programistkata-industriq/index.du @@ -109,8 +109,6 @@ .quote За IT ТУ е абсолютна загуба на време - редовно ми идват стажанти от там. Ако не са се занимавали с програмиране от преди това, почваме от 0 -\n - .quote Завършил съм компютърни системи и технологии на немски в ТУ. Знам за какво иде реч и в българските факултети. След като разбрах какво се изучава във ФМИ ме хвана яд, че не се бях записал там. diff --git a/src/blog/friendship-ended-with-funtoo-now-gentoo-is-my-best-friend/index.du b/src/blog/friendship-ended-with-funtoo-now-gentoo-is-my-best-friend/index.du index a4cd802..6d7504d 100644 --- a/src/blog/friendship-ended-with-funtoo-now-gentoo-is-my-best-friend/index.du +++ b/src/blog/friendship-ended-with-funtoo-now-gentoo-is-my-best-friend/index.du @@ -26,7 +26,6 @@ Before we begin, I want to take a second and explain some Gentoo/Funtoo terminol :unordered - {` emerge} (as a verb): what does "install" mean? I would argue it means copying a program and the file it depends on somewhere on a system, with the goal of being able to run this program. - .p Now, in Gentoo and Funtoo, most programs are compiled from source code, so before you install you download it's source and compile. For this reason, on such systems you would usually say a certain program/package is {i being emerged, not installed} (and the words comes from the {url package-manager command-line utility of the same name;https://wiki.gentoo.org/wiki/Emerge}). @@ -43,17 +42,11 @@ Before we begin, I want to take a second and explain some Gentoo/Funtoo terminol Most packages and their dependencies on Funtoo go unmaintained and untested for years, which significantly limits your abilities to install and build software. -'footnote packages-in-repo-tree Not all of those packages are in the repository tree, but that doesn't matter, if you want to compile a program, you should be able to do so. - -'footnote required-3.8 Required might be a strong word, I don't remember if I tried (though I'm sure I did) just downgrading the Python version in the ebuild. Nevertheless, there were for sure useful packages which really did need it. - -Python was stuck at version 3.7, while a lot of packages like barrier, libplacebo, mpv and pulseeffects{packages-in-repo-tree} required{required-3.8} at least 3.8. +Python was stuck at version 3.7, while a lot of packages like barrier, libplacebo, mpv and pulseeffects{fn Not all of those packages are in the repository tree, but that doesn't matter, if you want to compile a program, you should be able to do so.} required{fn Required might be a strong word, I don't remember if I tried (though I'm sure I did) just downgrading the Python version in the ebuild. Nevertheless, there were for sure useful packages which really did need it.} at least 3.8. So, with a lot of effort and poking around, I got python 3.8 to work, just barely. What's even better is that eventually I reached an {b unfixable} circular python dependency (between dev-python/packaging and dev-python/setuptools). -'footnote glibc This point may not be completely fair, since Funtoo has a system for {url ebuild generation;https://web.archive.org/web/20230528115518/https://projects.funtoo.org/metatools/docs/autogen.html}, which means that they might've made configuration changes and/or applied patches which "fix" that version, but still, it really isn't a good look. - -Another problem child was glibc, it is {i currently} at {url version 2.33-r2;https://github.com/funtoo/core-kit/tree/1.4-release/sys-libs/glibc}, which under Gentoo {url is officially masked and discouraged for usage;https://gitweb.gentoo.org/repo/gentoo.git/tree/profiles/package.mask#n542}{glibc} and wouldn't you know it, also prevents some packages from being compiled (mainly I remember ungoogled-chromium). +Another problem child was glibc, it is {i currently} at {url version 2.33-r2;https://github.com/funtoo/core-kit/tree/1.4-release/sys-libs/glibc}, which under Gentoo {url is officially masked and discouraged for usage;https://gitweb.gentoo.org/repo/gentoo.git/tree/profiles/package.mask#n542}{fn This point may not be completely fair, since Funtoo has a system for {url ebuild generation;https://web.archive.org/web/20230528115518/https://projects.funtoo.org/metatools/docs/autogen.html}, which means that they might've made configuration changes and/or applied patches which "fix" that version, but still, it really isn't a good look.} and wouldn't you know it, also prevents some packages from being compiled (mainly I remember ungoogled-chromium). There were a lot more problematic packages, but I've forgotten most details. What I do remember is that the day I decided to hop to Gentoo, I tried to update my system and yet again I got some sort of issue, either a package couldn't compile properly or there was some dependency conflict. @@ -68,20 +61,18 @@ On the {url Welcome;https://www.funtoo.org/Welcome} page of Funtoo's website, in This is essentially a document describing how a member of the community should behave, and I didn't follow it. Any member of the pack is supposed to: .unordered -- {b Be Mindful of the Pack} by tackling challenges with the community\n +- {b Be Mindful of the Pack} by tackling challenges with the community{br} but as I found (package) challenges, I tackled them on my own, not trying to consult anyone or ask for help -- {b Be Interconnected} by supporting and being supported by the community\n +- {b Be Interconnected} by supporting and being supported by the community{br} but I didn't connect with anyone on my issues -- {b Howl} by expressing their needs and sharing their "adventures"\n +- {b Howl} by expressing their needs and sharing their "adventures"{br} but I didn't express them and didn't share the work I've done Or more simply put, Funtoo is a small project, and you need to communicate with others to get things done. -'footnote kicad On that aforementioned kicad package, drobbins, the benevolent dictator for life of Funtoo, categorized it as a {url package which people aren't interested in;https://bugs.funtoo.org/browse/FL-8435?focusedId=52907&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-52907}. - Another way to look at it is that in a project of this scale, what gets supported is what the community uses, so in a way, I was trying to use Funtoo in the {i wrong} way. This may sound ridiculous, but then again, they aren't making a project which "just works" for everyone (like Ubuntu or Linux Mint), this is a project by the community for the community. -You can't expect them to support everything that a big-scale distro does, like Gentoo, with a fraction of the manpower, so if nobody supports a package (which exists in the repository tree) that doesn't work and you don't at least speak up, it will probably stay broken{kicad} (this kind of relates to the {b Is Territorial} point in the philosophy). +You can't expect them to support everything that a big-scale distro does, like Gentoo, with a fraction of the manpower, so if nobody supports a package (which exists in the repository tree) that doesn't work and you don't at least speak up, it will probably stay broken{fn On that aforementioned kicad package, drobbins, the benevolent dictator for life of Funtoo, categorized it as a {url package which people aren't interested in;https://bugs.funtoo.org/browse/FL-8435?focusedId=52907&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-52907}.} (this kind of relates to the {b Is Territorial} point in the philosophy). However, in my defense, I didn't open bug reports or create forum posts because my issues weren't "directly" related to Funtoo, or a normal Funtoo installation. Most of the time I would have an issue with a package, then get it's Gentoo counterpart, try to get all dependencies working one by one, and it will fail with some unsearchable error. @@ -159,7 +150,9 @@ Though I can't empirically prove this, I found that the packages that worked on I'm not saying Gentoo's documentation is bad, but Funtoo's is often written a bit more simply. -\n +{br} Funtoo has it's audience, if you're ready to be a part of the wolf pack, it has to potential to be even better than Gentoo. That said, if you need something which always just works, your choice should be Gentoo, as it is for me. + +{footnotes} diff --git a/src/blog/how-to-encrypt-email/index.du b/src/blog/how-to-encrypt-email/index.du index 13b49a5..fe539a5 100644 --- a/src/blog/how-to-encrypt-email/index.du +++ b/src/blog/how-to-encrypt-email/index.du @@ -284,9 +284,9 @@ When writing a message, don't forget to check if encryption is turned on for thi -<span id="1">{^ 1}</span> Available with an extension/plugin\n -<span id="2">{^ 2}</span> Available in a paid version of the software (assuming the software is Freemium; this is true for all Premium software)\n -<span id="3">{^ 3}</span> Available with a Premium account (even if the software is Free)\n +<span id="1">{^ 1}</span> Available with an extension/plugin{br} +<span id="2">{^ 2}</span> Available in a paid version of the software (assuming the software is Freemium; this is true for all Premium software){br} +<span id="3">{^ 3}</span> Available with a Premium account (even if the software is Free){br} <span id="*">{^ *}</span> You can read S/MIME messages, but signing and encrypting is a pro feature 'def 1 'def 2 diff --git a/src/blog/icon-fonts-arent-evil-you-just-have-to-care/index.du b/src/blog/icon-fonts-arent-evil-you-just-have-to-care/index.du index 744eac3..d2e316a 100644 --- a/src/blog/icon-fonts-arent-evil-you-just-have-to-care/index.du +++ b/src/blog/icon-fonts-arent-evil-you-just-have-to-care/index.du @@ -82,17 +82,14 @@ The main tricks are: 1. {b Adding text to every clickable option}, where possible. For example, I changed my theme button from an icon to "Dark theme" or "Light theme" (depending on the current theme). - .p Even outside this topic, having text instead of icons {url has many benefits;https://dev.to/megazear7/no-icon-web-design-16eb}, mainly making it easier for users to understand how to interact with the website. 2. {b Putting important navigational and functional icons outside the PUA} (and leaving decorational ones there). - .p For example, on mobile devices my sidebar is put on the top, but as to not take too much space, it is "folded" up. To expand it, you need to click an arrow on the top-right corner of the page. Now, that arrow image is "mapped" to the standard triangle pointing up and down characters, so if the font doesn't load or is changed, you would get a triangle, which conveys the same action. - .p This isn't always possible though, for example, what if you have a company logo of some sort? The solution is in the previous point: don't make your link to that company a single icon, at least add the name next to the icon (or in other words, make the icon decorative). @@ -123,7 +120,7 @@ On average a page probably requests less than 7KB of icons, but still, 7KB isn't Overall, I would say size-wise, with a font containing only what you need, it could easily take up less space than the separate SVGs. If you still have speed issues, {url there are always ways to load fonts progressively;https://www.filamentgroup.com/lab/font-events.html}. -\n +{br} Overall, even with a lot of customization, icon fonts could still sometimes cause issues for accessibility and are more limited in some ways. For me, I've found that their negatives (when applicable) don't degrade website usage that much and their positives make my life a whole lot simpler. diff --git a/src/blog/install-drivers-for-epson-scanners/index.du b/src/blog/install-drivers-for-epson-scanners/index.du index 0d3c5ec..9699945 100644 --- a/src/blog/install-drivers-for-epson-scanners/index.du +++ b/src/blog/install-drivers-for-epson-scanners/index.du @@ -49,9 +49,7 @@ sudo rpm -Uvh --nodeps ./epsonscan2-bundle-SOMETHING.rpm/core/epsonscan2-SOMETHI Alternatively, you can install the {` deb} package with {` dpkg} or build and install it from {url source;https://download.ebz.epson.net/man/linux/epsonscan2_e.html#sec5-1-4} (source file is available at the bottom of the {url support site;https://support.epson.net/linux/en/epsonscan2.php}). -'footnote gentoo-epkowa Surprisingly enough, on my Gentoo installation everything works fine without the package. Either something else is helping me or {url something is in the "more magic" position;http://www.catb.org/jargon/html/magic-story.html}... - -You will need{gentoo-epkowa} to install {` iscan}, which usually provides the aforementioned {` epkowa} backend. +You will need{fn Surprisingly enough, on my Gentoo installation everything works fine without the package. Either something else is helping me or {url something is in the "more magic" position;http://www.catb.org/jargon/html/magic-story.html}...} to install {` iscan}, which usually provides the aforementioned {` epkowa} backend. Also make sure you have {` epkowa} inside {` /etc/sane.d/dll.conf} without a leading {` #}. Finally, only for the very first time after connecting your powered-on scanner, start "Epson Scan 2", select it and press "Next". diff --git a/src/blog/managing-apps-with-adb-without-root/index.du b/src/blog/managing-apps-with-adb-without-root/index.du index b4b0fd9..bac9338 100644 --- a/src/blog/managing-apps-with-adb-without-root/index.du +++ b/src/blog/managing-apps-with-adb-without-root/index.du @@ -59,9 +59,7 @@ adb devices On your phone you should get a poppup asking "Allow USB debugging?", press OK. You should get a "List of devices attached", and it should have one entry (a line below it, with some number and letters and then the word "device"). -'footnote interactive-shell You could just run every command like {` adb shell COMMAND}, which wouldn't give you an interactive shell, so it is less convinient - -Now, we'll open a shell{interactive-shell}, a program with which to directly enter commands that the device understands: +Now, we'll open a shell{fn You could just run every command like {` adb shell COMMAND}, which wouldn't give you an interactive shell, so it is less convinient}, a program with which to directly enter commands that the device understands: ```sh adb shell @@ -309,7 +307,9 @@ pm uninstall -k --user 0 com.mobitv.client.tmobiletvhd pm uninstall -k --user 0 us.com.dt.iq.appsource.tmobile -\n +{br} More information on available package commands can be shown with {` pm help}. You can learn more about the adb tool from {url developer.android.com;https://developer.android.com/studio/command-line/adb}. + +{footnotes} diff --git a/src/blog/mundus-first-shot-at-gamedev/basic-concepts.du b/src/blog/mundus-first-shot-at-gamedev/basic-concepts.du index 4bc87f8..a969627 100644 --- a/src/blog/mundus-first-shot-at-gamedev/basic-concepts.du +++ b/src/blog/mundus-first-shot-at-gamedev/basic-concepts.du @@ -9,7 +9,7 @@ {due_for_rework} -\n +{br} .contents .numbered @@ -40,8 +40,10 @@ There is only one type of mob tile and that is {` MobTiles}. All mobs, with the - the superlayer they are currently in + Items, however, are divided into: +:unordered - Material tiles: primary used for crafting. Some of them are "consumable", meaning they can be consumed by the mob, which removes them from the inventory and changes a property of the mob. In your inventory they are surrounded in orange. - Gear tiles: something you equip (in your accessories and gear inventories) that modifies properties of the mob. In your inventory they are surrounded in purple. None are implemented. diff --git a/src/blog/mundus-first-shot-at-gamedev/timeline.du b/src/blog/mundus-first-shot-at-gamedev/timeline.du index 2d4466e..f4aed7e 100644 --- a/src/blog/mundus-first-shot-at-gamedev/timeline.du +++ b/src/blog/mundus-first-shot-at-gamedev/timeline.du @@ -9,7 +9,7 @@ {due_for_rework} -<br/> +{br} As mentioned, I had big plans for Mundus, so I wanted to make sure it would be well planned. But at the same time, the project took too much energy and I often had holes of no development time. This is an overview of the development "cycle" I went through. @@ -51,11 +51,11 @@ Things started to take a turn for the better, I had planned everything I needed And then, they extended the break for one more week, the productivity boost could've continued even further, but, alas, I was burned out. The productivity boost, as good as it was, it tired me out very fast. There were still a couple of days with progress, but this time I actually took a break. -<br/> +{br} However, remember how they extended the spring break by a week? Well, this was caused by the emergence of the COVID-19 pandemic in Europe and Bulgaria. Subsequently, after the break, we didn't go back to school. Due to the emergent situation, development on Mundus became increasingly sporadic and progress slowed down drastically. At least the exam got pushed back by a month/month and a half. -<br/> +{br} .quote {i {b 23.05.2020}} Day 105 diff --git a/src/blog/mundus-first-shot-at-gamedev/user-interface.du b/src/blog/mundus-first-shot-at-gamedev/user-interface.du index 9fe7f33..d355a34 100644 --- a/src/blog/mundus-first-shot-at-gamedev/user-interface.du +++ b/src/blog/mundus-first-shot-at-gamedev/user-interface.du @@ -9,7 +9,7 @@ {due_for_rework} -\n +{br} .contents .numbered diff --git a/src/blog/plan9-in-linux-mouse-menus/index.du b/src/blog/plan9-in-linux-mouse-menus/index.du index 79f391e..b22d1c3 100644 --- a/src/blog/plan9-in-linux-mouse-menus/index.du +++ b/src/blog/plan9-in-linux-mouse-menus/index.du @@ -47,10 +47,10 @@ Finally, the middle mouse button (button 2), shows text-control options, which c {img ./img/plan9-mouse2-menu.png} -You'll recognise {` cut}, {` paste} and {` snarf} {fn It's hard to deduce why exactly it was named like this, but the most probable explanation comes from {url unix.stackexchange;https://unix.stackexchange.com/questions/308943/why-does-plan-9-use-snarf-instead-of-copy/309350}: copying might've been seen as a two step action, obtain the contents you want to copy and paste them somewhere. So to copy something you need a duplicate of itself to be created, and either putting it in the "clipboard" isn't considered duplicating, or an optimization makes "the clipboard" store some sort of reference to what you snarfed, but not the exact thing itself. \n On an unrelated note, this might have played a part in the reasoning behind vim using the word "yank" for copy.}, the latter being just another word for copy. -Since every modern window manager supports those in some form, I'll concentrate on the others.\n +You'll recognise {` cut}, {` paste} and {` snarf} {fn It's hard to deduce why exactly it was named like this, but the most probable explanation comes from {url unix.stackexchange;https://unix.stackexchange.com/questions/308943/why-does-plan-9-use-snarf-instead-of-copy/309350}: copying might've been seen as a two step action, obtain the contents you want to copy and paste them somewhere. So to copy something you need a duplicate of itself to be created, and either putting it in the "clipboard" isn't considered duplicating, or an optimization makes "the clipboard" store some sort of reference to what you snarfed, but not the exact thing itself.{br}On an unrelated note, this might have played a part in the reasoning behind vim using the word "yank" for copy.}, the latter being just another word for copy. +Since every modern window manager supports those in some form, I'll concentrate on the others.{br} {` plumb} is the most interesting: it sends the selection to a "plumber" application, which practically{fn Technically, a plumber just passes messages between applications, so you can configure it to not open a URL but do something else with it in a certain application. However, the aforementioned way is how it works most of the time.} tries to open or execute it. -For example, a selected URL will open in the browser, but a selected image file will open in an image viewer.\n +For example, a selected URL will open in the browser, but a selected image file will open in an image viewer.{br} {` send} enters the selected text as a command in the current shell. ### Usefulness in Linux @@ -290,7 +290,7 @@ Pressing and releasing the mouse button will stop resizing (that's why {` keyup Though it work, it's kind of clunky and the normal Alt+RightClick is arguably simpler and easier to work with. -<br/> +{br} With this our script if finished. You can find the whole thing (including some personal modifications) in my {url dotfiles;https://gitlab.com/Syndamia/dotfiles/-/blob/main/.a/plumb.sh}. diff --git a/src/blog/sane-explanation-of-compilers/part-1/index.du b/src/blog/sane-explanation-of-compilers/part-1/index.du index 125c778..39d1a15 100644 --- a/src/blog/sane-explanation-of-compilers/part-1/index.du +++ b/src/blog/sane-explanation-of-compilers/part-1/index.du @@ -65,7 +65,7 @@ In this post, we'll be looking only at the first one. Syntax in current programming languages can be quite sophisticated and ambiguous. For example (taken from {url wikipedia;https://en.wikipedia.org/wiki/Most_vexing_parse}) this C++ snippet -``` +```cpp void f(double d) { int i(int(d)); } @@ -458,7 +458,8 @@ It all boils down to using a whole bunch of conditional statements and tracing w We need to track the current state of the string, because imagine we've just read an "a", it could either be from the left or right handside of "a + a", and that changes what character to expect next. We're going to track the state with different numbers, defined like this: - .table_2 + .table + .2 |= State (number) |= Current expression ends with |: 0 @@ -531,7 +532,8 @@ It all boils down to using a whole bunch of conditional statements and tracing w It's also helpful to put what we do in different situations in another table: - :table_4 + :table + :4 |= State |= If ends on |= Change state to @@ -583,6 +585,7 @@ It all boils down to using a whole bunch of conditional statements and tracing w |: Replace "(S + F)" with "S" + where, if there is a value in "If ends on", we read the next character, while otherwise we don't and we just execute "Change state to" and "Also do". - You're probably wondering why the table works so weird, like why on state 3 we don't directly replace "a" with "S" and change to state 5 for example. @@ -703,34 +706,34 @@ Let's look at the input string {` 2 * (1 + 3)}, while abstracting ourselves from :unordered - we read the {` 2}, that is a number, we add it as a node - .p {img ./img/tree-building-1.svg} + {img ./img/tree-building-1.svg} - then we read the {` *}, we now know our expression is in the form {` E* E}. If you think about it, up to this point, we've basically been building a tree for the left handside. {b If} the topmost element in that tree is a brace, - .p {img ./img/tree-building-ex1.svg} + {img ./img/tree-building-ex1.svg} we connect it to the left handside of {` *}: - .p {img ./img/tree-building-ex2.svg} + {img ./img/tree-building-ex2.svg} {b Otherwise} (when it's {` +} or {` *} or a number), because of precedence, we'll attach the latest number to the left handside. However we have to be careful, if something connects to the number, we now need it to connect to the {` *}.\n For example, let's say we had {` 1 + 2 * 3}, and we've just read the {` *}. The tree up to this point would look like, - .p {img ./img/tree-building-ex3.svg} + {img ./img/tree-building-ex3.svg} where the latest number we've found was {` 2}, but the {` +} connects to it. So, we need to make the {` 2} connect to the left handside of {` *}, and make {` +} connect to {` *} instead of {` 2} - .p {img ./img/tree-building-ex4.svg} + {img ./img/tree-building-ex4.svg} In our original case, nothing connects to the {` 2} in {` 2 * (1 + 3)}, so we can just connect it to the left handside of {` *} - .p {img ./img/tree-building-2.svg} + {img ./img/tree-building-2.svg} where the three dots signify there isn't anything there (but we expect there to be). Somewhere we'll store that the next element we find has to be connected to the right handside. @@ -738,7 +741,7 @@ Let's look at the input string {` 2 * (1 + 3)}, while abstracting ourselves from - now we read {` (}, we cannot have it by itself, so we directly decide we're working with {` (E)} (in our full algorithm we would need a check for existance of matching brace). We'll create a {` ()} node and because of the last step, we'll connect it to the right handside. - .p {img ./img/tree-building-3.svg} + {img ./img/tree-building-3.svg} Now, moving forward, we'll be creating a subtree, essentially making a second tree, and after that is done, we'll connect it's topmost element (root) to the {` ()} node. @@ -763,7 +766,7 @@ Lex is the original program, from 1975, in the modern day it's successor/impleme A lex source file is divided into three parts: -'def LANG lex +'def LANG c ``` 'snippet 1 $ ./template.l @@ -777,7 +780,7 @@ Usually the {` C_code} in the regex would be a return (more commonly called "emi Let's look at a very simple example program: every whole number is printed as "NUMBER", while everything else is printed as-is: -'def LANG lex +'def LANG c ``` 'snippet 1 $ ./example_lex/lexer.l @@ -809,7 +812,7 @@ There are three ways to fix this problem: It should return 0 if our lexer should continue with the next given file, after finishing with the current one, or 1 if it should stop execution. The function could be written in either "C code" section, but I personally prefer the last one. - 'def LANG lex + 'def LANG c ``` int yywrap() { return 0; } @@ -839,7 +842,7 @@ and strings: We'll define numbers as both whole digits and floating point numbers (with sign) and strings can be surrounded in either single or double quotes. -'def LANG lex +'def LANG c ``` 'snippet 1 $ ./example_lex/numbers_html.l @@ -862,7 +865,7 @@ Similarly to lex, yacc originates from 1975, and it's modern replacement is {url A yacc file looks very similarly to a lex one: -'def LANG yacc +'def LANG y ``` 'snippet 1 $ ./template.y @@ -870,7 +873,7 @@ however rather than definitions you have declarations, and the rules are in a co Token names are defined in {` declarations}, in the format -'def LANG yacc +'def LANG y ``` %token NAME1 NAME2 ... @@ -879,14 +882,14 @@ There are also other options you can set, like the start name with {` %start}. Grammars are in the form -'def LANG yacc +'def LANG y ``` name : TOKEN1 TOKEN2 ... ; where alternation is defined like -'def LANG yacc +'def LANG y ``` name : TOKEN1 | TOKEN2 @@ -896,7 +899,7 @@ name : TOKEN1 and it always must end with a {` ;}. On each alternation, you can (should) specify a body, which will contain C code to be executed, if this rule is reached -'def LANG yacc +'def LANG y ``` name : TOKEN1 { C code here } | TOKEN2 @@ -924,7 +927,7 @@ S -> N | (S M S) First, we need to make our {` lexer.l}, it is going to be very simple: -'def LANG lex +'def LANG c ``` 'snippet 1 $ ./example_yacc/lexer.l @@ -934,7 +937,7 @@ This file is in the format {` FILENAME.tab.h}, where {` FILENAME.y} is our sourc Second, we need to make our {` parser.y}: -'def LANG yacc +'def LANG y ``` 'snippet 1 $ ./example_yacc/parser.y @@ -969,7 +972,7 @@ The way we created that lexer and parser worked, but it wasn't very useful and h For example, if we enter the letter {` a} or any string which doesn't have {` (}, {` )}, {` 1}, {` 2}, {` 3}, {` +} or {` -} characters, it will just get printed back. Ideally, we want to raise an error, so we're going to add one rule which catches any (non-special) character and throws an error with the built-in {` yy_fatal_error}: - 'def LANG lex + 'def LANG c ``` . { yy_fatal_error("Bad character"); } @@ -983,7 +986,7 @@ The way we created that lexer and parser worked, but it wasn't very useful and h By default it's type is {` int} (in Bison), but usually you would want it to be a {url union;https://en.wikipedia.org/wiki/Union_type#C/C++}. Let's make it a union of int and char, though the first part is kind of useless, since we're only working with single digit numbers. \n - 'def LANG yacc + 'def LANG y ``` %union { int num; @@ -992,7 +995,7 @@ The way we created that lexer and parser worked, but it wasn't very useful and h Now, inside our lexer, rules would look like: - 'def LANG yacc + 'def LANG y ``` RULE1 { yylval.num = 129; return TOKEN; } RULE2 { yylval.chr = 'a'; return TOKEN; } @@ -1000,14 +1003,14 @@ RULE2 { yylval.chr = 'a'; return TOKEN; } Inside C blocks for grammar rules we can reference the token values with {` \$i}, where {` i} is the i'th "token" in the expression. For example, in this rule, {` \$1} would be {` (}, {` \$3} would be value of token {` B} and {` \$5} would be the value of the rule name: - 'def LANG yacc + 'def LANG y ``` rule : ( A B ) rule ; You can set rule "return" values by setting the variable {` \$$}: - 'def LANG yacc + 'def LANG y ``` rule : LBRACE rule RBRACE { $$ = 10; } @@ -1015,7 +1018,7 @@ rule : LBRACE rule RBRACE { $$ = 10; } However, {` \$i} isn't of type union, we cannot do something like {` \$i.num}, it is the precise value that was set for the token. Therefore, we also need to define which value from the union every token will set, which is done by adding {` <PROPERTY>} before every defined token (and {` PROPERTY} is a property name inside the union): - 'def LANG yacc + 'def LANG y ``` %token <num> NUMBER <chr> MATHOP <chr> LBRACE <chr> RBRACE @@ -1023,7 +1026,7 @@ rule : LBRACE rule RBRACE { $$ = 10; } That is because we try to match only one expression, after it is matched our parser is waiting for an end of file character. Let's make it so we would try to match an expression on every line: - 'def LANG yacc + 'def LANG y ``` start : expr | expr start @@ -1035,14 +1038,14 @@ start : expr 4. We're getting input from the user, but our source text (code) will be in a file. First, our {` main} function needs to take program parameters: - 'def LANG yacc + 'def LANG y ``` int main(int argc, char* argv[]) Then we need to take the first argument, and open a file. Additionally, we have to check if the file was successfully opened, and print an error and stop execution if so: - 'def LANG yacc + 'def LANG y ``` FILE* input = fopen(argv[1], "r"); if (input == NULL) { @@ -1054,13 +1057,13 @@ if (input == NULL) { To read a file, all we need to do is change the value of that variable. Also, that variable is defined externally, so first we need to add to (the top) C section: - 'def LANG yacc + 'def LANG y ``` extern FILE* yyin; and then put in our {` main}: - 'def LANG yacc + 'def LANG y ``` yyin = input; @@ -1100,13 +1103,13 @@ All in all, we'll have 4 source files for our simple front-end: :unordered - {` lexer.l} - 'def LANG lex + 'def LANG c ``` 'snippet 1 $ ./proper/lexer.l - {` parser.y} - 'def LANG yacc + 'def LANG y ``` 'snippet 1 $ ./proper/parser.y diff --git a/src/blog/taming-the-fun-too/index.du b/src/blog/taming-the-fun-too/index.du index 018f6ae..f6bcf41 100644 --- a/src/blog/taming-the-fun-too/index.du +++ b/src/blog/taming-the-fun-too/index.du @@ -13,7 +13,7 @@ However, at that time I was a bit softened by my growing pains with Fedora, the So, about a month later I bit the bullet, and installed it on my main computer. It has now been a tad more than a year later and I can comfortably say: {i a lot could go wrong...} -<br/> +{br} In the same way that a distro is made to solve a certain problem, every distro introduces a fundamental flaw in it's design. Ubuntu solves the "it's too complicated" problem, but introduces issues with performance. Arch solves "my packages are too old and what I need isn't there" issue, but introduces "my packages are too new and something just broke". @@ -21,7 +21,7 @@ Then there's Funtoo. You might reason, since it's a fork of Gentoo, it's big fla The distribution is a lot smaller than it's big brother so a lot of stuff, understandably, cannot be tested. However, the real kicker is that package ebuilds{fn Files with instructions and settings for the package manager (portage) on how to build a specific package} are generated in a different way from Gentoo. This often means that using a Gentoo ebuild will make the problem even worse, but sometimes it does work out. -<br/> +{br} The first such problem child was QtWebEngine. As the name suggests, it gives the ability for graphical applications, made with the Qt framework, to render webpages. I don't {i need} it for my setup, but there are a couple of useful programs that required it. @@ -32,7 +32,7 @@ A fairly deep dive into different forums led me to the wondrous conclusion that After {i much} tweaking and trying, I found out there just wasn't enough memory, the package needed at least 32 GiB (including swap) of memory for a successful compilation... D'oh! And here comes the really bad part: I had setup a swapfile of adequate size! However, as it turned out, in the configuration I tried loading it before loading the drive it was stored in... {b Double D'OH!!} -<br/> +{br} Then came the big boss: python. Now, I wasn't planning on doing any software development with it, but as it turned out, other people had, so certain packages had building issues. And what was the exact issue you might ask? @@ -45,7 +45,7 @@ Usually there are solutions to such situations, but I kid you not, I had tried { This time, there isn't even a solution, I just made sure to never upgrade these packages again. Which proved problematic, since these packages were important and over time other stuff broke, but that wouldn't be relevant for long. -<br/> +{br} Not too soon after, armageddon struck: glibc, GNU's C library. All I wanted to do was try out Ungoogled Chromium, but not as a flatpak. The only thing standing in the way was the requirement of "glibc 3.4.29", while all I had was 2.70.0. @@ -65,7 +65,7 @@ A sanity check override and a package downgrade later, {i it wasn't...} Yes, my system was broken. Very broken. So broken in fact, portage wasn't working, so un-downgrading was not an option. And, of course, booting successfully my machine up ever again wasn't an option either... Thank goodness for {url Timeshift;https://github.com/linuxmint/timeshift}'s system restore functionality or I would've had to rebuild my whole system. -<br/> +{br} There are {b a lot} of other situations in which Funtoo's package difficulties and my sheer incompetence have led to wasted time and broken stuff, but these are the main ones that stand out in my mind (or more accurately, the ones that I still remember). Nowadays I use the distro in a much smarter fashion, with a much tighter grip. diff --git a/src/blog/the-physics-behind-a-black-hole-shader/index.du b/src/blog/the-physics-behind-a-black-hole-shader/index.du index fdb6589..ee42654 100644 --- a/src/blog/the-physics-behind-a-black-hole-shader/index.du +++ b/src/blog/the-physics-behind-a-black-hole-shader/index.du @@ -82,7 +82,7 @@ However, what if our surface isn't flat? Imagine two points on a sphere, what is the shortest distance between them? Obviously, it's an arc of a circle and extending it to it's maximum possible length, we get a {url great circle;https://en.wikipedia.org/wiki/Great_circle}. -{img ./img/Illustration_of_great-circle_distance.svg.png}<br/> +{img ./img/Illustration_of_great-circle_distance.svg.png}{br} {i Image by CheCheDaWaff on {url Wikipedia;https://commons.wikimedia.org/w/index.php?curid=48187293}} Now, what does it mean to go "forwards"? @@ -126,7 +126,7 @@ Schwarzschild's metric and accompanying black hole properties are the simplest p Let's imagine atoms as a set of glass marbles, scattered on a table: -{img https://upload.wikimedia.org/wikipedia/commons/thumb/0/0e/Marbles_from_Indonesia.jpg/1280px-Marbles_from_Indonesia.jpg}<br/> +{img https://upload.wikimedia.org/wikipedia/commons/thumb/0/0e/Marbles_from_Indonesia.jpg/1280px-Marbles_from_Indonesia.jpg}{br} {i Image from By Okkisafire on {url Wikipedia;https://commons.wikimedia.org/w/index.php?curid=30338734}} Now, start pushing from all sides of the table to it's center. @@ -156,15 +156,15 @@ In our case, the only important part is it's effect on gravity, and more precise Since a black hole is a single infinitely small point, then all of it's mass is concentrated on that point, making it alter the geodesics in a relatively small area of space {b a lot}. So much so, if you get too close, you will not be able to overwhelm gravity and "merge" into that infinitesimal point: -{img https://upload.wikimedia.org/wikipedia/commons/9/91/CNX_UPhysics_13_07_spacetime.png?utm_source=commons.wikimedia.org&utm_campaign=index&utm_content=original}<br/> -{i The white lines are our geodesics}<br/> +{img https://upload.wikimedia.org/wikipedia/commons/9/91/CNX_UPhysics_13_07_spacetime.png?utm_source=commons.wikimedia.org&utm_campaign=index&utm_content=original}{br} +{i The white lines are our geodesics}{br} {i Image by OpenStax University Physics on {url Wikipedia;https://commons.wikimedia.org/w/index.php?curid=64307901}} A fascinating realization is that light always travels along geodesics ("forwards"), therefore this extreme bending allows us to view otherwise obstructed objects. We call that effect {url gravitational lensing;https://en.wikipedia.org/wiki/Gravitational_lens}. Though not unique to black holes, that's when the effect is strongest: -{img https://upload.wikimedia.org/wikipedia/commons/0/02/Gravitational_lens-full.jpg}<br/> +{img https://upload.wikimedia.org/wikipedia/commons/0/02/Gravitational_lens-full.jpg}{br} {i Notice how the gray arrows show the path light travels from a galaxy that is behind (obstructed by) the black hole} I'll abstain from explaining the specifics of light, but you may think of it as a small particle, "similar" to an electron, travelling through space. @@ -189,7 +189,7 @@ Let's get down to business, our starting point, the {url Schwarzschild metric;ht {b YOUCH!} -The variables themselves aren't that bad: {` c} is the speed of light, <code>τ</code> is time, <code>Ω</code>, {` t} and {` r} are Schwarzschild coordinates. +The variables themselves aren't that bad: {` c} is the speed of light, {` &tau\;} is time, {` &Omega\;}, {` t} and {` r} are Schwarzschild coordinates. However, as you can see, there are two big problems: we have to calculate derivatives (that's what the {` d} signifies) and convert from Schwarzschild coordinates to normal (euclidean) coordinates, that the computer understands "natively". This would be {b too slow} to render in real time. @@ -232,53 +232,43 @@ Although the function takes in only one argument, {` r}, that doesn't mean that - {` h} is the magnitude of the {url "specific angular momentum";https://en.wikipedia.org/wiki/Specific_angular_momentum} of the light "particle". - .p "Normal" linear momentum specifies how much "force" at what speed it takes to stop (or change) the speed and direction of an object in linear motion (that's why it's in kg\*m/s). Imagine a big heavy train on a perfectly straight rails going at a fast speed. How do you forcefully stop it? - .p You can put a {i really} heavy barrier on the tracks, in front of the train. Since the train is moving at a really great speed, this barrier will have to be much much heavier (with much more mass) than the train itself. - .p Alternatively, you can "launch" something against the train, meaning you can put a second train, moving in the opposite direction of the first train, so they hit head-on. Since the second train would also be moving, if it's travelling at the same speed and has the same mass as the first train, upon collision they would both stop{fn Of course, I'm assuming the trains are strong enough they won't break upon the collision.}. If the second travels at twice the speed, then it can have half of the mass of the first to produce the same effect. - .p The property with which we can "prove" why both a larger mass at no speed, and a smaller mass at a faster speed, can stop the train, is the momentum. - .p Angular momentum specifies how much "force" at what speed it takes to stop (or change) the speed and direction of a rotating object. Imagine the train scenario but on a circular track. - .p The specific angular momentum is the angular momentum of an object, divided by it's mass. It's magnitude kind of tells us which property is more prevalent in the momentum, the mass or the speed. For the same angular momentum, a long (big magnitude) {i specific} angular momentum means our object is small and moves fast, while for a short (small magnitude) {i specific} angular momentum out object is large and moves slowly. - .p Another simplification we need to is {b make our black hole stationary}! Then, rather than finding the angular momentum{fn Angular momentum is actually {url defined using the cross product;https://en.wikipedia.org/wiki/Specific_angular_momentum#Definition}} and dividing by the mass{fn As mentioned, light has no mass, so this version of the formula wouldn't work.}, we'll use another formula: - .p {img ./img/specific-angular-momentum-wikipedia.png} + {img ./img/specific-angular-momentum-wikipedia.png} - .p where {b in this specific formula only} {` r} is the vector from the singularity to the corpuscle and {` v} is light's velocity. - .p The cross product returns a vector, so we'll need to take the magnitude of the result and plug that into the formula. It's also important that {b we calculate it only once, in the beginning}. So, we shouldn't be calculating the magnitude of the specific angular momentum every time the light "particle" is moved, rather we calculate it once, after it gets close enough to be affected by the black hole. - .p You might think that makes no sense, since we cannot divide by zero, so the specific angular momentum shouldn't exist, but then with the cross product we find a value for it. You would be correct: Antonelli does some funky approximations, combining Newtonian physics with General theory of relativity, to make the formula that simple. - {` r{^ ^}} is the normalized ({url unit;https://en.wikipedia.org/wiki/Unit_vector}, hence the {` ^} on top) vector from the center of the black hole to the light particle: - .p {img ./img/normalize-vector-wikipedia.png} + {img ./img/normalize-vector-wikipedia.png} Finally, putting all needed variables together in one proper function, we get: @@ -324,7 +314,7 @@ Formula: {img ./img/isco-wikipedia.png} Putting them all together, we should expect light to travel like this: -{img https://upload.wikimedia.org/wikipedia/commons/2/27/Black_Hole_Shadow.gif} +{img https://upload.wikimedia.org/wikipedia/commons/2/27/Black_Hole_Shadow.gif}{br} {i Animation by Hugo Spinelli on {url Wikipedia;https://commons.wikimedia.org/w/index.php?curid=138168679}} ## Light-bending algorithm @@ -349,11 +339,11 @@ An algorithm doing this would look a bit like this (in pseudocode, inspired by P {img Refer to "Algorithm" section of the Appendix;./img/algorithm.png} -as a reminder, here is the definition of {` F{^ →}}: +as a reminder, here is the definition of {` F{^ &rarr\;}}: {img ./img/antonelli-formula-expanded.png} -<br/> +{br} That's it! We have all of our theoretical background, formulae and algorithm to start work on our actual program. diff --git a/src/blog/turn-off-notifications-windows/index.du b/src/blog/turn-off-notifications-windows/index.du index 4215d81..8b0a204 100644 --- a/src/blog/turn-off-notifications-windows/index.du +++ b/src/blog/turn-off-notifications-windows/index.du @@ -16,10 +16,8 @@ What if you need to concentrate on some work, and you don't want to have your no {img ./img/windows-settings-notifications-off.png} - .p {i Note: "Suggest best ways", "Welcome Experience" and "Tips and tricks" will still show up, you'll have to uncheck those individually} - .p If you want to turn off notifications for specific apps, scroll down to the {b Get notifications from these senders}, find the applications you want to turn off notifications for and flick the switch {img ./img/windows-settings-notifications-application.png} diff --git a/src/blog/virt-manager-freeze-on-browse/index.du b/src/blog/virt-manager-freeze-on-browse/index.du index a5646cf..ff6bdfc 100644 --- a/src/blog/virt-manager-freeze-on-browse/index.du +++ b/src/blog/virt-manager-freeze-on-browse/index.du @@ -9,9 +9,7 @@ The title explains what the problem is. You might've also noticed that it spikes a CPU core's utilization to 100%. Furthermore everything works if you enter a file location manually in the corresponding input field, it's just that darn button. -'footnote storage-pools The storage pool is just a folder with files that store what locations can be used by virtual machines (more info {url here;https://libvirt.org/storage.html}). In the case of virt-manager, pretty much every time you select any folder or file, a folder entry gets added there. - -This issue is caused by some sort of problem with the storage pools{storage-pools} when it tries to load them. +This issue is caused by some sort of problem with the storage pools{fn The storage pool is just a folder with files that store what locations can be used by virtual machines (more info {url here;https://libvirt.org/storage.html}). In the case of virt-manager, pretty much every time you select any folder or file, a folder entry gets added there.} when it tries to load them. I was able to fix it by pretty much deleting that folder, but you really should just rename it: ```sh @@ -21,3 +19,5 @@ libvirt automagically regenerates the original folder, so you might need to rest ```sh sudo systemctl restart libvirtd + +{footnotes} diff --git a/src/blog/windows-run-dialog/index.du b/src/blog/windows-run-dialog/index.du index 5269555..179a54a 100644 --- a/src/blog/windows-run-dialog/index.du +++ b/src/blog/windows-run-dialog/index.du @@ -80,7 +80,7 @@ But, whats more important is that you can more easily launch some Windows apps, |: Sound Recorder |: {` wuapp} |: Windows Updates -|: {` shutdown}\* +|: {` shutdown}* |: Shutdown or restart computer |: |: @@ -113,7 +113,7 @@ But, whats more important is that you can more easily launch some Windows apps, |: {` sigverif} |: File Signature Verification Tool -\*: The {` shutdown} command {url requires parameters;https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/shutdown}: +*: The {` shutdown} command {url requires parameters;https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/shutdown}: .bulleted - {` /s} will shutdown in one minute diff --git a/src/teaching/oop-2023/week1/good-software.du b/src/teaching/oop-2023/week1/good-software.du index bb19eb0..237cec2 100644 --- a/src/teaching/oop-2023/week1/good-software.du +++ b/src/teaching/oop-2023/week1/good-software.du @@ -319,6 +319,7 @@ void generateLayer(char** layer, int rows, int cols, Решения със слоеве правят същото. Лошо - {` doX()} при циклите: ```cpp +'emplace void generate(char*** board, int rows, int cols, int layers, char* tiles, int* tileCounts, int tilesSize) { ... @@ -328,6 +329,7 @@ void generate(char*** board, int rows, int cols, int layers, } while(layer[x][y][layer] != ' '); ... } +'endemplace Без абстракция отново ще пренапишем голяма част от {` generate} функцията, за да се побере на слайда съм оставил само "най-сложната" промяна - случайните стойности. diff --git a/src/teaching/upp-2023/week12/index.du b/src/teaching/upp-2023/week12/index.du index ed4dc89..c54114c 100644 --- a/src/teaching/upp-2023/week12/index.du +++ b/src/teaching/upp-2023/week12/index.du @@ -90,21 +90,25 @@ GitHub classroom: {url classroom.github.com/a/KEDSxDjl;https://classroom.github. |: ``` +'emplace 5 11 - - # # - - - - - - - - # - - # - - - - - - -\# - - - - # # # # # # +# - - - - # # # # # # - # - - # - - - # - # - - # # - - - - - - - 2 2 +'endemplace |: ``` +'emplace - - # # - - - - - - - - # # # # - - - - - - -\# # # # # # # # # # # +# # # # # # # # # # # - # # # # - - - # - # - - # # - - - - - - - +'endemplace diff --git a/src/teaching/upp-2025/week13/index.du b/src/teaching/upp-2025/week13/index.du index d8edf79..f73b1f9 100644 --- a/src/teaching/upp-2025/week13/index.du +++ b/src/teaching/upp-2025/week13/index.du @@ -504,7 +504,7 @@ He should not have built the fire under the pine tree. Трябва да върнете (приближение на) екцентричната аномалия, като рекурсията ви трябва да се "вложи" максимум "дълбочина" на брой пъти. За дъно на рекурсията, може да върнете стойността {` M}. -Използвайте {` <cmath>} за синус функцията. +Използвайте {` {nohtml <cmath>}} за синус функцията. :table :2 |