After LiveBook minor version upgrade, can’t connect to node There was a “small” change in the recent LiveBook project which may prevent LiveBook from connecting to other nodes. LiveBook Changelog To make your node visible to LiveBook now, you must use long names. Now when starting iex, use ✅ --name instead of ❌ --sname . Then in the LiveBook config, specify the full node name such as…
My zsh command-line approach to toggling my light/dark modes for the dev tools I use In my ~/.zshrc I have the following: # Function to change WezTerm, VSCode theme, and macOS appearance change_themes () { local wezterm_theme = $1 local vscode_theme = $2 local macos_mode = $3 local settings_file = " $HOME /Library/Application Support/Code/User/settings.json" # Update WezTerm theme sed -i ''…
TLDR; In a pipeline function, call halt() after a redirect() . In a controller action, it is not necessary to halt after a redirect. Halt - The Confusion If you’re a Phoenix beginner like me, you may have seen some code where a redirect() is followed by a halt() . The code generated by mix phx.gen.auth includes a module called UserAuth , which has the following function defined: def…
Problem Wordpress on a Virtual Machine keeps redirecting to old IP address Using a virtual machine with a dynamic IP bridged to the host machine, and the host machine connects to various different WIFI networks… I found that my development Wordpress site on my (virtualbox) VM kept redirecting my web browser to the old/original IP address the VM had when Wordpress was first setup. I do not yet know…
Problem I wanted to do some Elixir/Phoenix development in Windows 10 (don’t ask why…), but I couldn’t build my Phoenix app due to a failure building the comeonin module. could not compile dependency :comeonin, "mix compile" failed. You can recompile this dependency with "mix deps.compile comeonin", update it with "mix deps.update comeonin" or clean it with "mix deps.clean comeonin" ** (Mix.Error)…
Problem In Elixir, when trying to write an Ecto query such as this: q = from(v in Vol, where: v.user_id == ^user.id, order_by: [desc: v.inserted_at]) you may encounter the error: undefined function from/2 This is a rather difficult error to search for on a search engine, and more than once over time I have encountered it and had to dig around to find the solution. Solution import Ecto.Query Do…
Goal We want to superimpose (or overlay) our logo image on top of all images in the current directory. These instructions are for macOS , and they assume a basic level of familiarity with entering commands via the Terminal . This example shows how to overlay an image (such as a logo) on every image in the current directory. It works on macOS 10.12, and it probably works in Linux. The command will…
Sorting with CoreData is pretty simple, but I ran into difficulty while trying to get string sorting to be case-insensitive. Examples I found worked, but they gave deprecation warnings regarding using selectors. This is the solution that worked for me: sortDescriptors . append ( NSSortDescriptor ( key : "title" , ascending : true , selector : #selector( NSString.localizedCaseInsensitiveCompare )…