255 karma · joined October 26, 2009
I suspect, that the Elixir REPL is more like the Erlang REPL, which might be the same kind as LISP REPLs, but I have no direct experience, I just saw Erlang REPL usage from John Hughes videos.
* https://www.youtube.com/watch?v=St0_jsPnGAw - analyze some SO HTTP API responses * https://www.youtube.com/watch?v=TaazvSJvBaw - transducers from the ground up
I think they are great, crystal-clear examples of REPL-based development.
This way I can be in any file, modify any `def` of `defn` and see its effect on the expression I'm working on.
After modified something, I might jump to its unit test or jump to some definition of some adjacent vars, where i see a point which I want to probe (with a function like this: `(defn ? [x] (pprint x) x)`).
Then I have 2 modified files, and my cursor is in a 3rd file and the expression I'm iterating on is in a 4th; doesn't matter, I can just keep hitting the same shortcut (Cmd-Ctrl-Enter) to see the effects of my changes on the "expression-under-test".
It's an extremely convenient workflow, which is also easy to teach to ppl!
Downside is that you can't have namespaces, which have side-effects WHEN they are loaded.
To deal with that problem, I'm using `redelay`, `rmap`, `meta-merge` & `defonce`, eg:
(ns service
(:require
[meta-merge.core :refer [meta-merge]]
[gini.rmap :as rmap :refer [rmap ref] :rename {ref $}]
[redelay.core :as redelay])
(def kit
(merge {:cfg {:db/uri "..."}}
(rmap {:db (connect (:db/uri ($ :cfg)))})))
(defonce service-ref
(redelay/state
:start (rmap/valuate!
(meta-merge service/kit
{:cfg {:param 'override}
:some 'special-component}))))
(defn service [] (deref service-ref))
(comment
(.close service-ref)
(-> (service) (some-operation x y z))
)
More info on this topic is here:
https://functionalbytes.nl/clojure/rmap/2020/07/04/rmap-2-up...you should read the previous articles from the author, eg. https://jrsinclair.com/articles/2022/javascript-function-com...
then
https://jrsinclair.com/articles/2022/what-if-the-team-hates-...
it would address some of the concerns and critiques ppl had on this topic here.
Of course it's a bit painful and error prone, given SQL is a textual language, but as HoneySQL (https://github.com/seancorfield/honeysql) shows, you can represent SQL statements as data and generate them programmatically in a safe manner. I think it's compatible with https://babashka.org/ so you don't need a full Java environment to use it.
On the other hand, maybe the time is ripe for you to "graduate" to using Datalog via other kind of databases, like Datomic, XTDB (fka Crux) and the likes (DataScript, Datalevin, etc)
Of course knowing Datalog won't help you with your SQL issues, but you can look into changing jobs, if you like what you see or maybe do some ETL job to spill over some data into the mentioned DBs and see whether querying it with Datalog is any better.
Used Fantasque Mono before it. I was quite happy with that, but compared to Comic Code, it just feels soul-less... If you don't have the money though, it's a great alternative.
Otherwise I would highly recommend the Ubuntu fonts, because they are very well hinted at smaller sizes and look great without antialiasing too, just like Envy Code R!
I also prefer the lack of them, exactly because they apply to strings and comments too, where they are often undesired.
I write Clojure code most of the time, so maybe that's a deciding factor too...
I knew very little about Emacs (27.1) at that time, yet it was an effortless endeavor to grow my own config: https://github.com/onetom/onetomacs
I had literally zero hiccups with packages, though I haven't even froze them, while kept upgrading every few weeks with straight-pull-all.
I think the other big contributor to my pleasant experience was that I've vetted and studied every package, before I've added it to my config and tried to figure out what would it offer compared to built-in functionality.
I'm programming for 40 years by now and primarily in Clojure for the past ~7 years (using IntelliJ/Cursive), so I guess that helped a lot too...
it could be the built-in vc.el too, because I can imagine straight depending on that, but I haven't checked.
Straight.el carries over the idea of reproducible builds from the Nix package manager and applies it to the specifics of the Emacs ecosystem.
So the whole point is to get away from the reproducibility issues of Ansible, use-package and the likes.
I suspect, your definition "crypto" is not the same as the definition of OP.
Can you elaborate more, why do you think it's a fad?
Have you tried to write, deploy or at least use any Ethereum contacts? Do you know how Merkle trees work or at least what are they useful for? How about elliptic curves?
I worked on this off-chain technology a few years ago: https://github.com/enumatech/sprites/tree/master/examples/pa...
The point of the article is avoiding feature interaction. Try to implement a feature first on top of a smaller feature set first, just so you can learn about the problem domain and the solution space. After that, integrating such a feature on top of a more complete application should be significantly easier.
Forking is to be understood conceptually, not as a terminology of any specific version control system. As in a git branch represents a fork in the time-line of the evolution of a code-base. It just happens to be that fork also means something more specific in case of the GitHub/GitLab online services.
Not that performance or file size would matter in this case, BUT what using SQLite would allow is to use a single format for persisting all aspects of the password database, with immediate, programmatic, random access to all fields, including attachments.
But I also agree, that for this specific use-case, even SQLite is a bit of an overkill probably.
Finally, there is always https://www.passwordstore.org/ :)
The trick is not to mix your personal stuff, like movies, photos and music with your work stuff. Also make sure you regularly clean up the older versions of the software you use, including Docker layer caches, brew / nix packages, JetBrains IDEs, browser caches, etc. If you are not doing audio/video work, then removing iMovie and GarageBand frees up 4.5GB. Similarly Keynote/Numbers/Pages 2GB.
and it's freaking buttery smooth. notice the "aarch64" part!
What actually feasts on memory is the various chat apps and project management and knowledge-base management software, in-browser email clients, github pages, JetBrains IDEs.
You should keep these closed, whenever u can and then 8GB is enough comfortably. You will still receive Slack notifications on your phone, then u can fire up Slack to reply or have a discussion. Same with Notion or Logseq. You don't need to have a gmail tab open all the time either. The built-in Mail.app might just be enough for you too, which might eat slightly less memory. You can use Sublime Text or Emacs for editing, instead of VS Code or WebStorm. Install a browser-tab suspender extension. Download technical docs and read them via Dash (or whatever open-source equivalent it has). Have you looked into how much memory does a github.com page eats?