1. 3

    On my VPS:

    1. 1

      How do you like cloudmacs? I enjoyed using org mode for work/school/life, but keeping it on multiple machines and synced properly made me stop using it.

      1. 1

        I like it! (I’m the author :D )

        On my computers/phones I use syncthing (also used Dropbox previously) and it works perfectly.

        The reason for cloudmacs is that sometimes I need access to my org-mode files where I don’t have SSH client or even Emacs.


          Oh! I didn’t even make the connection at first - Awesome!!

          Do you use Emacs/Cloudmacs for everything or mainly just org?

          Is Syncthing used for keeping your org files across devices, or for configs and such?

          I tried to only keep one org file, but it got cluttered (even though I separated out work/non-work) and I didn’t really change and defaults since I was trying to use it on 3-4 different machines


            Emacs – most of plaintext editing and most of my coding. Cloudmacs – mostly for accessing org-mode and hotfixing html for my blog when I’m not near my laptop.

            I sync pretty much all my files with Syncthing (apart from really heavy stuff like photos/huge binaries/etc).

            I’ve got lots of org-mode files, with org-refile/projectile and search it’s all pretty manageable!

    1. 7

      I am creating a webappsite for my self-tracking and lately figuring out a way to track and measure social media consumption, with the goal of finding out how much of it is truly beneficial or how much is not.

      1. 2

        Cool! I’ve often wanted this and thought about it for many years. What tech will you use? Open source?

        I think the hardest part is making it general enough. e.g. tracking steps or whatever is pretty simple, but it gets a little more complex the more metrics and shapes you add. Steps, nutrition/calories/macros, workouts, sleep, stress level, whatever else.

        What kind of stuff do you plan to track? Anything beyond social media?

        My latest conclusion is that I should just stream all my data into google sheets to avoid being locked into a single platform. My data sources are Oura, Strava, Cronometer and maybe some random apple health stuff.

        1. 1

          My site is currently static, generated from Haskell DSL (via rib). It is visible only to me, due to sensitive of the data. But if I were to do dynamic stuff, I might just use ghcjs via obelisk (basically Haskell and FRP, which is Elm on steroids).

          Things I currently track:

          • Food consumed & skin health (to identify triggers)
          • Progress in PCE contemplation and its (mental) blockers
          • Random markdown notes

          Things I want to track:

          • bazqux.com stats (how much I read, how much of the feeds are actually useful to me, how much is just fluff, etc.)
          • Calisthenics “greasing the groove” style reps and progress
          • Mood tracking (think a calendar view of color-coded days, which you can drill down to specific journal entries)
          • Work mood tracking (similar, but in work contexts)
          1. 1

            Do you input this data in any apps or do you plan to track it all manually?

            Tech sounds amazing. I’ve played with both Haskell and Elm and wish I had more opportunity to use either/both. I wouldn’t consider myself proficient at either, but understand the concepts pretty well.

            1. 1

              I input it in my Haskell DSL which is defined using something called “free monads”. I’ve written about it here. Here’s a screenshot, showing the DSL definition on left and its use on right:

              1. 1

                Wow. So there’s no data store? The data is literally hardcoded and you update the code every day to add a new entry?

                Edit: from the blog:

                Better alternatives? What do you think, dear reader?

                This is super interesting but I can’t imagine building this without a separate Haskell/lang/platform-agnostic data store! 😨

                1. 2

                  Wow. So there’s no data store?

                  Yes, everything is checked in to git. I’m not a fan of using databases unless actually needed. Well-structured text files suffice for most cases.

                  The data is literally hardcoded and you update the code every day to add a new entry?

                  Yup. I just add a few lines every day to the DSL, but don’t do anything else. ghcid (which rib uses) will instantly re-compile it (giving me feedback on syntax errors if any) and run the code, publishing updated HTML to my website (via keybase pages; so no deploy needed).

                  One day I might write a blog post describing this workflow.

        2. 1

          that reminds me, I want to get some stats on myself to see how many times I use the right alt and right ctrl keys on the keyboard. I just need to get the computer to track them then forget about it for a week.

          My gut feeling is I never use them. But proving that should be easy enough. I could also perhaps just pop them out and see if I get annoyed when my fingers go there and hit nothing lol

          1. 1

            logkeys is pretty good and very simple to set up for such kind of analysis

        1. 3

          Some good tips, though I have learned to be wary of relying on proprietary products for this. I can’t count the number of times I’ve realized that a privacy policy was abusive, or a company got bought by a larger corporation with a worse privacy policy, or a product was shut down… causing me to delete or migrate everything to some new service.

          Don’t get me wrong, occasionally using cloud products is fine. But if I’m going to dump my brain into something and depend on it throughout the day, I want to either (a) have complete control over it, or (b) have an easy exit plan that allows me to migrate to something else with minimal effort. Oh, and I guess (c) it should work without an Internet connection.

          1. 1

            Yep, fully agree: siloing, poor offline support – also reasons I’m avoiding proprietary products as much as I can. Personally I’m a heavy org-mode user :)

          1. 2


            Fully static, I’m selfhosting (although mirroring on github pages too just in case). Most pages are built from org-mode or ipython. Org-mode is compiled by emacs, ipython by jupiter and then it’s all glued together by Hakyll. After that I fix things I don’t like about emacs/jupiter exports by changing HTML directly in python (with BeautifulSoup).

            I write here and on github on the choice of software and design decisions.

            1. 2

              I like the idea behind this, couple of questions about it:

              1. If my python service is scaled to run on multiple containers how well will this work across containers with sqlite?
              2. Are there any plans to support redis as the store?
              1. 2


                1. I’ve been using it mostly in single consumer mode or they were spaced apart in time so concurrency was never an issue. I did discover some concurrency issues and just fixed them and released new version.

                  So it should work correctly now, and worst case is if two concurrent processes have mismatched cache and want to start writing – in that case one of them ‘wins’ and updates the cache and another one simply calls the function without modifying the database.

                2. I’ve never thought of it, however, I can see how it could be useful!

                  Should be relatively straighforward: the bit responsible for converting into sqlite-compatible row is separated from code actually dealing with sqlite. So it would be a matter of providing different primitive type mapping (in redis everything is a string iirc?) and implementing transactional logic for Redis (which I’m less familiar with than sqlite).

                1. 2

                  Awesome great. For sure will take a closer look and use your project when I can.

                  Created this issue from our conversation: https://github.com/karlicoss/cachew/issues/9

                  Short of bandwidth at the moment but if one day I have some time will contribute above to your project if you don’t get to it first :-)

              1. 2

                Thanks for writing this! Wondering if you’re planning a second part with a higher dimensional state, demonstrating entanglement or more sophisticated behaviour?

                Asiking since I feel like this particular example doesn’t answer yet “why bother using quantum computing for that”? In essence, here we just multiply initial state by the evolution matrix, which is a trivial task for classical computers (when the size isn’t exponential).

                For instance, when justifying use for Shor’s or Grover’s algorithm it’s easy to understand the speedup since the problems are fairly abstract and it’s clear how compexity grows with size. Wonder if in a similar manner, it’s possible to come up with some made-up system of N electrons (or other particles, if it would make Hamiltonian simpler/closer to reality), that would be relatively easy to solve analytically (or just reason about qualitatevely), but straighforward construction of Hamiltonian matrix would be infeasible? And then once could map the Hamiltonian onto quantum gates and that demonstrate that the results predicated by quantum computer match the analytical solution.

                1. 2

                  Glad you enjoyed it! I submitted another of my quantum-themed blog posts here: https://lobste.rs/s/ohmr6o/walking_faster_than_light_tightrope

                  You’re correct that classical computers are perfectly capable of executing the simulation method described in the post, and indeed this is a simulation method used on classical computers in the real world. However, this method reaches its classical limit for systems with 40-50 atoms; beyond that other approximations must be used. Quantum computers would (theoretically) encounter no such limit, and could simulate systems scaling more or less linearly with the size of the quantum computer itself.

                  It’s a common problem with introductory quantum computing presentations: by necessity they must be simple, and simplicity requires small problem sizes, so anything in an introductory presentation will be easily simulated by a classical computer. I suspect any presentation involving systems that would actually be difficult to execute on a classical computer would be extremely math-heavy (requiring dense notation to wrangle the large problem size) and thus have very limited appeal.

                  Your idea of a problem which is easy to solve analytically might exist, I’ve heard things involving the Ising model are like this; I’ll have to ask my coworkers about it!

                  1. 1

                    Was also discussing that with a coworker today and he wondered, perhaps known statistical properties of quantum systems would be a good candidate for demonstration?

                    E.g. we know certain properties of Bose-Einstein condensates analytically and experimentally, now what if we try to infer these properties via ‘quantum brute force’, that is solving equations explicitly on quantum computer?

                    1. 1

                      Yeah, and to be fair even something with, say 10 particles even if it’s possible to solve numerically by classical computer (e.g. if one just uses the 1024 x 1024 matrix, which is manageable for modern cpus), the solution would still be sort of blackboxy and hardly comprehendible for a human (at least, to the target audience who wants to learn why quantum simulations would be cool).

                      That’s why I feel it’s important to have some pedagogical made up example/approximation that allows for some analytical solution and scales well with number of atoms/particles involved. I understand though that it might be harder than it seems (e.g. like in QFT where numerically simulating vacuum is a big achievent and still requires supercomputers). Would be interesting if with some tweaks or unphysical assumptions it was possible to simplify Hamiltonian and make it tractable, just for the sake of demonstrating quantum advantage :)

                      Oh, cool, Ising model was on my reading list for a while; should bump it up. Thanks!

                  1. 5

                    Wondering if Java is worth learning. I see a lot of jobs requiring Java experience. I know to write code in C++ and Python. Never was attracted to Java. I see no point in it especially since it is slower than C++ by reputation.

                    1. 6

                      Lots of strong opinions in this thread. Java is more than a language; it’s a platform. Java and JVM are used interchangeably a lot. Java is verbose, probably a little slower than C++ in some cases, but the JVM is the platform for almost all, modern day data engineering libraries. Hadoop, Spark, etc. You don’t have to write Java code, you can use Scala or Clojure if you want a different language on the JVM, but still want to interop with the vast ecosystem of Java libraries.

                      Java and C# still seem to be pretty prevalent for enterprise development, so it’s up to what you want your career path to look like. If you are wanting to do data engineering the JVM will be useful to work with. If you want to work in enterprise apps, Java or C# are useful.

                      tl;dr Don’t learn Java just to learn something fast. The virtual machine (JVM) is a powerful platform to use, which can leveraged by learning Kotlin, Clojure, or Scala. If an interviewer refuses you a job because you haven’t done Java, you probably are looking for the wrong job(E.g. senior java developer) or looking at the wrong workplace(e.g. you must check all the boxes to get this job)

                      1. 2

                        A thousand times this.

                        If you were going to work with java day-to-day, I’d suggest learning any of the following over studying the language:

                        • An IDE, in depth (java and c# are the only languages I’d use an IDE for; they need it).
                        • How code gets loaded (dependency management, the classpath)
                        • A smattering of JVM bytecode (relevant if your code needs performance or you are integrating with non-java code).
                      2. 4

                        This may be more of an advanced topic, but instead of trusting reputation of being ‘slower’, I’d recommend playing with tools and techniques for benchmarking and profiling. It’s not only relevant to choice of programming languages: even within the same language you might have different opinions on performances of algorithms, data structures and language features. (e.g. lambdas are slow! virtual functions are slow! etc.)

                        Different parts of different systems require different performance, and in many cases it doesn’t matter which language you choose at all. Being able to measure what actually matters and justify your choices would make you more pragmatic and essentially give you higher ground in arguments over choice of languages and technologies.

                        1. 4

                          Don’t bother. The language’s market share is in gradual decline for years, and there is nothing to be learned except the Platonic meaning of ‘cumbersome’.

                          1. 3

                            Arguments this bold are rarely true… I don’t write Java and I do vaguely agree with the sentiment, but I also would write C before C++ so.

                            1. 1

                              shrug I do have some experience with Java (and would also choose C before C++). Its killer feature was restricting C++ programmers from shooting themselves in a foot. Which is hardly a special selling point nowadays, with so many fairly nice, popular languages out there.

                              1. 1

                                I suppose it may just be a knee jerk reaction, I don’t like it when people say “Don’t learn X” without even proposing an alternative. I never did enjoy Java, it was quite verbose and quite ceremonious. Still I’m hesitant to say that someone shouldn’t learn it at all.

                          2. 3

                            I’m not recommending either learning java or not, but java is hardly slow. there’s a good reason many large companies with performance requirements swear by it. The jvm is underrated in general and the JIT is especially underrated.

                            1. 3

                              If you’re coming from C++, there isn’t that much to learn. My opinion..learn something new like a functional language if you want to broaden your horizons. If you need Java experience for a role, you can obtain enough in a short period to pass their “test” and learn the rest on the job.

                              1. 2

                                Lots of code is in Java, and there is a career path in knowing a JVM language.

                                Lack of speed is overrated, and Java’s JIT is reasonable.

                                I am not a Java Guy though I would become one for a job. The standard library is too massive and ever expanding for my tastes, and I refuse to spend time memorizing obscure classes that will make a possible future job easier. I’d rather have Google when I need it.

                                1. 2

                                  Java is slower and more memory intensive but it’s also easier and faster to write correct code. It’s a conscious trade off, and depending on the task may be a worthwhile trade. Rust is a good compromise, but I think it is important to be mindful that it is a compromise.

                                1. 3
                                  • finishing writing post about exporting and liberating your data (followup to this). Also related to the personal API thing posted last week!
                                  • final touches for cachew, Python serialization/caching library powered by type hints
                                  1. 6

                                    Shameless plug: I’m using python package, i.e. import my as my personal API; I’m in progress of writing up on it, you can see some examples here.

                                    1. 2

                                      Great talk, thanks for sharing.

                                      I like his pragmatic approach, i.e. having clear goal of doing modern math, rather than playing with fancy type theories.

                                      Also interesting bit where he mentions that for math students, often one of the main barriers of entry into proof assistants is installing and running in the first place (they are often using Windows laptops). E.g. ‘what the fuck is git clone’, or even ‘command line? eh?’

                                      Wonder if it’s something worth solving on a larger scale: e.g. something cloud based. Once students find it useful, there would be at least motivation to overcome the technical difficulties and install locally.

                                      Prof Buzzard is also running a cool blog, Xena.

                                      1. 2

                                        Sounds interesting! How do you think it would compare with existing CRMs/habit trackers?

                                        1. 1

                                          Thanks for sharing the link! My thing would probably trade off features for flexibility. I probably don’t have specific support for calendars or even that fancy of a GUI like the examples in the link. My goal is to build something that does one thing well: generate interrupts. Views help keep the physical data segmented and composable, and data dumps help with scriptibility, but all that really means is being able to tune interrupt generation to the granularity I want.

                                          I mentioned “for software engineers” because I don’t think another audience base would really get what I’m saying or why all of this is important from a development standpoint. It’d be like trying to explain the UNIX philosophy to a non-technical stakeholder :P

                                        1. 3
                                          • Scott Aaronson, quantum complexity theorist and generally great guy
                                          • John Baez, category theorist, but don’t let it scare you off, he writes about all sorts of things and also tremendously good at explaining
                                          1. 1

                                            Great post. My own thinking takes a different turn, towards local-first designs, but I’m also happy to see people working on sync-based approaches—because that’s going to be useful for the local-first and multi-device stories to not be in conflict.

                                            1. 2

                                              Thanks, glad you enjoyed it. I’m all pro local-first as well! The sad reality though is it’s gonna take a while to actually get there (in part due to the burden of existing products). I’m also not that familiar with such types of distributed systems, so would struggle to advocate for them without backing it up by facts. But I do believe we’ll get there at some point :)

                                              Yep, the sync-based solution I’m suggesting is sort of a first order approximation to local first, which one can get today with some effort (I’d be describing my setup in subsequent post).

                                              1. 2

                                                Looking forward to it! I’ll follow your Atom feed to watch for it.

                                                I’m currently working on a local-first social journaling protocol called Cavern, which you might be interested to read the design and philosophy documents for.

                                            1. 20

                                              … or, instead of thinking of types as a solution to everything you may be lucky to use a language with named arguments, so you could

                                              fetch(account_id, disabled=True, history=True, details=True)

                                              … and in cases where you already have named variables with values you could avoid duplicating names by calling this same function as

                                              fetch(account_id, disabled, history, details)

                                              What I’m saying is, language matters.

                                              1. 6

                                                Language does matter, but your example is still an instance of boolean blindness. What intuition should I have about the truthiness of history or details?

                                                1. 2

                                                  It’s a question of better naming. I just copied names from the article for a quick example.

                                                  1. 4

                                                    Ok, but also in your example you have connascence of position, which is worse than connascence of name. There’s not much stopping someone (other than just being really careful!) from calling the function with the arguments in the wrong order, because the constructors inhabit the types of almost all the arguments.

                                                    1. 3

                                                      I did not understand that, sorry. But for the record, Python allows you to pass named arguments in any order. Don’t know if that has anything to do with what you’re saying.

                                                      1. 3

                                                        I mean it’s very easy for the caller to confuse the position of the arguments, and if the types in your function’s signature have very loose semantics, your program will compile but it will still be wrong.

                                                        Compare the following:

                                                        -- error prone
                                                        fetch "abc123" True False True
                                                        -- better
                                                        fetch (AccountId "abc123") IncludeDisabled WithHistory WithDetails

                                                        But for the record, Python allows you to pass named arguments in any order

                                                        I think we’re arguing different things in that case. It’s like the difference between (in JS)

                                                        foo(true, false)


                                                        foo({ someField: true, someOtherField: false })
                                                2. 5

                                                  Good point! If you even luckier, your language would support keyword only arguments. E.g. in Python you can declare

                                                  def fetch(account_id, *, disabled, history, details)

                                                  That would forbid calling it like fetch(acc_id, True, False, False)

                                                  1. 1

                                                    I wouldn’t do that, actually. Because it would prevent my second example from existing, and you’ll end up with silly stuff like disabled=disable, history=history, .... Overall, I prefer an API to not overly restrict usage choices. Because a consumer is almost always in the better position to judge what’s useful and what’s not than the author of the API. And mis-uses are better prevented with good naming, documentation and code reviews.

                                                    1. 5

                                                      But otherwise there’s nothing ensuring the args are passed in the right order. Even if you name your variables nicely, fetch(account_id, history, details, disabled) runs without any warnings, but is all wrong.

                                                      1. 0

                                                        But otherwise there’s nothing ensuring the args are passed in the right order.

                                                        Tests are.

                                                        1. 4

                                                          That’s a cop-out. If you assume there’s always adequate test coverage for everything, then no code can be wrong.

                                                          Of course it’d be nice to have tests for every argument of every invocation of every function, but let’s be honest: it’s not going to happen often. In terms of required discipline and effort vs correctness achieved, named arguments or typed enums solve that better.

                                                          1. 1

                                                            I look at it differently :-) Type checking is a cop-out, where people make testing so hard that they don’t do it and have to rely on types to provide semblance of correctness. “If it compiles, it works”, something I hear too often.

                                                            it’d be nice to have tests for every argument of every invocation of every function

                                                            This is trying to emulate type checking with testing, which is the wrong way to do it. But we are way, way off topic here, and I can’t hope to elaborate enough details in the middle of a comment thread. May be I’ll work myself enough to blog a series on it some time…

                                                  2. 3

                                                    Aren’t named arguments enums that carry a value? ;)

                                                    1. 2

                                                      Absolutely. This style is an excellent alternative, in languages where it’s practical.

                                                      1. 1

                                                        I don’t like keyword arguments; I would much rather have a “bag of flags” and write:

                                                        fetch(account_id, FETCH_DISABLED|FETCH_HISTORY|FETCH_DETAILS)

                                                        One of the biggest problems with keyword arguments is that the temptation to add “just another keyword” argument is very high, so someone might have this:

                                                        def GetReportData(selector, fields=None):
                                                          if not fields: fields = self.DEFAULT_FIELDS

                                                        and get this crazy idea to try extending the API:

                                                        def GetReportData(selector, fields=None, start=None, end=None):
                                                          if not fields: fields = self.DEFAULT_FIELDS
                                                          if not start: start = datetime.min
                                                          if not end: end = datetime.utcnow()

                                                        and never see the bug! Surely this isn’t all the fault of keyword arguments (and especially so in this case), but designing your API to be clear and useful without relying on keyword arguments also prevents this problem (and problems like it) from being introduced in the first place.

                                                      1. 12

                                                        I know this one is likely to be controversial, so I should say that I agree with it. This practice is suggested in Google’s C++ style guide, I’ve coded with it, and it’s made my code more robust and maintainable. The cost of maintenance far exceeds the cost of writing code to begin with; this is a simple thing with concrete benefits and it’s hard for me to see a justification for not doing it.

                                                        (Edit: syntax issue with the link)

                                                        1. 6

                                                          Also, for c++ I find strong type aliases work pretty well, e.g.

                                                          using IncludeDisabled = NamedType<bool, struct IncludeDisabledTag>;
                                                          // caller uses:
                                                          fetch(accountId, IncludeDisabled{true}, ...)
                                                          // caller can't just pass true or false because of explicit constructor

                                                          wouldn’t handle the “compatibility matrix” scenario, but works well when you need simple flags.

                                                          You can also add cast operator to NamedType, that would make it transparent in if statements.

                                                          1. 1

                                                            Sadly strong typedefs can cause performance degradations - wrapping int/float in a struct might require compiler (due to ABI requirements) to pass such values differently to calee.

                                                        1. 1

                                                          So the reason they use the bare repo and set up the alias, etc. is so that git and other tools don’t treat your entire home directory as a repository?

                                                          1. 1

                                                            The –git-dir, yes, to avoid always treating home as git. Bare repo is not strictly necessary, but without it you’d have an extra copy of dotfiles next to .git directory which might be confusing.

                                                          1. 13

                                                            I use Hakyll. It’s written in Haskell and is completely programmable. It’s actually more of a framework for writing static site generators. That said, there are example codebases that you can get started with. It supports all your desires.

                                                            1. 3

                                                              I use Hakyll, too, but it’s complete overkill for me. And I’m not deep enough in Haskell any more to do much development on it, so I’ve been considering moving to something else.

                                                              I still endorse Hakyll, fwiw, but its strength lies in either: 1- leveraging your existing Haskell knowledge, and/or 2- generating sites that are far more complex than most personal sites/blogs.

                                                              1. 4

                                                                I still endorse Hakyll, fwiw, but its strength lies in either: 1- leveraging your existing Haskell knowledge, and/or 2- generating sites that are far more complex than most personal sites/blogs

                                                                It’s also fun to spend more time programming your blog than writing blog posts.

                                                                1. 1

                                                                  i use hakyll and i’ve used it to also teach myself odd bits of haskell.

                                                                  i like how extensible it is, and i’ve occasionally used it to add various bits and pieces

                                                                  the main downside w.r.t. github is that you have to commit all the generated artefacts; which is definitely a shame.

                                                                  i’ve not done too much funky stuff with it; but on my companies website i’ve used it to build some (very simple) features, such as lists and specialised rss views, next/previous blog post buttons, etc.

                                                                  it’s not the most elegant code; but gets the job done.

                                                                  1. 1

                                                                    Late to the party, but you might be interested in rib.

                                                                    Why? Because by using rib, you will automatically learn Shake which it is built on top of. Compared to Hakyll, rib is relatively simple to use.

                                                                    Disclaimer: I’m the author. :-)

                                                                  2. 3

                                                                    hakyll here as well

                                                                    1. 2

                                                                      Great to see you’re blogging (again), Pavlo!

                                                                    2. 2
                                                                      1. 1

                                                                        Hakyll too. It’s simple if you only want to convert text into HTML, however, if you want something more advanced be prepared that you might spend more time figuring out how to implement this instead of writing.

                                                                        I’m also using supplementary python scripts and relying on external means (e.g. jupiter/emacs) to generate HTML too, I shared my setup here

                                                                      1. 4

                                                                        Sounds like I should really give mypy a try. For my big project, rewriting from Perl to Python was a huge improvement, but type errors are still common.

                                                                        1. 2

                                                                          Highly recommend trying! Mypy has completely changed my python experience from type error frustration and having to read the code all over again to understand what it actually does to something pleasant and safe to use.

                                                                        1. 14

                                                                          Modern C++ is certainly better than pre-C++11, but I don’t think it’s going to ever be something I actually want to use until they start removing misfeatures.

                                                                          1. 7

                                                                            Fully agree. This article seems to be addressing a criticism of C++ which I don’t think anybody is making – that C++ doesn’t have enough features.

                                                                            C++ has enough features. My problem with it is that it has so many features that 5 people working with one C++ codebase can be essentially working with 5 completely different languages.

                                                                            1. 3

                                                                              Unlikely misfeatures would be actually removed, but there is effort for cpp core guidelines, basically a ‘sane’ subset of modern c++. Part of it is already in clang-tidy, and if I recall correctly, the idea is that it would become the default mode in compilers at some point (although I might be wrong here).

                                                                              1. 2

                                                                                The issue I have with Core Guidelines is that the majority still can’t be enforced by the compiler (there are only some warnings for some things, and even then you may still need to put appropriate keyword/attr to get them).

                                                                                This doesn’t solve my problem with C++ of having to remember to be careful about so so many things (“Remember that if feature X is used, then do Y, except when Z”). If I get them wrong, then it’s my fault for not remembering and adhering to all the guidelines.

                                                                                1. 1

                                                                                  Is there at least a flag?

                                                                                  1. 1

                                                                                    I think it is still work in progress (without a strict deadline) hence no flag yet. But they mention clang-tidy and CppCoreCheck from Microsoft.

                                                                                    I agree though that compiler flag is very important to have, reasonable defaults are very helpful for easier adoption and learning about patterns and antipatterns.

                                                                              1. 7

                                                                                This has been a problem I’ve also had, but compared to this text, I just can’t properly do the switch from reading a text (usually physical or ebook) to taking notes, such as on a laptop, or even in a notebook. I have a pretty bad reading endurance to begin with, which makes working with any books hard to begin with. My best hope is just to remember where I can find something, and look it up when I need it again.

                                                                                1. 4

                                                                                  You can go analog and use pen and paper. I’m going to give you some links that might help you.

                                                                                  You can use translucent sticky notes to add notes to the books without obscuring the text below. They are available from many vendors, such as the linked above and this other one for example. You can also use index sticky notes to create your own organization on the side of the book and grant you quick access to the parts you need. Another useful tool are erasable highlighet pens like Pilot Frixion soft color highlighter which you can use to add highlights to your text that is not too agressive (pastel highlights don’t add too much noise to the book). Those are erasable with heat/friction, so you can remove them if you want.

                                                                                  To be honest, I could go on forever about things like these but those items are the ones I think you’ll find useful right now. With them you can quickly annotate your books without taking your attention away from the context like when constantly executing context switches between laptop and book. I hope this helps.

                                                                                  1. 2

                                                                                    Have you tried using stick it bookmarks? I just can’t use my laptop to take notes as it’s a focus killer. Adding many little color coded bookmarks with numbers or short annotations helps me return to hard parts and then when I feel like it to write useful notes.

                                                                                    1. 1

                                                                                      No I haven’t but the idea isn’t bad. I’ll try it when I try reading a physical book the next time. The only problems seems to be that you’d either have to have the stickers with you all the time, or just read at home/work/etc.?

                                                                                      1. 2

                                                                                        Leave the stickies in the book, depending on size?

                                                                                    2. 1

                                                                                      I’ve described few tricks I’m using on rare occasions I’m reading paper books here, some might help. They feel pretty low context switch.