1. 37

    if you are at all in a vulnerable place, skip reading the comments about this on places like reddit or phoronix. the amount of hate being conveyed is disappointing if unsurprising.

    1. 10

      I’m appalled but not surprised to see this much hate in reddit, Slashdot, Hacker News and such. They were never inclusive communities to begin with, but somehow the quality of discussion exponentially went down in the last few years. I’m trying to think of a catalyst, but I’m not sure. Perhaps 4chan’s /g/ is to blame, as 4chan itself decayed into toxic sludge. Gamergate came out of /v/ after all.

      1. 6

        I was interested in that and wrote a small script to see where the 120 (-1 for deleted comments) reddit users comment besides the r/linux thread about the new CoC.

        I only looked at the 100 latest comments of each user.

        https://gist.github.com/Duncaen/3c80b044ca6fcd94c60265d171ad227d

        The list contains the number of unique users who commented in the subreddit.

        I expected a bit more users frequent the same subreddits, but there are also many new accounts.

        1. 3

          It more or less confirms my suspicions. If I weren’t familiar with /r/linux as a community, I would’ve suspected brigading. It’s not a good look either way.

      2. 15

        Ignorant people see apologies as an attack vector.

        1. 8

          Yes, it seems apologizing is a sign of weakness to some people.

      1. 18

        Didn’t systemd hard code 8.8.8.8 as well at some point?

        It’s such a good thing that people are watching out for violations in free software.

        1. 19

          They use it as the default for the fallback if no DNS is configured. https://github.com/systemd/systemd/blob/master/meson_options.txt#L200

          1. 2

            Which is quite reasonable.

            1. 9

              That depends on your individual situation. Some users might appreciate that the system ‘just works’ even if not configured properly. Other wouldn’t, for 2 reasons:

              1. Sending data a third party, especially one like google, without telling the user, is not ok in terms of privacy.
              2. If something is misconfigured but silently falls back to a default which appears to work (while actually behaving in a different manner to how the user intended), then it’s much more difficult for the user to know that it needs fixing, and often much more difficult for the user to fix.
          2. 7

            2 people marked this as incorrect but the source code proving it is linked right there!

            1. 5

              You cannot imagine how many people mark comments they do not like as incorrect without even checking the sources, commenting or noticing that they are opinions!

              You shouldn’t care much: other might learn something from your comment anyway. At least an incorrect downvote make you double check the sources!

              1. 3

                Is it hard coded or is it a fallback default?

            1. 3

              There was a recent discussion about whether file-based APIs were better or worse the specific ones (https://lobste.rs/s/ckqzbn/why_filesystems_have_loose_coupling_your).

              I think a lot of the pros and cons of that API choice are illuminated by unveil.

              Things can always be implemented either way (layered on top of the generic mechanism, or given their own specific mechanism). But if you then enhance the general mechanism with a new feature, you get to use that for all of the functionality you have layered on top.

              (As a side thought - it’s kind of a nice thought experiment: If the only syscalls were open/close/read/write and friends - how would you (a) provide an interface for all other system calls and (b) put them together in a filepath hierarchy so that unveil() grouped things nicely.)

              1. 4

                I know very little about either of these topics, but I wonder if it would be interesting to combine OpenBSD’s security syscalls like pledge and unveil (is there a generic name for these? Privilege-based security?) with Plan 9’s extreme everything is a filesystem approach.

                1. 5

                  The amount of syscalls in Plan9 is so small that pledge(2) wouldn’t make much sense. And unveil(2) wouldn’t really be necessary as there are already mount namespaces, a process can unmount paths and then use rfork(2)s RFNOMNT flag to disallow mounting new resources.

                  https://swtch.com/~rsc/talks/nauth.pdf

                  1. 3

                    In other words, Plan 9 obviated the need for these approaches. It really was the wave of the future, but it hasn’t reached the shore yet. Yet …

              1. 2

                The USR1 signal is supported on Linux for making dd report the progress. Implementing something similar for cp and other commands, and then make ctrl-t send USR1 can’t be too hard to implement. Surely, it is not stopped by the Linux kernel itself?

                1. 8

                  SIGUSR1 has an nasty disadvantage relative to SIGINFO: by default it kills the process receiving it if no handler is installed. 🙁 The behavior you really want is what SIGINFO has, which is defaulting to a no-op if no handler is installed.

                  • I don’t want to risk killing a long-running complicated pipeline that I was monitoring by accidentally sending SIGUSR1 to some process that doesn’t have a handler for it
                  • there’s always a brief period between process start and the call to signal() or sigaction() during which SIGUSR1 will be lethal
                  1. 1

                    That’s interesting. The hacky solution would be to have a whitelist of processes that could receive SIGUSR1 when ctrl-t was pressed, and just ignore the possibility of someone pressing ctrl-t at the very start of a process.

                    A whitelist shouldn’t be too hard to maintain. The only tool I know of that handles SIGUSR1 is dd.

                  2. 5

                    On BSD it’s part of the TTY layer, where ^T is the default value of the STATUS special character. The line printed is actually generated by the kernel itself, before sending SIGINFO to the foreground process group. SIGINFO defaults to ignored, but an explicit handler can be installed to print some extra info.

                    I’m not sure how equivalent functionality could be done in userspace.

                    1. 1

                      It would be a bit hacky, but the terminal emulator could send USR1 to the last started child process of the terminal, when ctrl-t is pressed. The BSD way sounds like the proper way to do it, though.

                      1. 4

                        I have a small script and a tmux binding for linux to do this:

                        #!/bin/sh
                        # tmux-signal pid [signal] - send signal to running processes in pids session
                        # bind ^T run-shell -b "tmux-signal #{pane_pid} USR1"
                        
                        [ "$#" -lt 1 ] && return 1
                        sid=$(cut -d' ' -f6 "/proc/$1/stat")
                        sig=$2
                        : ${sig:=USR1}
                        ps -ho state,pid --sid "$sid" | \
                        while read state pid; do
                                case "$state" in
                                R) kill -s"$sig" "$pid" ;;
                                esac
                        done
                        
                        1. 4

                          Perfect, now we only need to make more programs support USR1 and lobby for this to become the default for all Linux terminal emulators and multiplexers. :)

                  1. 15

                    I recently discovered how horribly complicated traditional init scripts are whilst using Alpine Linux. OpenRC might be modern, but it’s still complicated.

                    Runit seems to be the nicest I’ve come across. It asks the question “why do we need to do all of this anyway? What’s the point?”

                    It rejects the idea of forking and instead requires everything to run in the foreground:

                    /etc/sv/nginx/run:

                    #!/bin/sh
                    exec nginx -g 'daemon off;'
                    

                    /etc/sv/smbd/run

                    #!/bin/sh
                    mkdir -p /run/samba
                    exec smbd -F -S
                    

                    /etc/sv/murmur/run

                    #!/bin/sh
                    exec murmurd -ini /etc/murmur.ini -fg 2>&1
                    

                    Waiting for other services to load first does not require special features in the init system itself. Instead you can write the dependency directly into the service file in the form of a “start this service” request:

                    /etc/sv/cron/run

                     #!/bin/sh
                     sv start socklog-unix || exit 1
                     exec cron -f
                    

                    Where my implementation of runit (Void Linux) seems to fall flat on its face is logging. I hoped it would do something nice like redirect stdout and stderr of these supervised processes by default. Instead you manually have to create a new file and folder for each service that explicitly runs its own copy of the logger. Annoying. I hope I’ve been missing something.

                    The only other feature I can think of is “reloading” a service, which Aker does in the article via this line:

                    ExecReload=kill -HUP $MAINPID

                    I’d make the argument that in all circumstances where you need this you could probably run the command yourself. Thoughts?

                    1. 6

                      Where my implementation of runit (Void Linux) seems to fall flat on its face is logging. I hoped it would do something nice like redirect stdout and stderr of these supervised processes by default. Instead you manually have to create a new file and folder for each service that explicitly runs its own copy of the logger. Annoying. I hope I’ve been missing something.

                      The logging mechanism works like this to be stable and only lose logs in case runsv and the log service would die. Another thing about separate logging services is that stdout/stderror are not necessarily tagged, adding all this stuff to runsv would just bloat it.

                      There is definitively room for improvements as logger(1) is broken since some time in the way void uses it at the moment (You can blame systemd for that). My idea to simplify logging services to centralize the way how logging is done can be found here https://github.com/voidlinux/void-runit/pull/65. For me the ability to exec svlogd(8) from vlogger(8) to have a more lossless logging mechanism is more important than the main functionality of replacing logger(1).

                      1. 1

                        Ooh thankyou, having a look :)

                      2. 6

                        Instead you can write the dependency directly into the service file in the form of a “start this service” request

                        But that neither solves starting daemons in parallel, or even at all, if they are run in the ‘wrong’ order. Depending on network being setup, for example, brings complexity to each of those shell scripts.

                        I’m of the opinion that a dsl of whitelisted items (systemd) is much nicer to handle than writing shell scripts, along with the standardized commands instead of having to know which services that accepts ‘reload’ vs ‘restart’ or some other variation in commands - those kind of niceties are gone when the shell scripts are individually an interface each.

                        1. 6

                          The runit/daemontools philosophy is to just keep trying until something finally runs. So if the order is wrong, presumably the service dies if a dependent service is not running, in which case it’ll just get restart. So eventually things progress towards a functioning state. IMO, given that a service needs to handle the services it depends on crashing at any time anyways to ensure correct behaviour, I don’t feel there is significant value in encoding this in an init system. A dependent service could also be moved to running on another machine which this would not work in as well.

                          1. 3

                            It’s the same philosophy as network-level dependencies. A web app that depends on a mail service for some operations is not going to shutdown or wait to boot if the mail service is down. Each dependency should have a tunable retry logic, usually with an exponential backoff.

                          2. 4

                            But that neither solves starting daemons in parallel, or even at all, if they are run in the ‘wrong’ order.

                            That was my initial thought, but it turns out the opposite is true. The services are retried until they work. Things are definitely paralleled – there is not “exit” in these scripts, so there is no physical way of running them in a linear (non-parallel) nature.

                            Ignoring the theory: void’s runit provides the second fastest init boot I’ve ever had. The only thing that beats it is a custom init I wrote, but that was very hardware (ARM Chromebook) and user specific.

                          3. 5

                            Dependency resolving on daemon manager level is very important so that it will kill/restart dependent services.

                            runit and s6 also don’t support cgroups, which can be very useful.

                            1. 5

                              Dependency resolving on daemon manager level is very important so that it will kill/restart dependent services

                              Why? The runit/daemontools philsophy is just to try to keep something running forever, so if something dies, just restart it. If one restarts a service, than either those that depend on it will die or they will handle it fine and continue with their life.

                              1. 4

                                either those that depend on it will die or they will handle it fine

                                If they die, and are configured to restart, they will keep bouncing up and down while the dependency is down? I think having dependency resolution is definitely better than that. Restart the dependency, then the dependent.

                                1. 4

                                  Yes they will. But what’s wrong with that?

                                  1. 2

                                    Wasted cycles, wasted time, not nearly as clean?

                                    1. 10

                                      It’s a computer, it’s meant to do dumb things over and over again. And presumably that faulty component will be fixed pretty quickly anyways, right?

                                      1. 5

                                        It’s a computer, it’s meant to do dumb things over and over again

                                        I would rather have my computer do less dumb things over and over personally.

                                        And presumably that faulty component will be fixed pretty quickly anyways, right?

                                        Maybe; it depends on what went wrong precisely, how easy it is to fix, etc. We’re not necessarily just talking about standard daemons - plenty of places run their own custom services (web apps, microservices, whatever). The dependency tree can be complicated. Ideally once something is fixed everything that depends on it can restart immediately, rather than waiting for the next automatic attempt which could (with the exponential backoff that proponents typically propose) take quite a while. And personally I’d rather have my logs show only a single failure rather than several for one incident.

                                        But, there are merits to having a super-simple system too, I can see that. It depends on your needs and preferences. I think both ways of handling things are valid; I prefer dependency management, but I’m not a fan of Systemd.

                                        1. 4

                                          I would rather have my computer do less dumb things over and over personally.

                                          Why, though? What’s the technical argument. daemontools (and I assume runit) do sleep 1 second between retries, which for a computer is basically equivalent to it being entirely idle. It seems to me that a lot of people just get a bad feeling about running something that will immediately crash.

                                          Maybe; it depends on what went wrong precisely, how easy it is to fix, etc. We’re not necessarily just talking about standard daemons - plenty of places run their own custom services (web apps, microservices, whatever).

                                          What’s the distinction here? Also, with microservices the dependency graph in the init system almost certainly doesn’t represent the dependency graph of the microservice as it’s likely talking to services on other machines.

                                          I think both ways of handling things are valid

                                          Yeah, I cannot provide an objective argument as to why one should prefer one to the other. I do think this is a nice little example of the slow creep of complexity in systems. Adding a pinch of dependency management here because it feels right, and a teaspoon of plugin system there because we want things to be extensible, and a deciliter of proxies everywhere because of microservices. I think it’s worth taking a moment every now and again and stepping back and considering where we want to spend our complexity budget. I, personally, don’t want to spend it on the init system so I like the simple approach here (especially since with microservies the init dependency graph doesn’t reflect the reality of the service anymore). But as you point out, positions may vary.

                                          1. 2

                                            Why, though? What’s the technical argument

                                            Unnecessary wakeup, power use (especially for a laptop), noise in the logs from restarts that were always bound to fail, unnecessary delay before restart when restart actually does become possible. None of these arguments are particularly strong, but they’re not completely invalid either.

                                            We’re not necessarily just talking about standard daemons …

                                            What’s the distinction here?

                                            I was trying to point out that we shouldn’t make too many generalisations about how services might behave when they have a dependency missing, nor assume that it is always ok just to let them fail (edit:) or that they will be easy to fix. There could be exceptions.

                                        2. 2

                                          Perhaps wandering off topic, but this is a good way to trigger even worse cascade failures.

                                          eg, an RSS reader that falls back to polling every second if it gets something other than 200. I retire a URL, and now a million clients start pounding my server with a flood of traffic.

                                          There are a number of local services (time, dns) which probably make some noise upon startup. It may not annoy you to have one computer misbehave, but the recipient of that noise may disagree.

                                          In short, dumb systems are irresponsible.

                                          1. 2

                                            But what is someone supposed to do? I cannot force a million people using my RSS tool not to retry every second on failure. This is just the reality of running services. Not to mention all the other issues that come up with not being in a controlled environment and running something loose on the internet such as being DDoS’d.

                                            1. 2

                                              I think you are responsible if you are the one who puts the dumb loop in your code. If end users do something dumb, then that’s on them, but especially, especially, for failure cases where the user may not know or observe what happens until it’s too late, do not ship dangerous defaults. Most users will not change them.

                                              1. 1

                                                In this case we’re talking about init systems like daemontools and runit. I’m having trouble connecting what you’re saying to that.

                                        3. 2

                                          If those thing bother you, why run Linux at all? :P

                                      2. 2

                                        N.B. bouncing up and down ~= polling. Polling always intrinsically seems inferior to event based systems, but in practice much of your computer runs on polling perfectly fine and doesn’t eat your CPU. Example: USB keyboards and mice.

                                        1. 2

                                          USB keyboard/mouse polling doesn’t eat CPU because it isn’t done by the CPU. IIUC the USB controller generates an interrupt when data is received. I feel like this analogy isn’t a good one (regardless). Checking a USB device for a few bytes of data is nothing like (for example) starting a Java VM to host a web service which takes some time to read its config and load its caches only to then fall over because some dependency isn’t running.

                                        2. 1

                                          Sleep 1 and restart is the default. It is possible to have another behavior by adding a ./finish script to the ./run script.

                                      3. 2

                                        I really like runit on void. I do like the simplicity of SystemD target files from a package manager perspective, but I don’t like how systemd tries to do everything (consolekit/logind, mounting, xinet, etc.)

                                        I wish it just did services and dependencies. Then it’d be easier to write other systemd implementations, with better tooling (I’m not a fan of systemctl or journalctl’s interfaces).

                                        1. 1

                                          You might like my own dinit (https://github.com/davmac314/dinit). It somewhat aims for that - handle services and dependencies, leave everything else to the pre-existing toolchain. It’s not quite finished but it’s becoming quite usable and I’ve been booting my system with it for some time now.

                                      4. 4

                                        I’d make the argument that in all circumstances where you need this you could probably run the command yourself. Thoughts?

                                        It’s nice to be able to reload a well-written service without having to look up what mechanism it offers, if any.

                                        1. 5

                                          Runits sv(8) has the reload command which sends SIGHUP by default. The default behavior (for each control command) can be changed in runit by creating a small script under $service_name/control/$control_code.

                                          https://man.voidlinux.eu/runsv#CUSTOMIZE_CONTROL

                                          1. 1

                                            I was thinking of the difference between ‘restart’ and ‘reload’.

                                            Reload is only useful when:

                                            • You can’t afford to lose a few seconds of service uptime (OR the service is ridiculously slow to load)
                                            • AND the daemon supports an on-line reload functionality.

                                            I have not been in environments where this is necessary, restart has always done me well. I assume that the primary use cases are high-uptime webservers and databases.

                                            My thoughts were along the lines o: If you’re running a high-uptime service, you probably don’t care about the extra effort of writing ‘killall -HUP nginx’ than ‘systemctl reload nginx’. In fact I’d prefer to do that than take the risk of the init system re-interpreting a reload to be something else, like reloading other services too, and bringing down my uptime.

                                          2. 3

                                            I hoped it would do something nice like redirect stdout and stderr of these supervised processes by default. Instead you manually have to create a new file and folder for each service that explicitly runs its own copy of the logger. Annoying. I hope I’ve been missing something.

                                            I used to use something like logexec for that, to “wrap” the program inside the runit script, and send output to syslog. I agree it would be nice if it were builtin.

                                          1. [Comment removed by author]

                                            1. 1

                                              We don’t know anything, that’s why we kept the name out of the original blog post. I don’t think there is a reason to associate the name with the issues that we are having right now, It doesn’t help anyone and could have negative impact.

                                            1. 7

                                              Massive kudos to this guy for not putting up with this SJW madness. I wish him all the best!

                                              We at suckless are heavily opposed to code of conducts and discriminatory organizations of any shape or form.

                                              1. 11

                                                Suckless takes a similarly principled stand against runtime config files.

                                                1. 8

                                                  How does suckless oppose discrimination?

                                                  1. 13

                                                    It’s very simple. Any non-technological matters during software development move the software away from its ideal form. Thus, to make your software suck less, you only take the best developers no matter what race, gender, heritage, etc. these persons have.

                                                    We do not believe in equal status (i.e. e.g. forcibly obtaining a 50/50 gender ratio), as this immediately leads to discrimination. We do however strongly believe in equal rights, naturally. You also naturally cannot have both.

                                                    1. 94

                                                      Any non-technological matters during software development move the software away from its ideal form.

                                                      Suckless makes a window manager: a part of a computer that human beings, with all their rich and varying abilities and perspectives, interact with constantly. Your choices of defaults and customization options have direct impact on those humans.

                                                      For example, color schemes determine whether color-blind people are able to quickly scan active vs inactive options and understand information hierarchy. Font sizes and contrast ratios can make the interface readable, difficult, or completely unusable for visually impaired people. The sizes of click targets, double-click timeouts, and drag thresholds impact usability for those with motor difficulties. Default choices of interface, configuration, and documentation language embed the project in a particular English-speaking context, and the extent to which your team supports internationalization can limit, or expand, your user base.

                                                      With limited time and resources, you will have to make tradeoffs in your code, documentation, and community about which people your software is supportive and hostile towards. These are inherently political decisions which cannot be avoided. This is not to say that your particular choices are wrong. It’s just you are already engaged in “non-technical”, political work, because you, like everyone else here, are making a tool for human beings. The choice to minimize the thought you put into those decisions does not erase the decisions themselves.

                                                      At the community development level, your intentional and forced choices around language, schedule, pronouns, and even technical terminology can make contributors from varying backgrounds feel welcome or unwelcome, or render the community inaccessible entirely. These too are political choices. Your post above is one of them.

                                                      There is, unfortunately, no such thing as a truly neutral stance on inclusion. Consider: you wish to take only the best developers, and yet your post has already discouraged good engineers from working on your project. Doubtless it has encouraged other engineers (who may be quite skilled!) with a similar political view to your own; those who believe, for instance, that current minority representation in tech is justified, representing the best engineers available, and that efforts to change those ratios are inherently discriminatory and unjust.

                                                      Policies have impact. Consider yours.

                                                      1. 7

                                                        I don’t know if that was your goal, but this is one of the best arguments for positive discrimination I’ve read. Thanks for posting it, and also thanks for noting that all decisions have some inherent politics whether we like it or not.

                                                        Unfortunately there is simply no solution: positive discrimination is opposed to meritocracy. Forced ratios are definitely an unethical tool, as they are a form of discrimination. However, this unethical tool brings us to a greater good, which is a final product that incorporates diversity on its design and accommodates more users, which is a desirable goal on itself, for the reasons you explained.

                                                        1. 4

                                                          color schemes determine whether color-blind people are able to quickly scan active vs inactive options and understand information hierarchy. Font sizes and contrast ratios can make the interface readable, difficult, or completely unusable for visually impaired people. The sizes of click targets, double-click timeouts, and drag thresholds

                                                          Let me see if I understand what you’re saying. Are you claiming that when color schemes, font sizes and drag thresholds are chosen that that is a political decision? I think that many people would find that quite a remarkable claim.

                                                          1. 3

                                                            It’s impossible to not be political. You can be “the status quo is great and I don’t want to discuss it”, but that’s political. The open source “movement” started off political - with a strong point of view on how software economics should be changed. In particular, if you say a CoC that bans people from being abusive is unacceptable, you are making a political statement and a moral statement.

                                                            1. 3

                                                              It’s impossible to not be political

                                                              Could I ask you to clarify in what sense you are using the word “political”?

                                                              Merriam-Webster (for example) suggests several different meanings that capture ranges of activity of quite different sizes. For example, I’m sure it’s possible to act in a way which does not impinge upon “the art or science of government” but perhaps every (public) action impinges upon “the total complex of relations between people living in society”.

                                                              In what sense did you use that term?

                                                              1. 4

                                                                Let’s start off with a note about honesty. FRIGN begins by telling us “We do not believe in equal status (i.e. e.g. forcibly obtaining a 50/50 gender ratio)” as if someone was proposing the use of force to produce a 50/50 gender ratio - and we all know that wasn’t proposed by anyone. There’s no way to discuss this properly if people are going to raise false issues like that. What comment’s like FRIGN’s indicate is an unwillingness to have an open and honest conversation. The same bogus rhetoric is at the heart of Damore’s memo: he claims to be in favor of equal rights and just against mythical demand for 50/50 gender equality so that he can oppose obviously ineffective affirmative action programs at Google where 80% of technical staff are male (Damore’s misappropriation of science is similarly based on an objection to a position that nobody ever argued.).

                                                                The next point is that some people are objecting that a CoC and a minority outreach program are “political”. That’s true, but it involves the use of the more general meaning of “political” which the Collins dictionary provides as “the complex or aggregate of relationships of people in society, esp those relationships involving authority or power”. If we are using that definition, of course a CoC and a minority outreach program are political, but opposition to a CoC and a minority outreach program fits the definition as well. If you have an opinion one way or another, your opinion is political. You can’t sensibly use this wide definition of political to label the effort to adopt a CoC and to recruit more minorities and then turn around and claim your opposition to those is somehow not political. So that’s what I mean by “it is impossible to not be political”. The question is a political question and those who try to claim the high ground of being objective, disinterested, non-political for their side of the question are not being straightforward (perhaps it’s just that they are not being straightforward with themselves).

                                                                1. 3

                                                                  I agree that a CoC, a minority outreach program, and opposition to a CoC all impinge upon “the complex or aggregate of relationships of people in society, esp those relationships involving authority or power”.

                                                                  Would you also agree that there is a popular ideological political movement in favour of CoCs (some combination of the feminist, civil rights and social justice movements)? Perhaps there is also a popular ideological movement against CoCs (some combination of MRAs and the alt right). Are you also claiming that if one claims a “neutral” stance on CoCs one is de facto supporting one of these ideologies?

                                                                  1. 3

                                                                    I’m not sure it is possible to have a neutral stance. In fact, I doubt it.

                                                                    1. 1

                                                                      Interesting! Do you also doubt it is possible to take any action that is neutral with regard to a political ideology?

                                                                      1. 3

                                                                        You are introducing something different. I don’t think you have to line up with one “side” or another, but you can’t avoid being a participant.

                                                                        1. 1

                                                                          You said “It’s impossible to not be political” so I’m trying to understand what you mean by that. So far I’m not clear whether you think every action is political. I’d appreciate it if you’d clarify your position.

                                                                          1. 2

                                                                            I’m making a very concrete assertion, which I sense does not fit into your schema. My assertion is that there is no neutrality on workplace equality and inclusion for anyone involved in the workplace. Anyone who, for example, participates in an open source development effort has a position on whether efforts should be made to make it more inclusive even if that position is “this is not important enough for me to express an opinion.”

                                                                            1. 1

                                                                              Thank you for clarifying. When you originally said “It’s impossible to not be political” I got the wrong impression.

                                                                              Do you also hold the same point of view when it comes to roughly comparable statements in other spheres? For example ‘Anyone who eats has a position on vegetarianism even if that position is “this is not important enough for me to express an opinion.”’?

                                                          2. 1

                                                            You’ve been quoted by LWN: https://lwn.net/Articles/753709/

                                                          3. 11

                                                            AKA shut up and hack? :)

                                                            1. 1

                                                              The suckless development process has no non-technical discussions?

                                                              How are the best developers identified?

                                                              1. 8

                                                                just curious, why would you need to identify the best developers? Wouldn’t the quality of their code speak for that?

                                                                1. 5

                                                                  I also fail to see what the reasoning is. Just send your code, get the non technical discussions out.

                                                                  1. -1

                                                                    Apparently, quoting @FRIGN from above, “to make your software suck less.”

                                                                  2. 8

                                                                    How are the best developers identified?

                                                                    I think this is a totally reasonable question, and one I’d like to see the answer too–if for no other reason than it might help those of us on other projects find more objective metrics to help track progress with.

                                                                    Do you all at suckless use something like:

                                                                    • defect rate
                                                                    • lines of code/feature shipped
                                                                    • execution time
                                                                    • space in memory, space in storage

                                                                    Like, what metrics do you use?

                                                                    1. 7

                                                                      You know, suckless is not a big company and the metrics that can be applied are more of a heuristic. A good developer is somebody who e.g. supplies a patch with a bug report, provides feedback to commits, makes contributions to the projects, thinks his commits through and doesn’t break stuff too often and does not personally identify with their code (i.e. is not butthurt when it’s not merged).

                                                                      What needs to be stressed here is that the metric “lines of code” is completely off. There are horrible programmers who spit out lots of code and excellent ones who over time drop more lines than they add. Especially the latter group is very present among us and thus the LOC-metric will only give false results. Same with execution time, you find that when not enough time is spent on a problem you end up solving it wrong, in the worst case having to start all over.

                                                                2. 5

                                                                  By being very diverse and doing fackelmärsche of course. https://suckless.org/conferences/2017/

                                                                  1. 3

                                                                    @FRIGN What’s the purpose of this “torchlight hike” in the context of producing code that sucks less? Don’t you see that the activities you choose to have during your conferences are a cultural stance, and because of that, can be perceived as exclusive by programmers that don’t recognize themselves in these activities?

                                                                    1. 0

                                                                      I get your point, but must honestly say that your argument sadly aligns with the ever-excluding and self-segregating destructful nature of cultural marxism. By eating food together at the conferences, do we exclude anorexics that might otherwise be willing to attend such a conference? I don’t drink any alcohol and never have. Still, it was not a problem when we went to a local Braukeller and some people drank alcohol and others like myself didn’t.

                                                                      The fundamental point I think is that one can never fully and analytically claim that a certain process is completely unaffected by something else. If we dive down into these details we would then move on and say that the different choice of clothings, hairstyle, means of travel and means of accomodation all affect the coding process at suckless. This can be taken further and further with no limit, as we all know about the butterfly effect. At some point it is just not measurable any more.

                                                                      If you ask me, this is a gross overstretching of what I said. There are quite a lot of people who do not attend the conferences but still work together with us on projects during that time. What really matters is that we e.g. do not ignore patches from these people or give them less relevance than those of others. To pick the example up: The torchlight hike did not affect any coding decision in a direct way, but it really bonded the team further together and was a very nice memory of this conference that I and the others are very fond of from what I’ve heard. On top of that, during the hike we were able to philosophize about some new projects of which some have become a reality. The net-gain of this event thus was positive.

                                                                      In classical philosophy, there are two main trains of thought when it comes to evaluating actions: Deontology and Teleology. Deontology measures the action itself and its ethical value, completely ignoring the higher goal in the process. Teleology is the opposite, evaluating actions only by their means to reach a goal, completely ignoring the value of the action itself. The best approach obviously should be inbetween. However, there is a much more important lesson that can be taken from here: When evaluating a decision, one needs to realize what they are measuring and what is unimportant for a decision. What I meant is that to reach the goal of software perfection, the gender and other factors of the submitters do not matter. So even though we here at suckless have a goal, we are not teleologists, as we just ignore the factors that do not matter for coding.

                                                                      It is an ethical question which norms you apply to a decision.

                                                                      If we look at organizations like Outreachy, one might be mistaken to think that they are deontologists, striving to improve processes. However, after closer inspection it becomes clear that this is not the case and they are actually working towards a certain goal, increasing the number of trans and minority people in such communities. No matter how you think about this goal, it makes one thing clear: When you are working towards such a goal and also do not ignore irrelevant factors in your norms (and they in fact do by not ignoring e.g. race and gender), you quickly end up discriminating against people.

                                                                      I hope this clears this up a bit, but as a short sentence, what can be taken from here is: When discussing ethical matters, it’s always important to make clear which norms are applied.

                                                                      1. 2

                                                                        fackelmärsche

                                                                        I’m not going to wade into anything else on this, but I’d like to just take a second and let you know that, while you may not mean it in this way the phrase “cultural marxism” is very, very often used as a stand in for “jews”. Some links for the record:

                                                                        https://www.splcenter.org/fighting-hate/intelligence-report/2003/cultural-marxism-catching

                                                                        https://newrepublic.com/article/144317/trumps-racism-myth-cultural-marxism https://www.smh.com.au/world/cultural-marxism--the-ultimate-postfactual-dog-whistle-20171102-gzd7lq.html

                                                                        1. 3

                                                                          It’s not my fault that some idiots don’t understand this term or it’s critical analysis. Cultural marxism, as the term implies, is the classical theory of marxism applied to culture. It has nothing to do with jews directly, it’s just an idea. If you know any better term to describe it, please let me know.

                                                                          Anyway, in the philosophical realms it’s known as ‘Critical Theory’, which originated in the Frankfurt School. However, nobody knows this term.

                                                                          Unless a better term is found, I disregard your argument and won’t accept your attempt to limit language of perfectly acceptable words to describe an idea. At the end of the day, terminology must be found that adequately describes what a certain idea is, and I see no reason why this should be wrong.

                                                                          Regarding the torch hike: Yes, marching with torches was abused by the NSDAP as a means of political rallying. However, at least in Germany, it is a much older and deeper-reaching tradition that dates back hundreds of years.

                                                                          1. 0

                                                                            You have amply demonstrated that you don’t know anything about the topic. You could start with the decent Wikipedia article. https://en.wikipedia.org/wiki/Frankfurt_School

                                                                          2. 2

                                                                            wow, uh, kind of a weird red flag that pointing this out is getting seriously downvoted. I picked these links pretty quickly, and anybody who comes behind and reads this and wonders how serious this is, do yourself a favor and image search and see how many memes have the star of david, greedy merchant, world strangling octopus or any of a number of openly anti-semitic imagery. Its not hidden, its not coy. If you’re tossing “cultural marxism” around you’re either willfully ignoring this or blatantly playing along. Its not a thing in the world. There are no leftists (at all) who call themselves “cultural marxists”, and in fact there is a sizeable faction of marxists who are openly disdainful of any marxism that eschews political struggle. The new republic article linked above goes into this, Perry Andersons “Considerations on Western Marxism”, a well known, well regarded text across a number of marxist subsects, is explicitly based on this. Anyway, enjoy contributing to a climate of increasing hostility toward jews. good stuff.

                                                                            edit: have some fun with this https://www.google.com/search?q=cultural+marxism&client=firefox-b&source=lnms&tbm=isch&sa=X&ved=0ahUKEwjz2tWrhvnaAhUJ7YMKHVgcCccQ_AUIDCgD&biw=1247&bih=510#imgrc=_

                                                                            1. 1

                                                                              The term ‘Cultural Marxism’ describes very well what it is, and not all leftists are cultural marxists. The classical theory of marxism, roughly spoken, is to think of society as being split in two camps, the Proletariat and the Bourgeoisie, eternally involved in a struggle, where the former is discriminated against and oppresed by the latter.

                                                                              Cultural Marxism applies these ideas to society. In the Frankfurt School it was called ‘Critical Theory’, calling people out to question everything that was deemed a cultural norm. What is essentially lead to was to find oppressors and oppressed, and we reached the point where e.g. the patriarchy oppressed against women, white people against minorities, christians against muslims and other religions and so forth. You get the idea. Before you go again rallying about how I target jews or something please take a note that up to this point in this comment, I have just described what cultural marxism is and have not evaluated or criticized it in any way, because this here is the wrong platform for that.

                                                                              What you should keep in mind is that the nature of cultural marxism is to never be in a stable position. There will always be the hunt for the next oppressor and oppressed, which in the long run will destroy this entire movement from the inside. It was a friendly advice from my side to you not to endulge in this separatory logic, but of course I understand your reasoning to the fullest.

                                                                              Just as a side note: I did not see you getting ‘seriously’ downvoted. What do you mean?

                                                                              1. 2

                                                                                It’s uncommon to find such a well-put explanation; thanks for that.

                                                                                There will always be the hunt for the next oppressor and oppressed, which in the long run will destroy this entire movement from the inside.

                                                                                If the movement runs out of good targets (and falls apart because they can’t agree on new ones), wouldn’t that imply that it will self-destruct only after it succeeds in its goals? That doesn’t sound like a bad thing.

                                                                                1. 1

                                                                                  I’m glad you liked my explanation. :)

                                                                                  That is a very interesting idea, thanks for bringing this thought up! It’s a matter dependent on many different factors, I suppose. It might fall apart due to not being able to agree on new targets or when everybody has become a target, but it is a very theoretical question which one of these outcomes applies here.

                                                                                2. 1

                                                                                  Did you actually read any of the links I posted? Specifically the New Republic and SPLC links? I don’t know how else to say this and you pretty much side stepped what I said the first time so I’ll try to reiterate it: There is no such thing as “Cultural Marxism”. At all. Its not a descriptive category that any marxist actually self applies or applies to other marxists. I’m fully aware of the Frankfurt School, Adorno, Horkheimer, etc. I’ve read some of them and many, many of their contemporaries from Germany, people like Karl Mannheim. I read marxist publications everyday, from here in the states and from Europe. I’m a member of an explicitly marxist political party here in the states. I can’t emphasize this enough, “cultural marxism” isn’t real and is roughly on par with “FEMA camps”, “HARRP rays” and shape shifting lizard jews, meaning; its a far far right wing paranoid fantasy used to wall off people from other people and an actual understanding of the material conditions of their world. I also didn’t say, specifically in fact pointing out that I wasn’t saying this, that you were “targeting jews”. That being said, if you use a phrase that has its origins in anti-semitic polemics, is used explicitly and over-whelmingly by anti-semites, than that is on you. (Did you take a look at the linked image search? Does that sort of thing not give you pause?) To say that you “just described what cultural marxism is” is also inaccurate, you absolutely used it in a descriptive way

                                                                                  I get your point, but must honestly say that your argument sadly aligns with the ever-excluding and self->segregating destructful nature of cultural marxism.

                                                                                  White supremacist organizing is experiencing an enormous upsurge, not only here in the states but in Europe as well. From Le Pen to AfD to SVO in Austria and on and on. These people are not interested in polite conversation and they’re not using “cultural marxism” as a category to illuminate political opponents, its meant to denigrate and isolate, ironically given thats exactly what Neo Nazis and white supremacists here in the states accuse left wingers and “SJWs” of doing.

                                                                                  I appreciate that you’re discussing this peacefully but I’m going to bow out of this thread unless you’re interested enough to take some time and read the links

                                                                                  FWIW these also dismantle the trope and point out pretty much exactly what I’m saying around anti-semitism: https://www.vice.com/en_us/article/78mnny/unwrapping-the-conspiracy-theory-that-drives-the-alt-right https://www.theguardian.com/commentisfree/2016/feb/22/chris-uhlmann-should-mind-his-language-on-cultural-marxism

                                                                                  1. 2

                                                                                    I took some more time to read it up and from what I could see, I found that indeed cultural marxism has become more of a political slogan rather than a normal theoretical term in the USA.

                                                                                    Here in Germany the term “Kulturmarxismus” is much less politically charged from what I can see and thus I was surprised to get this response after I just had “translated” this term into English. It might be a lesson to first get some background on how this might be perceived internationally, however, it is a gigantic task for every term that might come around to you.

                                                                                    So to reiterate my question, what term could be better used instead? :)

                                                                                    1. 1

                                                                                      interesting that it has a different grounding/connotation in Germany, but then again I’m not surprised since thats where its supposed to have originated from. I’ll reread your other posts and come up with a response thats fair. Thanks for taking the time to read those links.

                                                                                  2. 1

                                                                                    Generally people who use “cultural marxism” as a pejorative are sloganeering. The idea of an “eternal struggle” is completely foreign to any kind of marxism which is based on a theory that classes come out of the historical process and disappear due the historical process. Marxism claims that the proletariat and bourgeosie are temporary divisions that arise from a certain type of economic organization. Whatever one thinks of that idea, your characterization of Marxism is like describing baseball as a game involving pucks and ice. Your summary of “cultural marxism” is even worse. Maybe take a class or read a decent book.

                                                                      2. 17

                                                                        I’m not going to remove this because you’re making a public statement for suckless, but please don’t characterize positions you disagree with as madness. That kind of hyperbole generally just leads to unproductive fights.

                                                                        1. 9

                                                                          Please don’t remove anything unless it’s particularly vulgar…

                                                                          1. [Comment removed by author]

                                                                            1. 3

                                                                              hey that’s my account you’re talking about!

                                                                          2. -1

                                                                            Removing differing viewpoints? It is precisely this kind of behavior that maddens people who complain about SJW, who (the SJW) seem unable to take any discussion beyond calling their opponent’s position “evil”, “alt-right”, “neo-nazi”, or, if they are exceptionally well-spoken, “mad”.

                                                                            1. 14

                                                                              No, removing abuse and hyperbole that acts as flamebait regardless of the political opinions expressed. So far I’ve removed one post and hope not to remove more.

                                                                              1. 2

                                                                                It’s hard for me to see a reason to remove things when we have the voting system in place, neither are perfect but one is at your sole discretion whereas the other is the aggregate opinion of the users.

                                                                                1. 21

                                                                                  Voting isn’t a replacement of moderation. It helps highlight and reward good comments and it can punish bad comments, but it’s not sufficient for running a community. I’m trying to head off places where people give up on argument and just try to hurt or tar the people they disagree with because it doesn’t lead to a good community. Lobsters is a very good place for discussing computing and I haven’t seen that in communities this size with hands-off moderation (but I’d love counter-examples to learn from!) From a quick query, we’ve had comments from 727 unique users in the last 30 days and there’s around 15k unique IPs in the logs per weekday, so people are constantly interacting with the others who don’t know their background, don’t share history, can’t recognize in-jokes, simply don’t have reason to trust when messages are ambiguous, let alone provocative. Friendly teasing like “ah yeah, you would think that” or “lol php sucks” that’s rewarding bonding in a small, familiar group hurts in a big one because even if the recipient gets the joke and laughs along or brushes it off as harmless, it’s read by thousands of people who don’t or can’t.

                                                                                  1. 2

                                                                                    Lobsters is a very good place for discussing computing and I haven’t seen that in communities this size with hands-off moderation

                                                                                    I support your position on sub-topic but even my Trial you linked to shows a bit otherwise on just this point. This site has more flexible, hands-off moderation than many I’ve seen with this much political dispute. Even in that link, we saw an amount of honest, civility, and compromise I don’t usually see. There’s been quite a bit better results in this thread than usual elsewhere. There seems to be enough community closeness despite our size that people are recognizing each others positions a bit. Instead of comments, you can actually see it by what’s not said more since it’s prior ground we’ve covered. The others are learning as discussion furthers. Then, there’s the stuff we don’t want which seems to be basically what those individuals are intending in a way that has nothing to do with site’s size.

                                                                                    So, I support you getting rid of just pure abuse, trolling, sockpuppeting, etc. I don’t think we’ve hit the full weaknesses and limited vision of large sites yet despite our increase in comments and views. We’re still doing a lot better than average. We’re still doing it with minimal intervention on things like politics relative to what I’ve seen elsewhere. I think we can keep at current moderation strategy for now because of that. For now.

                                                                                    Just wanted to say that in the middle of all this.

                                                                                    1. 0

                                                                                      Voting isn’t a replacement of moderation. It helps highlight and reward good comments and it can punish bad comments, but it’s not sufficient for running a community.

                                                                                      I’m not sure if I see why it’s not a good replacement. To me, I see voting as distributed moderation and the “real” moderation is automatically hiding (not removing) comments when they fall below a threshold.

                                                                                      I’m trying to head off places where people give up on argument and just try to hurt or tar the people they disagree with because it doesn’t lead to a good community.

                                                                                      I think this method relies on an accurate crystal ball where you can foresee people’s actions and to an extent, the reactions of the people reading the comments.

                                                                                      I’d have to question what you mean by “a good community”, it seems like it’s just a place where everyone agrees with what you agree with and those that disagree aren’t heard because it risks offending those that do agree.

                                                                                      I think the best discussions on here are because we have many people with wide and varied opinions and backgrounds. The good comes from understanding what someone else is saying, not excluding them from the discussion. The only places I see that warranted is where someone has said something purposely and undeniably vile.

                                                                                      1. 8

                                                                                        The automatic hiding of low-scoring comments is also a “sole discretion” thing; jcs added it and I tweaked it a few months ago. The codebase enforces a lot of one moderator’s ideas of what’s good for a community in a hands-off way and the desire to do that motivated its creation.

                                                                                        I strongly agree that a community where everyone agrees with the moderator would be bad one, even if I am that moderator. It’s tremendously rewarding to understand why other people see things differently, if for no other reason than the selfish reason that one can’t correct learn or correct mistakes if one never sees things one doesn’t already agree with.

                                                                                        I think the crystal ball for foreseeing problems is experience, from many years of reading and participating in communities as they thrive or fail. I think it’s possible to recognize and intervene earlier than the really vile stuff because I’ve seen it work and I’ve seen its absence fail. I keep asking for examples of excellent large communities without active moderators because I haven’t seen those, and after a couple decades and a few hundred communities I see the anthropic principle at work: they don’t exist because they self-destruct, sink into constant vileness, or add moderation. At best they have maintain with signal-to-noise ratios far below that of Lobsters where the thoughtful commentary is crowded out by trolling, running jokes, ignorance, and plan low-quality comments because it doesn’t seem worth anyone’s while to care when posting.

                                                                                        But moderation is not a panacea in and of itself. Without good experience, judgment, and temper a bad moderator swiftly destroys a community, and this is a very common way communities fail. If it helps any, the author of the comment I removed agrees that it wasn’t done to suppress their opinion.

                                                                                        1. 1

                                                                                          The benefit I see from moderation being part of the codebase is that it’s public, predictable and repeatable (it terms of reliability). When you take moderation decisions into your own discretion many of these virtues are lost.

                                                                                          As for experience, I think that’s tricky because it can easily lead you to making the same mistake twice. It’s also made of your personal experiences and you’re using that to curate the discussion of other people, I would caution that it’s another method of controlling dialog (perhaps subconsciously) to what you find acceptable, not necessarily what’s best for everyone.

                                                                                          1. 3

                                                                                            The benefit I see from moderation being part of the codebase is that it’s public, predictable and repeatable (it terms of reliability). When you take moderation decisions into your own discretion many of these virtues are lost.

                                                                                            Most of them go into the Moderation Log. I’ve been watching it since the jcs days since it’s what folks are supposed to do in a transparent, accountable system. Gotta put effort in. I haven’t seen much of anything that bothered me. The bans and deletes I’ve been able to follow @pushcx doing were trolling, alleged sockpuppeting, and vicious flamewaring. Some I couldn’t see where I’d rather the resource go off the front page rather getting deleted so someone looking at logs could see it for whatever it was. Nonetheless, his actions in the thread about me, the general admining, and what I’ve seen in moderation have been mostly good. A few really good like highlighting the best examples of good character on the site. I think he’s the only one I’ve seen do that on a forum in a while.

                                                                                            You have little to worry about with him in my opinion at the moment. Do keep an eye on the comments and log if you’re concerned. Scrape them into version storage if concerned about deletions. What goes on here is pretty public. Relax or worry as much as you want. I’m more relaxed than worried. :)

                                                                                            1. 3

                                                                                              Yeah, I agree on the pitfalls of experience. As SeanTAllen noted in a separate branch of this thread a minute ago, there’s “but you didn’t say” and other wiggle room; I think that’s where automatic moderation falls down and human judgment is required. Voting has its own downsides like fads, groupthink, using them to disagree (which is all over this thread), in-jokes, a drifting definition of topicality, all the parallels to the behaviors of political rhetoric, etc. Lobsters has never been voting only and I don’t see a compelling reason to change that. jcs’s involvement in the site was steadily declining so I’m certainly more actively moderating, but I don’t see that as a change in character. I guess what it comes down to is that I agree with you about what successful communities do and don’t look like, but I haven’t seen one that works on the model you’ve outlined and I don’t see that kind of fundamental change as a risk worth taking.

                                                                                  2. 1

                                                                                    So FRIGN writes to oppose “SWJ madness”, and you chime in to complain that “SWJ” calls opponents “mad”. Are you calling FRIGN “SWJ” or what? It’s kind of hard to discern your point in that cloud of grievance.

                                                                                    1. 1

                                                                                      “SJW” for “social justice warrior.”

                                                                                      @COCK is sarcastically non-replying because you typo’ed.

                                                                                      1. 2

                                                                                        Not exactly, I was sarcastically non-replying because I assumed he was intentionally misunderstanding me. I assumed this because I didn’t see any ambiguity in my answer. On later inspection I noticed the ambiguity so I gave an actual reply:

                                                                                        https://lobste.rs/s/nf3xgg/i_am_leaving_llvm#c_yzwuux

                                                                                        1. 1

                                                                                          The interesting thing is how people agreeing with Mr. cock pile on the insults against the people who they complain are insulting them by forcing them to sign on to codes of conduct which prohibit insults. It’s almost as if there was a good reason for those codes.

                                                                                          1. 1

                                                                                            I doubt the irony is lost on anyone supporting a CoC.

                                                                                        2. -1

                                                                                          Yes, I’m calling FRIGN a “SWJ”.

                                                                                          1. -1

                                                                                            Yes, well, one sympathizes with your plight.

                                                                                            1. 2

                                                                                              Ah now I see the ambiguity: “people who complain about SJW, who…” the “who” referred to the “SJW”, not the “people”

                                                                                        3. 1

                                                                                          The only comment that was removed was against FRIGN point of view. Nobody is removing differing point of view, just enforcing civil discussion.

                                                                                      2. [Comment removed by author]

                                                                                        1. 4

                                                                                          “We at suckless are heavily opposed to code of conducts and discriminatory organizations of any shape or form.”

                                                                                        2. 4

                                                                                          It’s responses like yours that really make the case for codes of conduct.

                                                                                          1. 2

                                                                                            Are you speaking for the group or is that your own opinion? Knowing that the group aligns itself with that position would certainly make me not interested in working with it or contributing.

                                                                                            1. 6

                                                                                              To be fair, suckless is not well-organised enough to be a group that can have a single opinion to be spoken for.

                                                                                              That said, FRIGN is a prominent contributor and I from what I’ve seen most contributors are heavily on the side of “the code will speak for itself”.

                                                                                          1. 4

                                                                                            I don’t get what the problem is here - do a fork and move on? Call it VoidStar Linux or something? :)

                                                                                            1. 15

                                                                                              We would like to keep the name, Void is still a small distribution and just started to get a bit more known. I don’t think a fork would kill the project but it would be annoying and we would like to avoid (“Avoid Linux” would get my vote for a rename) it.

                                                                                              1. 3

                                                                                                I really like Void. I use it on my Media PC and it has a lot of cool stuff in it. It feels so minimalist and that’s really great.

                                                                                                So long as you have control over the .com, losing the .eu would kinda suck but it feels more like an inconvenience than a killer issue. Thankfully there are lots of Github alternatives like BitBucket, Gitlab or even a self hosted solution like Gog or the self-host Gitlab.

                                                                                                Thanks for all your work. I’m glad Void is out there and hope it continues to grow as a distro. Currently I only use Void and Gentoo .. probably because I can’t do anything the easy way. :-P

                                                                                                1. 1

                                                                                                  We would like to keep the name

                                                                                                  Is this legal?

                                                                                                  1. 7

                                                                                                    I don’t know. We just want to continue the project like we did for over a year now. But its becoming more challenging each month that goes by without any contact.

                                                                                                    If he for some reason doesn’t agree with us continuing the project we can hard fork and rename. But because there is no contact we don’t know.

                                                                                                    I would personally be happy to hear from him again and I hope he is fine.

                                                                                              1. 3

                                                                                                Really wish this had example programs on the page or just something I could see without watching a video.

                                                                                                  1. 1

                                                                                                    Looks like a design bug for @andrewrk (or someone) to fix :-)

                                                                                                    1. 2

                                                                                                      What’s wrong with minimal (or no) design? It’s fully functional as is.

                                                                                                      1. 3

                                                                                                        Nothing’s wrong with it. All I meant to say was, if someone couldn’t find examples maybe it could be made clearer where to find them. By “design” I didn’t mean just the CSS.

                                                                                                1. 8

                                                                                                  You see, one of the biggest problems with a Linux distro or any large system is bootstrapping. At some point you get to the point where you need a previous version of your tooling to build the current version. This is not really desirable as it ultimately can become a very difficult to break build loop. Because of this, xbps-src is in fact not a binary, it is a collection of very intricate shell scripts that use standard tooling available on almost any Linux distribution to bootstrap a compiler, build chroot, and XBPS itself.

                                                                                                  It’s cool that their build system is a bunch of shell scripts that will run on any Linux distro. I wrote about some related stuff here in January [1]:

                                                                                                  • Alpine’s abuild script is also a pure shell script – a pure busybox ash script! But it doesn’t run on anything besides Alpine.
                                                                                                  • Debootstrap is a shell script that also only runs on Debian (as far as I know). I believe building Debian packages (as opposed to the base image) requires a lot of native / non-shell tools.
                                                                                                  • Aboriginal Linux is a bunch of pure shell scripts as well.

                                                                                                  So it sounds like I should download xbps-src and try it out with Oil :)

                                                                                                  However, I also don’t think the bootstrapping issue is as big a deal as he thinks? Because you want/need some kind of isolation anyway. You don’t want your build platform leaking into your binaries, i.e. a Void package built under Debian or Alpine should not be different than a Void package built under Void.

                                                                                                  The usual solution for Alpine is to download an Alpine image and build packages there; likewise for Debian you download a Debian image. And this image can generally be a chroot – i.e. you don’t need a dedicated piece of hardware (or a VM, or a Docker container). (However I wish that Alpine would make the chroot story more straightforward. It doesn’t feel “first class”.)

                                                                                                  Without the chroot or similar to pin down the versions of your build toolchain, I think it’s hard to solve the “reproducibility” issue. I don’t know exactly how Void Linux does it, but I am a bit confused by the description. You still need two stages to build, and it’s natural to use your own distro as the first stage, rather than some other distro.

                                                                                                  Linux From Scratch has the steps “preparing the host system”, “constructing a temporary system”, and “building LFS”.

                                                                                                  http://www.linuxfromscratch.org/lfs/view/stable/

                                                                                                  [1] Success with Aboriginal, Alpine, and Debian http://www.oilshell.org/blog/2018/01/15.html

                                                                                                  1. 6

                                                                                                    Void’s build system uses isolation to build packages. From readme [1]:

                                                                                                    xbps-src requires an utility to chroot and bind mount existing directories into a masterdir that is used as its main chroot directory. xbps-src supports multiple utilities to accomplish this task:

                                                                                                    • xbps-uunshare(1) - XBPS utility that uses user_namespaces(7) (part of xbps, default).
                                                                                                    • xbps-uchroot(1) - XBPS utility that uses namespaces and must be setgid (part of xbps).
                                                                                                    • proot(1) - utility that implements chroot/bind mounts in user space, see https://proot-me.github.io/.

                                                                                                    NOTE: you don’t need to be root to use xbps-src, use your preferred chroot style as explained below.

                                                                                                    I’m very slowly developing a Linux distribution using xbps-src. I can build a (still quite useless) squashfs image without root privileges [2].

                                                                                                    [1] https://github.com/voidlinux/void-packages/blob/master/README.md

                                                                                                    [2] https://github.com/hadrianw/tomatoaster

                                                                                                    1. 4

                                                                                                      Wow totally unrelated but “an utility” sounds so wrong. I didn’t realize there were words starting with vowels that don’t use “an.” Apparently it’s words starting with vowel sounds that get an “an.” Utility, as well as words like user and euphemism, phonetically start with a y sound and therefore don’t use “an.” Crazy that I knew that intuitively, but until I read “an utility” just now I would have said “an” goes before words starting with vowels. I had thought “an hour” and a few other h words were the only exceptions. Weird.

                                                                                                    2. 5

                                                                                                      The bootstrap process is done by building a meta-package base-chroot (https://github.com/voidlinux/void-packages/blob/master/srcpkgs/base-chroot/template) and its dependencies using the tools available on the host. After the bootstrap xbps-src uses base-chroot to create clean/void environment which can be used to build all the packages available.

                                                                                                      1. 1

                                                                                                        OK thanks for the info. I guess my point is that this is very much like other Linux distros, including Alpine, and even Debian.

                                                                                                        At least this is true in theory – I don’t see that Void necessarily has a unique take on bootstrapping. But in practice it might be better, because with the distros I’ve tried this area feels a little like undocumented black magic that only the core devs know about.

                                                                                                        I have used: https://github.com/alpinelinux/alpine-chroot-install

                                                                                                        But I haven’t yet rebuild a lot of packages under it.

                                                                                                        1. 2

                                                                                                          Voids take reminds me more of netbsd here, which isn’t a huge surprise given who started it.

                                                                                                      2. 3

                                                                                                        Also if anyone is interested in trying Void build scripts with OSH let me know :-)

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

                                                                                                        I’m not familiar with Void Linux, but it sounds BSD-ish and interesting.

                                                                                                        1. 2

                                                                                                          I’ve actually been using fpm to do a lot of my packing as of late, rather then dealing with deb scripts and RPM spec files. fpm does things amazingly well for most use cases.

                                                                                                        1. 2

                                                                                                          On wikipedia it says:

                                                                                                          For most of its lifetime, the Lisa never went beyond the original seven applications that Apple had deemed enough to “do everything”

                                                                                                          Does anyone know what these applications were?

                                                                                                          1. 3

                                                                                                            The Lisa Office System was eventually renamed “7/7”, in reference to the seven supplied application programs: LisaWrite, LisaCalc, LisaDraw, LisaGraph, LisaProject, LisaList, and LisaTerminal.

                                                                                                            https://en.wikipedia.org/wiki/Apple_Lisa#Software

                                                                                                            1. 1

                                                                                                              Ah, missed that bit

                                                                                                          1. 0

                                                                                                            You don’t want to manually write makefiles. Use Autotools instead: https://autotools.io/index.html

                                                                                                            1. 14

                                                                                                              Why not, its completely fine to write “simple” makefiles for “simple” projects. I think the musl makefile is a good example for a not so simple but still simple makefile.

                                                                                                              To me autotools generated makefiles are a hell to debug, just slightly less hellish than debugging cmake.

                                                                                                              1. 5

                                                                                                                The musl makefile is one of the cleanest production makefiles I’ve ever seen. But I note even its opening comment says, “This is how simple every makefile should be… No, I take that back - actually most should be less than half this size.”

                                                                                                                I count, at least, 3 languages used:

                                                                                                                1. GNU dialect of make
                                                                                                                2. shell
                                                                                                                3. sed

                                                                                                                And hacks like this:

                                                                                                                obj/musl-gcc: config.mak
                                                                                                                	printf '#!/bin/sh\nexec "$${REALGCC:-$(WRAPCC_GCC)}" "$$@" -specs "%s/musl-gcc.specs"\n' "$(libdir)" > $@
                                                                                                                	chmod +x $@
                                                                                                                
                                                                                                                obj/%-clang: $(srcdir)/tools/%-clang.in config.mak
                                                                                                                	sed -e 's!@CC@!$(WRAPCC_CLANG)!g' -e 's!@PREFIX@!$(prefix)!g' -e 's!@INCDIR@!$(includedir)!g' -e 's!@LIBDIR@!$(libdir)!g' -e 's!@LDSO@!$(LDSO_PATHNAME)!g' $< > $@
                                                                                                                	chmod +x $@
                                                                                                                

                                                                                                                Local legend @andyc of Oil Shell fame pushes the idea that Shell, Awk, and Make Should Be Combined. IMHO, the musl example is persuasive empirical evidence for his position.

                                                                                                                (I’m hoping @stefantalpalaru is being sarcastic about Autotools and we’re all falling to Poe’s Law.)

                                                                                                                1. 2

                                                                                                                  (I’m hoping @stefantalpalaru is being sarcastic about Autotools and we’re all falling to Poe’s Law.)

                                                                                                                  No, I’m not. I’ve worked with hand written Makefiles, Autotools and CMake on complex projects and I honestly think that Autotools is the lesser of all evils.

                                                                                                                  Local legend @andyc of Oil Shell fame

                                                                                                                  Now I hope you’re the one being sarcastic. Who exactly uses the Oil Shell?

                                                                                                                  1. 3

                                                                                                                    Now I hope you’re the one being sarcastic.

                                                                                                                    I was not being sarcastic. @andyc’s Oil Shell posts consistently do well in voting here.

                                                                                                                    Who exactly uses the Oil Shell?

                                                                                                                    Who uses a less than a year old shell that explicitly isn’t for public use yet? I’m hoping very few people.

                                                                                                                    What does the number of Oil Shell users have to do with his argument?

                                                                                                              2. 7

                                                                                                                Err. Last time I touched autotools it was a crawling horror.

                                                                                                                Makefiles are fine. Just don’t write ones that call other makefiles (recursive make considered harmful and all that).

                                                                                                                1. 3

                                                                                                                  Just don’t write ones that call other makefiles (recursive make considered harmful and all that).

                                                                                                                  Clearly someone needs to write “Make: The Good Parts” 😂

                                                                                                                  1. 2

                                                                                                                    Isn’t non-recursive make also considered harmful?

                                                                                                                    1. 2

                                                                                                                      I think the ideal is a makefile that includes parts from all over your source tree, so that there’s one virtual Makefile (no recursive make invocation O(n^2) issues) but changes can be made locally. Best of both worlds!

                                                                                                                  2. 5

                                                                                                                    I’m no expert on Make or Autotools, but my response to building automation on top of an automation tool is: “Please, god, no!”

                                                                                                                    If your automation tool lacks the expressiveness to automate the problem your solving, the solution should never be to bolt another automation tool on top of it. It’s time to start over.

                                                                                                                    1. 2

                                                                                                                      I’m going to take a guess that you’re not a DevOps engineer.

                                                                                                                      1. 1

                                                                                                                        “Lets just use another layer of automation!” is the DevOps version of solving every problem with another layer of indirection clearly! :)

                                                                                                                      2. 1

                                                                                                                        But why not? One tool (cmake, meson) checks dependencies and works on high-level concepts such as “binary”, “library”. Other tool (make, ninja) is low-level and operates on building individual files. It’s sane separation of concerns.

                                                                                                                        Make, however, tries to be high-level (at least GNU make, it even has built-in Scheme), but not enough high-level and it might be better at low level (that’s why ninja was invented).

                                                                                                                        Monolith build tools like Bazel might better handle invalidation but this class of tools is not explored enough (existing tools are designed for specific Google/Facebook’s use cases).

                                                                                                                      3. [Comment removed by author]

                                                                                                                        1. 3

                                                                                                                          Autotools is terrible.

                                                                                                                          Yes, but all the alternatives are worse.

                                                                                                                        2. 1

                                                                                                                          Disagree

                                                                                                                          https://varnish-cache.org/docs/2.1/phk/autocrap.html

                                                                                                                          And look how complicated this configure script is which doesn’t take 60 seconds to run:

                                                                                                                          https://github.com/bsdphk/Ntimed/blob/master/configure

                                                                                                                        1. 5

                                                                                                                          Why is this still a blacklist instead of a whitelist? There are many more environment variables in glibc that might result in undefined behavior or worse.

                                                                                                                          1. 22

                                                                                                                            Compiling Firefox on 8 core ryzen targetting the host arch takes between 10 and 15 minutes.

                                                                                                                            1. 10

                                                                                                                              Wow that is fast, takes ~2h on a build server that takes 7 hours for chromium. All the recent rust stuff really slowed it down.

                                                                                                                              1. 6

                                                                                                                                All the recent rust stuff really slowed it down.

                                                                                                                                Oof, yeah, I bet. Rust is notoriously slow to compile. Luckily, incremental compilation is in the nightly compiler right now. I’ve been using it wherever I can and it really does make a difference. But I suppose it wouldn’t do much for an initial compilation of a project. :(

                                                                                                                                1. 4

                                                                                                                                  In this case a large chunk of this is just bindgen; we need to generate bindings so we throw a libclang-based-bindings generator at all of the header files. Twice (complicated reasons for this).

                                                                                                                                  It’s also pretty single threaded (codegen units will help with this, but currently isn’t, and I have to investigate why).

                                                                                                                                  Incremental compilation and working codegen units and cleaning up the bindgen situation will help a lot. Going to take a while, though.

                                                                                                                                  1. 3

                                                                                                                                    But I suppose it wouldn’t do much for an initial compilation of a project.

                                                                                                                                    Also not going to help packagers who use only temporary compilation environments which are discarded after a package is built.

                                                                                                                                    1. 6

                                                                                                                                      Package managers (and regular builds also) should not be starting from scratch every time. Even if we insist on doing all source editing in ASCII, we need to be delivering modules as fully-typed, parsed ASTs.

                                                                                                                                      This insistence on going back to plain source code every chance we get and starting over is easily wasting more energy than the bitcoin bubble.

                                                                                                                                      1. 9

                                                                                                                                        Package managers (and regular builds also) should not be starting from scratch every time.

                                                                                                                                        They should if you want reproducible builds.

                                                                                                                                        1. 3

                                                                                                                                          These are completely orthogonal. There’s nothing stopping reproduceable builds where you run the entire pipeline if you insist on comparing the hash of the source and the hash of the output. And you would still get the same benefit by comparing source<->ast and ast<->binary

                                                                                                                                          1. 1

                                                                                                                                            Yeah, ideally a compiler would take a difference in source to a difference in output. Compiler differentiation?

                                                                                                                                          2. 2

                                                                                                                                            I believe you can do a decent amount of caching in this space? Like MSFT and co. have compile serverse that will store incrementally compiled stuff for a lot of projects so you’re only compiling changes

                                                                                                                                      2. 7

                                                                                                                                        My non-beefy lenovo x series laptop takes ~45 minutes for a complete recompile, ~12min for average changes w/ ccache etc. and ~min for JS-only changes (which you can do as artifact builds, so they’re always 3min unless you need to build C++/Rust components

                                                                                                                                      1. 16

                                                                                                                                        Can I get a “Hates Electron” hat?

                                                                                                                                        It looks like you made a web version! - I wish everyone that made electron “apps” had the foresight to make web version (do they even need to be different repo?!). There is a lot more potential for your app now that it isn’t encumbered by electron! Someone can turn it into a service or run it on a BSD!

                                                                                                                                        I’d also like to nip something in the bud.. electron (and anything built on top of it) is not “mimimal”. It might have taken you very little code to produce said thing.. but electron is very very not minimal.

                                                                                                                                        Here is some data to chew on:

                                                                                                                                        Electron (66846bff975f92dd721d5ca29f332edf3795f1c0)
                                                                                                                                        -----------------------------------------------------------------------------------
                                                                                                                                        Language                         files          blank        comment           code
                                                                                                                                        -----------------------------------------------------------------------------------
                                                                                                                                        C++                                312           9711           4385          46244
                                                                                                                                        Markdown                           513          18985              0          43674
                                                                                                                                        JavaScript                         199           2979           1012          22966
                                                                                                                                        C/C++ Header                       337           5855           4674          19227
                                                                                                                                        Objective C++                       47           1573            713           6642
                                                                                                                                        Python                              39            911            288           2909
                                                                                                                                        HTML                               123            102              0           1885
                                                                                                                                        YAML                                 5             23             16            347
                                                                                                                                        Bourne Shell                         8             74             70            309
                                                                                                                                        JSON                                15              3              0            243
                                                                                                                                        Windows Resource File                1             21             33             85
                                                                                                                                        Bourne Again Shell                   7             23             21             70
                                                                                                                                        Dockerfile                           1              5              4              9
                                                                                                                                        PowerShell                           1              0              0              2
                                                                                                                                        CSS                                  1              0              0              1
                                                                                                                                        CoffeeScript                         1              0              0              1
                                                                                                                                        -----------------------------------------------------------------------------------
                                                                                                                                        SUM:                              1610          40265          11216         144614
                                                                                                                                        -----------------------------------------------------------------------------------
                                                                                                                                        
                                                                                                                                        Chromium (61.0.3163.100)
                                                                                                                                        qbit@slip[0]:chromium-61.0.3163.100λ cloc .                 
                                                                                                                                          209609 text files.
                                                                                                                                          189475 unique files.                                          
                                                                                                                                        Out of memory!800
                                                                                                                                        panic: POPSTACK
                                                                                                                                        qbit@slip[1]:chromium-61.0.3163.100λ 
                                                                                                                                        
                                                                                                                                        Entire OpenBSD src tree (includes clang and gcc)
                                                                                                                                        ---------------------------------------------------------------------------------------
                                                                                                                                        Language                             files          blank        comment           code
                                                                                                                                        ---------------------------------------------------------------------------------------
                                                                                                                                        C                                    16045        1151514        1394479        6409501
                                                                                                                                        C++                                   9027         380730         428645        2129520
                                                                                                                                        C/C++ Header                         12480         401032         766593        2026578
                                                                                                                                        Perl                                  4122         157859         208622         982209
                                                                                                                                        HTML                                   903          33457           6243         471775
                                                                                                                                        Bourne Shell                          1298          62248          76580         469701
                                                                                                                                        Markdown                               259          46737              0         402916
                                                                                                                                        PO File                                129         141599         190451         319672
                                                                                                                                        Python                                1208          31439          29325         120108
                                                                                                                                        Assembly                               896          19716          53416         107674
                                                                                                                                        yacc                                    89          13030           8543          99830
                                                                                                                                        Expect                                 459          14444          21708          74919
                                                                                                                                        make                                  2271          14044           7875          59234
                                                                                                                                        m4                                     179           6227           3099          54859
                                                                                                                                        Windows Module Definition              179           5820             41          43062
                                                                                                                                        ASP.Net                                  2           1013             18          24720
                                                                                                                                        TeX                                     19           3073          12237          21050
                                                                                                                                        CMake                                  660           3043           2162          20623
                                                                                                                                        Lisp                                   104           1551            455          13386
                                                                                                                                        Pascal                                  42           2045           6029          10822
                                                                                                                                        lex                                     32           1620           1791           9035
                                                                                                                                        Fortran 77                             183            893           2886           7495
                                                                                                                                        Objective C                            201           1772            830           6473
                                                                                                                                        Objective C++                           16           1019            998           6024
                                                                                                                                        awk                                     51            500           1384           4363
                                                                                                                                        OCaml                                   59           1355           2442           4100
                                                                                                                                        Go                                      28            544            655           3876
                                                                                                                                        Fortran 90                              73            264            818           3457
                                                                                                                                        XML                                     36            193             53           3389
                                                                                                                                        CSS                                     22            528            251           3087
                                                                                                                                        Korn Shell                              12            565            958           2738
                                                                                                                                        YAML                                    52             20            113           2186
                                                                                                                                        sed                                     47            221            596           1851
                                                                                                                                        Antlr                                    2              0              0           1726
                                                                                                                                        DOS Batch                               29            258             97           1507
                                                                                                                                        JSON                                    21              3              0           1190
                                                                                                                                        JavaScript                               6            106            182            856
                                                                                                                                        Racket                                   3             76            132            626
                                                                                                                                        C#                                       8             87            108            557
                                                                                                                                        Bourne Again Shell                       7            111            196            532
                                                                                                                                        Forth                                    1             96            123            497
                                                                                                                                        Windows Message File                     1            102             11            489
                                                                                                                                        vim script                               9             60             78            395
                                                                                                                                        Mathematica                             93             18              0            350
                                                                                                                                        DTD                                      1             91             58            335
                                                                                                                                        MSBuild script                           1              0              7            254
                                                                                                                                        R                                       32             26             12            252
                                                                                                                                        diff                                    20             37            248            248
                                                                                                                                        Windows Resource File                    7             35             12            194
                                                                                                                                        XSLT                                     1             46              9            187
                                                                                                                                        MATLAB                                   6             69              3            173
                                                                                                                                        C Shell                                  2             17             22            132
                                                                                                                                        GLSL                                     1             16              0             61
                                                                                                                                        Protocol Buffers                         1             47            168             47
                                                                                                                                        Java                                     3              5             24             47
                                                                                                                                        Prolog                                   4             30             -1             44
                                                                                                                                        D                                        6              7              7             42
                                                                                                                                        Dockerfile                               6             26             90             38
                                                                                                                                        SAS                                      1             14             21             29
                                                                                                                                        Ada                                      4             13             45             23
                                                                                                                                        NAnt script                              1              0              0              9
                                                                                                                                        INI                                      1              1              0              6
                                                                                                                                        Standard ML                              2              0              0              4
                                                                                                                                        Lua                                      1              0              1              2
                                                                                                                                        ---------------------------------------------------------------------------------------
                                                                                                                                        SUM:                                 51464        2501512        3231949       13931085
                                                                                                                                        ---------------------------------------------------------------------------------------
                                                                                                                                        

                                                                                                                                        If someone else wants to run cloc on the chromium tree - I would love to see the complete output!

                                                                                                                                        1. 2
                                                                                                                                           ryzen chromium/src [287861b160] » time loc -uu
                                                                                                                                          --------------------------------------------------------------------------------
                                                                                                                                           Language             Files        Lines        Blank      Comment         Code
                                                                                                                                          --------------------------------------------------------------------------------
                                                                                                                                           C++                  51006     16769880      2144056      1660815     12965009
                                                                                                                                           Plain Text           52868      7840453       186175            0      7654278
                                                                                                                                           C/C++ Header         44407      6524647      1001316      1603227      3920104
                                                                                                                                           HTML                 67998      4149634       440243       206856      3502535
                                                                                                                                           C                     8773      4570335       541083       691917      3337335
                                                                                                                                           JavaScript           24789      4317194       494352       888292      2934550
                                                                                                                                           Python               12200      2650721       424870       258194      1967657
                                                                                                                                           JSON                  5696      1813849         2895            0      1810954
                                                                                                                                           Assembly              1561       975142        67340        23191       884611
                                                                                                                                           Java                  4417       967647       124617       191860       651170
                                                                                                                                           Hex                    351       602556            0            0       602556
                                                                                                                                           Objective-C++         3278       649941       100102        73113       476726
                                                                                                                                           XML                   2338       506560        38555        15844       452161
                                                                                                                                           Markdown              1910       263887        68139            0       195748
                                                                                                                                           GLSL                  6800       334925        46917       138825       149183
                                                                                                                                           CSS                   1729       120394        16977         8405        95012
                                                                                                                                           Makefile              1137       127804        16903        18113        92788
                                                                                                                                           Bourne Shell           821       126147        15239        22305        88603
                                                                                                                                           Perl                   196        88120         9900         8442        69778
                                                                                                                                           Objective-C            231        87862        11087         9129        67646
                                                                                                                                           Autoconf               367        69611         5883         7138        56590
                                                                                                                                           C#                     226        76446         7066        13049        56331
                                                                                                                                           Go                     115        55798         5386         5570        44842
                                                                                                                                           reStructuredText       299        55210        15199            0        40011
                                                                                                                                           INI                     25        41413         3327            5        38081
                                                                                                                                           Tcl                    134        39870         3773         6628        29469
                                                                                                                                           Protobuf               536        59063         8600        21791        28672
                                                                                                                                           PHP                    752        37499         3868         7485        26146
                                                                                                                                           YAML                   239        28976         2569          738        25669
                                                                                                                                           Yacc                    13        18205         1731         1457        15017
                                                                                                                                           Ruby                    36         6653          896          473         5284
                                                                                                                                           OCaml                   71         9685         1782         2796         5107
                                                                                                                                           Batch                  121         7016          991         1008         5017
                                                                                                                                           SQL                    145         4792          157          236         4399
                                                                                                                                           Lua                     31         4975          574          459         3942
                                                                                                                                           Sass                    35         3246          468          607         2171
                                                                                                                                           Lisp                    20         2594          291          441         1862
                                                                                                                                           TypeScript              34         3021          399         1067         1555
                                                                                                                                           TeX                      3         1875          286          238         1351
                                                                                                                                           Jsx                      5          849          112           60          677
                                                                                                                                           LinkerScript             3          584           15            0          569
                                                                                                                                           VimL                    13          774          117          191          466
                                                                                                                                           Swift                    2          469           53           58          358
                                                                                                                                           Awk                      2          291           53           55          183
                                                                                                                                           ASP.NET                176          176            0            0          176
                                                                                                                                           CUDA                     1          212           15           33          164
                                                                                                                                           R                        2          160           17           27          116
                                                                                                                                           Coq                      9           75            0            0           75
                                                                                                                                           Handlebars               7           70            4            0           66
                                                                                                                                           CoffeeScript             7           89           11           21           57
                                                                                                                                           ActionScript             1           75           18            0           57
                                                                                                                                           Prolog                   1           25            4            0           21
                                                                                                                                           Z Shell                  1           25            4           15            6
                                                                                                                                          --------------------------------------------------------------------------------
                                                                                                                                           Total               295938     54017520      5814435      5890174     42312911
                                                                                                                                          --------------------------------------------------------------------------------
                                                                                                                                          loc -uu  11.45s user 7.23s system 445% cpu 4.191 total
                                                                                                                                          
                                                                                                                                          1. 1

                                                                                                                                            42312911

                                                                                                                                            whoa, I got 28,103,031 on chromium 61.0.3163.100! I wonder what the difference is - did you run depot-tools?

                                                                                                                                            1. 2

                                                                                                                                              I got 33 million with cloc earlier but don’t want to run it again to try to figure out what I’m either getting wrong or they’re ignoring. Was using my own thing: https://github.com/cgag/loc/

                                                                                                                                              Oh, I see you posted the output of cloc in another comment. I see I’m counting 7.6 million lines of plain text. I don’t know why I do that, but subtracting that out gets me down to 34 million which is reasonably close. Also finding far more HTML .

                                                                                                                                              I did use depot-tools, I think I’m at head.

                                                                                                                                              edit: I get a very similar count to tokei when I respect .gitignore like it does so I think mines reasonably accurate.

                                                                                                                                          2. 2

                                                                                                                                            So I got the output from chromium!

                                                                                                                                            So Electron (144,614) and Chromium (28,103,031) mean that electron’s “code base” is 28,247,645 lines of code long. 13.9 million more than a fairly feature complete OS!

                                                                                                                                            1. 1

                                                                                                                                              What is your point? You’re comparing a browser and an operating system (which is orders of magnitude larger and more complex).

                                                                                                                                              Electron is fast to run (even on older hardware and laptops) and easy to build apps with, Slack is a terribly built application but is still the only one people mention when talking about Electron.

                                                                                                                                              Granted, I would probably use a Gecko version of electron if I could, but I am not aware of any projects like that.

                                                                                                                                              1. 3

                                                                                                                                                (which is orders of magnitude larger and more complex).

                                                                                                                                                The point is that the browser is “magnitude larger and more complex” than a complete operating system. Electron is by no means fast to run, the memory usage is over the top and its not portable to systems they don’t support because of the enormous complexity.

                                                                                                                                                The way how electron is designed makes it impossible to have a shared runtime, which would reduce the amount of work to add electron based programs to distributions package managers or ports systems.

                                                                                                                                                Its not feasible to build a whole browser for each electron app.

                                                                                                                                                1. 1

                                                                                                                                                  I’m confused, you say that Electron is larger, but the numbers you posted don’t follow that: Electron: 1610 files, 144614 LOC OpenBSD: 51464 files, 13931085 LOC

                                                                                                                                                  Electron is by no means fast to run, the memory usage is over the top

                                                                                                                                                  I’ll say it again, that is the individual application’s responsibility. Most JS devs don’t know how to be memory safe.

                                                                                                                                                  not portable to systems they don’t support because of the enormous complexity

                                                                                                                                                  This is a legitimate complaint, but is a solvable problem. It’s possible to support FreeBSD and OpenBSD in the near future (as far as I know).

                                                                                                                                                  I’ll admit that a shared runtime would be advantageous from a package managment standpoint, but then you need the latest runtime for one app, but that breaks another and it becomes a big mess.

                                                                                                                                                  1. 2

                                                                                                                                                    Out of memory!800

                                                                                                                                                    panic: POPSTACK

                                                                                                                                                    while running cloc on chromium, it never finished.

                                                                                                                                                    1. 1

                                                                                                                                                      Why don’t you try running it on OpenBSD?

                                                                                                                                                      1. 5

                                                                                                                                                        What? The post from @qbit includes cloc of the OpenBSD source tree and includes the attempt to run it on the chromium source.

                                                                                                                                                        The point is that chromium is too larger to even run cloc on it, while you can completely scan the OpenBSD tree.

                                                                                                                                                        https://www.quora.com/How-many-lines-of-code-is-Google-Chrome

                                                                                                                                                        1. 1

                                                                                                                                                          Oh, I misunderstood your first post, I didn’t understand that the tables were the output of cloc (I’ve never used it before). I see what your saying now, but my point still stands, JS devs are the problem, not Electron.

                                                                                                                                                        2. 2

                                                                                                                                                          Are you taking about electron or cloc of chromium? - because I have tried electron and that cloc cmd above was run on OpenBSD.

                                                                                                                                                          1. 1

                                                                                                                                                            See above.

                                                                                                                                                  2. 3

                                                                                                                                                    Yeah, my point is that an entire OS* src tree is orders of magnitude smaller than the chromium source (which is included when you build electron apps!!)!

                                                                                                                                                    (*) With awesome things like:
                                                                                                                                                    • acme client
                                                                                                                                                    • perl
                                                                                                                                                    • dns server
                                                                                                                                                    • http server
                                                                                                                                                    • dhcp server
                                                                                                                                                    • clang
                                                                                                                                                1. [Comment removed by moderator pushcx: don't make "hate posts"]

                                                                                                                                                  1. 4

                                                                                                                                                    And Direct3D. But for an electron app it really is minimal: only 145.3 MiB on disk.

                                                                                                                                                    1. 5

                                                                                                                                                      A “minimal X app” generally means an app with a simple and straightforward interface, not an app that fits in 64kb.

                                                                                                                                                      1. 3

                                                                                                                                                        I mean, you sort of need a browser to render markdown.

                                                                                                                                                        1. 3

                                                                                                                                                          Isn’t the point of markdown the ability to see ‘formatted’ text without rendering it as HTML? I’ve never really understood the value of these markdown editors, given that the most complex thing in MD seems to be lists

                                                                                                                                                          1. 4

                                                                                                                                                            What makes you think you need a browser for simple text formatting?

                                                                                                                                                            1. 8

                                                                                                                                                              Markdown has full support for inline HTML.

                                                                                                                                                              It’s even so central to the language that it’s literally the second section in the original markdown document

                                                                                                                                                              1. 3

                                                                                                                                                                Never saw this, but I guess that comes from all the different markdown flavors.

                                                                                                                                                                But ok, use electron for this and call it minimal, I don’t have to care if I don’t use it.

                                                                                                                                                                Edit: But using some webkit view from gtk or qt would make it less of a problem for me as someone who packages software for a linux distribution. Packaging electron apps is just not feasible because we need patches for it to support musl libc and building it over and over again for each electron app is just wrong.

                                                                                                                                                                1. 4

                                                                                                                                                                  I find your comment particularly infuriating.

                                                                                                                                                                  Your original post was a lowbrow dismissal of someone’s work couched with irony to provide plausible deniability. Even then, you knew it wasn’t the right thing to do.

                                                                                                                                                                  You then showed that you hadn’t even bothered to understand the field before dismissing the project.

                                                                                                                                                                  You then did another lowbrow dismissal comment, but then followed it up with an edit, in which you suggested:

                                                                                                                                                                  1. the developer take a hard dependency and rewrite their entire software in one of two perennially buggy, flaky, fast-moving and platform-locked desktop linux frameworks, just because it would make your life as a linux software packager easier

                                                                                                                                                                  2. it’s impossible to package electron apps because you have to do work to compile it and that makes you sad

                                                                                                                                                                  I’m trying to imagine scenarios under which you could express more entitlement or lack of respect for people who actually do work, but they’re not coming to me. Additionally, if the job of packaging software is too hard for you, maybe stop doing it.

                                                                                                                                                                  1. 6

                                                                                                                                                                    After your edit this is a much more informative post than your top level one dissing the project. Perhaps you could lead with something more like this next time?

                                                                                                                                                                    1. 3

                                                                                                                                                                      To my understanding, though, there’s no good quick solution to package GTK and QT applications to OS X/Windows, which - to my understanding - is one of the main reasons people pick electron?

                                                                                                                                                                      1. 1

                                                                                                                                                                        Edit: But using some webkit view from gtk or qt would make it less of a problem for me

                                                                                                                                                                        I maintain the OpenBSD port for ghostwriter, it’s pretty minimalistic and uses qt5 webkit view.

                                                                                                                                                                    2. 2

                                                                                                                                                                      There are much nicer ways to make a technical point than this. Please use one of them in the future.

                                                                                                                                                                1. 2
                                                                                                                                                                  deny odedlaz as root cmd /bin/rm args .*\s+/$
                                                                                                                                                                  

                                                                                                                                                                  Does that seem right?

                                                                                                                                                                  doas /bin/rm -rf //
                                                                                                                                                                  doas /bin/rm -rf / /tmp/whatever.txt
                                                                                                                                                                  

                                                                                                                                                                  The gist is that sudo is hard to configure is it. doas might be slightly easier to configure for some cases, but it’s so easy to get these things wrong that I simply don’t recommend the use of sudo or doas or any similar tool to anyone for any reason.

                                                                                                                                                                  setuid-root programs are dangerous. Heck, setuid-anyone programs are dangerous. These kinds of programs are very difficult to get right, so it makes sense to try and store all of the functionality and logic in a single place like sudo or doas, but I think it’s much too difficult for most programmers and worse still there’s simply no reason you need to use it.

                                                                                                                                                                  SSH forced commands are better, and if you forward environment variables and write wrapper scripts, you’ll get an audit trail (which could potentially and trivially be on a separate machine if you have configured pam that way), and what’s more: it’s easy to get right.

                                                                                                                                                                  1. 3

                                                                                                                                                                    The gist is not only the easier configuration but also the small codebase, which should statistically reduce the amounts of bugs. (I’m talking about the original doas, I think the c++ author didn’t get the memo) How is ssh any better, doas has a really small codebase, the configuration is easier to write than wrapper scripts. And you can get the audit trail through syslog and/or bsd-auth or pam.

                                                                                                                                                                    1. 2

                                                                                                                                                                      How is ssh any better?

                                                                                                                                                                      I assume I’ve already paid for ssh; I’m going to use it to reach the machine. The additional code is sudo/doas.

                                                                                                                                                                      If you don’t need ssh (e.g. because you access via the console, via a physically connected terminal, or a terminal simulated via a hypervisor, or even via a separate management network) then I wonder why don’t you audit the use of your terminal server instead of trying to do it from the machine?

                                                                                                                                                                      I’m talking about the original doas, I think the c++ author didn’t get the memo

                                                                                                                                                                      It’s hard to otherwise talk about doas: OpenBSD isn’t an option for most of what I do, but yes: it looks a lot better than this. I’m talking about this article which purports to represent “doas”.

                                                                                                                                                                      the configuration is easier to write than wrapper scripts

                                                                                                                                                                      You’ll probably need to write wrapper scripts anyway. OpenBSD’s doas doesn’t have a particularly flexible configuration file format, and this one has such a horrible grammar that you’re likely to get it wrong as well.

                                                                                                                                                                      But hey, you know bourne-shell already, so you’re probably likely to get your wrapper script correct.

                                                                                                                                                                  1. 3

                                                                                                                                                                    Given all the aspects in which it would seem to be technically superior, how come OpenBSD isn’t eating away at some of Linux’s market share?

                                                                                                                                                                    1. 12

                                                                                                                                                                      Network effects. Default choices. AWS launches with linux support, so people pick linux, then they pick docker, etc etc etc.

                                                                                                                                                                      Linux does solve a great many problems that OpenBSD does not. (Well, it offers a great many features and buttons and such which look like solutions. :)) I’m not sure that one operating system that solves all problems is the best approach, though. there’s a lot of disagreement about how even a desktop OS should work and how components should fit together.

                                                                                                                                                                      1. 5

                                                                                                                                                                        I had also heard that performance on newfangled hipster tasks (http service, MP scheduling, databases) was nontrivially worse, so I started trying to run an OpenBSD instance on AWS to run some side by side tests in order to invalidate those rumors. Apparently one guy once heard of a file you can UUCP from sunsite.unc.edu that enables 80-character mode so that you can give it a shot, but that was from a Byte magazine reader article so I cannot vouch for its veracity. I had to give up when my eyelids started twitching uncontrollably.

                                                                                                                                                                        The reputation for security doubtless partially stems from the fact that installing the thing requires delivering the One True Ring to a locked basement cabinet guarded by leopards in an abandoned mausoleum underneath a nuclear waste disposal site in Afghanistan. Minimization of attack surface and all that. Somewhere, a Haskell core developer is putting down his glasses and rubbing his eyes in admiration.

                                                                                                                                                                      2. 9

                                                                                                                                                                        Hardware support is what keeps me from switching.

                                                                                                                                                                        1. 7

                                                                                                                                                                          And historically, perofrmance. I haven’t seen any good performance comparisons in the last few years (that I remember anyway), but several years ago there were several comparisons done that showed somewhat poor openbsd (and netbsd as I recall) scalability (multi-core performance, etc). Linux has often been one of the top performers in those types of benchmarks.

                                                                                                                                                                          Go fast until the wheels fly off?

                                                                                                                                                                        2. 5

                                                                                                                                                                          The following HN comment from Brendan Gregg might be worth a read. It’s answering in detail basically the same question, just for Illumos rather than OpenBSD: https://news.ycombinator.com/item?id=12837972

                                                                                                                                                                          1. 8

                                                                                                                                                                            The reply is a touch acerbic, but makes some good points too I think. Like why not just give up when linux is 1000 developers ahead? Because half of them are wasting their time inventing ten different tracing frameworks. Ok, admittedly it would be nice for openbsd to have one perf tool, but I think we’re not so far behind as it may seem.

                                                                                                                                                                            Also, for something like inteldrm, there’s a team of devs who keep churning the code, which causes kettenis some struggle when he tries to import it, but on the whole we get most of the benefits of that driver at a considerable manpower discount. The precise economics aren’t quite that simple, but not all of the effort spent on linux is locked in linux either.

                                                                                                                                                                            1. 3

                                                                                                                                                                              Sure, I agree on both of those points. Some effort will be wasted to duplication and churn, some will have little effect as it can be easily reused by other projects.

                                                                                                                                                                              But if the larger developer base is at all positive, it will add up over the decades. E.g. 20 years ago the common wisdom would have been that the BSD TCP stack was both battle hardened and state of the art, while the one in Linux was flaky and scaled badly with load. It’s definitely the other way around these days (to a different extent for different BSDs), with a steadily increasing delta. And then repeat the same story over dozens of subsystems.

                                                                                                                                                                              Clearly there are things that more manpower doesn’t help with. Like deleting code to reduce attack surface; I’m pretty sure that the larger the team, the harder that is to achieve :) It’s not that developers of non-Linux operating systems should just give up, or anything like that. But the assertion at the start of this thread on Linux’s technical inferiority doesn’t feel realistic to me.

                                                                                                                                                                              1. 2

                                                                                                                                                                                That interesting comment reminds me a lot of the Worse is Better effect that got UNIX to dominance in the first place. There were better systems including some focused on good docs, reliability, and high security. I write about them a lot. ;) They lost with them being in close to legacy mode or gone depending on the product/project. The Linux situation, esp as Brendan Gregg describes it, looks like a repeat of that with Linux doing it to the other UNIX’s. I already knew this seeing the likes of SGI, IBM, and Oracle get on the Linux bandwagon despite having proprietary UNIX’s to push. In contrast, OpenBSD is trying the UNIX version of The Right Thing. It will fail in broad sense because that always happens.

                                                                                                                                                                                It’s destined to a niche of those that care about The Right Thing. You’ve all done a great job keeping it up despite your filter on the kind of contributors you accept and not giving into market’s crap that much. I saw Theo backtrack a bit with VMM admitting OpenBSD might have to do a little more for marketability. Still, the project will probably need a like-minded sponsor with lots of money and/or talent to break past what we’ve seen so far since The Right Thing is always swimming upstream vs Worse is Better which sometimes creates tsunami’s. Those of us focused on quality might always be also-rans in larger scheme of things. (shrugs)

                                                                                                                                                                            2. 5

                                                                                                                                                                              Linux is easier to use.

                                                                                                                                                                              How do you search for a package in OpenBSD? How do you get a description in your search results? You can search package names by downloading the index.txt file from the packages directory on a mirror. But anything more sophisticated you have to use the ports tree and the janky makefile system with non-intuitive syntax and cryptic errors to do any interesting searches.

                                                                                                                                                                              It’s actually possible to download and install a Linux distro that comes with a desktop environment, installs quickly, and works fine right away. When I was first getting into non-Windows operating systems in middle school, I tried out OpenBSD because the whole secure OS thing sounded cool to me. I screwed with it for hours, felt like I was getting nowhere, then gave up and installed Linux Mint.

                                                                                                                                                                              I run OpenBSD now, but I’m also a systems programmer / SRE at a database company, so I’m not exactly an “average user” that represents the trend of the market.

                                                                                                                                                                              1. 6

                                                                                                                                                                                pkg_info -Q is what you want. That said - it looks like it doesn’t respect the -d or -c flags (I have a diff to make it work with it though)

                                                                                                                                                                                1. 3

                                                                                                                                                                                  yep. i use pkg_info, i browse the ports mailing list, read the website, and also look at my mirror of choice from time to time.

                                                                                                                                                                                  i just use cwm that’s in base. i had previously used gnome and xfce from packages. i reckon my willingness to read documentation mostly gets me to where i need to be… other things figured out by trial and error, mailing list, and searching the internet.

                                                                                                                                                                                  1. 2

                                                                                                                                                                                    You make it seem like reading the documentation is a bad thing? This should be the preferred approach.

                                                                                                                                                                                    On linux the preferred approach is asking half assed questions on stack overflow.

                                                                                                                                                                                    1. 1

                                                                                                                                                                                      i don’t think it’s a bad thing. i’m implying that everyone saying openbsd is difficult to install or use aren’t reading these things and i don’t really understand why.

                                                                                                                                                                                  2. 2

                                                                                                                                                                                    Ahhhh. I’m somewhat amazed that I didn’t know that. But I will still call it unintuitive. See, I expected something like pkg_search, or to find something searching for “search” in man pkg_info. Searching “OpenBSD search for package” on Google returns a bunch of ancient results about ports. It IS mentioned in the packages FAQ though, but the preview text on Google mentions ports specifically. So I must have searched for it, seen those results, rolled my eyes, looked in the man pages, seen nothing, and decided to just download the index file.

                                                                                                                                                                                    Compare to most Linux package managers, which when run with no arguments tell you the commands to install and search. The word “search” specifically is much more well known than “query” because of Google.

                                                                                                                                                                                    So even though I’m a bit lazy and it’s clearly my fault for not knowing this as a sophisticated user, I think helping rather than blaming the user isn’t the right strategy towards getting adoption. Linux is really good about that, OpenBSD not so much.

                                                                                                                                                                                    1. 2

                                                                                                                                                                                      or to find something searching for “search” in man pkg_info.

                                                                                                                                                                                      Query is close. I guess it’s a difference in terminology.

                                                                                                                                                                                      Searching “OpenBSD search for package” on Google

                                                                                                                                                                                      This seems to be a common trend among Linux users, google is consulted with more authority than local documentation. I personally do the same thing.. when finding issues with linux machines I always go to google first.. the crap documentation (often lacking entirely) has trained me to do so!

                                                                                                                                                                                      I think helping rather than blaming the user isn’t the right strategy towards getting adoption. Linux is really good about that, OpenBSD not so much.

                                                                                                                                                                                      Where was there lack of help and who is doing blaming?

                                                                                                                                                                                      1. 3

                                                                                                                                                                                        I realize query and search are close, but search is definitely the layman terminology.

                                                                                                                                                                                        Googling isn’t just a Linux strategy, that’s what Windows and Mac users do too. Apple in particular is pretty good about making their support pages show up on Google.

                                                                                                                                                                                        I didn’t originally mean people blaming the user directly, but rather a UX that “blames the user” in its design, and for OpenBSD I mostly see this in docs or commands. Not being able to find the -Q flag in the man page by searching (querying?) for search is poor UX. It implicitly becomes the users fault for not reading the whole manual. There are no examples either, where surely a common operation like search would be demonstrated. And OpenBSD commands don’t self document or provide assistance, whereas Linux commands will often list the most common usage if you don’t type a valid command. Using OpenBSD feels a bit RTFM, wheras on Linux stumbling around in an interactive session is much more viable, as most things try and point you in the right direction.

                                                                                                                                                                                        This goes both ways, on OpenBSD it’s way more likely that if you can’t figure something out, it actually is documented somewhere. But that documentation could be more accessible and searchable.

                                                                                                                                                                                        But also user blaming happens directly on misc@. I am part of no other community that ever makes me think “wow these people are such outrageous stuck up assholes, I’m not even sure I want to be a a part of this anymore.” Mostly OpenBSD people are intelligent, articulate, and kind. For example, I’ve had nothing but good experiences talking with OpenBSD folks on lobsters. But wow some of the stuff on misc makes my blood boil.

                                                                                                                                                                                        I’ve considered contributing to OpenBSD docs to make them more accessible, especially FAQs / new user guides, but my experiences on misc have always stopped me. I worry that I’ll be shot down for going against the OpenBSD philosophy, and I won’t even be rightly told why, just be told I’m a moron. It sucks, because I love OpenBSD and I want to share it and make it easier for people to learn about, but I feel discouraged from contributing.

                                                                                                                                                                                        1. 1

                                                                                                                                                                                          again i feel the direct opposite here.

                                                                                                                                                                                          i was able to find everything i needed without asking for help and without googling for the most part.

                                                                                                                                                                                          still don’t understand how you missed -Q in the pkg_info man page because it’s right at the top in synopsis.

                                                                                                                                                                                          maybe i’m a stuck up asshole too.

                                                                                                                                                                                          1. 1

                                                                                                                                                                                            maybe i’m a stuck up asshole too.

                                                                                                                                                                                            I don’t think so.

                                                                                                                                                                                            still don’t understand how you missed -Q in the pkg_info man page because it’s right at the top in synopsis.

                                                                                                                                                                                            I wanted to search, I scanned the first line for search, /searched for search, moved on. I’m just too impatient. But a lot of people are too impatient, and worse a lot of people just don’t care enough to persist.

                                                                                                                                                                                            1. 1
                                                                                                                                                                                  3. 3

                                                                                                                                                                                    i’m an average to below average user and i use openbsd as my daily driver.

                                                                                                                                                                                    i don’t program and my knowledge of computers is intermediate at best.

                                                                                                                                                                                    i also work in a non-tech field.

                                                                                                                                                                                    i think it’s the easiest and most straight-forward OS to use.

                                                                                                                                                                                    so, obviously i disagree with this.

                                                                                                                                                                                    1. 3

                                                                                                                                                                                      I wonder what you’re doing on lobste.rs :)

                                                                                                                                                                                      1. 2

                                                                                                                                                                                        Interesting! So, how do you look for packages you need to install? How’d you get going with a desktop environment?

                                                                                                                                                                                    2. 3

                                                                                                                                                                                      The file system isn’t great…

                                                                                                                                                                                      1. 11

                                                                                                                                                                                        Please. Greatest filesystem of the 80s. Best decade, best filesystem.

                                                                                                                                                                                        1. 2

                                                                                                                                                                                          That was Files-11 on OpenVMS with versioning and stuff. Especially integrated with high-uptime stuff like clustering and distributed lock manager. Or NonStop’s Guardian with its crazy reliability. Or first system (SCOMP) certified to high security that added ring and segmented protection to them with system-wide security policy.

                                                                                                                                                                                          I do agree it was one of best decades for applied IT with all kinds of awesome shit happening based on what CompSci had worked on in 1960’s-1970’s with better hardware available. A lot of things started coming together that couldn’t before.

                                                                                                                                                                                      2. [Comment removed by author]

                                                                                                                                                                                        1. 8

                                                                                                                                                                                          Or they need to run certain applications that are only available on Linux, or they need drivers that are only available on Linux, or they want a filesystem that has more features than UFS/FFS, etc.

                                                                                                                                                                                          OpenBSD picked a niche and perfected itself in that niche. I think it is a shining example that picking one problem and solving it well, is often better than being a jack of all trades, master of none.

                                                                                                                                                                                          (Which does not mean that it cannot be used as a general purpose OS with some care.)

                                                                                                                                                                                          1. 6

                                                                                                                                                                                            Even as someone who likes the FSF, I doubt many Linux users are there because of (rather than despite, or indifferent to) the GPL. It’s not hard for me to imagine an alternate universe without the BSD lawsuits where FreeBSD or something got popular as the mainstream free hobbyist Unix in the 1990s, and I seriously doubt FSF diehards would have been able to keep more than a handful of people from going with that bandwagon, had it developed (and had they actually wanted to).

                                                                                                                                                                                          2. 1

                                                                                                                                                                                            Same reason as many other similar situation throughout the industry. People know something else, a lot is built on other systems, marketing, and once you have a certain amount of people using tech X it’s really hard to use something else.

                                                                                                                                                                                            Another side effect that kicks in with Linux Distributions, Operating Systems and Programming languages is that at many places if you introduce a technology that isn’t the currently dominant one you will be personally blamed for every single bug or different obstacle it has. It will often be blamed on it, despite also existing on the dominant OS.

                                                                                                                                                                                            Something related is that sadly a lot of software that companies and people end up using at some point is written in unnecessarily non-portable ways. I once worked at a company that used a software running a bash script (stored inside a string in a program) and it had a typical non-portable #!/bin/bash instead of #!/usr/bin/env bash. As usually I’d report that and even create a pull request on a huge (in terms of stars, in the tens of thousands) and very hyped software, expecting it would be accepted. After being baffled that the authors didn’t even know about /usr/bin/env and what it does, a link to Wikipedia didn’t help either the conversation stalled. Since that project was being used by the front end developers I kept patch sets for such things around.

                                                                                                                                                                                            And while those tiny things are really not hard in general these tiny things add up. I know the problem even exists if you don’t use Ubuntu, but for example Alpine in the Linux world.

                                                                                                                                                                                            Having these kind of portability issues leads to the dominant technology in a field to quite often not be the best. The most famous example is how long Internet Explorer stuck, despite Opera and the Mozilla browser, until Firefox came along.

                                                                                                                                                                                            When there is a lot of users and developers even pretty bad technology can stick, because there will be widely used workarounds for problems, there will be progress on fronts, even when the architecture is flawed, etc. Change is rarely that quick, especially when many parties are involved and put their money and effectively lives on it.

                                                                                                                                                                                            Of course that doesn’t mean that Linux is bad and OpenBSD is great, just that technical superiority or being a bit better than others usually is far from a good indicator for dominance in a field. Especially if marketing and politics have a big presence, but even without. People simply need to have heard of it and a good reason to switch and get into something new to them and settle there. When there is no direct financial effect, that is significant enough people tend to not just switch utilities from one moment to the next. And even when you know OpenBSD really well and are convinced its better introducing that in an existing company might not be an option. Of course you can always switch, but why give up a safe, well-paying job with great coworkers for an operating system?

                                                                                                                                                                                            1. 1

                                                                                                                                                                                              Docker / namespaces

                                                                                                                                                                                            1. 6

                                                                                                                                                                                              lol

                                                                                                                                                                                              /* Just a safe strncpy(3) */
                                                                                                                                                                                              static void
                                                                                                                                                                                              xstrlcpy(char *dest, const char *src, size_t n)
                                                                                                                                                                                              {
                                                                                                                                                                                              	strncpy(dest, src, n - 1);
                                                                                                                                                                                              	dest[n - 1] = '\0';
                                                                                                                                                                                              }
                                                                                                                                                                                              ...
                                                                                                                                                                                              xstrlcpy(cmd + strlen(cmd), newpath, strlen(newpath) + 1);
                                                                                                                                                                                              xstrlcpy(buf + strlen(buf), fpath, strlen(fpath) + 1);
                                                                                                                                                                                              ...
                                                                                                                                                                                              
                                                                                                                                                                                              1. 2

                                                                                                                                                                                                Very small nitpick: this only works if /bin/sh is bash (or something that supports $((...))). Works like a charm after telling it to run with bash.

                                                                                                                                                                                                I missed the original sct thread, and redshift felt heavy, so this little script + sct will be of great use to me. Thanks!

                                                                                                                                                                                                1. 4

                                                                                                                                                                                                  Piling on the nitpick wagon, error messages should go to stderr rather than stdout:

                                                                                                                                                                                                  - echo "Please install sct!"
                                                                                                                                                                                                  + echo >&2 "Please install sct!"
                                                                                                                                                                                                    exit 1;
                                                                                                                                                                                                  
                                                                                                                                                                                                  1. 2

                                                                                                                                                                                                    FWIW, dash handles this properly as well:

                                                                                                                                                                                                    % file /bin/sh
                                                                                                                                                                                                    /bin/sh: symbolic link to dash
                                                                                                                                                                                                    % sh
                                                                                                                                                                                                    $ echo $((1440 - 720))
                                                                                                                                                                                                    720
                                                                                                                                                                                                    

                                                                                                                                                                                                    OpenBSD’s ksh, same goes for zsh:

                                                                                                                                                                                                    $ echo $((1440 - 720))
                                                                                                                                                                                                    720
                                                                                                                                                                                                    

                                                                                                                                                                                                    So I guess on the majority of systems you’d run X on, this won’t be an issue ;)

                                                                                                                                                                                                    Now, my own nitpick - I’ve ran shellcheck and fixed some warnings:

                                                                                                                                                                                                    #!/bin/sh
                                                                                                                                                                                                    
                                                                                                                                                                                                    # Copyright (c) 2017 Aaron Bieber <aaron@bolddaemon.com>
                                                                                                                                                                                                    #
                                                                                                                                                                                                    # Permission to use, copy, modify, and distribute this software for any
                                                                                                                                                                                                    # purpose with or without fee is hereby granted, provided that the above
                                                                                                                                                                                                    # copyright notice and this permission notice appear in all copies.
                                                                                                                                                                                                    #
                                                                                                                                                                                                    # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
                                                                                                                                                                                                    # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
                                                                                                                                                                                                    # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
                                                                                                                                                                                                    # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
                                                                                                                                                                                                    # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
                                                                                                                                                                                                    # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
                                                                                                                                                                                                    # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
                                                                                                                                                                                                    
                                                                                                                                                                                                    S=4500
                                                                                                                                                                                                    INC=2
                                                                                                                                                                                                    SCT=$(which sct)
                                                                                                                                                                                                    
                                                                                                                                                                                                    if [ ! -e "$SCT" ]; then
                                                                                                                                                                                                        echo "Please install sct!"
                                                                                                                                                                                                        exit 1;
                                                                                                                                                                                                    fi
                                                                                                                                                                                                    
                                                                                                                                                                                                    setHM() {
                                                                                                                                                                                                        H=$(date +"%H" | sed -e 's/^0//')
                                                                                                                                                                                                        M=$(date +"%M" | sed -e 's/^0//')
                                                                                                                                                                                                        HM=$((H*60 + M))
                                                                                                                                                                                                    }
                                                                                                                                                                                                    
                                                                                                                                                                                                    setHM
                                                                                                                                                                                                    
                                                                                                                                                                                                    if [ $HM -gt 720 ]; then # t > 12:00
                                                                                                                                                                                                        for _ in $(jot $((1440 - HM)));  do
                                                                                                                                                                                                            S=$((S+INC))
                                                                                                                                                                                                        done
                                                                                                                                                                                                    else # t <= 12:00
                                                                                                                                                                                                        for _ in $(jot $HM); do
                                                                                                                                                                                                            S=$((S+INC))
                                                                                                                                                                                                        done
                                                                                                                                                                                                    fi
                                                                                                                                                                                                    
                                                                                                                                                                                                    while true; do
                                                                                                                                                                                                        setHM
                                                                                                                                                                                                    
                                                                                                                                                                                                        if [ $HM -gt 720 ]; then
                                                                                                                                                                                                            S=$((S-INC))
                                                                                                                                                                                                        else
                                                                                                                                                                                                            S=$((S+INC))
                                                                                                                                                                                                        fi
                                                                                                                                                                                                    
                                                                                                                                                                                                        $SCT $S
                                                                                                                                                                                                    
                                                                                                                                                                                                        sleep 60
                                                                                                                                                                                                    done
                                                                                                                                                                                                    

                                                                                                                                                                                                    Also note that on linux systems, the jot binary is often not available (I just discovered it today, it’s an OpenBSD utility). At least on void linux one can install it with the outils package.

                                                                                                                                                                                                    Either way, very useful - no need to run sct by hand now :)

                                                                                                                                                                                                    1. 2

                                                                                                                                                                                                      Odd, my dash at home barfed on the script. I now checked again, and it errors out on function setHM { .. }: it wants setHM () { ... } instead.

                                                                                                                                                                                                      Not quite sure why I remember $((...)) being a problem…

                                                                                                                                                                                                      1. 1

                                                                                                                                                                                                        function, even though technically a bashism, originated in ksh.

                                                                                                                                                                                                        In terms of $((...)) being a problem, you are most likely referring to ((...)) which is indeed a bashism. Alternatively, you might have come across ++ or -- in $((...)), which are not required by POSIX.

                                                                                                                                                                                                      2. 1

                                                                                                                                                                                                        for _ in $(jot $((1440 - HM))); do

                                                                                                                                                                                                        huh, I had no idea _ was a thing, neat!

                                                                                                                                                                                                        1. 1

                                                                                                                                                                                                          $_ holds the last argument of the preivously run command. Overwriting it does no harm here and in similar places, so I occasionally make use of it (both to silence shellcheck and to signal the value won’t be used). It’s possible though some folks might object :)

                                                                                                                                                                                                        2. 1

                                                                                                                                                                                                          Also note that on linux systems, the jot binary is often not available (I just discovered it today, it’s an OpenBSD utility).

                                                                                                                                                                                                          You can use seq instead of jot on linux.

                                                                                                                                                                                                        3. 1

                                                                                                                                                                                                          In similar vein, I’d suggest to replace [ with [[ because the latter is a bash/zsh/dash builtin.

                                                                                                                                                                                                          1. 1

                                                                                                                                                                                                            Its a myth, you can check it with type [, both are builtin, [[ is only available in larger shells, [ is POSIX. The [ should be preferred for #!/bin/sh portability.

                                                                                                                                                                                                          2. 1

                                                                                                                                                                                                            $((…)) is very much POSIX.