Also it's a bit dumb to store a CP437 character on i32 because that codepage has only 256 entries (meaning 3 zero bytes overhead for every cell).
All in all I would rather store such character art in ANSI escape sequences (that's actually a sort of run-length-encoding), much smaller files, easier to decode.
You lost me there. Why are ppl still using this electron monstrosity when there are so many better alternatives? (Like dd, WIN32Imager, USBImager, DiskImager, etc.)?
I mean, Etcher is bigger than the entire NetBSD image, what the hell?
This is one of those things that SystemD can make more complicated. When you DD a disk image on something it rewrites the disk header, which can cause SystemD to reparse the header and do some weird stuff with the device that causes the write to fail or get corrupted. Etcher works around that problem.
That said, the more lightweight "Disk Image Creator" also gets around this problem without dragging in an entire self contained browser.
> You usually don't even need dd, plain cat device is fine
Definitely not. In fact, even dd is insufficient unless you use os specific flags to flush the disk cache, otherwise your stick might be corrupted. Read about the fdatasync syscall.
For what it's worth, probably not much, net/openbsd still has raw devices /dev/rsd1a vs /dev/sd1a(the block device) while it looks like linux made them all block devices (unless opened a special way O_DIRECT) and freebsd(as best I can tell) made all devices raw. https://docs-archive.freebsd.org/doc/11.2-RELEASE/usr/local/...
So, on openbsd, make sure you use the raw device when writing images with dd, and in my experience you want to use dd because the block size on cat is too small. dd bs=64k if=image.file of=/dev/rsd2c (c on obsd is entire disk)
May not work, OS dependent. According to POSIX "sync" flushes the file system level buffer cache of opened files, and not necessarily the block device cache inside the kernel. (Eg. "sync" flushes devfs under /dev, so updates the /dev/sda directory entry, but maybe not the block cache of the (8,0) device.)
There's a good reason why the dd command exists, believe me.
I like it. It’s cross platform, so you can recommend it to anyone. It prevents you from writing to system disks accidentally. It verifies the image after writing.
Who cares if it’s an electron monstrosity? It’s a portable executable, you run it once and then never again.
> It’s cross platform, so you can recommend it to anyone. It prevents you from writing to system disks accidentally. It verifies the image after writing.
USBImager likewise, cross-platform, stupid-proof, verifies write, decompresses on-the-fly, but it's multilingual too and does not collect your data like Etcher. All of that in just 300 kilobytes in a single portable executable.
There are a few too many Linux builds, imo, that I wouldn’t feel comfortable recommending it to a newbie Linux user. It looks like on Linux that the authors are obsessed with making the smallest possible binary instead of the smallest possible binary that runs anywhere.
> It looks like on Linux that the authors are obsessed with making the smallest possible binary instead of the smallest possible binary that runs anywhere.
Yep, the site offers a download link to a binary that should work everywhere (small JS detects OS and arch). The default Linux binary even has an embedded Unifont and implements its own widgets to avoid as much dependency as possible (this version is 800k because Unifont takes a lot of space).
But if you want, there's a smallest version too in the repo (uses GTK widgets and fonts installed on the system, calls the portal for open file modal, and relies on udisks2 daemon to access the device without privilege). This latter also downloadable as .deb (Ubuntu and RaspiOS ARM too).
I'm not who you're replying to, but maybe alternatives need better marketing. However I'm going to check this out and if I have a good experience I'll recommend it to people I know in the future instead. Thanks.
You're misrepresenting the parent comment. It's making the point that work on the project is not free (and could thus be unsustainable despite people desiring updates to bugs or security issues) even if access to the source is free.
However, I do get the feeling from your other comment that you have an axe to grind against this project, so I won't expect high standards.
> You're misrepresenting the parent comment. It's making the point that work on the project is not free
Che? It literally says "people who use the software for their work", and not "people working on MbedTLS". Also, MbedTLS is distributed under a Free and Open Source license, therefore devs rightfully assume to get the latest source under the terms of that said license.
And for the records, the announcement is about MbedTLS being discontinued and only keeping PSA, it's not about a license change or not being free, or whatever.
> I do get the feeling
And you're obviously wrong.
> you have an axe to grind against this project
:FACEPALM: yeah, dude, I've chosen MbedTLS for several projects and have used it for many years because I always wanted to axe it... And I also wanted the latest versions not to compile and not to work with codeberg, may I presume...? (sacrasm)
> I won't expect high standards.
Dude, you misinterpreted the original post and tried to falsely accuse me. Are you seriously trying to talk about standards?
That's nonsense. I've been using MbedTLS for years now in lots of FLOSS projects, and it's biggest mistake was forcing that terrible and buggy PSA API (a mandatory git module in MbedTLS which does not even compile without dirty hacks (*)).
Now they are saying that MbedTLS is going to be discontinued and only the shitty PSA remains? They have lost their minds, time to look for another Open Source alternative, I'm afraid. :-(
(*) - after days of debugging, I've found that an uninitalized variable bug in psa_crypto_mac.c prevents my https client to download files from codeberg. I had to apply a patch to make it work: https://codeberg.org/bzt/ludus/src/branch/main/src/lib/mbedt... That's how "great" PSA is.
He was definitely not "mostly golfing", he was actively destroying US allies and was actively helping US adversaries, and obvious from the Capitol incident that he already started building a fascist dictatorship.
> The damage he did was low-to-moderate, all things considered.
I don't think that's true. I'd say it was more like a Phantom Menace, like arming a ticking bomb with a postponed effect.
> Now, the damage is beyond repair. The USA is fucked, on a downward spiral that will be difficult(near impossible) to correct.
Yeah. Instead of MAGA, he managed to loose the USA's remaining superpower status in just a few years, that's some achievement history will surely remember.
But I don't think everything is lost, although extremely hard and might take at least a century or so to correct (assuming no further damages, that China won't take over and of course that there will still be a human civilization to speak of by the end of the century).
From the perspective of the architects of his policies, The Heritage Foundation, things are roughly going as they want, and these losses are a price worth to pay to ensure what they want to happen, happens.
Their perspective is relatively simple. Unhinged, but simple.
They believe the US is strictly incapable of remaining as the sole global superpower, and that due to cultural this and that, risks falling into a middle power or worse. Hence, they want to resuscitate the pre-WW1 notion of imperial Spheres of Influence, in which the world is carved between Great Powers that dominate their surroundings, and to make sure the US stays as one for decades to centuries. The US Sphere would be the Americas plus a small piece of Europe.
For this to work, a few things are needed:
a) The middle powers, and the weak countries, must all learn their place, that they have no real agency, that they must submit to the Great Power that dominates the sphere they're inserted into, and that if they revolt they're going to experience all manners of pain, from economic warfare to actual hot war in their territories.
b) The other strong countries must agree with this project, so although they're enemies on the long run, they must unite in the process of carving the world into those Spheres, and not to interfere too much with the other powers doing their own carving. Any current potential interference (Taiwan, Ukraine, Iran etc.) is a piece in the table to be used in negotiating the future frontiers between their Spheres.
c) And, internally, a shared culture, where the majority becomes supportive of this via the indoctrination appropriate to each case for the long run.
That's the gist of it. Everything else, including the public face of the implementation, are details that can be replaced as long as the overall strategy keeps advancing.
If an agent has goal A, and they believe (strong believe) the way to reach A is via method P, and that any criticism of P is invalid no matter what, they will keep trying P until it arrives as A, since they know P eventually leads to A.
Reality doesn't care about strong beliefs though. If reiterating over P in reality leads to result B, that's what doing P will achieve, always and invariably.
This problem affects an immense number of things. In economics a prime example is Marxism. If you read the goals (A) of Marxism, they're pretty nice, all things considered. The problem is that Marxism (P) doesn't lead to those results, but to a very different set of outcomes (B). And since ideological purity requirements never allow P to be questioned, all it keeps resulting in is B, irrespective of how amazing A would be if P in fact led to A.
With American conservatives in general, and MAGA in particular, it's the same. A, B and P are different, but the dynamic is the same.
> If an agent has goal A, and they believe (strong believe) the way to reach A is via method P, and that any criticism of P is invalid no matter what, they will keep trying P until it arrives as A, since they know P eventually leads to A.
> Reality doesn't care about strong beliefs though. If reiterating over P in reality leads to result B, that's what doing P will achieve, always and invariably.
Yeah, some say that repeating the same thing and expecting different result is the definition of stupidity.
> If you read the goals (A) of Marxism, they're pretty nice, all things considered. The problem is that Marxism (P) doesn't lead to those results, but to a very different set of outcomes (B).
I'm not sure. I mean nobody knows if it could lead to its goal, because Marxism in practice is yet to be seen. What the USSR implemented was not Marxism (and not even Communism), but in fact Leninism and Socialism. This latter is a freaky, twisted, sick version of it with an actual ruling class, no different to the bourgeoisie or the former feudal nobility (Stalin effectively acting like a czar and his inner circle being the new nobles).
> With American conservatives in general, and MAGA in particular, it's the same. A, B and P are different, but the dynamic is the same.
So true. But I would go even further, the actual ideology (P, A) doesn't matter at all. The root cause of the problem, just like you've said, is "ideological purity requirements never allow P to be questioned". When there's no feedback on P (or worse, only false positive feedback given), then this is technically flying blind, no matter what the ideology in question is, the result will surely be an epic fail and fall (since A != B).
IMHO, although Marxism has some good insights, it's a very limited analysis of reality due to the necessity of framing things within a Hegelian framework, while at the same time ignoring, for example, the most recent peer-reviewed, reproducible discoveries in psychology and neuropsychology. That lack of the later causes all manners of misalignment when real people, and the whole psychological spectrum they comprise, have to intersect with that framework and its implications.
There are some kinda-ish modern, more nuanced versions of Marxism that may be more successful than orthodox variants in that. The Frankfurt School had some quite interesting developments there, such as incorporating Freudian psychology through Lacan, but that is itself already very dated by decades. Also, its approach requires abandoning or inverting many premises of orthodox Marxism, such as, for example, by accepting that in many cases it's the superstructure that determines the infrastructure, not the other way around, so they exist in a tensional relation, which leads adepts of orthodox Marxism to call Frankfurtians revisionists and not to want to hear much more.
So I suppose a fully modernized Marxism incorporating everything modern human sciences has to offer could do reasonably well, but it'd be extremely different from both old school Marxism, as well as from the Frankfurtian revisions.
I personally think that Marxism is a complete non-sense. His premissas were correct (being based on historical facts), but his conclusions were absurd wishful thinking at best. No modernization could help that. I'm not sure about this, just IMHO.
I mean yeah, at the end of the day increasing inequality always leads to unrest and revolt, sure, that's undeniable. Happened numerous times in the past, it is happening in the EU right now, and surely will happen in the future too. But I don't believe this can be solved like Marx imagined, even with psychology and neuropsychology added to the mix.
IMHO a strict, exhaustive, well thought-out, rule-abiding system with rock-solid breaks and balances is necessary at a minimum, not unlike how Solon and Cleisthenes reformed the entire system in ancient Athens. Demokratia was very different to today's democracy, it was an air-tight system that covered all corners without any loopholes. For example, voting was considered a work, therefore voters got paid (which made vote-buying futile, making the whole process corruption-free), and thanks to public lottery it was impossible to bribe or persuade the judges, as nobody knew in advance who they will be. It was a system that aimed for rights must not be influenced by wealth and status (which is the total opposite of today's democracies, where only the wealthy can run for presidency and have a say in lawmaking, not the common people).
IMHO fighting inequality can't be based solely on some ideology (maybe with psychology on top), but must be a multi-disclipinary effort covering all aspects of society like in demokratia. I'm not sure if even this could succeed (Greeks failed after all), but I'm sure without it will just reproduce the vicious cycle that Marx spoke of.
Oh, sorry, we have derailed the topic a bit, hope other readers don't mind.
When it comes to the economic side of things, I believe the best approach right now is to learn all major schools: mainstream economics plus Keynesianism, Libertarianism, Marxism, Distributism and at least a handful of minor ones. That helps to untie one's mind from holding too strong beliefs in what still isn't a science but at some point maybe become one.
On the political one, I fully agree. In fact, I wish lottery was used extensively, including for executive roles. There's research showing it results in way better outcomes all around, as politics ends up somewhat close-ish to having traits similar to the average of a population, rather than lower than it, as in other models. Alas, getting there from here is almost impossible. Too bad.
I scorn trump as much as the next socially-adjusted human, but this is overstated:
> he managed to loose the USA's remaining superpower status in just a few years
America is still the most powerful military force and the largest economy, and mickey mouse has recognition in places where they carry water from wells in pots. A beast that size keeps lumbering a long time after brain death.
Trump has shredded other nations' trust in America as a partner, but he has not made it possible to ignore. Ignoble but not ignorable.
If we run the clock forward, then declining arms exports due to sovereignty concerns wool make the USian defence industry harder to sustain. But that takes decades to play out.
> America is still the most powerful military force
Not true (not anymore). China always had more manpower for recruitment, their current navy fleet is already bigger (64 submarines both, but 4 times as many ships than USA), moreover Chinese fleet is top of the line and brand new, while USA's is old and rusty. Chinese are way ahead in space too. God knows what technology they have in their military satellites and in Tiangong. They have already demonstrated (potential) military maneuvers in space that US military is just dreaming of. https://interestingengineering.com/beyond-earth/shijian-chin...
> Trump has shredded other nations' trust in America as a partner, but he has not made it possible to ignore.
I'd argue that other nations are now working on solutions to exclude the USA as much as possible on every front possible, so basically to ignore. Agreed, they are not there yet, but they are actively working towards to that goal so they will be there (and sooner than later). The problem with loosing trust is, they will look for alternatives, and once found, they won't switch back, even after Trump's long gone. Regaining trust is much harder than loosing it.
FYI, Trump's f*ckup is much bigger than you realize.
There appears to be a crossing point, which you say has happened already, where China is the greater superpower. I think that point is still approaching. We do not disagree by much.
I'm not a military buff, but a couple of tubers say that China's navy includes a lot of coastal tonnage.
In China's favour, they seem to be getting more R&D "purchasing power". Against them, the demographics. The space race is wide open. I could believe they have the space military advantage, but frankly, if you can lift tonnage into space then you can drop tonnage onto cities from orbit.
Do not underestimate the power of Hollywood to set the frame for political conversations everywhere. Apart from anything else, immigration is America's safety net against demographics.
> There appears to be a crossing point, which you say has happened already, where China is the greater superpower. I think that point is still approaching. We do not disagree by much.
I'm not sure if there's one explicit crossing point. All I see is, as time passes China is gaining on the USA in more and more fields. I'm not sure if they already have the advantage in most fields, or in the most important fields, but if things do not change, they surely will.
> I'm not a military buff, but a couple of tubers say that China's navy includes a lot of coastal tonnage.
Could be. But it's worrying that they have 4 times as many ships and numbers are growing.
> In China's favour, they seem to be getting more R&D "purchasing power".
Not just that. I can't cite any scientific paper in the last decade which does not have at least one Chinese name as its author. They got the know-how while USA was paying the bill...
> The space race is wide open.
Maybe. But only China is able to sustain its own space station, nobody else.
> Do not underestimate the power of Hollywood to set the frame for political conversations everywhere.
Not any more. Since Scientology took over and brainwashed people started writing the scripts, everybody is laughing at Hollywood and their expensive but shitty movies (just take a look at box office numbers outside of the USA). And the last nail in their coffin was the rise of streaming, Hollywood has already lost its power too. https://planetoffilms.com/hollywood-box-office-failures-2025...
> Apart from anything else, immigration is America's safety net against demographics.
And also the reason for its success. Von Neumann, von Brown, Einstein, Pulitzer, Schwarzenegger, Natalie Portman, Henry Kissinger, Nikola Tesla, Rupert Murdoch, hell, even Elon Musk is an immigrant.
Thanks to Trump and it's ICE rampage, now great minds are literally fleeing the USA. https://www.scientificamerican.com/article/u-s-scientists-ar... Again, by loosing these people USA will surely loose the advantage in R&D too, if haven't lost it already.
The damage was small because other countries assumed he’d be a 1 term president.
Like Iran didn’t retaliate for US assassinating their leaders in term 1.
But also because every day builds on the previous one. His first year he hadn’t figured out he could use CBP (ICE) to remove US citizens from protests but by year 4 he had figured it out.
More importantly, where the name is originating from, is the DOS driver. By default DOS did not interpret color codes, one would have to load ANSI.SYS for that, and that's where the term "ANSI art" comes from. See https://en.wikipedia.org/wiki/ANSI.SYS
> There is also a debate as to whether Unicode/Utf-8 characters with ANSI and Xterm escape codes constitutes "ANSI art." Some are calling it "UNSI art," or just modern terminal art.
Yes, they do. Escape sequences have nothing to do with the encoding and code page (all characters in CSI and SGR are ASCII only, hence the same in both CP437 and UNICODE and even as UTF-8 encoded). Using the name "UNSI art" for these is good practice though to explicitly indicate UTF-8 encoding (and maybe the existence of non-standard SGR sequences, like 24 bit RGB colors).
I have a project (interactive textual adventure) where I convert graphics into ANSI/ASCII art on-the-fly. I've implemented several methods, you can choose between them with CLI flags (including different escape sequences and charactersets as well). See https://gitlab.com/bztsrc/meg4_advgame/#playing-in-a-termina...
I think that you need to re-read "escape sequences" and "American National Standards Institute" a few more times until it clicks that these are two entirely different noun phrases.
Then you need to learn a lot more about control sequences.
You can start with CSI, value 0x009B, not being an ASCII character. Then proceed to ITU T.416 (ISO 8613-6) where the SGR control sequences for indexed and direct RGB colours are standardized. Then you can learn that the "E" in ECMA-48 does not stand for "ANSI", but for "European". And finally you can discover that ECMA-48 standardizes exactly 8 colours. 16 colour SGR sequences beloved of CGA-like and VGA-like art are not in the standards and are in fact the product of IBM's AIXterm.
> I think that you need to re-read "escape sequences" and "American National Standards Institute" a few more times until it clicks that these are two entirely different noun phrases.
LOL, why is the page called "ANSI escape code" then? Why were the driver called ANSI.SYS then? I think it is you who should re-read that escape sequences were standardized by ANSI a few more times until it clicks.
> You can start with CSI, value 0x009B, not being an ASCII character.
CSI is NOT 0x009B (in fact C1 shorthand is not supported anywhere, not in the old 7-bit video terminals, and not in the modern UTF-8 aware terminal emulators either, and definitely wasn't supported by ANSI.SYS, hence no ANSI art uses it, never ever).
From the wiki page, I quote: "For Control Sequence Introducer, or CSI, commands, the ESC [ (written as \e[, \x1b[ or \033[ in several programming languages) is followed by any number (including none) of "parameter bytes" in the range 0x30–0x3F [...]"
That's all 7-bit ASCII characters in the full sequence (introducer, parameters, separators, terminators as well), dude. It is definitely you who should re-read a few more times until it clicks.
> Then you can learn that the "E" in ECMA-48 does not stand for "ANSI", but for "European".
Then you can learn that the driver that give the name "ANSI art" was called ANSI.SYS and not ECMA.SYS. Doesn't really matter which standard TBH, because the driver was called ANSI, period.
> 16 colour SGR sequences beloved of CGA-like and VGA-like art are not in the standards
LOL, one: CGA had 4 colors and not 16, and second: the 16 colors in SGR are defined by the standard alright. See for yourself, ECMA-48 section 8.3.117 page 62: https://www.ecma-international.org/wp-content/uploads/ECMA-4... (8 base colors named explicitly and their "increased intensity" variants in mode 1 (page 61), thus making up 16 colors in total).
CGA in text mode and low resolution graphics mode had 16 colors. So did CGA composite color graphics. Normal CGA graphics mode is 4 color. Hence why ANSI.SYS supported 16 colors in 1983, a year before EGA was introduced.
Since text mode essentially works like ROM tiles (character glyphs) on an 80x25 grid, the 16kb of CGA is enough to store color information (RGB and Intensity bits) for reach cell.
Yep, I agree. You can already run them locally on a top-shelf gamer PC with decent token throughput: https://github.com/Niko1221/Strata That's today.
As for tomorrow, consider that literally every chip maker is working on better and better NPUs to boost local performance (Ryzen AI, Intel Ultra, Apple M7, Broadcom PON, Huawei Ascend, Snapdragon X Elite, etc.), and imagine optimized models running on these, yeah, insanely huge potential.
As of 2026Q4 I wouldn't bet on any cloud AI, that's for sure.
This is too bloated to my taste. I've written a similar solution, but mine is a dependency-free single function only library, uses military-grade encryption and has multi-arch, multi-language support too (JS, PHP, Python, Lua, C).
File :: struct { version: i32, layers: []Layer, }
Should be
File :: struct { version: i32, count: i32, layers: []Layer, }
Also it's a bit dumb to store a CP437 character on i32 because that codepage has only 256 entries (meaning 3 zero bytes overhead for every cell).
All in all I would rather store such character art in ANSI escape sequences (that's actually a sort of run-length-encoding), much smaller files, easier to decode.
FYI, besides REXPaint, there were other binary ANSI art formats too, like BIN and XBIN (https://deepwiki.com/andre-simon/ansifilter/7.4-bin-and-xbin...), but those could not break the hegemony of ANSI escape sequences either.
reply