1. 1

    I can’t help but wonder at having does-added methods which override the self-same method and using this to implement a state machine.

    1. 15

      There are various command-line concoctions such as password-store which stores PGP-encrypted files in a Git repo, but that doesn’t improve my situation over 1Password. I would still have to manually look up passwords and copy them to the clipboard. These command-line packages also lack mobile apps and syncing.

      That’s not completely true. I use pass with syncing via a private Git repository, there’s a Firefox plugin with autofill support, good mobile clients for both Android and iOS. The best password management system I’ve used (I’ve been a user of 1Password for about 3 years before that). Being able to do git log to see password history for a website is awesome. Bonus point: OTP plugin works like a charm.

      1. 2

        The major problem with pass is that the mobile clients don’t supported encrypted git remotes, which is a huge problem: anyone with read access to the remote repo can see what your accounts are.

        1. 4

          So put the remote on a system you physically control ;)

          1. -3

            Given that git is distributed and makes it very easy to push from any client to any remote, it’s a pretty safe assumption that one day you’ll accidentally push to another remote where you realize shortly after doing so that this was A Bad Plan.

            1. 14

              … it’s pretty hard to accidentally push to a remote you never set up…

      1. 7

        The key to this work is throwing out old assumptions and requiring explicit guest support.

        Historically, VM systems “had” to be able to boot guests which didn’t need to know they were in a VM, but the guest could optionally implement dedicated “hardware” drivers to have more optimized I/O than through emulated devices. Still, you could take the install media for various OSes and install them all.

        This project requires explicit guest support for basic boot-up. Which is great, if your model is around managing everything in the guest and you can make that demand. They reap major benefits from doing so, and there’s no reason for everyone creating images for deployment needs to be held back because the target system is also trying to be compatible with stuff which you’ll never deploy. But it’s very much a case of needing the guest to be compiled explicitly for the target hosting platform.

        Since the competition is structured containerization with something like a Dockerfile defining entry-points, environmental dependencies, etc, this is not different. It’s a great trade-off. But it is made possible by the target audience having moved and adapted to a world of on-demand machine instances and container workloads.

        1. 1

          Link now 404s; going from http://vjolt.org/archives/older-volumes/ to volume 2 issue 1, we see:

          1. The Use of Encrypted Coded, and Secret Communications is an Ancient Liberty Protected by the United States Constitution [html] [Adobe .pdf format]
            By John A. Fraser III
          1. 2

            “I ask you to judge me by the enemies I have made.” — Franklin D Roosevelt

            1. 3

              Neat troll at the end:

              id also like to thank andrew loyd weber, inventer of the world wide web for making the internet

              [sic]

              1. 4

                Author is generous. Originally from UK, moving from NL to US in 2006 I ended up remarking to colleagues that the US banking system was like moving back to the 1970s. 11 years later I’m still using passwords for bank website authentication, with knowledge of a bank account number being a closely held secret.

                IBAN fee-free international transfers to friends or for paying bills (same day in-country, instant if same bank chain); fee-free cross-bank ATM withdrawals; sane security for web sign-in or initiating transfers; banking websites which don’t require you to lower the browser security settings to work; PIN-less on-card small-balance cash so you’re not typing your PIN into everything (paying for parking or using vending machines), all stuff I am still waiting for. Well, aside from the browser security settings: American banks have mostly caught up there.

                1. 2

                  IBAN fee-free international transfers to friends or for paying bills (same day in-country, instant if same bank chain)

                  SEPA Instant Credit Transfer is launching in November and will hopefully see support from banks somewhen next year. It will allow instant (less than 10s) transfers across banks.

                1. 11

                  It was inevitable.

                  If only it made him complete a quest with a random character in adventure mode before continuing to update his system. :D

                  This is one good reason why I always use full, explicit paths in my scripts.

                  1. 12

                    This is one good reason why I always use full, explicit paths in my scripts.

                    but then they are not portable

                    1. 8
                      qbit@slip[0]:~λ which bash
                      /usr/local/bin/bash
                      qbit@slip[0]:~λ
                      
                      1. -2

                        Just always use /bin/bash and don’t care about distros/BSDs that don’t care enough about their users to place bash there. Problem solved for 99% of users. ;)

                        1. 10

                          or you know, ignore developers that don’t care about their downstream packagers and users to learn about /usr/bin/env? Problem solved for 99% of users caring about cross platform software.

                          1. 3

                            Not all distros may have env in /usr/bin, so not necessarily an improvement over the extremely common /bin/bash. Then there’s the problem of what /usr/bin/env df might return…

                            1. 12

                              On NixOS, env is the only thing in /usr/bin, so that’s at least one distro that developers can avoid breaking by using it.

                              1. 7

                                IME, globally /usr/bin/env is more likely to exist than /bin/bash. The person who has this dwarf fortress issue seems to have done foolish things to get df to be dwarf fortress so I don’t think this situation is a valid motivator for something that is closer to being a standard (/usr/bin/env) than something that’s not (/bin/bash).

                                1. 1

                                  As long as neither /bin/bash nor /usr/bin/env are standards, there can be issues. In addition to this, there is no agreed upon registry for reservation of the names of the executables.

                        2. 1

                          Keep in mind, for this to happen, the user probably changed the system default PATH to put Dwarf Fortress first. sudo usually scrubs the environment to default settings unless you’ve taken steps.

                          1. 10

                            Read the comments on the answer. He dropped a symlink into /usr/local/bin to make the command available to him. /usr/local/bin/df ?

                            1. 1

                              I don’t get this. Did he override the linux df in /usr/local/bin?

                              1. 1

                                The original df is in /bin. He placed another df to /usr/local/bin. The default PATH on Ubuntu has /usr/local/bin before /bin, so his df gots executed instead of the system one.

                              2. 1

                                Why would they use df? Did they not know of the other df? Or did they just not care? I don’t care if someone else set the PATH variable and it isn’t your fault, at best it is confusing, at worst someone messes up an install/copy/backup script, with potential to hose their system.

                                1. 3

                                  Not all the world is Unix. I can’t confirm with cursory searches, but given the character set choice (CP437) I strongly suspect that Windows was the original platform.

                                  1. 1

                                    It was

                          1. 2

                            Isn’t stuff like better upstream standards around tooling, but without having to reinvent the wheel and set everything up for scratch, why organizations like The Apache Software Foundation exist? Defined software, governance, tooling etc, leaving the projects themselves to get on with the software they care about?

                            1. 6

                              Anyone know if any browsers explicitly define their caching semantics for what they store, for a live-streamed object which is never “terminated”? This isn’t server-push object replacement, after all, but one object which has internal framing, and so keeps getting larger. So if the 4kB/sec claim on the page is right, then if you leave the browser open for a day then that’s a third of a GB. I know people who can forget their browser tabs for days on end.

                              1. 4

                                I remember on older webcams, their web interfaces could stream video via motion JPEGs, which just sends endless JPEG frames to the browser. I don’t think it was a problem back then even for those old browsers.

                                1. 1

                                  I don’t think it was a problem back then even for those old browsers

                                  Even if it was a problem, this was the nineties we’re talking about. People would barely even notice if you crashed their browser or computer and they had to restart it, so long as you didn’t crash it much more than once an hour or so.

                              1. 16

                                One person at work put it best: “layers are only ever added, never removed.”

                                That just stings so painfully true.

                                1. 7

                                  Every problem in computers can be solved with another level of abstraction–except for the problem of too many levels of abstraction!

                                  1. 5

                                    Nonono, I don’t need to care about those five layers there. By using a layer of abstraction to hide that those layers exist, I can make it look like there are only three layers instead of seven.

                                1. 1

                                  For my new business account (with custom domains), I’m using ProtonMail. I had used FastMail in the past, and it was fine, but I wanted to support the FOSS aspect of ProtonMail (pretty much the same price for both). I thought about running my own email server on Digital Ocean, but even at $5 a month, that’s more expensive than ProtonMail’s “Plus” plan ($48/year) or FastMail’s $50/year.

                                  1. 2

                                    The Fastmail folks are the de facto (if not now de jure) maintainers of Cyrus IMAP and have open sourced their work there. They’ve been quietly supporting OSS right for years.

                                    1. 1

                                      Good to know! I guess ProtonMail’s web site/marketing is oriented more towards techies, e.g., OSS is a “feature” for them. So nice to know that either company is a good option for supporting OSS.

                                  1. 1

                                    For personal stuff, I run my own server (exim etc). The technical side of things is fine there.

                                    These days I have my own company, and one consideration is “how much proof is it, if I have an email record of something and there’s a dispute”. If I ran the mail-server and the logs, there’d be a high bar to prove something is a truthful record. As a one-person shop, I don’t have the staffing for it to be otherwise. By outsourcing my email, to people I presumably can’t influence to fake logs, I gain the ability for third-parties to trust that if I have evidence that it’s a truthful record.

                                    So I’m using Fastmail for my LLC. I’m happy with the service. There was some hinkiness around account types and 2FA because they shoe-horned support into existing auth protocols “strangely”, but they’ve gotten past that. Their public IMAP is excellent, the web-browser works well enough to handle the bulk of stuff conveniently and the iOS app works well enough for my needs. My biggest issue is the number of folks assuming Google Calendar and the more limited interop with sharing calendars between accounts, so I ended up creating a gmail-less Google account and eventually enabling Google Calendar on that too.

                                    1. 1

                                      a gmail-less Google account

                                      Is there a specific procedure for that? My cursory search didn’t bring up anything noteworthy.

                                      1. 1

                                        I just went to accounts.google.com in an incognito window, saw More options, clicked that, and the first item in the pop-up is Create account.

                                        You’ll need a working email account elsewhere, and the Google account will be tied to that address. If it’s in a domain which later transitions to Google Apps then there will some reconciliation work needed by the domain admins to handle stuff like Calendar, I don’t know what’s involved these days (and don’t recall what was involved back when I did know).

                                    1. 2

                                      Sympathetic as I am to OP as a (Neo)Vim user, I feel sad that it’s so hard to remix the advantages it finds (resource usage, responsiveness, large-file support) with a non-modal UI.

                                      Also, on large-file handling, this comment on vis was useful.

                                      1. 1

                                        Facepalm at naming an editor the same as a standard 4.4BSD command. :(

                                      1. 14

                                        That said, if the Go team decides to say “no” to generics and own that decision, I suspect they will never fully put an end to the discussion.

                                        The Go team’s stance on generics is pretty clear. What isn’t clear is whether they’re actually living up to their mantra of reducing complexity, or they’re merely shifting complexity elsewhere. It’s easy to think you’ve “simplified” a problem when in fact you have just refused to tackle the complex parts, to the detriment of the poor soul who will actually have to do it.

                                        1. 2

                                          Worked for Unix.

                                          That “worse is better” story about the MIT folks confused about how Unix dealt with system calls in the face of interrupts comes to mind.

                                          1. 4

                                            Except that in practice, the people behind UNIX are not the people who were behind UNIX. Modern UNIX is useful because of a distinct shift from simplicity of implementation to simplicity for the consumer.

                                            1. 1

                                              Mostly agreed. And yet, the core still “looks” like Unix and we still have creat(). What go7 supports may be very different from go1 or go2.

                                            2. 1

                                              When I looked into it, the VMS spawn vs UNIX fork was more interesting. VMS did things like safety checks, security permissions, resource metering, and so on which you could set for the process. UNIX found that stuff was unnecessary. Today, there’s all kinds of band-aid solutions in cloud or virtualization-oriented UNIX’s that do similar things. So, they needed the complexity in there somewhere in a consistent way, didn’t do it, and it got shifted all over the place later.

                                          1. 2

                                            I use this on a regular basis to cleanup my bash scripts.

                                            However what I’m missing: It doesn’t check coding style (unified intention, spaces between operators, pipes etc.). Does anyone know any such tool? I’ve been looking, but haven’t found any.

                                            1. 1

                                              https://github.com/mvdan/sh ? (Specifically, the shfmt command provided therein)

                                            1. 2

                                              I looked at elvish the other day and poked around and discovered that it does this by default. I shook my head at the switch away from grep’ability, then thought about it and decided that it was absolutely the right call to make (especially if you look at multiple shells, concurrency, and meta/unmeta for zsh to mangle what’s actually stored).

                                              1. 5

                                                This stuff is why I like the attention to detail which went into the PNG file format specification. http://www.libpng.org/pub/png/spec/1.2/PNG-Rationale.html#R.PNG-file-signature

                                                (ASCII C notation) \211 P N G \r \n \032 \n

                                                This signature both identifies the file as a PNG file and provides for immediate detection of common file-transfer problems. The first two bytes distinguish PNG files on systems that expect the first two bytes to identify the file type uniquely. The first byte is chosen as a non-ASCII value to reduce the probability that a text file may be misrecognized as a PNG file; also, it catches bad file transfers that clear bit 7. Bytes two through four name the format. The CR-LF sequence catches bad file transfers that alter newline sequences. The control-Z character stops file display under MS-DOS. The final line feed checks for the inverse of the CR-LF translation problem.

                                                I wish that more binary file formats did this sort of thing.

                                                To witness the same issue in the reverse direction: at an ISP where I was a sysadmin, a very large percentage of Support issues (early ‘00s) were from people uploading their CGI scripts and not handling text-mode for conversion from Windows. My boss at the time observed that these things were all written in Perl, which didn’t care about CRLF vs LF and the only reason it was a problem was because the kernel wouldn’t run the program because of #! parsing. We modified our (FreeBSD) kernels to also strip out \r if found immediately before the \n (and another change to let -*- perl -*- work again) and a large chunk of expensive-to-provide Support calls disappeared. Oh, and our customers liked our product more than the competitors’, because ours was easier to use (and switching may have involved more debugging; what a tragedy).

                                                1. 3

                                                  A technique I use when setting the PATH goes:

                                                  PATH="${HOME}/bin${PATH:+:${PATH#${HOME}/bin:}}"
                                                  

                                                  This command prepends ~/bin to PATH. If ~/bin is already at the front of the PATH is doesn’t append it again. If PATH is not defined it avoids appending the path separator, ‘:’, to ~/bin.

                                                  # If PATH is defined, prepend ":" to it (the +):
                                                  ${PATH:+:${PATH}}
                                                  
                                                  # If PATH begins with ~/bin:, remove it (the #):
                                                  ${PATH#${HOME}/bin:}
                                                  

                                                  This makes setting PATH generally idempotent, though it has a bug where ~/bin will be added to PATH twice if PATH is empty or unset. It’s also not idempotent if another directory is added to PATH between two invocations adding ~/bin to PATH. It works well enough in practice.

                                                  1. 9

                                                    Obnoxious zsh user chiming in here: in zsh you can typeset -U path to annotate the variable as being a unique array and then use array operators, like path+=(~/bin) for append or path[1,0]=~/foo for prepend or path=(foo $path bar) if you like cleaner syntax.

                                                    Another zsh note unrelated to parent comment: in zsh there’s ~/.zshenv if you are looking for the Right place to modify the path variable. Most of the zsh package managers / configuration frameworks should gently guide you toward that filepath.

                                                    1. 3

                                                      Second zsh user, here’s my over-engineered method of setting PATH, along with MANPATH and fpath too: https://library.evaryont.me/evaryont/dotfiles/blob/master/zshenv

                                                      The file automatically finds itself (assuming that ~/.zshenv is a symlink to the git clone of my dotfiles repository) and has a large list of directories that I want in my path, sorts, expands and make makes each array full of unique values. Super quick, too!

                                                      1. 2

                                                        That’s not over-engineered. Mine has arrays of common prefices where installation trees can be found, common patterns which might exist therein, functions for manipulation and so forth. You might want to use the (N/) qualifier on entries: only match directories, and remove from the list if no match.

                                                        1. 1

                                                          Interesting. Can you share your config?

                                                      2. 1

                                                        This small script from my dotfiles appends paths to $PATH only if they are existing. I think this solution is quite readable but it does not prevent a path from being added twice.

                                                      1. 3

                                                        I think the author may have looked into the technology and found it to not add anything (which I argue is false, one of the biggest benefits is inter-corporate communication, letting companies have their own clients and “logic” for contracts/payments but still be able to interop in a standard way). This might ultimately be a matter of opinion because there are many ways to solve something and blockchain isn’t the only way.

                                                        But his last statement of no-one trying to sneak this into orgs to solve problems is definitely false, I know people working at NASDAQ to use blockchain tech, J.P Morgan is doing massive investments into blockchain tech, there’s things like the electric car charging network, you have consulting companies like Consensys developing blockchain based solutions for companies and they’re not short of customers.

                                                        If you actually followed the community in any detail you’d see thousands of people trying to sneak the tech into their companies. I have no idea whether they’ll succeed or not, but they sure are trying. I don’t know how the author can justify saying that this isn’t happening “in the slightest”.

                                                        1. 3

                                                          there’s things like the electric car charging network

                                                          But why? Why are they trying to make something simple so complicated again?

                                                          1. 2

                                                            Handling a distributed network of semi-connected machines that need to sync up to a consistent state is hardly simple? I think you should try programming that yourself first before you say “why would you use an out-of-the-box solution for this?”

                                                            1. 2

                                                              There’s out of the box solutions for that which outperform Bitcoin etc on creating, updating, or deleting records. They can be cheaper to operate. They can use existing currency and banks. QED.

                                                              1. 2

                                                                Absolutely, that’s why I would never use Bitcoin for it, but there are many other use-cases of blockchain technology than Bitcoin. Bitcoin happens to be one use, you can’t condemn a whole area of technology because you don’t like Bitcoin. That’s like saying you’re never going to use the Raft algorithm because Docker Swarm is using it.

                                                                1. 3

                                                                  Neil Postman has some interesting stuff to say about this, as does Evgeny Morozov in “To save everything click here”.

                                                                  This as an antidote to the knee-jerk response to every problem, real or imaginary, to solve it with ever more technology without considering whether it is appropriate, proportional or actually solves the problem! I’m also guilty of this, because technology is cool, but I try to be aware of that.

                                                                  So whether or not Bitcoin/blockchain is great awesome elegant technology is not relevant, as it doesn’t solve any real problems that can’t be solved in a much simpler and cheaper way.

                                                          2. 3

                                                            Formal investments and large consultancies developing solutions is emphatically not sneaking it in. Instead, that’s formal projects with real money to fund them and consultancies knowing what they can charge for maybe managing to understand slightly better than their customers. Computing history is littered with such majorly hyped projects, funded in such ways, which have seen some traction inside this sort of customer. DCE (Distributed Computing Environment) is one such example, which has seen traction inside financial institutions, but is hardly a mainstay of typical computing today.

                                                            The author is speaking about the tech which gets snuck into companies and embedded as critical before management finds out about it, because the people at the coalface just need to get things done. This is how a lot of early Linux adoption happened, how … all the author’s examples happened, I think, but some of them predate me. :)

                                                            1. 2

                                                              So sneaking something in has to be non-public and not known outside the small sphere of people working on doing it. How does the author know this isn’t happening?

                                                              I know it’s happening in several places because I know people working on these things, the author is directly contradicting my experience and has no evidence to back it up. I’m not saying I’m right, maybe I’m in a bubble so small it doesn’t count, but at least I have anecdotal evidence, the author just blatantly claims that this isn’t happening without even anecdotal evidence.

                                                              1. 1

                                                                What are your peers doing with blockchain technology in their organizations?

                                                            2. 3

                                                              But his last statement of no-one trying to sneak this into orgs to solve problems is definitely false, I know people working at NASDAQ to use blockchain tech, J.P Morgan is doing massive investments into blockchain tech

                                                              They bought a ton of Microsoft, IBM, Cisco, overpriced consulting, and so on. I guess those are better than the competition at everything they do, too. Wait, they’re the thing holding businesses back now. The blockchain acquisitions might be the same thing later. Further, I’d look into how groups like Bank of America are patenting the hell out of any application of blockchains. It’s more likely the bankers see a new fad they can push hard to increase valuation a portion of which will be their own profit. Plus, they like controlling anything that’s a threat to them. It was a few of them, not governments or militaries, that destroyed Wikileaks when it was in peak, profitable form.

                                                              1. 3

                                                                Or, it’s because banks have problems that are solved by distributed byzantine fault tolerant consensus, and blockchains happen to be one of the easier ways to implement this, and not some conspiracy theory.

                                                                1. 2

                                                                  There’s no conspiracy theory. Investing in stuff that might make a return is standard for banks. It might also solve a problem for them at same time. Distributed, signed, hash chains are a simpler, cheaper technology that’s existed for some time in secure auditing schemes. A portion of it done by digital notaries, too. That plus a consensus algorithm is all they need.

                                                                  The combo would be faster, cheaper, and easier to assure than most blockchains. Additionally, retaining the settlement approach means they can keep transactions they’re liable for internal instead of all in a public database. The distributed database just needs to happen for exchanges and so on. They can evem delete internal logs when no longer needed by them or retention laws. Saves vast amount of CPU, storage, and energy vs blockchains like Bitcoin. Interledger even has a middle component for such a module with formal specification done already per one commenter elsewhere.