1. 3

    What a coincidence; I just set this up yesterday, and it works pretty well. I wanted automatic signing of all messages I sent, as well as automatic encryption when I reply to an encrypted message. That’s easy to set up with mu4e, which is great. The only thing I don’t understand is the seen/new vs. read/unread flags. Seems to me that seen/new is automatic, where as read/unread is manual. In my mind they mean the same thing. Why have both?

    1. 4

      I think a main distinguishing feature for GUIs vs CLIs is who uses which. If the same crowd that uses Emacs or Vim would use (and contribute to) more GUI software, it would quickly grow to support pervasive scripting and history.

      1. 7

        Many parts of at least GUI emacs is very GUI-like - it has buttons, advanced interfaces like magit, and so on. Obviously it’s not all “GUI-like”, but I do think that Emacs is a good example of what happens if the people that use CLI creates GUI software. The only limiting feature is that Emacs was made a long time ago, and its scars reveals that.

        1. 5

          Emacs is GUI software! It can be profitably used using just the menus and toolbar. I turn them off, but I imagine many people never do.

          1. 1

            I’m not sure about that, it would require the right design to begin with for a certain mentality to want to contribute without losing the legacy they already are proficient in. I’m not sure how a GUI awk would look like in our GTK/Qt/Electron world, if anything because you’ve always got those who have to go out of their way to create a “innovative” look and feel. HTML is probably the closes we’ve gotten to anything like this in real world applications, when considering user scripts, though I don’t think it was worth it.

            1. 2

              I think Applescript (on Mac) or ARexx (on AmigaOS) are better real-world applications. HTML with user scripts is basically screen scraping.

          1. 9

            GUI are superior sometimes. One aspect - better feature discovery and less learning how changing one thing affects the others.

            1. 9

              UI discoverability is orthogonal to {G,C}UI IME. I’ve seen great documentation come out of --help and man pages, and I’ve seen baroque and opaque GUIs.

              1. 16

                UI discoverability is orthogonal to {G,C}UI IME.

                I don’t think this is true. The default for GUI is a bunch of buttons you can click to see what happens. The default for CLI is a blank screen. Using a manual (–help) as a counter example isn’t arguing for CLI, but arguing for good manuals.

                When you are in a french bakery, pointing at a croissant is using a GUI, and trying to say things randomly hoping to make sense is using a CLI. Clearly one is superior to another, both in immediate usability, and discoverability.

                1. 4

                  The default for GUI is a bunch of buttons you can click to see what happens.

                  Not necessarily for three reasons:

                  1. Menus. GUIs tend to have menus, and menus are not discoverable unless you and the developers spontaneously develop the same ontology and, therefore, classification scheme for the program’s functionality. Conventions help, but conventions apply to CLI programs, too.
                  2. Buttons need to be labeled somehow, and iconic labels tend to verge on the pictographic. Even textual labels can be hard to decipher, but the trend is towards images, which are smaller and (supposedly) don’t need to be translated for different audiences.
                  3. The increase of mobile UIs as being the new default for GUIs means fewer buttons and more gestures, and gestures aren’t signposted. Can I pinch something here? Do I need to swipe? Is this operable now? Do I need to long-touch it or caress it in some other fashion? It might be good for you, but it’s remarkably inscrutable as opposed to discoverable.
                  1. 12

                    and menus are not discoverable

                    I disagree here. Going through the menus to see what options you have is a pretty common thing to do.

                    The increase of mobile UIs as being the new default for GUIs

                    But the mobiles GUIs are not discoverable the same way CLIs are not discoverable. There are no buttons and you are supposed to know what to do (the right incantation or the right gesture). But even then swipe and pinch are more intuitive than shlib -m -t 500

                    1. 2

                      I disagree here. Going through the menus to see what options you have is a pretty common thing to do.

                      Every user I have had an interaction with never looks through the menus; I can for certain tell you nine out of every ten people I work with are unaware the menu bar exists for the majority of executables they use and if they are aware of its existence its only to click something they have been shown how to use; they will rarely venture far from that well trodden path and its frustrating as a little bit of curiosity would have solved their question before they asked it.

                    2. 2

                      #3 is the big one for me. I have no idea how to use most mobile apps. Whereas with a well-designed CLI I can mash TAB and get completion at its repl or through its shell completion support, and work out what the thing can do.

                      1. 4

                        Leave out “well-designed” and you’re back in pinch-bash-swipe land on your CLI as well.

                    3. 2

                      A GUI is immediately useable in that you can see buttons and other widgets, and with the mouse you can point and click. However for GUI’s, as they are mostly implemented in todays world, the advantage stops there. There is no next step in that you can improve your mastery, possibly except for your mastery of mouse precision and keyboard shortcuts. However in CLIs, as they are today, there is a steep curve to getting started, however because of certain properties of the CLI, as the article mentions, when you have interned those key principles, the sky is the limit.

                      GUIs are excellent for basic usage, but doesn’t allow any kind of mastery. CLIs are tough to get started with, but allows all kinds of mastery. That’s a key distinction. However I don’t think those properties are inherent to “GUIs” and “CLIs”, it’s just inherent in the way they have been implemented in our current software landscape.

                1. 5

                  One thing I’d be curious to know from others is how do not get overwhelmed by your own systems. I have a lot of difficulty organising things and frequently forget where I put things.

                  Lately this has led to a workflow where I have two text files. One where I put what I ought to be working on today, and a second one I euphemistically call “the scroll” which is just a long file I append notes to as they come. But I like the idea of something where I schedule my day and keep track of next tasks. But I worry about committing to a system where tasks get buried across files under some subheading that org-mode might be hiding from me at that moment.

                  1. 3

                    This is exactly what I do, but just with orgmode. todo.org and journal.org (and archive.org for things coming out of todo.org). I sometimes try to schedule things with org-agenda, but inevitably something will take more time than I expect and I get off schedule. So, I really only use org-agenda for true deadlines. It’s really quite simple. As you said, if the organization system itself gets too complicated, then it breaks down.

                    1. 1

                      Thanks! I think I’ll try to turn the scroll into a proper org file and slowly migrate into something that uses org-agena

                      1. 2

                        Something that’s really important is good org-capture templates.

                        Here’s the line in my config where I define my org-capture-templates: https://github.com/wraithm/emacs.d/blob/dc49776342df4b75c732d8e27647c751d1043a48/lisp/init-org.el#L46

                        I’ve actually since moved on to doom emacs with slightly different capture templates, but that’s a good example of org capture templates that work well for the system you described.

                        1. 1

                          How well do org-capture templates handle large notes? Like I cut-paste large chunks of text into my scroll. Whether it be snippets of websites, emails, or conversations.

                          1. 2

                            Yeah, it can handle arbitrarily long text afaict. The capture template just opens a buffer with the node that’s gonna get inserted into your org file’s tree. It sounds like this is exactly what you’re looking for. The capture template is just for giving you automation around how the snippet that you want inserted into your scroll gets formatted and categorized.

                            1. 1

                              it does handle large text pretty well. org-capture is for quick short term storage. I move these eventually to other org files based on context. (using org-refile)

                      2. 3

                        Use org-mode with org-agenda. Here is one of many guides showing a workflow using org-agenda, but the point is that if you spread your stuff across many org-mode files, org-agenda will be your “dashboard” into those many files so you don’t have to go hunt through files and subheadings to find todos and so on. Instead it presents the data, scattered across many files, in a single, coherent view.

                        1. 1

                          So one issue I had is that there is my file where I keep all my tasks, and then the file which where the work for the task that needs to get done. How should that be stitched up in org-mode? Do I put the TODO and Schedules in my org file that has the tasks and link from that line to the file where I do the work?

                          1. 2

                            What do you mean by “and then the file which where the work for the task that needs to get done”? Is that file another org-mode file which describes the work in detail, or is it like a file in a software project or something like that? If it’s the former, I suggest putting the todo in there. If it’s the latter, I usually put a “org-mode link” to the file (and location in file) in the todo.

                            I have a “todo.org” file where I have todo’s that doesn’t fit in other places, but I also have todos in a lot of other places, and then I keep tap on them all with org-agenda.

                            1. 1

                              I meant the latter. Like I have a todo around expanding out a section of a paper.

                              1. 1

                                I’m still not sure I follow. Can you show me an example of what the two files can look like?

                                1. 1

                                  Sure suppose there is a file work.tex:

                                  \section{Background}
                                  Lorem Ipsum
                                  

                                  And I have a file tasks.org

                                  * Do grocery shopping
                                  * Flesh out Background section of paper
                                  * Water plants
                                  

                                  You would have me modify tasks.org to have:

                                  * TODO Do grocery shopping
                                  * TODO Flesh out Background section of [[/dir/to/paper/work.tex][paper]]
                                  SCHEDULED: <2020-05-27 Wed>
                                  * TODO Water plants
                                  

                                  Does that sound right?

                                  1. 2

                                    I think in that case, where the link is that “broad”, I’d replace the TODO-item with:

                                    * TODO [[/dir-to-paper-work.tex][Flesh out background-section]]
                                    

                                    the goal being to quickly go to where the actual work of the TODO-item should actually be done. Had there been more steps, I’d maybe have a TODO with subtodos that link to different parts. And in the event that the TODO-item expanded so as to justify it’s own org-mode file, I’d mode it all there. If you just make sure to tell org-agenda about where to look for your org-mode files, it will collect all the items from all the files, so you can have as many or as little as you need.

                                    1. 1

                                      Thanks! That clarifies a bunch.

                      1. 1

                        Are you sure you want to be handling passwords yourself? Shouldn’t you be using a third-party authentication provider? That way, you run no risk of getting compromised and leaking (reused) passwords.

                        1. 11

                          Handling passwords is really not that complicated. There are libraries around to do it, and quite frankly, it’s not magic. Just use bcrypt or something similar.

                          1. 2

                            I would note that it’s not so much just the handling of passwords, but getting all of the workflows for authentication and session management right too. That’s why I like libraries like Devise for Rails that add the full set of workflows and DB columns already using all best-practices to your application, with appropriate hooks for customization as needed.

                            1. 2

                              It’s not only the password in the database, but also the password in transit. For example, Twitter managed to log passwords:

                              Due to a bug, passwords were written to an internal log before completing the hashing process.

                              The risk remains, it’s just more subtle and in places you might not immediately think of instead.

                              1. 3

                                If anything that’s an argument against “just let someone else do it”.

                                You can review your own systems, you can organise an audit for them.

                                How do you plan to review Twitter’s processes to ensure they do it securely, given that they already have precedence for screwing the pooch in this domain?

                                1. 1

                                  It’s easier in smaller systems.

                                  1. 1

                                    Well, there’s a risk with anything you do when dealing with secrets; you can leak tokens or whatnot when using external services too.

                                    As I mentioned in another comment, the self-host use case makes “just use an external service” a lot harder. It’s not impossible, but I went out of my way to make self-hosting as easy as possible; this is why it can use both SQLite and PostgreSQL for example, so you don’t need to set up a PostgreSQL server.

                                2. 2

                                  you run no risk of getting compromised and leaking (reused) passwords

                                  You still have to handle authentication correctly, and sometimes having an external system to reason about can expose other bugs in your system.

                                  I recall wiring up Google SSO on an app a few years ago and thinking configuring google to only allow people through who were on our domain was sufficient to stop anyone being able to sign in with a google account. Turns out in certain situations you could authenticate to that part of the app using a google account that wasn’t in our domain (we also had Google SSO for anyone in the same application, albeit at a different path.) Ended up having to check the domain of the user before we accepted their authentication from google, even though google was telling us they’d authenticated successfully as part of our domain.

                                  1. 1

                                    If password hashing is a hard task for your project, I’d argue that’s because your language of choice is severely lacking. In most languages or libraries (where it isn’t part of the stdlib) it should be one function call to hash a new password, or a different single function call to compare an existing hash to a provided password.

                                    This idea that password hashing is hard and thus “we should use X service for auth” has never made any sense to me, and I don’t quite understand why it persists.

                                    I have never written a line of Go in my life, but it took me longer to find out that the author’s project is written in Go, than it did for me to find a standard Go module providing bcrypt password hashing and comparison.

                                    1. 1

                                      And salting! So many of these libraries store the salt as part of the hash, making comparison easy but breaking hard.

                                      1. 1

                                        I would consider it a bug for a library/function to (a) require the developer to provide the salt, or (b) not include the salt in the resulting string.

                                    2. 1

                                      Problem is what provider do you choose to use? Do you just go and “support everyone”, or do you choose one that you hope all your users use, and that you are in support of (I don’t support nor have accounts at Facebook, Twitter, and Google), which narrows it down quite a bit. And what about those potential users that aren’t using your chosen platform(s)? Are you gonna provide password-based login as an alternative?

                                    1. 5

                                      Reading and re-reading more books from The Domino Project and applying the lessons therein:

                                      • Anything You Want (Derek Sivers) was an excellent re-read. I’m going to reach out to him for the first time this week.
                                      • Do the Work (Steven Pressfield) comes up next.
                                      • After that, The Flinch (Julien Smith).

                                      It’s a year of revisiting proven works instead of constantly seeking out new ones.

                                      1. 2

                                        I also want to prototype my first ActivityPub app: a PWA (progressive web app) focused exclusively on posting authoring. Something to help me focus on creative work without getting distracted by new posts in my feed.

                                        1. 1

                                          How do you get started with The Domino Project? It seems like a cool project, but it seems like all the information is spread out in different “blog posts”?

                                          1. 1

                                            I wish I could recall but it was years ago. If I had to guess, some combination of blog posts and podcasts bringing the individual books to my attention.

                                            1. 1

                                              Alright, thanks ✌️

                                        1. 5

                                          I have been using the YouTube RSS feed for the past year. I like this a lot because of the problem mentioned in the article. I just hope Google doesn’t break the feed in the future.

                                          Now if Twitter we just put up a feed as well…

                                          1. 11

                                            You can use https://invidio.us which has a more accessible RSS feed than YouTube itself. It’s just a different frontend to YouTube with less adds, and more “liberating” options.

                                            1. 2

                                              I use this if I absolutely “must” use youtube. The performance is generally pretty bad for me, I think they might proxy all videos through their server? I’ve been tempted to self-host it if that helps the performance, but I honestly don’t use it enough yet to justify the extra effort to set up/maintain it..

                                          1. 4

                                            That “Preserve working directory in new terminal instances” script is neat!

                                            Also I can recommend waybar as a statusbar application. It’s easy to configure and has lots of neat features.

                                            1. 2

                                              I’m trying to figure out what I would gain adding uMatrix to my setup. I Use Multi-Account Containers as well as Temporary Containers, Facebook/Google/Twitter/Reddit Containers, so I get all the cookies I want placed where I want, and for all other cookies, they get deleted right after I close the tab (thanks to Temporary Containers), and it does it by itself, contrary to uMatrix, so I think I wouldn’t gain much by using uMatrix except a bit fewer cookies for the sites I trust.

                                              Does anybody see a fault in my thinking?

                                              1. 5

                                                It’s not just cookies but also blocking assets from remote hosts. For example, you can block css, iframes, images and scripts from ever being loaded from those hosts. That means tracking pixels, referer leaking and browser fingerprinting (which may defeat your container setup) will all be a whole lot less effective against you. Also many sites are much faster if you don’t load craptons of JavaScript.

                                                1. 1

                                                  Good points. I might give it a shot.

                                              1. 8

                                                I’m reading lobste.rs through RSS. I’m doing the same for the orange site. Same for all news sites I’m using. Same for selected github repos. Same for netcasts. All of this (and more) through the Nextcloud News app running on the server-under-the-stairs.

                                                RSS is far from dead.

                                                1. 1

                                                  I’ve thought about consuming lobste.rs and HN via RSS, only to be scared of the enormous amount of content. Normally I just visit the frontpage of the sites.

                                                  Where are the feeds located for lobste.rs? I see it mentioned here that there are both public and private feeds, but I only seem to be able to find the public ones for example lobste.rs/rss. Or is it already customized to my filters when I’m logged in?

                                                  1. 1

                                                    I’m using the comments feed: https://lobste.rs/comments.rss

                                                    The orange site: https://news.ycombinator.com/rss

                                                    The lobste.rs feed is fairly high-volume, not tailored to any login or account or filter. That is the way I like it, I’d rather be my own ‘filter’. The feed reader (Nextcloud News in my case) can take care of sorting high-volume feeds into their respective origins so they don’t drown out lower-volume feeds from other sites.

                                                    One of the advantages of using RSS for sites like HN is that it gets around the sometimes rather rabid front page censorship. While those who access those sites through the front page/door have to be extremely lucky (or waste inordinate amounts of time in checking the page every x minutes) to catch posts which are being sunk by the moderators, those who use RSS will see the post in their feed at the moment it was published, front page ranking be damned. The same goes for news sites which often publish first (because timeliness is important in the news business) but edit titles afterwards. It is often revealing to see their editorial bias shine through in the way they try to editorialise titles to fit their own narrative.

                                                    1. 1

                                                      You make some really good points. I’m gonna try using HN and lobste.rs via RSS for a couple of days and see how it goes.

                                                    2. 1

                                                      Where are the feeds located for lobste.rs?

                                                      You can follow each tag via RSS separately. Just append .rss to the tag’s URL. E.g. https://lobste.rs/t/historical.rss will give you the RSS feed for articles tagged historical.

                                                      1. 2

                                                        Thanks!

                                                  1. 24

                                                    Not sure I agree that an App Store is a requirement for a platform. Game consoles existed for a long time before App Stores became a thing, and I certainly would consider them “platforms”.

                                                    1. 6

                                                      I don’t ever use the App Store on Mac or Windows and I seem to have a perfectly functional environment. They didn’t even have stores until just a few years ago. So I agree, I don’t see how this is a requirement.

                                                      I think the actual requirement is the ability to package up an application into a downloadable installer that’s guaranteed to work.

                                                      1. 8

                                                        I can’t think of a major game console released this decade that doesn’t have an App Store, so I’m not sure this argument holds as much water as it might have.

                                                        IMO an App Store is just a package manager that takes payments.

                                                        I definitely want a package manager, and I don’t mind paying for software, so I tend to appreciate having one.

                                                        1. 10

                                                          released this decade

                                                          Why does that even matter? The PlayStation 2 is still a platform. The Wii didn’t need Internet access. People have already pointed out F-droid. Linux distributions allow you to add 3rd party repositories or overlays. Play/AppStore do not.

                                                          Modern platforms should be able to run and operate if their underlying service go away. They currently cannot, and that’s a big problem.

                                                          1. 2

                                                            “Released this decade” is relevant because it speaks to current consumer expectations.

                                                            RE “underlying service going away”: Once I buy/install a game on the switch, AFAIK it will never need connectivity again.

                                                            1. 1

                                                              Current consumer expectations don’t always involve an app store. People in a corporate environment that use Windows don’t expect an app store, especially if their environment is still windows 7. Yours is a narrow-minded view of the idea behind calling something a platform. User expectations don’t go so far as to assume some kind of central store for apps.

                                                          2. 1

                                                            While not GNU/Linux, LineageOS + F-droid is a functional platform that doesn’t have an ‘app store’ that takes payments. It (F-droid) does encourage donations to projects it distributes, but I still think defining a platform on the requirement that it includes an ‘app store’ that takes payments is not correct.

                                                            The article doesn’t actually define what exactly they mean by ‘app store’ though (package manager vs package manager that can charge you).

                                                            1. 3

                                                              LineageOS + F-droid

                                                              Off topic, but can you recommend something from F-droid? I recently switched from using iOS for years to buying a refurbished android phone and throwing LineageOS + mindthegapps + f-droid on it. I have installed most of the apps I use from the play store, a few from direct download from websites, and only a single one from f-droid: Material Files which works very well. I haven’t yet found any of the things I need (spotify, mullvad, firefox …) in the f-droid app, and yeah, any recommendations for free libre apps on f-droid that can replace things I might be using from play store? I know about the firefox fork that’s more open, but other than that?

                                                              1. 4

                                                                Really depends what you want.

                                                                • Amaze is a nice file manager
                                                                • BeHe keyboard is a slightly more tech-y keyboard app, which doesn’t send everything you type to an AI somewhere
                                                                • K-9 Mail for non-gmail email client
                                                                • Syncthing is a decent non-dropbox file sync
                                                                • VLC for video playing

                                                                What I haven’t found yet is a good, general-purpose music player that lets me work with actual files instead of assuming everything’s in albums the way iTunes does. If anyone has suggestions…

                                                                1. 2

                                                                  I really like Vanilla Music, but I do have everything tagged correctly and am fine with the Album/Artist view. It does have a file tab, but it’s probably not as full-blown as you’re looking for :(

                                                                  1. 1

                                                                    Thank you, I’ll check your suggestions out!

                                                                  2. 4

                                                                    We had a whole thread about it.

                                                                    1. 1

                                                                      Thank you!

                                                                    2. 2

                                                                      spotify

                                                                      I haven’t tried this, but this app claims to be capable of fetching and updating Spotify.. I’m not aware of any pure FOSS client that can interact reliably with this proprietary service.

                                                                      mullvad

                                                                      I’ve never heard of this so I had to search. If you are referring to the VPN service, they seem to use Wireguard, so unless they are doing something super crazy it seems like you should be able to use the Wireguard client on F-droid..

                                                                      firefox

                                                                      fennec, which is literally just Firefox without any proprietary bits or Mozilla branding.

                                                                2. 3

                                                                  I would call the Windows app store pretty much a failure, too.

                                                                  1. 1

                                                                    I have not personally used it, but from what friends and colleagues have told me, it does sound like a tire fire.

                                                                  2. 2

                                                                    The NES might not have had an Internet connection to browse and download new games, but it definitely had a specific place to go to find new content (toy stores), which was heavily curated and managed by the platform owner, and which charged developers to participate. And every game console ever since has followed the same basic business model.

                                                                    1. 2

                                                                      Back then you had actual, physical app stores, e.g. Gamestop.

                                                                      1. 1

                                                                        Presumably they just mean “an easy way for users to discover and install new programs, and for developers to publish them”.

                                                                        A package manager is a building block for such a thing, but it currently isn’t very easy for desktop users to add new repositories, which makes it harder to install new software. And having to manually add these is extra effort. Of course, that’s a tradeoff: I wouldn’t want random developers to be able to ship their crap to me (which is what the app stores basically boil down to, as much as Apple and Google try to pretend these things are curated, they’re not; they just try to keep the worst offenders out).

                                                                        On the other hand, quality of officially packaged software in Debian or Ubuntu really varies a lot, as well. But at least it’s all free software.

                                                                      1. 8

                                                                        Wow, that is a very unusual introduction to Haskell — going straight into imperative programs (everything’s a do!) and concurrency. And then it just…stops!

                                                                        1. 6

                                                                          It’s a phrasebook. It gives a way to do something in a language you don’t really know.

                                                                          It isn’t idiomatic, it’s just getting you to have something to show for it as quickly as possible.

                                                                          1. 6

                                                                            It’s a work in progress:

                                                                            We have launched the Phrasebook with 14 demonstrations of topics ranging from if-then-else expressions to transactional concurrency, and there is a lot more to come.

                                                                            1. 2

                                                                              In… a good way? Bad way?

                                                                              1. 5

                                                                                I don’t know! Well, it’s not good that it just stops. But I wonder what a Haskell book would be like that started with the imperative and concurrent stuff like “normal” languages have, and ended with the higher-order functions and so on, instead of the other way around, as a Haskell book normally does.

                                                                                Like, you would start off thinking it was like Go or something, just with weird syntax. You’d get sucked in that way, but then things would start getting more abstract and powerful, and by the end you’d be using pure functions and GADTs and free monads before you knew what hit you.

                                                                                1. 3

                                                                                  Like, you would start off thinking it was like Go or something, just with weird syntax. You’d get sucked in that way, but then things would start getting more abstract and powerful, and by the end you’d be using pure functions and GADTs and free monads before you knew what hit you.

                                                                                  I suspect you might give up, thinking, “what’s the point of this weirdness” before you got to any real motivation or reason to keep learning.

                                                                                2. 4

                                                                                  I like it. And I am waiting for it to provide more examples. I went through several books, still reading and still trying to learn. But did already write programs that I am using for my work and that are helpful for me. Still mostly reaching out for shell scripting, because the shell scripts naturally grow by combining commands and I wish I would use some Haskell Shell in which I would do my daily stuff and that would easily allow me at some point to put together the Haskell programs.

                                                                                  I like how they are showing ghcid early (how long did it take me to find settle on ghcid, how many editor/IDE tools did I try), and I like that ghci is introduced. It’s pragmatic.

                                                                                  I hope it will go on with many examples.

                                                                                  1. 0

                                                                                    In… a good way? Bad way?

                                                                                    Definitely a bad way.

                                                                                    All the weirdness and higher order stuff is there to give you all kinds of guarantees which can be extremely useful.

                                                                                    In fact: If you are not using the higher-order stuff, you might just as well use another language which requires you to jump though less hoops, because you are missing the whole point of what Haskell is about.

                                                                                    You should start with the higher-order stuff and then bolt this phrasebook on as an afterthought, not the other way around. If you start with this phrasebook, you will essentially be writing a bad code base.

                                                                                    Please keep in mind that I have actually reviewed assignments from a “Functional Programming” course, which used Haskell as it’s primary subject of study.

                                                                                    1. 9

                                                                                      You are gate-keeping, and this behaviour is definitely worse for the community.

                                                                                      I’m one of those developers who had no computer science education, and started programming essentially by banging rocks together, trying to pay the bills with WordPress and jQuery.

                                                                                      I learned Haskell the trial-and-error way, and the imperative way. My first foray into Haskell was from the book Seven Languages in Seven Weeks, which necessarily doesn’t go very deep into the languages it exhibits. I got some of the basics there, but otherwise trial-and-error, Google, IRC, etc. My first web apps in Haskell were pretty terrible, but I needed to just get something working for me to be more invested in the technology. Everyone sucks at something before they’re good at it anyway. There’s still an enormous amount of Haskell for me to learn. I see that as compelling, not a hurdle.

                                                                                      This has not “destroyed my reputation”, as you asserted. If anything it’s only improved it, especially among people who are interested in Haskell but are discouraged by people like you.

                                                                                      Now I run three businesses on Haskell, and employ other Haskellers who have worked at Haskell companies you have heard of.

                                                                                      1. 6

                                                                                        you will essentially be writing a bad code base.

                                                                                        But you WILL be writing a code base.

                                                                                        1. 1

                                                                                          But you WILL be writing a code base.

                                                                                          You will be writing a codebase that will force the next competent Haskell developer, to throw out all your work and start over. Also: It will destroy your reputation.

                                                                                          Honestly, it’s better to not write anything at all if this is your starting point. Just use something else like python, C/C++, Java or C#. This is simply not how Haskell should be written and I will probably also perform worse than the alternatives.

                                                                                          Why? Because if you use Haskell the right way, the compiler can throw in all kinds of optimizations, like lazy evaluation and memoization for free. If you are writing Haskell in the way that is proposed in the Phrasebook, you essentially loose all those perks without gaining anything. In fact your code will be much, much, (about a factor 10 actually) slower than it would be if you’d just started out by using a different language.

                                                                                          For an elaborate example, you can look at The evolution of a Haskell programmer. Note that the Juniors and the first Senior developer’s solutions are in fact perfectly valid and viable.

                                                                                          However, the second senior (which uses foldl) makes a critical mistake which costs him the “lazy evaluation perk”, which means that his best-case and worst-case performance are both O(n), whereas the senior that uses foldr will have O(1) as best case and O(n) as worst case performance.

                                                                                          And it goes downhill from there. However the Haskell code I see in the Phrasebook is similar to what the “Beginning graduate Haskell programmer” would do.

                                                                                          The “right” way to do it, is the “Tenured professor”-way all at the bottom. It doesn’t matter that product uses foldl’ internally in this case, which also sacrifices lazy evaluation. It’s about a way of doing things and in general, where you rely upon the implementation of libraries getting better. This phrasebook also throws a lot of those perks out by manually taking control over nearly the entire control flow (which is something you should do as little as possible when you are writing Haskell).

                                                                                          That is the kind of “bad codebase you would be writing” we are talking about here. If you find yourself in the situation where you need this phrasebook to get started, you are simply out of your league. The situation is really not unlike the software engineering team that programmed the flight computers of the 737 MAX 8. You should step away and say: “No, I am not up to this task right now. I need at least 120 hours (but 240 hours is a more reasonable estimate) of study before I can do this”.

                                                                                          But if you did invest the hours upfront and are using this Phrasebook as an afterthought… sure; Sure! Go ahead! You should now know where the pitfalls in these examples are.

                                                                                          1. 7

                                                                                            One of the authors of this Phrasebook is also an author of Haskell Programming from First Principles, which starts from the lambda calculus. I think she’s deliberately exploring as different an approach as possible. There’s isn’t a single Right way to teach, the readers’ varied backgrounds and motivations lead them to really different results.

                                                                                            1. 1

                                                                                              One of the authors of this Phrasebook is also an author of Haskell Programming from First Principles, which starts from the lambda calculus. I think she’s deliberately exploring as different an approach as possible. There’s isn’t a single Right way to teach, the readers’ varied backgrounds and motivations lead them to really different results.

                                                                                              The approach the author is taking now, is an approach which defeats the main purpose of Haskell: It’s type-system and a relatively smart compiler that exploits this through lazy evaluation. Because of this, I simply do not agree with this statement.

                                                                                              A pilot needs to learn at least some basic meteorology and aerodynamics, the same applies here, because if you don’t take the time to properly understand the type system and lazy evaluation, you are basically an unlicensed pilot that knows how to get an airplane off the ground, keep in in the air and land it again, but without any contact with air traffic control.

                                                                                              I would not want to fly with such a pilot, neither do I want to use an aircraft he/she has flown in. In reality we have systems in place to stop this from happening and the pilot will be told to stay on the ground and “pilot” something (like a car for example) he/she knows how to pilot. In the software world, we do not have a system, other than our own sound judgement, in place to prevent this from happening.

                                                                                              So please: Learn Haskell’s fundamentals first and then add this phrasebook to the mix afterwards or choose an entirely different technology. Everyone who is currently next to you or whom comes after you, will thank you for it.

                                                                                              1. 3

                                                                                                Hopefully Haskell can be many things to many people. I think it makes for a pretty good imperative language.

                                                                                            2. 6

                                                                                              I’m currently training a team of engineers to write Scala. We’re experiencing the “no code” problem right now. I prefer people write bad (but functional) code than no code.

                                                                                              1. 1

                                                                                                I’m currently training a team of engineers to write Scala. We’re experiencing the “no code” problem right now. I prefer people write bad (but functional) code than no code.

                                                                                                I would agree with you if this was about any other programming language, but Haskell really is a different beast in this regard.

                                                                                                I pose you this question: Would you rather spend some time training your engineers or would you rather have them dive in without them knowing what they are doing?

                                                                                                Since you are training a team, you’ve probably chosen the first approach, which is exactly what I am proposing you should do with Haskell as well. You do not hand a pilot the keys to an airplane without making sure they’ve had some proper training. The same applies here (see below). Most other programming languages are like cars or trucks, but Haskell really is more of an aircraft.

                                                                                                1. 8

                                                                                                  I think this type of elitist gate keeping dissuades people trying to learn Haskell and reflects poorly on the community. Furthermore the creators of the Haskell Phrasebook clearly know a lot about Haskell and have built a business around teaching it to people. Do you think it’s possible for them to have a compelling reason to create a resource like this?

                                                                                                  @argumatronic: I’ve seen people do similar with Haskell, starting with very imperative-style Haskell, but in the meantime: I can understand you, thank you for making effort to learn a new language, welcome.

                                                                                                  1. 0

                                                                                                    I think this type of elitist gate keeping dissuades people trying to learn Haskell and reflects poorly on the community.

                                                                                                    Actually I digress. There is nothing elitist about it. It’s about using a hammer to turn a screw in.

                                                                                                    Furthermore the creators of the Haskell Phrasebook clearly know a lot about Haskell and have built a business around teaching it to people.

                                                                                                    The fact that someone builds a business around something, doesn’t mean they are doing things the right way. Teaching people things the wrong way, has a tendency to stick around. Oh and btw, I also earned money teaching Haskell (and cryptography and security) to people during my studies at an accredited university with the oversight of a professor leading in the development of the language…. So I am no lightweight either…. And what I see here makes me cringe and would have awarded any student a non-passing grade with approval.

                                                                                                    Do you think it’s possible for them to have a compelling reason to create a resource like this?

                                                                                                    Yes I do. In fact, they state the same reason as I suspected on the Twitter feed you mention:

                                                                                                    IME, people start to write more Haskelly Haskell as they get comfortable with it, but we have the tools to write imperative-style Haskell as a bridge, no shame in using them.

                                                                                                    And:

                                                                                                    Eventually, by doing that a lot, I became quite fluent in Japanese. And I’ve seen people do similar with Haskell, starting with very imperative-style Haskell, but in the meantime: I can understand you, thank you for making effort to learn a new language, welcome.

                                                                                                    And like I said, there is nothing wrong with using the phrasebook, but you have to use it after you at least have a firm grasp op the basic concepts. Doing it the other way around will give the community and the language itself a bad name. If nothing else, the Haskell ecosystem will turn into a hack fest similar to python or nodejs with the decrease in quality and performance of everything that comes with it.

                                                                                                    That’s what I am worried about and it’s also why I disagree: You want people that write Haskell, to write it in a completely different way than you’d write an imperative language.

                                                                                    1. 2

                                                                                      I’m six chapters into The Targeter. It’s a great first-person account of the Iraq War from the perspective of a female CIA analyst who eventually took on the task of getting Zawquari. I’d recommend it for anyone interested in geopolitics, the Middle East, or war/intel stories.

                                                                                      1. 2

                                                                                        Got any more of these kinds of books? I love reading books but have an affinity for espionage/thriller/crime/true-crime/war shows, and this book looks like just what I’m looking for, and would like to shift more of that time to reading books filling that need.

                                                                                        1. 2

                                                                                          Let me see if I pull a list together from my Amazon orders and bookshelf.

                                                                                          1. 2

                                                                                            Sounds great!

                                                                                            1. 1

                                                                                              Recovering from surgery so have a lot of my list, but I might update this more later.

                                                                                              War on Terror reading

                                                                                              The Looming Tower (Lawrence Wright)

                                                                                              Great introduction to islamic fundamentalism and events leading up to 9/11. I think there is a series on TV outlining the events covered in the book.

                                                                                              Manhunt: The Ten-Year Search for Bin Laden from 9/11 to Abbottabad (Peter Bergen) Holy War, Inc.: Inside the Secret World of Osama bin Laden (Peter Bergen) The Longest War: The Enduring Conflict between America and Al-Qaeda (Peter Bergen)

                                                                                              Peter is someone I’ve seen on TV since the mid-nineties and his analyses always caught my attention. Having met Bin Laden and tracked the Al-Qaeda he has some deep insights into the people and places involved.

                                                                                              First In: An Insider’s Account of How the CIA Spearheaded the War on Terror in Afghanistan (Gary Schroen) Jawbreaker: The Attack on Bin Laden and Al Qaeda: A Personal Account by the CIA’s Key Field Commander (Gary Berntsen)

                                                                                              Early, first-hand accounts of on the war on terror. I want to read these again sometime now that I have more context and can decode some of the writing.

                                                                                              The Black Banners: The Inside Story of 9/11 and the War Against al-Qaeda (Ali Soufan)

                                                                                              FBI interrogator’s perspective on the war on terror.

                                                                                              The Triple Agent: The al-Qaeda Mole who Infiltrated the CIA (Joby Warrick)

                                                                                              IIRC this is in the movie Zero Dark Thirty, but it doesn’t go into the background.

                                                                                              Black Flags: The Rise of ISIS (Joby Warrick)

                                                                                              More recent happenings after the failures in Iraq.

                                                                                              General Middle East reading

                                                                                              The Persian Sphinx: Amir Abbas Hoveyda and the Riddle of the Iranian Revolution (Abbas Milani) The Shah (Abbas Milani) Our Man in Tehran (Robert Wright)

                                                                                              Understanding Persian influence on the middle east is important. Many people only know the history from the revolution onwards, if they know anything at all.

                                                                                              Motoring with Mohammed: Journeys to Yemen and the Red Sea

                                                                                              Fabulous travel story through Yemen. It makes me so sad to see and hear what is happening there now. I’ve forgotten which books I read about British involvement in Aden (which appears in many SAS histories), but this book gives a greater insight into the country and culture.

                                                                                              Escape from Dubai (Herve Jaubert)

                                                                                              Interesting read on culture and business in one of the smaller nations in the Middle East.

                                                                                              General Intel reading

                                                                                              Body of Secrets: Anatomy of the Ultra-Secret National Security Agency (James Bamford) The Shadow Factory: The Ultra-Secret NSA from 9/11 to the Eavesdropping on America (James Bamford) Blind Man’s Bluff: The Untold Story of American Submarine Espionage (Sherry Sontag) Lockheed Blackbird: Beyond the Secret Missions (Paul Crickmore)

                                                                                              International law reading

                                                                                              The Internationalists: How a Radical Plan to Outlaw War Remade the World (Oona A. Hathaway)

                                                                                              I read this from the perspective of a historian, but others may read it as it relates to the legal matters. There is a lot of good stuff in here that I had never read in-depth about. It’s a pretty tough read compared to many of the other books on this list.

                                                                                              1. 2

                                                                                                That’s really kind of you to compile that list! Thanks a ton, the titles sounds really interesting, I will add them to my reading list pronto! Thanks a lot, and godspeed!

                                                                                      1. 2

                                                                                        I’m reading The Mastermind: Drugs. Empire. Murder. Betrayal. by Evan Ratliff. It’s an easy, entertaining read if you like good journalistic biographical true crime stories. It’s about the computer wiz who created what was a break through for personal encryption software, and later became a murdering drug kingpin, while also being thought of by many (not me) to perhaps be Satoshi Nakamoto, the creator of bitcoin.

                                                                                        1. 1

                                                                                          I remember reading a long article about him that covered most of the same ground. It was an unbelievably strange story!

                                                                                          1. 1

                                                                                            I believe the book is actually originally extracted from a series of articles by the same author. Might be it.

                                                                                        1. 3

                                                                                          Saturday morning yoga. Hopefully get my deck stained. Brush up on my “tech skills” for a technical interview next week. Watch Stranger Things S3 with son. Work on a side project. Sleep.

                                                                                          1. 2

                                                                                            Please share if Stranger Things S3 is worth watching. Wife and I are watching Chernobyl now, which is great so far (2/5).

                                                                                            1. 2

                                                                                              I finished ST3 yesterday and it was great!

                                                                                              1. 1

                                                                                                That’s on my list. Need to watch it before my HBO sub expires on the 25th.

                                                                                            1. 5

                                                                                              Today I set up a peertube instance at https://watch.44con.com/ for Security conferences and researchers.

                                                                                              We won’t have open registration, but for any existing security conferences worried about their talks being taken down, they can use our site as a backup. They just need to get in touch with us (details on the about page).

                                                                                              We’re also open to security researchers of note.

                                                                                              1. 3

                                                                                                I take it you have experience with peertube. So just a quick question. Feel free to disregard it.

                                                                                                Where do I find interesting things to watch on peertube? If I go to peertube.social, I don’t find anything of interest to me. I try the names of channels I know from youtube, but no luck. Do I have to find specific instances just like watch.44con.com or is there other ways to find content other than “just browsing” page after page? And where do I find other instances?

                                                                                                It’s kinda the same problem as with mastodon. It’s not easy to find things to follow. Not as easy as twitter and YouTube anyways. Sigh.

                                                                                              1. 8

                                                                                                We should all take a look at peertube. It’s matodon for video https://joinpeertube.org/en/

                                                                                                1. 1

                                                                                                  It’s mastodon for videos, alright. Just like with mastodon, the people and foundations and so on that I want to follow is just not there. It sucks to be honest. I’m keeping the hope alive, though.

                                                                                                  1. 2

                                                                                                    You should ask them to move to mastodon. Actually would be nice to have some kind of petition asking people to move to mastodon.

                                                                                                1. 3

                                                                                                  I also really struggle with technical interviews. The timed take-home tests are probably my weakest area right now, it is something about that clock ticking that quite literally makes my hands start shaking. I have been writing code for 20 years, the last 10 years in some kind of lead/staff role. I have recently worked my way through all the exercism puzzles and yet… add a clock and I can’t function. These are new to me since they weren’t around the last time I interviewed - or not as prevalent.

                                                                                                  I don’t think it is about pressure, one area I thrive is when there is a critical outage and the solution requires quick and decisive actions - that doesn’t bother me.

                                                                                                  Anyway, FWIW - I really like your suggestions here but what I have come to terms with is that if that is how they want to hire and if these are the things they care about - I probably am not going to be a good fit for the company. It does not take all of the sting out of the rejections, but it does help in reflection. I keep doing them because I do believe I can get better if I practice. But in the meantime, I just trust that the right opportunity will come along.

                                                                                                  1. 3

                                                                                                    That’s really interesting as many people are the exact opposite. The stress of not having a time limit causes anxiety because you’re constantly wondering how much time and energy the rest of the applicants are spending on this challenge and whether your submission will look bad in comparison.

                                                                                                    I have a horse in this race as I run what I believe to be the first time-limited technical challenge tool that allows you to use your own editor/IDE. - https://takehome.io

                                                                                                    I think what this underscores is the author’s point about building flexibility into your process that can allow for the different preferences of your candidates. There’s no one-size-fits-all interview technique.

                                                                                                    1. 2

                                                                                                      How do you, at takehome, make sure candidates don’t fiddle with the git history so they maybe look like they performed better than they did?

                                                                                                      1. 1

                                                                                                        What do you mean by fiddle?

                                                                                                        If just rebasing, moving commits around, etc. to make the commit history look Good(TM), when you’re worried that your natural workflow looks unprofessional e.g. if it’s anything like mine:

                                                                                                        git add -A && git commit -m "more stuf" && git push
                                                                                                        git add -A && git commit -m "dang" && git push
                                                                                                        git add -A && git commit -m "ttt" && git push
                                                                                                        

                                                                                                        I don’t see that as a problem. The end result is a clean commit history - whether it happened during the writing of the code, or after the fact, is irrelevant - the candidate demonstrated that they could A) write a functional POC and B) release it with (eventually) good commit history.

                                                                                                        Also, the above disorganized git commits I find are almost unavoidable for “first commit” style POCs, when there is no codebase.

                                                                                                        Once the codebase is established, maybe then creating clean commits is expected as a skill, when working with a team on a large codebase - but even so you can do dirty crap in a branch and then fix the commits before creating a PR.

                                                                                                        1. 1

                                                                                                          My understanding of takehome is you use git (partly) to make sure assignments are done inside a desired schedule. But since you can edit git history, people can easily use three hours but edit the history to make it look like they used two.

                                                                                                          But maybe I misunderstood what takehome uses git for?

                                                                                                          1. 1

                                                                                                            Ah, I see - didn’t think of time limit cheating.

                                                                                                        2. 1

                                                                                                          Takehome has a custom git server implementation. When the candidate fetches the repository from their unique URL a timer starts. When that timer expires, the git server stops accepting pushes from the candidate into that repo.

                                                                                                          While the submission window is open they’re welcome to fiddle with the history all they like. All I care about is that they didn’t spend longer than allowed writing their response.

                                                                                                          1. 1

                                                                                                            That makes sense. I thought you where relying on normal git history to track time.

                                                                                                    1. 5

                                                                                                      Maybe I am missing something, but how is it different from having 1 Dockerfile, with multistage build? what is worth introducing a new tool to the build chain :) ?

                                                                                                      1. 5

                                                                                                        Or similarly, what does this give over docker-compose?

                                                                                                        I actually stopped containerising my dev environment because having to rebuild and restart a container every time I modified the source code was time-consuming and a pain, and left useless Docker images on disk which would have to be cleaned up.

                                                                                                        1. 4

                                                                                                          I actually stopped containerising my dev environment because having to rebuild and restart a container every time I modified the source code was time-consuming and a pain, and left useless Docker images on disk which would have to be cleaned up.

                                                                                                          I wonder what the motivation is for people to containerize their development environments. Is it to be able to specify a set of dependencies and have the same environment between machines? For getting project-specific system dependencies, I put a default.nix or shell.nix in the project’s directory (my system and home environments have practically no development tools). E.g., here is a project where I want the latest Rust stable, libtensorflow, the Tensorflow Python module:

                                                                                                          https://git.sr.ht/~danieldk/sticker/tree/2fec307290/default.nix

                                                                                                          If I really want the dependencies to be completely frozen, I just import a specific nixpkgs commit.

                                                                                                          I use shell.nix files with direnv so that I automatically switch into this environment when I cd into the project directory, plus an emacs package that switches the environment when I open a file in such a directory.

                                                                                                          There is nothing to rebuild or special to run when I want to recompile a project. I just run a regular cargo build. Also, the dependencies are in the Nix store, so most of the dependencies are shared between projects (it’s space efficient).

                                                                                                          1. 1

                                                                                                            I wonder what the motivation is for people to containerize their development environments. Is it to be able to specify a set of dependencies and have the same environment between machines?

                                                                                                            Essentially, yes, and to make sure anyone working on the project can spin it up easily and work the same way. Also if your service is containerised in production it can help to test it works that while during development, although CI should handle that.

                                                                                                            1. 1

                                                                                                              For someone who has never used nix, what should I do to get going with a setup like that? Can it run on macos? I use homebrew; can it coexist with nix? Can I use homebrew for systemwide things and nix for development environments? I know of direnv; what’s the emacs package?

                                                                                                              1. 1

                                                                                                                I also use Nix on macOS (besides NixOS). On the Mac I have it installed side by side with Home brew, which generally works ok. On macOS people generally disable sandboxing, since not all derivations build with sandboxing. This has the risk of introducing stray dependencies in libraries installed with Homebrew. Another problem is that derivations break more often on macOS. So you generally have to fix more.

                                                                                                                That said, people use Nix on macos. A good starting point is John Wiegley’s presentation on using Nix on macOS :

                                                                                                                https://youtu.be/G9yiJ7d5LeI

                                                                                                                On NixOS or even Linux with Nix things are much simpler. Install Nix, configure direnv, create a shell.nix, and that is pretty much it.

                                                                                                                1. 1

                                                                                                                  Thanks, I’ll give it a try!

                                                                                                                  1. 1

                                                                                                                    I think I’ve got things working pretty well in the terminal. What is the emacs package you are using to switch in and out of nix environments in emacs?

                                                                                                                    UPDATE: Never mind, I found this which seems to work.

                                                                                                                    1. 2

                                                                                                                      Sorry for the late reaction, I was traveling. Yes, that’s the emacs package that I am using:

                                                                                                                      https://github.com/danieldk/nix-home/blob/72c4b0f606aeeae5db3c8606ac0f856d9d01c776/cfg/emacs.nix#L13

                                                                                                              2. 2

                                                                                                                because having to rebuild and restart a container every time I modified the source code was time-consuming and a pain

                                                                                                                How about mounting your code via a volume in the container, so docker takes care of the sync? That’s what I do

                                                                                                                1. 2

                                                                                                                  That works “OK” for cases where you have something that hot-reloads on file change (e.g. a Flask app in dev mode) but for compiled Go or Rust programs this doesn’t work.

                                                                                                                  1. 1

                                                                                                                    It does. During development I have a standard golang image with the code mounted to the proper gopath and gin as the command.

                                                                                                                    1. 1

                                                                                                                      Gin is relatively unique in supporting hot reload. This also implies only work on on HTTP services.

                                                                                                                      Personally I don’t like Gin for HTTP services (I use Chi or Gorilla), but I also work on other things. It’s far easier to not use Docker for almost everything else.

                                                                                                                      1. 1

                                                                                                                        I only have this set up so the container can live amongst half a dozen other containers on this particular docker-compose setup. Not all of my team need to tinker with the Go part and I want docker-compose up to be the only required command to run the project.

                                                                                                                        I agree that using docker when writing go is not terribly useful, but it can be done.

                                                                                                                  2. 1

                                                                                                                    I used to do this, but it’s a huge pain in the neck for repl-based flows; when your editor says “reload this file” the containerized repl server is like “that’s not a file” so you have to translate the paths from host versions to containerized versions. I found for what I was doing there was a lot of friction for zero benefit, so I stopped.

                                                                                                                    I can see how it’d be useful if the stack you used was really finnicky to install, but for Clojure development it makes no sense. (We still use docker to automate starting background services like queues and databases.)

                                                                                                                  3. 2

                                                                                                                    Yea, and you can’t use tooling like the debuggers in most IDEs without adding a lot of extra steps or work or special plugins (I mean you should just be able to attach to the process, but it’s run in a different cgroup with different privileges).

                                                                                                                    Containers make sense if you’re working with a set of services. I don’t even fuck with docker-compose. It’s easier just to have each docker create/start/run command in a .sh file and just start the services you need and stop the one you’re currently working on .. point the others to it and run that one locally/natively (If you’re using Docker for Mac or Windows, you need to VPN into the docker subnet .. which is so dumb .. just develop on Linux. More companies need to allow devs on Linux or even help Linux be a first-class/supported environment).

                                                                                                                    1. 1

                                                                                                                      Its interesting to see this attitude for development in dockerized environment. I wonder is this solvable via some better tooling or tech is simply overly complex for such use case.

                                                                                                                      I guess its similar to what was once Vagrant problems. Looks like Guix did this like a champion - solve isolated development once and for all, on the OS level, which means you can add stuff to environment that are out of scope for all other tools.

                                                                                                                    2. 2

                                                                                                                      That was my thought as well: this seems to be a redo of the docker-compose concept.

                                                                                                                      FWIW I have used / recommend docker-compose for (1) integration testing and (2) providing a spec of a database my local app can connect to.

                                                                                                                      Use case 1 sets up a database, sets up the app, then runs tests against the app, which then, at the end, can all be torn down in a hermetic way.

                                                                                                                      Use case 2 is simply the first part of use case 1, but exposing the port for my fine app to do on my laptop.

                                                                                                                      arguably these days use case 1 can be done via minikube, but that just adds a few more turtles to the stack.

                                                                                                                      1. 1

                                                                                                                        I’m curious. Putting code-reloading aside, did you notice any benefits in your development workflow compared to what you had prior to containerising everything?

                                                                                                                        1. 1

                                                                                                                          No, none. The only reason I’d started was because of a project I’d inherited. I tried to go along with it but it frustrated me at every turn. The only part of the stack I kept in a container was a Postgres instance.

                                                                                                                          As @djusumdog says, it causes problems with debuggers, etc. Containers are alright for production or staging but it impedes development workflow for compiled programs.

                                                                                                                          1. 1

                                                                                                                            I doubt benefits are visible on single projects, its probably way worst then having everything locally.

                                                                                                                            Benefits certainly come when working on multiple projects, where those reuse some of the stuff of other projects. This always complicates stuff locally.