Skip to main content

C'est la Z

Tag: emacs

A Teacher looks at Advent of Code 2020 - Days 7 and 8

Today we'll talk about days seven and eight. Let's start with 7. I teach all morning on Mondays. I woke up and worked out and then took a look at the problem in the few minutes before class. It was certainly harder than days one through six but I felt it was something I knew I could do based on past experience so I quickly started to throw something together.
# COMMENTS

A Teacher looks at Advent of Code 2020 - Day 06

Day 6 turned out to be pretty straightforward. Like day 4 you had to deal with two consecutive newlines when parsing the data but assuming you did day 4 that's no problem. The gist is that a group is formed by consecutive lines and groups are separated by a blank line. Each line in each group is a string of letters representing answers to questions. For instance, for this group: abc abd ab you have three people.
# COMMENTS

A teacher looks at Advent of Code 2020 - Day 5

Day five's problem is a nice one for an early CS class. It can be very much brute forced but it also touches on some nice concepts and can be solved pretty elegantly. I've embedded a walk through in Clojure at the end but a Python solution would be pretty similar. Read the problem over if you haven't. At it's core you are taking a boarding pass representing a coded airplane seat number and you're converting it to a known seat (row and column).
# COMMENTS

A Teacher Looks at Advent of Code 2020 - Day 4

One of the nice things about Advent of Code is that it gets me to explore language features I haven't used yet. Today's problem got me to explore Clojure Spec which is a very cool validation library. There's a complete run through of the solution in Clojure in the video but here I'll talk about the problem in Python (mostly). Today's problem is about validating passports. You start with a text file consisting of passport information.
# COMMENTS

A Teacher Looks at Advent of Code 2020 - Day 3

I thought I'd do a video for today. No particular reason. Mostly why not. I'll talk about day 3's problem and code up a solution in Clojure. If you haven't ever used Clojure, hopefully this will give a bit of the flavor. This video also serves double duty as being my next Using Emacs video since it demos Emacs's Clojure tools. Mostly Cider which even with a few quirks is the best development environment I've ever used.
# COMMENTS

Using Emacs 75 - Bufler

Quick Emacs hit today. After my last video, I received a comment noting that I was using ibuffer and that there was another package I might want to consider - bufler. I started with basic ibuffer and then started to customize it to group buffers but that was always somewhat finicky. More often than not I couldn't tune it the way I wanted. Most recently, I started using ibuffer-projectile which group projects for me but lost the other customizations.
# COMMENTS

Using Emacs 74 Eglot

I primarily program in four languages these days - Clojure C++ Python Java And most of the time, my Emacs configuration has handled each one differently. Cider for Clojure, Irony for C++, Elpy and Jedi for Python and Java I could never figure out. This is of course on top of tools that work across languages like company for completions, or flycheck for general language syntax checking. A while ago I heard about lsp-mode - Language Server Protocol mode.
# COMMENTS

Using Emacs 73 - Ripgrep and updating the blog

As I said in my last post, I'm moving to a new Hugo theme. I decided on Anubis. It's simple and clean. Unfortunately, in this change over, many things broke. Specifically, all my embedded html. Using earlier version of Hugo I could directly embed HTML and it would render. Now I have to bracket the HTML with special org markup - #+begin_export html and #+end_export html. #+begin_export html <h1>html stuff to render goes in here </h1> #+end_export Minimally I had to find all my embedded videos and all my embedded Tweets.
# COMMENTS

Using Emacs 72 - Customizing Elfeed

I made this video write after I made the openwith one so even though I don't mention anything in this video, I wanted to share some updates on dired and openwith. I got a lot of suggestions on alternate ways to achieve the workflow I was seeking - being able to open a file using an external viewer. One person noted that under newer versions of Emacs, the W key is bound to the command (browse-url-of-dired-file) which does exactly what I wanted.
# COMMENTS

Using Emacs 71 Openwith

I spend most of my time in Emacs but still use the shell and browser for some things. One of the things I use my shell for is to launch libreoffice to view and edit docx files and spreadsheets, evince for pdf files and imagemagick for image files. Yes, I know I can view all of these in Emacs but there are a few limitations: Emacs chokes on large files I can't edit the docx file or the image So, I hop to the shell and launch the program I need on the files in question.
# COMMENTS