1. 2

    I’m sorry you had a hard time with this. Did you not keep the old machine around while you were setting up the new one? Whenever I upgrade the OS on my VPS I do that. I also tend to tarball the whole disk rather than try to select files and then I keep the tarball around for a few months after I case I had forgotten something.

    1. 3

      I was thinking the same, but it seems that OP is trying to change the OS in place. I imagine it is a vps with longer term commitment, not a hetzner cloud instance.

      1. 2

        I think it’s a Hetzner dedicated server, with monthly rates and a setup fee.

        The following reads sorta like nitpicks, I know. I’m thinking aloud.

        I would have considered rsynced tarballs elsewhere; tarsnap can be slow in cases with latency to an East Coast AWS region, like, say, Germany. GPG tarballs to s3 or to Hetzner storage sound ok.

        It’s nice that it’s all in Docker. My last Alpine experience was unpleasant; any space savings were countered by lack of operational context and image caching anyway.

        If I was worried about downtime I’d maybe doing a prototype / trial migration to a vps with hourly or daily rates.

        A benefit of sticking to tarsnap is that it would show any gaps in backup coverage, such as the .env file here. Unfortunately, by doing this in place, it only surfaces any issues too late.

        The self-hosted Bitwarden blip feels … very close to a very serious outage, too.

        Thanks for the honest recap!

        1. 1

          I ran them all with docker-compose from a Debian VPS.

          Doesn’t sound like it was a dedicated server.

    1. 5

      I was such a heavy vagrant user years ago. I had single node and multi node hadoop cluster in vagrant and it just worked. I took it from job to job and was happy with it. Nowadays I use more docker and cloudy things, but I am happy to hear that they are still investing into vagrant.

      1. 8

        How do you know if somebody does not use a debugger/line numbers/syntax highlighting? They are going to tell you!

        Seriously though, what is that? Trying to show how smart you are? I use the excellent debugging facilities of Intellij for java, python and js almost daily and would not want to miss them. I have debugged hairy classpath issues in datacenters on other continents with my IDE. It is a wonderful tool. The thing is though, that unlike Mr. Professor here I can’t do green field development, but have to work in big messy production code bases.

        Sorry, but this really annoys me.

        1. 3

          Seriously though, what is that? Trying to show how smart you are?

          So here’s an example from personal experience. I program with extremely limited syntax highlighting. Everything is in black font, except for comments which are (a fairly bright, almost garish) green. It’s limited enough that I’ve had coworkers ask how I work without syntax highlighting, so I’ll claim to qualify as using “no syntax highlighting” :)

          I have a not all that rare, but uncommon enough corneal disease. It reduces my visual acuity. The low contrast themes that seem to be perpetually in vogue (think Zenburn, Solarized, Gruvbox) can have elements that contrast so poorly with the background that I would need to crank the font up to a huge size to really see and read them. And if I don’t make the font uselessly big, I find myself working harder to read the thing someone tried to hint away from me with a low contrast color choice - talk about irony.

          When I have attempted to yak-shave my way to a color scheme that I can see well, I’ve found that what it tells me doesn’t actually help me in any meaningful way: I don’t need to highlight “function”, I know I’m in a function because I trust my editor/style enforcer to set the right indentation, because I jumped to the tag, because I navigated by balanced expression - whatever. And because I’m an easily distracted person, the visual noise from a screen filled with colors denoting data types, control structures, function calls… it’s just too much cognitive load. So I turn it off – with the exception of comments, but that’s easy for my brain, “black is live, green is dead”.

          I can’t defend the others, but that doesn’t mean they are indefensible. Of course, it’s also quite possible that those choices are ascetic cargo culting of the bad old days too.

          1. 4

            I have a not all that rare, but uncommon enough corneal disease. It reduces my visual acuity.

            This makes a lot of sense to adapt to a unique setup based on what works for you personally! A lot of “I don’t need syntax highlighting” talk feels more like “I don’t need this and neither should you” which comes across as a superiority complex on top of just not understanding how the typical visual cortex processes color.

            1. 2

              I strongly agree with the low contrast color schemes, I can’t stand them either. I am not arguing that everyone should use any of the things I mentioned, I am just annoyed by people that try to show off by not using them and the article came across like that. To each their own.

            2. 2

              I’ll use an IDE when it doesn’t crash within five minutes of me using it.

              Seriously, every couple of years, I attempt to use an IDE, and without fail (starting from the late 80s mind you) I have not had one that did crash on me. And I wasn’t trying to load millions of lines of code into the thing—no, generally, just a single simple file and in five minutes, poof—there goes the IDE down in flames and forget it, I’m not wasting my time. I move back to my previous editor (back in the 80s to mid-90s that was PE from IBM, and from the mid-90s to today it’s joe because I now work mostly in Unix). They work. I don’t need an IDE per language, nor do I need a few gigabytes just to run the environment and by now, it doesn’t get in my way of editing.

              As for debugging, I can get by without one, and since I tend to play around with languages from time to time, a debugger might not even exist for the language I’m using. And oh, hey! At work I too have to deal with a big, messy production code base spread across three languages!

              Sorry, but programmers who have to use an IDE annoy me. Get off my lawn!

              1. 1

                joe

                Could you perhaps point me to a write up or a config/scripts repo with a good Joe setup? Just curious if I’m missing on something good here. :)

                1. 3

                  Sorry, I use the stock installation, no customizations. And I think I use three different versions (different computers) but I don’t recall for sure since all the versions I have work the same.

                  1. 1

                    Thanks, now you got my interest :) I’m always on the lookout for tools that just work with their default config.

              2. 1

                I agree that IDEs are very useful. But they’re also very slow. I have a license for IntelliJ IDEA via my university and have been very impressed with it. But it takes a non-trivial time to start even on my rather powerful desktop PC. And when I program on UNIX, I usually use hardware from the early 2000s. My favorite editor is (n)vi. On Windows, I usually use Notepad2.

                Would I like the tons of useful features that IDEs provide? Sure. But if I have to choose between useful features and low latency, I’ll personally choose low latency. I find I get by pretty well without the features. Vi’s ! and | commands are able to make up for much of the lost functionality.

                Not to mention the immense, confusing complexity of the IntelliJ GUI…

                1. 1

                  But it takes a non-trivial time to start even on my rather powerful desktop PC.

                  Sure, but an IDE is meant to be started once a day (or kept running all the time) It is the tool you are going to spend all day in, so I think it is fine if it takes a bit to start.

                  I program on UNIX, I usually use hardware from the early 2000s.

                  Luckily my employer gives me hardware that is less than 15+ years old..

                  My favorite editor is (n)vi.

                  I prefer more than one level of undo tbh. vim it is for me.

                  Not to mention the immense, confusing complexity of the IntelliJ GUI…

                  Any expert tool will be complex. A 3D modeling, CAD or photo editing tool will not be simple and obvous either.

                  1. 1

                    I prefer more than one level of undo tbh. vim it is for me.

                    Most vi implementations have multiple undo. Unlike Vim, however, most don’t have the Ctrl-R binding. Instead, you press . (period) to continue undoing, then u again to undo the last undo, then . to undo the previous undo, and so on.

                    Any expert tool will be complex. A 3D modeling, CAD or photo editing tool will not be simple and obvous either.

                    Eh, I think Photoshop has a pretty good interface, despite being an expert tool. For the most part. I’m quite comfortable in it despite knowing very little about it.

                    1. 1

                      Unlike Vim, however, most don’t have the Ctrl-R binding.

                      Ctrl-R is redo, not multiple undos though: https://vimhelp.org/undo.txt.html#CTRL-R

                      For the most part. I’m quite comfortable in it despite knowing very little about it.

                      well, then scratch the photo editor from the list. My point still stands.

                      1. 1

                        Ctrl-R is redo, not multiple undos though

                        Yeah, I mean that Vim uses uu for “undo two changes” and ^R^R for “undo two undos”, whereas many other vi implementations use u. for both (depending on which “direction” you’re currently going). uu is “undo one change and then undo the undo”, which makes people think that vi doesn’t have multiple undo.

                        well, then scratch the photo editor from the list. My point still stands.

                        Or perhaps other companies could learn something from Adobe :-)

                        In any case, I agree as others have noted that this whole discussion really is about employed programmers vs people who program their own stuff.

                2. 1

                  Or … different people work in different domains and benefit from different approaches? I’ve spent a lot of years debugging interactions between systems where logging, tracing, pcap, and other log-oriented tools have been more useful to me than debuggers. I’ve also spent lots of time debugging customer reported problems in on-premise installations that I don’t have access to - so robust logging becomes a supportability requirement.

                1. 15

                  I thought business news are off-topic here

                  1. 7

                    I don’t think it’s “business news”. Stream from conference is more like it, which I think is valuable content – if nothing else, then only for @calvin’s excellent summary.

                    1. 6

                      how are feature announcements for products of a publicly traded company not “business news”? I know Apple is loved by many, but if it was any other company, this article would be removed as off-topic very quickly. I think we should apply the same rules for all articles/companies.

                      1. 12

                        I’m reading because I develop for these platforms. It’s not just feature news for end users.

                        1. 9

                          Barring inflammatory threads, I think the users of the site, reflected in the votes, best decide what is valuable content.

                          1. 6

                            I really can’t wait for this ‘just let the market decide’ meme to die. Surely content and editorial policies are allowed on websites. Surely I can give my kids vegetables even if they just want fries and chocolate. Surely we can regulate fentanyl even if it proves popular with users. Is this a weird opinion now?

                            1. 6

                              Take it easy, it’s not like it’s my life principle or anything. Yeah, policies are fine. I’ve already said that I don’t think this is “business news”.

                              1. 1

                                Of course policies are allowed. And no, having policies isn’t weird. But it was nice back when Lobsters was smaller and we didn’t need policy*, when just community consensus was enough.

                                * except for extreme cases

                              2. 3

                                I had submissions removed that had 10+ up votes for being business news and therefore off topic. The moderation works differently here, well except if it is the fruit company, it seems.

                              3. 6

                                Something like an iphone announcement, sure. But wwdc is specifically the announcement of developer tools. “we’re adding async/await and the actor model to Swift” seems very much on-topic for this site and was one of the things they talked about today. “The new iphone will have NINE camera lenses” would be something that I would agree is off-topic, but that’s a separate event.

                                1. 3

                                  I agree with you regarding classification. But please take a look at the summary that Calvin posted. Does any of that text has developer related information, or has exactly the off topic info? “We improved maps”, “our watch can now do X”, and others are just plain marketing for end users, not useful information for developers. WWDC might be for developers, but this presentation ain’t :)

                                  1. 1

                                    Calvin’s post most definitely has information for developers. Sure, not all of it is really relevant to developers, but I think being able to make apps within the iPad, and using Xcode in the cloud on a non-MacOS device, is absolutely huge for enabling more people to develop Apple applications.

                                    There’s tons of APIs made available too now, which developers will need to start using in order to get on the App Store afaik (I think if you work around an API they disallow your app, but maybe that isn’t true?).

                                    All the other features might not be directly tied to code, but they are useful when looking at design decisions that devs may want to pick up on.

                                    1. 2

                                      I think this cuts deep into what people classify as relevant. For me, all the content from that presentation are news, something that I would normally find on the orange site. It doesn’t have any explanation how and why something works. Thus, I would disagree with your statement it is for making design decision, as no one would make design decisions based on the presentation alone, without going into documentation or some other relevant material to understand how the feature works(*). And that is the crux of my argument – the whole presentation is marketing for end users, some of which are developers.

                                      (*) now, that would be a great, relevant material to show up here, at least in my definition of relevant.

                                      1. 2

                                        That’s certainly a fair point to make, that it is just different classifications. I also wish they had gone more in depth into how certain features work (I’m looking at you, Private Relay and Email tracking protection [is it just on the mail client? what does it do if the tracked image is one that is visible to the reader?]).

                                        the whole presentation is marketing for end users, some of which are developers.

                                        I agree with this, and wish it were not the case :(

                                2. 4

                                  I disagree, we have an entire “releases” tag explicitly for announcements of products/features on both open source and proprietary technology.

                            1. 7

                              Good article. I’ve used FreeBSD on my servers with great success, but I recently installed NetBSD on my ThinkPad T41, because I couldn’t get FreeBSD working on it. I’ve been very impressed with it! I feel it’s a nice balance between simplicity and functionality. On OpenBSD, I was dismayed to find out that the r* commands have been completely removed.

                              FreeBSD Ports sometimes shows me a text menu for configuring package options

                              You can show all the configuration screens at once if you do make config-recursive. It unfortunately takes a while to load – maybe there’s a shell script somewhere waiting to be rewritten – but it’s a lot better than random configuration prompts showing up in the middle of compilation.

                              the pw man page is much scarier than NetBSD’s useradd.

                              I’ve never liked pw, precisely for the same reason…

                              1. 4

                                I’m curious, which r* commands? Like rlogin/rsh/rcp? I think it makes sense in light of OpenBSD’s security stance.

                                1. 3

                                  Yeah, those. Useful for connecting to old software/computers on the local network. IMO removing rsh because ssh exists is like removing HTTP because HTTPS exists. I enjoy OpenBSD otherwise, but I don’t like it when people decide what’s best for me.

                                  1. 1

                                    is like removing HTTP because HTTPS exists

                                    We are kind of doing that with HTTP/2. The browser vendors only support it in the TLS fashion, not the plain text way.

                                    1. 1

                                      Fortunately, HTTP/2 doesn’t obsolete HTTP/1.

                              1. 1

                                It is going to be really good weather, so my wife and I will spend quality time with our baby boy in the park. There is a train line and a river and he loves watching the trains and boats.

                                Otherwise baking bread on Sunday, maybe some cycling and if I find the time finally finishing a server consolidation of the various VPSs I accumulated for my personal projects.

                                1. 2

                                  Can someone with a better understanding of copyright assignment explain what the implications of this are? What will it mean practically for companies, individuals and users?

                                  1. 4

                                    Before, in order to contribute to GCC you had to give the FSF copyright of your change. Now, you don’t.

                                    This will make it easier to contribute, since the process of assigning copyright to the FSF is (I believe) nontrivial, and just saying “I assign copyright of this patch to the FSF” doesn’t work. In particular, people who work for companies that claim ownership of their employees’ free-time contributions may be more likely to accept a patch if it doesn’t require signing over their copyright.

                                    The other change is that this means that relicensing GCC would be harder, since now there are multiple copyright holders to the work. But I don’t think that GCC will be relicensed any time soon.

                                    The FSF also says that copyright assigntment is important for enforcement reasons, since only the owner of a copyright can enforce it and it’s easier if the entire codebase has a single owner. But in practice… when was the last time you saw any GPL enforcement?

                                    1. 7

                                      companies that claim ownership of their employees’ free-time contributions

                                      The fact that this is even legal is mind boggling.

                                      1. 4

                                        You can claim anything you want!

                                        It’s anyone’s guess whether the claim would hold up in court, so it’s basically a game of chicken. You’re a lot more likely to flinch first vs a million-dollar software company.

                                        1. 1

                                          In CA, it’s explicitly illegal to claim ownership unless the free-time contribution relates to the employer’s business. But if you work for a megacorp, they very well might take the position of “our business is everything”.

                                          1. 2

                                            I guess my point is that even in California, it’s in the company’s best interest to lie and say that they own everything, because the penalties for making a false claim are lesser than the benefits of intimidating employees.

                                            1. 1

                                              Yeah. And worst comes to worst, they can always say “give us this or you’re fired”. I dunno if that’s legal, but I also don’t want to find out.

                                            2. 1

                                              So that is the sinister side of letting people work on their own stuff at the office.

                                              Nice!

                                              1. 2

                                                Oh, this isn’t even at the office. If you work on stuff using company resources/on company time, everywhere in the US will just give that to your employer. This is about stuff you do on your own time at home!

                                                1. 1

                                                  If it came to that I’d start writing incredibly offensive stuff and give them full credit.

                                                  1. 1

                                                    Well, then you’d get fired.

                                                    Though, based on a friend’s anecdote, at least one megacorp is definitely way more likely to sign a copyright release for things related to pornography, and will even require you to not mention their name in connection with it…

                                                    1. 1

                                                      glad I don’t care anymore. You can only keep someone threatened and scared for so long.

                                                      funny how they don’t want that attribution when its seemingly not coinvent. At the same time it’s just begging for ‘rm -rf /’ to be attributed to them under the guise of their legal department.

                                                      I guess doing something a little more involved than changing twitter icons is a bit much for people these days.

                                      2. 3

                                        The FSF requires copyright assignment for two reasons:

                                        • It lets them change the license at will. When LLVM switched from the UIUC license to Apache 2 + GPL exemption, it required a complex process to get permission from all copyright holders (actually, from almost all and then to rewrite the remaining bits).
                                        • It gives them standing to sue for copyright violation and to settle violations.

                                        The first is important if you believe that GCC may wish to move to GPLv4 (or AGPLv3 or whatever) in the future. That may be a concern, but it took 20 or so years for the FSF to release GPLv3, so it’s probably not urgent. Note that the FSF could also unilaterally release the current version of GCC under the MIT license or something equally permissive and some of the concerns from contributors over copyright assignment relate to that: If some company managed to lobby / bribe / stage a takeover of the board of the FSF, then they could release all of the FSF-owned code under a permissive license, against the express wishes of the authors.

                                        The second one is more interesting. Somewhat ironically, the FSF makes (made?) quite a lot of its money as a purveyor of proprietary software. If a company is caught violating the GPL on any GNU projects, the standard policy for the FSF is to send them a cease and desist letter that gives them a time limit to get into compliance and offers them a time-limited proprietary license for the software from their first violation date until the deadline. If they accept, then they pay the FSF for the license and are now not violating anyone’s copyright and so have no legal liability (as long as they become compliant by the deadline). Compare this with Linux: if you’re violating the GPL on Linux, there are hundreds of people and companies who have standing to sue you and no single entity that has the ability to give you immunity from prosecution if you stop. It’s not clear how much of a problem that is these days.

                                        In terms of corporate contributions, it is generally quite difficult to get approval to contribute to the assign copyright in a lot of companies. This means that the GPL + copyright assignment ends up being the opposite of what a lot of folks here want from a license: it makes it easy for big companies to use the code but hard for them to give back.

                                        For individuals, it means you don’t need to send a piece of paper international post to be able to contribute. The FSF never paid me the $1 for my copyright assignment, so I don’t regard it as valid since they didn’t act in good faith (you can’t assign copyright without some recompense in the US, so the copyright assignment form says that they will pay you $1 in exchange). I wonder how widespread that is….

                                        1. 1

                                          If some company managed to lobby / bribe / stage a takeover of the board of the FSF, then they could release all of the FSF-owned code under a permissive license, against the express wishes of the authors.

                                          This concern seems unlikely. The copyright assignment papers you sign for the FSF have some wording that says the one of the conditions of assigning copyright is that the FSF won’t do something like completely changing the license.

                                          But the most important element of the assignment contract is the promise we make to every contributor and community member: We promise to always keep the software free. This promise extends to any successors in the copyright, meaning that even if the FSF were to go away the freedom of all users to share in the contributions wouldn’t.

                                          https://www.fsf.org/bulletin/2014/spring/copyright-assignment-at-the-fsf

                                          Since a weak license like MIT could compromise the freedom of a software package, it seems like it could be in violation of this promise.

                                          The FSF never paid me the $1 for my copyright assignment,

                                          Nowadays the exchange is usually a sticker. You didn’t get a sticker?

                                          1. 1

                                            Since a weak license like MIT could compromise the freedom of a software package, it seems like it could be in violation of this promise.

                                            The MIT license is on the FSF list of approved Free-Software licenses, so I think they could justify an MIT-licensed release.

                                            Nowadays the exchange is usually a sticker. You didn’t get a sticker?

                                            Nope, nothing. This would have been around 2003ish.

                                          2. 1

                                            The first is important if you believe that GCC may wish to move to GPLv4 (or AGPLv3 or whatever) in the future.

                                            This is really strange; most other projects I’ve looked at from GNU already use a “GPL v$LATEST or (at your option) any later version”. Does GCC omit this? If so, they could add it immediately before accepting the first non-assigned contribution, since at that point it’s still within their power to relicense.

                                            1. 3

                                              I am not a lawyer, this is not legal advice:

                                              As I understand it, the ‘or later’ doesn’t allow you to change the license, it just means that you may choose to be bound by only the later conditions. Without copyright assignment, the FSF could have started accepting new code under GPLv3 or later, but would not have been able to release GCC 4.3 with every source file updated to GPLv3 or later. They possibly would not have been able to incorporate GPLv3-or-later patches into GPLv2-or-later files either, though I’m much less sure about that. GPLv2 and GPLv3 were incompatible and so the combination of GPLv2-or-later and GPLv3-or-later is GPLv3-or-later (if you accept GPLv3 for any portion, you cannot accept GPLv2 for any portion).

                                              Not having to think about this kind of thing except as an intellectual exercise is a big part of the reason that I avoid FSF licenses.

                                        1. 4

                                          At the job I just left we used Phab and I liked it a lot. It was good at enforcing standards. Sad to see that there is no business in that. Github is eating everything, it seems.

                                          1. 14

                                            But why? Ain’t broken, do not fix it. Better cd? Seriously? Better cat? Seriously??? I wish I had the time to rewrite such trivial things in Rust for no good reason. Literally zero value is added by this.

                                            1. 27

                                              Literally zero value is added by this.

                                              This is literally false. I use bat for its syntax highlighting, and it is a significant value add for me over cat.

                                              1. 6

                                                But that is not what cat is for. cat is for concatenation, nothing else.

                                                1. 6

                                                  I used to use cat to quickly view short files in the terminal. bat replaced cat for me:

                                                  https://github.com/matklad/config/blob/f5a5a9db95b6e2123d2588fe51091fa53208c6e6/home/.config/fish/set_universals.fish#L28

                                                  I am sure that this matches significant fraction of usages when people type cat. I’d even say that viewing files + “priming the pipe” (for which <in.txt prog is the “proper” tool) represent majority of cat usages in the wild.

                                                  So, I don’t find “cat is for concatenation, nothing else” statement useful, as it doesn’t describe the reality.

                                                  1. 3

                                                    it does for me. I never use cat to view files, I either use less (sometimes more, if I am on a very restricted system) or vim. I think you could remove cat from my system an I would not even notice, that is how often I use it. Most cli heavy people I know tend to be similar.

                                                    1. 1

                                                      Then you were misused it as you should have been using less for viewing files. That is the purpose of pager.

                                                      1. 9

                                                        less is less convenient to me. I do not want to have to type q to close it, and I do want the file to be visible while I type further commands.

                                                        On a meta level, I just don’t get these prescriptivist comments. I would understand “less is more convenient than cat” framing, but what is the value of “cat should be used only for concatenation” statement eludes me.

                                                    2. 5

                                                      cat(1) is also, depending on your platform, for line numbering, non-blank-line numbering, the removal of runs of multiple blank lines, the explicit display of end-of-lines, the explicit display of tabs and form feeds, converting all non-printables to a human-readable escaped form, and for line ending conversion.

                                                      1983 called and wants its boring whinge back.

                                                      1. 1

                                                        Right, and now we have a program for bonbatenation. It replaces cat and less. I don’t see the problem here.

                                                        1. 1

                                                          To be clear, bat’s pager capabilities start and end at running an external pager if stdout is a tty. It supplements less, it doesn’t replace it.

                                                          I wonder how much stuff would break if you taught cat to do the same thing. Nothing springs to mind.

                                                    3. 13

                                                      If humanity had followed the “if it ain’t broke, don’t fix it” maxim to the tee without exception, we would all still be living in the stone age.

                                                      1. 8

                                                        And we might actually be better off that way. At least, a lot less likely to drive half the planet to extinction, and probably not significantly less happy (hedonic treadmill, etc).

                                                      2. 11
                                                        • Bat is awesome. It’s not really a cat replacement, but a “terminal file viewer with syntax highlighting”. I would never use bat in, say, a script to concatenate files. Two tools for two different jobs.
                                                        • I haven’t tried loc or tokei, but cloc is a giant ball of slightly buggy perl. Run cloc on a big enough project and you’re bound to encounter issues.
                                                        • Cut can only split based on single-byte delimiters. Lots of tools try to do some form of alignment by using multiple space characters, or they use a syntax like key: value, so cut usually doesn’t cut it. Having to reach for awk just to get the third column of a thing is unfortunate, so a better cut seems like a good idea.
                                                        • Sudo is security critical. Every now and then, there are new memory issues found in sudo which couldn’t have existed if sudo was written in a safer language.
                                                        • People like writing system monitors. Htop, bashtop, bpytop, gotop, the list goes on. I’ve even written a few myself. It only makes sense that someone would eventually write system monitors in Rust.
                                                        • Hyperfine isn’t really a replacement for time. Rather, hyperfine is a fairly complete benchmarking solution which does multiple timed runs, warmup runs, detects outliers, and can compare multiple commands against each other. It’s become my ad-hoc benchmarking tool of choice.
                                                        • Zoxide is certainly not just a cd replacement. It’s a completely different way to navigate the filesystem, learning which paths you usually go to so that you can write part of a path and have zoxide take you to a frequently used directory which matches your pattern. If you’re gonna complain about zoxide, complain that it’s a reimplementaiton of something like autojump (Python) or z.lua (lua).

                                                        I don’t have any experience with the rest of these projects, but I would bet that the same pattern holds for most of them. It seems like, actually, a lot of value is added by many of these projects.

                                                        1. 5

                                                          tokei replaced my use of sloccount, which is also a giant ball of Perl and assorted support programs.

                                                          It’s slightly faster than either. On FreeBSD /usr/src:

                                                          • cloc: 3 minutes 40 seconds
                                                          • sloccount: 3 minutes 16 seconds
                                                          • tokei: 2.1 seconds
                                                        2. 9

                                                          How sure are you that the existing pieces of software are in fact not broken (in the sense of having some memory-safety-related security vulnerability that might get discovered and exploited tomorrow and become the next Heartbleed)?

                                                          1. 2

                                                            I have been using broot instead of tree and it is quite a joy.

                                                          1. 9

                                                            As much as I love and respect (I should, since I wrote a small part of the C library) the enthusiasm Andreas has, I kinda wish Serenity would dabble with different ideas/research. But that’s just a hobbyist OS development thing in general - everyone races to implement POSIX.

                                                            1. 14

                                                              everyone races to implement POSIX.

                                                              it opens the door for a lot of software, so I can see why people do that

                                                              1. 9

                                                                Yeah, the dopamine from having gcc run on your OS is obvious. I just wish other stuff happened too.

                                                                1. 8

                                                                  Interestingly enough, I’m only aware of a few “Operating Systems Specifications” that could be implemented:

                                                                  • POSIX/SUS (and its various profiles/derivatives/antecedents/related specs)
                                                                  • OpenStep
                                                                  • Windows 3.1 (ECMA-234)
                                                                  • TRON
                                                                  • Various avionics/maritime/motor vehicle specs
                                                                  • You could call (U)EFI an “operating system specification” but that’s not really its intended goal

                                                                  Obviously there are a lot of •de facto* OS standards. The above is purely those standards recognized as endorsed by a standards body.

                                                                  If anyone else knows of any OS standards, I’d love to hear about them.

                                                                  1. 19

                                                                    No one said you had to implement a spec. In fact, a hobby OS without the commercial imperatives to implement a standard frees you of much of that, unless you want to explicitly run the morass of POSIX programs out there. Mix what you like or make new things.

                                                                    SUS

                                                                    Also, I hate that I’m doing this on this website, but I can’t resist:

                                                                    1. 1

                                                                      thank you, it was hard for me to fight the temptation

                                                                    2. 5

                                                                      Unix isn’t just attractive because of its compatibility. It’s also:

                                                                      • fairly simple—not that hard to implement on your own

                                                                      • familiar; it’s hard to come up with new paradigms

                                                                      • still in common use; how much new, real-world software still supports other specifications you mention?

                                                                      1. 4
                                                                        • Windows 3.1 (ECMA-234)

                                                                        I hadn’t heard that there had been a standard written up for that! I love that ECMA make it easy to get the standards text, unlike some bodies (cough fucking ISO coughcough)

                                                                        • TRON

                                                                        I hadn’t heard of this either and now I’m slightly upset because there’s a whole family of stuff there that I’d been totally unaware of.

                                                                        What a pain in the neck to Google for, though. Blame Disney.

                                                                        First really interesting detail that jumps out to me on http://www.ecos.sourceware.org/docs-1.3.1/ref/ecos-ref.a.html is this:

                                                                        In particular, the default configuration has time slicing (also known as round-robin scheduling) switched on; this means that a task can be moved from RUN state to READY state at any time, in order that one of its peers may run. This is not strictly conformant to the µ ITRON specification, which states that timeslicing may be implemented by periodically issuing a rot_rdq(0) call from within a periodic task or cyclic handler;

                                                                        So the ITRON standard explicitly requires cooperative multitasking rather than preemptive. At first blush I would kind of expect that to rule out multiprocessing?

                                                                        It’s amusing to see every function name I saw mentioned on that page is either 7 or 8 characters long. Reminds me of the ANSI C 6 characters thing. https://stackoverflow.com/questions/38035628/c-why-did-ansi-only-specify-six-characters-for-the-minimum-number-of-significa

                                                                  2. 5

                                                                    POSIX has created a humongous social gravity well, if not a black hole at this point: POSIX is very widely taught and gives developers (at least subjectively) a simple and understandable shared view of computing. OSes are more than just implementations of their basic concepts, OSes are also their users, their community and their worldview, the sum of their experience and time invested in understanding (and human attention is very expensive).

                                                                    Sadly, the more original a hobby OS is, the less popular it will be. SerenityOS is a good case in point: it has never tried to be original in its concepts, it is explicitly optimized for familiarity and reimplementing well-known and popular concepts (POSIX and Windows UI) using well-tested tools (C++) while doing this with character, taste and coherence.

                                                                    1. 5

                                                                      I think you kinda have to implement POSIX – even Windows has done so on multiple occasions. But that doesn’t preclude implementing new paradigms as well.

                                                                      I would like to see something a lot better in terms of security and process-level virtualization (containers). I think it makes sense to do that on top of something POSIX-ish so you have some application code to test it out on. Otherwise I think you will be left with a lot of toy applications on your OS that don’t really give it a workout.

                                                                      I’d also like to see more introspection, tracing, and performance monitoring along the lines of eBPF.

                                                                      Basically all the “cross-cutting concerns”, which Linux is bad at, or at least has very messy bolted-on designs for.

                                                                    1. 17

                                                                      I have no idea what Oxide is and why it is relevant for Lobste.rs, but this specific post looks like it’s just a big ad for some server hardware. Is there any interesting technical content that I’m missing?

                                                                      1. 18

                                                                        I think it’s because two of the C-level people are “lobste.rs-approved”. Bryan Cantrill was the Joyent CEO, and wrote DTrace. Jessie Frazelle is a former Docker, Inc. employee who played a significant part in the popularisation of containers beyond Docker itself. (mostly during her time at Microsoft)

                                                                        But your comment is relevant though.

                                                                        1. 2

                                                                          Bryan was CTO of Joyent

                                                                          1. 1

                                                                            You’re right. My mistake. I can’t edit my comment anymore :P .

                                                                        2. 5

                                                                          It’s hyperscaler hardware most people have no use for. I think people are interested on the engineering work going on, w/ work on low-level boot firmware and…. rewriting it in Rust.

                                                                          1. 10

                                                                            The annoying thing is that the submission has nothing to do with the engineering, at its core. It isn’t a deep-dive into any of the sales points, no real technology is discussed.

                                                                            And now these folks just got a rather expensive ad slot on a slow-traffic site with high-value eyeballs.

                                                                          2. 7

                                                                            Just fanboyism here I am afraid

                                                                          1. 20

                                                                            I save myself the headache and run my things on hetzner cloud and scaleway, which are both cheap, have excellent hardware and no crazy traffic prices.

                                                                            1. 1

                                                                              Wow, they even have a custom macports repo! That is rare to see.

                                                                              1. 21

                                                                                Please don’t bring this toxicity over to lobste.rs. Let it live and die on the orange site.

                                                                                1. 19

                                                                                  I’ve had a few interesting discussions about our tribal and memetic expectations as exemplified by this repository. Sometimes, when somebody does something unbearably cringy in the name of what they think is supremely excellent taste, it is an opportunity to delve deeper into their implicit beliefs.

                                                                                  Nowhere in this repository is it ever imagined that C is not an appropriate language for today’s coders. Rather, the machismo which is required to write fresh C code against an ever-steeper gradient of better toolchains for higher-level languages is also the same machismo which is stoked by the underlying family of memes used to theme and decorate the repository.

                                                                                  Sometimes a project’s only purpose is to serve as a warning to others. Even in those moments, let us learn something from the precise nature of the warning.

                                                                                  1. 22

                                                                                    Can you define what you mean by ‘toxicity’? I don’t see anything ‘toxic’ in this repository.

                                                                                    1. 5

                                                                                      I don’t like the way its naming and meming relies on using virgin man vs not as a shorthand for bad vs not, however ironically.

                                                                                      It’s a cool trick. Why couple it with a bad meme?

                                                                                      1. 19

                                                                                        The meme is incredibly funny, that’s why.

                                                                                    2. 21

                                                                                      Toxicity? Orange site? I didn’t get any of that.

                                                                                      I could agree that the theming is a little overboard, not because of bad taste, but because it detracts from the technical side, as speps said.

                                                                                      Code needs to market itself, and it seems “skullchap” had some fun in that department.

                                                                                      1. 11

                                                                                        It seems interesting from a technical perspective but I agree on the bad taste aspect, it detracts from the technical side.

                                                                                        1. 8

                                                                                          I think we need a new flag, because this isn’t really spam or off-topic: I suggest “bad taste” ;)

                                                                                          1. 27

                                                                                            The best way to deal with content that’s on-topic but otherwise not very valuable is simply to ignore it.

                                                                                            A comment, btw, counts as an upvote, at least as far as visibility on the front page is concerned.

                                                                                            1. 16

                                                                                              Or maybe some more tags. “based” and “redpilled” come to mind :-D

                                                                                              Alright, I’ll see myself out.

                                                                                              1. 5

                                                                                                Agreed. I marked it off-topic. Whatever your taste or politics, this repository was built simply “for the lulz”. It’s not tech, it’s a social experiment with code.

                                                                                                While there are many social topics in the tech world, that’s generally not what lobste.rs is good for.

                                                                                                1. 53

                                                                                                  It’s tech, you and others just seem to be distressed by the cultural shibboleths it touches.

                                                                                                  We have articles here that are dripping with furry stuff that are routinely defended from fursecution…a mainstream meme plus cool hack isn’t outside our Overton window for me.

                                                                                                  1. 10

                                                                                                    Labeling something “toxic” with the intent of banning it is as much of a cultural shibboleth as any of the memes in the article.

                                                                                                    1. 4

                                                                                                      The furry stuff is a positive expression of someone’s own personal identity, while the chad/virgin meme is a ridiculous objectification of others for being ingroup/outgroup. Do you see a difference?

                                                                                                      1. 4

                                                                                                        Yeah, what’s up with all the furry stuff?

                                                                                                      2. 13

                                                                                                        this repository was built simply “for the lulz”. It’s not tech,

                                                                                                        It’s not? I’m confused. I haven’t tried compiling it, but there’s a C file in there with a bunch of complex-looking code in it. Does that count as tech?

                                                                                                        I don’t know if anyone would use this library for reals (I sure hope not), but the same goes for stuff like Brainfuck or (IMHO) a 6502 assembler. There’s a lot of stuff posted here that is, at some level, done for teh lulz.

                                                                                                        1. 8

                                                                                                          this repository was built simply “for the lulz”. It’s not tech, it’s a social experiment with code.

                                                                                                          A lot of software is written “just because” or “for the lulz”. A lot of good software is even written for this express purpose— Linux started out as a hobby project, no?

                                                                                                          I also don’t see what makes this a social experiment. What’s the experiment? The readme being silly? Is that an experiment?

                                                                                                          1. 4

                                                                                                            Linus Torvalds biography is called “Just for fun”, because that is why he wrote Linux. That is how older people say “for the lulz”. Is Linux now also off-topic?

                                                                                                            There is some actual C macro (ab-)use in there, that is interesting to look at. It is def. tech.

                                                                                                            Why are you so triggered by this stupid meme?

                                                                                                        2. 6

                                                                                                          The shitposting C chad versus the virgin crustacean.

                                                                                                        1. 11

                                                                                                          Note that the internet uplink remains untouched at 1 Gbit/s

                                                                                                          cries in suburban Texan

                                                                                                          1. 4

                                                                                                            telecom germany wants 55€ for 250 Mbit/s (if its available at all), in another post they said they pay ~50€ for 1Gbit/s T_T

                                                                                                            1. 4

                                                                                                              I have gigabit cable from vodafone in Germany. I def. get the downstream when I am using an ethernet cable. 500Mbit via Wifi is def. also the norm. Upstream is unfortunaltely only 50Mbit. All in all it costs me 50€/month. I think that is an okay price.

                                                                                                              1. 1

                                                                                                                Friend of mine was happily switching to 300Mbit unitymedia and then got total outages over days when corona hit..

                                                                                                                1. 1

                                                                                                                  It works well for us because we live on the ground floor and there is some sort fo problem with the cable in the appartements above us. But due to certain people not being on speaking terms in our house for some reason, it is not going to be fixed. Therefore nobody else has cable internet and we don’t share the line. Sometimes human drama is to ones advantage.

                                                                                                                  That being said, there is the occasional 6 hour outtage at night with vodafone cable too, but I guess that is unavoidable with residential internet.

                                                                                                                  1. 1

                                                                                                                    I’ve got the 100 Mbit from t-com but without any outage. I really dislike any kind of glitches to my connection.

                                                                                                              2. 1

                                                                                                                Here they offer 10 Gbit/s for ~40€ but I can’t really justify it. I’m happy with my cheap 200 Mbit.

                                                                                                              3. 3

                                                                                                                Cheer up; in my part of London, UK, I can’t get more than 8Mb. “First world”, “Global capital”.

                                                                                                              1. 2

                                                                                                                Funny hack, but it is not a full shortener, if the shortening is not part of your 59 lines. It is just a lookup of a TXT record. I don’t want to be negative, but I think the far more irky write path should be part of it too

                                                                                                                1. 2

                                                                                                                  Probably in theory, sure. The trouble with the writing is “how many different DNS providers are there?” and moreover there is no standard way to create a record :(

                                                                                                                  Maybe I should change the project to be called a url-lengthener, seeing as that is the only function it handles?

                                                                                                                  1. 3

                                                                                                                    As a suggestion: Route53 has a Go API I assume, it at least some kind of HTTP API, and would fit the theme perfectly. ❤️

                                                                                                                    1. 3

                                                                                                                      Ah yes that is a good idea. Certainly food for thought!

                                                                                                                    2. 1

                                                                                                                      Unsurprisingly there is a standard (RFC2136 DNS UPDATE), but it suffers from a lack of an end-user-friendly authentication mechanism, with the result that basically nobody uses it, at least in any broadly-available service. But there are scenarios where it works fine.

                                                                                                                      1. 2

                                                                                                                        You can use RFC2136 with bearer token authentication, especially useful for DNS ACMEv2 validation. Shouldn’t be too hard to use the same here.

                                                                                                                      2. 1

                                                                                                                        Yes there are many different providers. Having at least one as an example would be fun.

                                                                                                                    1. 2

                                                                                                                      What I really want is something like Python (or like Haskell, depending on the circumstances) where running shell commands is a “first-class” language construct, with ergonomic piping of stdout/stdin/files. Oil seems much-improved compared to Bash, but it (intentionally, for good reason) borrows many of the same bad design choices with regard to control flow and cryptic naming schemes.

                                                                                                                      The best solution I’ve found so far is to call subprocess.run from a Python script and use string interpolation to pass arguments to the commands I want to run. But this is far from ideal.

                                                                                                                      1. 8

                                                                                                                        Why not Perl? It’s the obvious choice for a language where shell commands are a “first-class” language construct.

                                                                                                                        1. 3

                                                                                                                          Totes agreed!

                                                                                                                          I find shell logic and data structures impenetrable and error prone, so I write all my “shell scripts” in Perl. It’s easy to pull shell output into Perl data structures using backticks, e.g. print the names of files in $TMPDIR iff they are directories

                                                                                                                          chomp(my @out = `ls $ENV{TMPDIR}`); for (@out) { print "$_\n" if -d qq[$ENV{TMPDIR}/$_]; }
                                                                                                                          

                                                                                                                          For non-perl users, the backticks above mean “run this shell command”, chomp removes the newlines, qq[] means “wrap this in double quotes and handle the annoying escaping for me”, and $ENV{X} is how you access env var X, etc.

                                                                                                                          The book Minimal Perl for UNIX and Linux People has a lot of information about how perl can be used to do everything on unices that awk, grep, sed, etc. can do

                                                                                                                          also with Perl you get a real debugger (see also perldoc perldebtut or the book Pro Perl Debugging)

                                                                                                                          1. 3

                                                                                                                            I think it easily gets overlooked these days, since it is no longer hip and therefore less on the frontpage news

                                                                                                                            1. 5

                                                                                                                              Apropos of “no longer hip”, tcl is a nice scripting language with a clean syntax.

                                                                                                                              1. 1

                                                                                                                                I used to mess with tcl scripts all the time in the early 2000s when I ran eggdrop irc bots. Good old days…

                                                                                                                                1. 4

                                                                                                                                  Sqlite started as a tcl extension and still has a good tcl interface: https://sqlite.org/tclsqlite.html

                                                                                                                                  1. -2

                                                                                                                                    TIL!

                                                                                                                          2. 3

                                                                                                                            Depending on your use cases, have you ever tried Fish, or more on the programming side, Raku/Perl? Raku is awesome for shell-style scripting.

                                                                                                                            1. 2

                                                                                                                              Hm what do you mean by control flow? I’m working on more docs so it probably isn’t entirely clear, but control flow looks like this

                                                                                                                              if test --dir $x {
                                                                                                                                echo "$x is a dir"
                                                                                                                              }
                                                                                                                              

                                                                                                                              And you can use expressions with ()

                                                                                                                              if (x > 0) {
                                                                                                                                echo "$x is positive"
                                                                                                                              }
                                                                                                                              

                                                                                                                              For loops are like bash with curly braces

                                                                                                                              for x in a b c { echo $x }  # usually written on 3 lines, being compact here
                                                                                                                              for x in *.py { echo $x }
                                                                                                                              for x in @(seq 3) { echo $x }  # explicit splitting rather than $(seq 3)
                                                                                                                              

                                                                                                                              I’m also interested in feedback on naming. Oil has long flags like test --dir instead of test -d. I am trying to get rid of all the one letter obscureness (or at least ALLOW you to avoid it if desired).


                                                                                                                              It’s accurate to describe Oil as “Python where running shell commands is first class” (and pipelines and more).

                                                                                                                              Although I would take care to call it perhaps the “David Beazley” subset of Python :) That is a prominent Python author who has been lamenting the complexity of Python.

                                                                                                                              He writes some great code with just numbers, strings, lists, dicts, and functions. Oil is like Python in that respect; it’s not like Python in the sense that it has a meta-object protocol (__iter__ and __enter__ and __zero__ and all that).

                                                                                                                              I’m interested in language feedback and if that matches your perception of Oil :) Does the code look cryptic?

                                                                                                                              1. 3

                                                                                                                                I’ve only had a cursory look at Oil, so forgive me if I have the wrong idea :). I really admire the effort, and I can really relate to what you’ve written about your motivations for creating Oil!

                                                                                                                                Oil is also aimed at people who know say Python or JavaScript, but purposely avoid shell

                                                                                                                                It seems like Oil will be great for people who spend a lot of time maintaining shell scripts and want to work with something a little more sane. However, the Oil docs impression that Oil will be just as confusing as Bash for someone like me who wants to spend as little time as possible writing / reading / maintaining shell scripts and who only finds occasion to do so once every few months. For someone like me, I wish there were some syntax-level construct in Python or Haskell for running shell commands that lets me take advantage of my existing knowledge of the language, rather than having to learn something entirely new.

                                                                                                                                I took another look at the Oil docs, and the control flow actually seems ok, even if minimal. It would be cool to see some more tools to map / flatmap / fold commands, especially when I have a bunch of parameters that are used to generate a sequence of commands.

                                                                                                                                I think the biggest improvement a new shell-scripting language can offer is an alternative syntax for specifying command-line flags. Now that I think of it, this is actually the main reason I wrap all my CLI calls in Python scripts. For instance, here are some commands I had to run at work last week:

                                                                                                                                docker run -itd --name container_name --rm -e CUDA_VISIBLE_DEVICES=0 -e API_KEY="..." -v /home/ben:/ben/ -v /data/v2/:/data image_name
                                                                                                                                
                                                                                                                                docker exec -d container_name sh -c 'mkdir -p /ben/train/train_2021-05-16_144614 && python /ben/project_name/train.py \
                                                                                                                                                --batchSize 16 --loadSize 160 \
                                                                                                                                                --alpha 1.0 \
                                                                                                                                                --annotations /data/project_name/sourceA/v3/really_long_name.txt \
                                                                                                                                                --annotations /data/project_name/sourceB/v1/really_long_name.txt \
                                                                                                                                                --annotations /data/project_name/sourceC/v4/really_long_name.txt \
                                                                                                                                                --data-path /data/project_name/images \
                                                                                                                                                --output-path /ben/train/train_2021-05-16_144614/checkpoints \
                                                                                                                                                --gpu_ids 2 \
                                                                                                                                                2>&1 > /ben/train/train_2021-05-16_144614/log_2021-05-16_144614_outer.txt'
                                                                                                                                

                                                                                                                                I actually had to run the exec command four different times with different arguments. I wrote a Python script to generate the Python command, wrap it in the docker command, and pass in all the necessary parameters with string interpolation. But to me this seems like a pretty silly to glue together different programs, when we already have familiar syntax for function calls! I would love to write instead:

                                                                                                                                var env_variables = [
                                                                                                                                  CUDA_VISIBLE_DEVICES=0,
                                                                                                                                  API_KEY="..."
                                                                                                                                ];
                                                                                                                                
                                                                                                                                var volumes = [
                                                                                                                                  /home/ben/:/ben/,
                                                                                                                                  /data/commondata/v2, /data
                                                                                                                                ];
                                                                                                                                
                                                                                                                                docker.run(
                                                                                                                                  flags="interactive, tty, remove",
                                                                                                                                  env=env_variables,
                                                                                                                                  name="container_name",
                                                                                                                                  image="image_name",
                                                                                                                                  volume=volumes
                                                                                                                                );
                                                                                                                                
                                                                                                                                ...
                                                                                                                                
                                                                                                                                image_annotations=[ /data/project_name/sourceA/v3/really_long_name.txt, ... ]
                                                                                                                                
                                                                                                                                python_command=python(train.py,
                                                                                                                                  batchSize=16, loadSize=160, alpha=1.0,
                                                                                                                                  annotations=image_annotations,
                                                                                                                                  data-path=/data/project_name/images,
                                                                                                                                  output_path=...
                                                                                                                                  gpu_ids=2,
                                                                                                                                )
                                                                                                                                
                                                                                                                                docker.exec(
                                                                                                                                  detached=True,
                                                                                                                                  container=container_name,
                                                                                                                                  command=python_command
                                                                                                                                )
                                                                                                                                

                                                                                                                                This should work, automatically, for ANY command line interface, not just docker. It should work without writing any custom wrapper code. Without actually running the command, I want some kind of TypeScript-style static type-checking to know if the flag/argument I provided does not match what the CLI expects.

                                                                                                                                1. 1

                                                                                                                                  Thanks this is useful feedback!

                                                                                                                                  Yes I understand that Oil feels like it’s for the “shell expert” now. Because I do frame many things in terms of an upgrade path from bash, and that requires knowing bash (lots of people don’t!).

                                                                                                                                  But it’s absolutely the goal for a Python/JS programmer to be able to pick up Oil with minimal shell knowledge. You have to understand argv, env, stdin/stdout/stderr, and exit code, and that’s it hopefully. Maybe file descriptors for the advanced.

                                                                                                                                  I have an upcoming “Tour of Oil” doc that should help with this. It will document Oil without the legacy stuff.

                                                                                                                                  It would be cool to see some more tools to map / flatmap / fold commands, especially when I have a bunch of parameters that are used to generate a sequence of commands.

                                                                                                                                  Yes, great feedback, there is a pattern for this but it’s probably not apparent to newcomers. In shell map / flatmap are generally done by filtering streams of lines, and I think that pattern will help.

                                                                                                                                  https://github.com/oilshell/oil/issues/943

                                                                                                                                  There is also splicing of arrays, which are natural for command line args

                                                                                                                                  var common = %( --detached=1 --interactive )
                                                                                                                                  var args1 = %( --annotations /data/1 )
                                                                                                                                  var args2 = %( --annotations /data/2 )
                                                                                                                                  
                                                                                                                                  # Run 2 variants of the command
                                                                                                                                  docker run @common @args1
                                                                                                                                  docker run @common @args2
                                                                                                                                  
                                                                                                                                  # Run 4 variants
                                                                                                                                  for i in @(seq 4) {
                                                                                                                                    docker run @common --index=$i
                                                                                                                                  }
                                                                                                                                  

                                                                                                                                  Does that make sense as applied to your problem? You can also apply to env vars with “env”:

                                                                                                                                  var env_args = %( PYTHONPATH=. FOO=bar )
                                                                                                                                  env @env_args python -c 'print('hi')
                                                                                                                                  

                                                                                                                                  There is no static checking, but Oil’s philosophy is to give errors earlier in general. It will be possible to write your own argv validators if you like.

                                                                                                                                  A useful pattern will be to define “subsets” of Docker as “procs”. As in, you can just accept the flags you use and validate them:

                                                                                                                                  proc mydocker {
                                                                                                                                     argparse @ARGV %OPT {   # not implemented yet
                                                                                                                                        -v --verbose "Verbose flag"
                                                                                                                                     }
                                                                                                                                     docker @myarray
                                                                                                                                  }
                                                                                                                                  mydocker --oops  # syntax error
                                                                                                                                  

                                                                                                                                  Thanks for the feedback, let me know if that makes sense, and if you have other questions. And feel free to follow the issue on Github!

                                                                                                                              2. 1

                                                                                                                                Golang exec’s module is much better for piping in the classic shell way. You might consider that.

                                                                                                                                1. 1

                                                                                                                                  The best solution I’ve found so far is to call subprocess.run from a Python script and use string interpolation to pass arguments to the commands I want to run. But this is far from ideal.

                                                                                                                                  I do a similar thing. What sort of improvements can you envision?

                                                                                                                                1. 11

                                                                                                                                  I am going to be doing a talk about systemd at AlpineConf. Tune in at noon EDT to rustle all the jimmies into orbit!

                                                                                                                                  1. 4

                                                                                                                                    Ooh, the lion’s den. Wear asbestos undergarments.

                                                                                                                                    1. 1

                                                                                                                                      I’m just sad I forgot to order popcorn from the grocery store.

                                                                                                                                    2. 1

                                                                                                                                      Do you know if there will be recordings of the talks? I’d love to check this out

                                                                                                                                      1. 2

                                                                                                                                        I know that my talk at least is already recorded and I’m going to push the slides and notes live as soon as the talk starts. I think the other talks are prerecorded as well. I’d suggest asking in #alpine-conf on Freenode for exact details though.

                                                                                                                                      2. 1

                                                                                                                                        Interesting. The majority of use cases of alpine I have seen was as a base for docker containers due to its size. Since you can’t run systemd inside a container, this does not matter much for that crowd. Do you see many people running alpine as the main OS on their servers?

                                                                                                                                        I ran an alpine/arm tor node for a while, but that was not the most stable machin I ever had. I may have been the hardware though.

                                                                                                                                        1. 2

                                                                                                                                          I run Alpine as the main OS for my servers – The package management is blazing-fast, the init system is out of my way (I stick to the happy path, but I’m sure it’s flexible.), and I keep the system minimal.

                                                                                                                                          When I need to run something that requires a heavier environment, I can stick it in a Docker container, and give it an image that’s based on another distro.

                                                                                                                                          1. 2

                                                                                                                                            I used to run Alpine as the main OS on my servers for many years. I even did a few production deployments with it. Docker certainly made Alpine a lot more popular overnight for bandwidth reasons though!

                                                                                                                                        1. 10

                                                                                                                                          Who here uses dragonfly BSD and what do you do with it? I keep reading about it, but never read any articles from regular users

                                                                                                                                          1. 12

                                                                                                                                            TIL about starship for prompts. Looks good, I will give that a try.

                                                                                                                                            1. 3

                                                                                                                                              I used it when it was a regular zsh script. I got tired of having to re-configure it whenever updates broke my configuration as it changed or removed features I used. I’m not sure how stable it is now but I did enjoy it while it lasted.

                                                                                                                                              1. 2

                                                                                                                                                I’ve been using it for a while and haven’t had any of the problems that the other commenter seemed to have. My setup is pretty simple though.

                                                                                                                                                1. 3

                                                                                                                                                  There was one significant backwards-incompatible change that I can recall, but it was trivial to address. And for my part, I’d rather have my software evolving than never releasing a change in case it breaks someone somewhere.

                                                                                                                                                2. 1

                                                                                                                                                  I used starship previously and something happened to make it grind to a halt. I moved to romkatv/powerlevel10k and have had no such issues since. I once saw a discussion around a plug-in being implemented which was rejected as it took 10ms to run!

                                                                                                                                                  Edit: found the discussion, it was 11.4ms and it was reworked rather than rejected, but hopefully you get the point I was trying to make

                                                                                                                                                  1. 2

                                                                                                                                                    One aspect of my choice of Starship that doesn’t come through in this post is that I use the fish shell as my daily driver, but I use zsh and bash on remote hosts in various places. Having a consistent prompt on all three of those is a huge selling point, even if my prompt might take 50-70ms to render.

                                                                                                                                                    1. 2

                                                                                                                                                      Don’t worry, not trying to invalidate your choices or anything. I’m sure it was something I did otherwise the GitHub issues would be full of noise! Having a consistent prompt is a really solid pro for sure.

                                                                                                                                                      1. 1

                                                                                                                                                        I didn’t think you were :D

                                                                                                                                                        I just figured it might help to have a bit of clarity on the rationale. Arguably I should edit the post with that :)

                                                                                                                                                      2. 1

                                                                                                                                                        I’m curious why such a dichotomy? Are you required to use zsh/bash on the remote machines or is it a matter of convenience? I’m forced to use bash, but would gladly switch to zsh if I could install it…