Monthly review: April 2016

Last month, I wrote that I was looking forward to:

  • working more closely with the healthcare system and learning more about what to do
  • improving our routines and tools
  • gradually building a habit of going out (parent/baby groups, exercise, etc.)

A- is gradually moving past the slug stage of infancy. We’ve reached the awesome milestone of social smiles and cooing, hooray! That’s been helpful in getting us through those early morning wake-ups and occasional fussiness. W- has been super wonderful. I’m starting to feel like I might actually be getting the hang of this, too!

Warmer weather and A-‘s increasing wakefulness encouraged me to take her out for social activities. I checked out lots of free baby- and parent-oriented activities in the neighbourhood. They provide good excuses to go for a walk, A- gets to hear lots of words, and I’m learning from being around other parents and kids.

It’s great that there are so many resources available in the city. After a close call with a plugged duct, I started going to the breastfeeding clinic nearby. The weight history they’ve been keeping has shown that A- is gaining weight more slowly than normal. Based on my research and my conversations with the nurse at the cardiologist’s office, this is probably due to her heart defect. Having graduated from midwife care, we’re now seeing a pediatrician. I hope she can help keep an eye on the big picture, what with all the medical professionals we need to talk to.

The benefits of continuous improvement are starting to build up. Here are some of the little changes we’ve been trying:

  • Pizza is a handy way to use up leftovers.
  • The ring sling is a handy way to keep A- close, especially when she’s fussy and wants to be held. I can put it on even if I’m holding her.
  • Salads are fresh, convenient, and easy to eat. If I cut up ingredients and put them in containers, that makes mixing a salad pretty straightforward. I want to get us used to eating more vegetables, so I’ve been exploring salads. I think I’m getting the hang of having salad ingredients on hand, and I’ve been having fun exploring classic combinations too.
  • If I do laundry every other day instead of everyday, that saves time and energy.
  • If I brush my teeth and shower after dinner instead of timing it for before bed, then I feel better during A-‘s bedtime routine.
  • If I forget to do my pre-bed routine before A-‘s bath, I can brush my teeth while W- washes her.
  • If A- is cooing and not quite ready for bedtime, it can be a good opportunity to call my parents over Facebook Messenger so that they can interact with her.
  • If I draw my journal in the morning instead of at night, I don’t have to try to squeeze it into our bedtime routine.
  • If I keep lots of small towels handy, nursing becomes a more civilized affair.
  • If she’s crying, I can give her a short period of time to try settling down before I pick her up and more actively try to calm her.
  • If I loosen the bottom rail of the ring sling a little bit more compared to how I was doing it before, A- can sit more securely.
  • If I start Emacs as a daemon, I don’t have to worry about it crashing when I restart X.
  • If I use Tasker to set up call forwarding to either my home phone or a free voicemail service depending on location, I can worry less about missing calls or messages.

As our household routines improve and A- grows, W- and I have been gradually getting back more time for discretionary activities, too. W-‘s been getting back into woodworking, and he has also been able to go to the gym a couple of times a week. He’s great at coming up with songs and rhymes for A-, too, and she has come to enjoy bathtime.

I’m less worried about squeezing in naps while A- naps. I know that I can sleep in or start the bedtime routine a little earlier if I’m feeling tired, and I can call in W- for reinforcements if A- is fussier than usual. This has freed up time for me to learn more things. I’ve been sewing clothes, accessories, and stuffed toys. In terms of coding, visualizing baby data has helped me feel more comfortable with the d3 library (including animations, yay!). I applied that experience on my consulting gig, creating a couple of visualizations of their data. My drawing and writing still tends to be pretty journal-focused, but I can now take the time to explore other thoughts or go into more detail.

Most of the next big steps in terms of A-‘s medical stuff will be in June (cardiology update, eye clinic impression-taking). May will probably be more about improving our routines and skills. More social stuff, too. W-‘s parents are hosting a 100-day celebration for A-, and my eldest sister Ching is flying in for that. I’m looking forward to bringing A- to more get-togethers for exercise and stimulation. It would be nice to get back into the swing of drawing and blogging non-journal-type stuff – perhaps more kaizen posts. More salads and gardening, too! =)

2016-05-04b April 2016 -- index card #monthly #review output

Blog posts

Sketches

Time

Category Period 1 % Period 2 % Diff h/wk Diff h/wk
Business – Build 0.2 0.2 0.0 0.3 0.0
Discretionary – Play 1.5 0.4 -1.1 0.7 -1.8
Unpaid work 41.6 42.2 0.6 68.7 1.0
Unpaid work – Childcare 35.6 36.8 1.2 59.9 2.0
Discretionary – Social 0.7 1.7 1.0 2.8 1.7
Discretionary – Family 0.7 0.3 -0.4 0.5 -0.7
Sleep 36.9 33.5 -3.4 54.6 -5.6
Business – Connect 0.5 1.2 0.7 1.9 1.3
Business – Earn 0.3 1.2 0.9 2.0 1.5
Discretionary – Productive 6.5 6.5 -0.0 10.6 -0.0
Personal 11.1 12.7 1.5 20.6 2.6

Childcare’s a bit up and sleep is a bit down, but that’s probably influenced by the fact that I’ve improved my tracking system to allow me to capture more details for late-night feeds. I thought about breaking childcare down into subcategories (maybe stimulation, routine care, medical stuff, nursing, and other?), but I can handle that with notes instead of separate categories for now.

2016-05-02 Emacs News

Links from reddit.com/r/emacs, /r/orgmode, Hacker News, planet.emacsen.org, Youtube, the changes to the Emacs NEWS file, and emacs-devel.

Past Emacs News round-ups

Weekly review: Week ending April 29, 2016

This week felt like a good one for making progress in a variety of areas. =)

We’ve been learning a little more about A- and sleep. I don’t mind letting her sleep whenever she wants, even if it means she might be up at an awkward time. It’s easier to deal with a well-rested and curious A- than a cranky and overtired A-, anyway! I can manage the occasional middle-of-the-night fussing. When I’m too tired or if W-‘s going to be up anyway, A- spends time with W-.

I’ve been researching flight options and tips for super-long-haul travel. It looks like getting a separate seat for A- could be worth the cost. I’m not sure about taking care of her on my own for the ~22+ hours it takes to go from Toronto to Manila, so any trips may have to wait until either W- files for parental leave or gets more vacation days next year. Anyway, we need more information about her medical needs first before I’d feel comfortable planning any travel. Hard to plan with all these uncertainties!

Speaking of medical stuff – after lots of research and calling, I’ve learned that our current situation (having a pediatrician) is actually pretty awesome and that it can be difficult to “shop around,” so we’ll probably stick with what we have. I got on the waitlist to switch my family doctor relationship to someone closer, though, in case I can find a good fit. We’ll find out more about A-‘s heart and eye in June. In the meantime, May will be busy enough with breastfeeding clinic follow-ups, routine vaccinations, and a visit from a nurse in the Healthy Babies Healthy Children program. (Talk to all the support organizations!)

I spent some time consulting, too. I finally figured out how to animate data in d3 by working on my personal visualization of baby data, so I felt ready to transfer that knowledge to visualizations of client data. Building up the skills on my own time meant I didn’t feel guilty about charging my client for fuzzy-brain-learning-time. =) I’m looking forward to tweaking the visualizations based on their feedback, and building some more.

Since I’m doing all this stuff at home and outside, I decided to leave Hacklab. I really like the community, but I didn’t think I’d make it out there often enough to justify the membership. I wasn’t quite sure I could make the most of the space while also taking care of a baby. It’s easier to code or sew at home, where I’ve got everything I need for A- and where W- can take care of her if I need to focus on something. I’d been mentally treating my Hacklab membership as more like a donation to support something I like. Now that Hacklab’s finances are more solid, I can turn that money to other uses. I might consider rejoining it if I figure out how to make it work, as volunteering to help make Tuesday open house dinners was lots of fun.

Slowly sorting out new routines. Yay! =)

2016-05-02a Week ending 2016-04-29 -- index card #journal #weekly output

Blog posts

Sketches

Focus areas and time review

  • Business (9.5h – 5%)
    • Earn (8.9h – 92% of Business)
      • ☑ [#A] Prepare invoice
      • ☐ Earn: E1: 1-2 days of consulting
    • Build (0.4h – 4% of Business)
      • Drawing (0.0h)
      • Paperwork (0.4h)
        • ☑ Check if I need to amend T5
        • ☑ Transfer from savings
        • ☑ Issue and print resolution
        • ☑ Write and deposit cheque
        • ☑ File dividend in Quickbooks
    • Connect (0.3h – 2% of Business)
      • ☑ Retrieve my things
  • Relationships (4.1h – 2%)
    • ☐ Take A- for vaccinations
    • ☐ Call TD and ask about RESP
    • ☑ Check with OHIP re name change
    • ☑ Braindump notes for flight
  • Discretionary – Productive (10.2h – 6%)
    • Emacs (0.6h – 0% of all)
      • ☑ Do another Emacs News review
    • Coding
      • ☑ Apply d3 update to histogram
      • ☑ Save last activity when we start nursing
      • ☑ Go to W-‘s extended family thing
      • ☑ Disable touchpad in init script
      • ☑ Fiddle with image composition
      • ☑ Figure out why ssh was asking for passphrase
      • ☑ Radial tree for status
      • ☑ Figure out what’s going on with BEGIN_HTML
      • ☑ Set up Tasker to forward to home phone when I’m on home wifi
    • Sewing (1.4h)
      • ☑ Peasant top
    • Writing (0.0h)
  • Discretionary – Play (0.0h – 0%)
  • Personal routines (15.4h – 9%)
  • Unpaid work (69.8h – 41%)
    • Childcare (62.4h – 37% of total)
  • Sleep (59.0h – 35% – average of 8.4 per day)

2016-04-25 Emacs News

Links from reddit.com/r/emacs, /r/orgmode, Hacker News, planet.emacsen.org, Youtube, the changes to the Emacs NEWS file, and emacs-devel.

Past Emacs News round-ups

Weekly review: Week ending April 22, 2016

Lots of medical-related conversations this week. I called the eye clinic to follow up on A-‘s timeline. She’s scheduled for an impression under general anesthesia in June. I also called the cardiologist’s office to ask about her slow wealthweight gain, and they recommended seeing the pediatrician earlier than our scheduled appointment. We saw the pediatrician, and she isn’t worried about A- yet (she’s in the 25th percentile for length and weight). A- was definitely not happy about the physical exam, though, and the vaccine injections didn’t help. She was a bit fussier for two days, and now she seems back to normal. We’ll see the pediatrician again in two weeks for another vaccine and another weighing. Sometimes I wonder if I should also be building up a record for A- at home, but since it doesn’t seem easy to get a copy of medical notes, I guess I’ll have to leave that up to her primary care provider.

The downside of all this phoning around was that I’ve been stuck playing an embarrassing game of phone tag. I’m currently looking around for more options in terms of pediatricians or family doctors in case I can find someone with excellent rapport. I forgot that I had meeting assist turned on and plenty of optional activities on my calendar, so I missed a few calls. I’ve set up call forwarding and I’m experimenting with a free service that provides voicemail (fongo.com), so we’ll see if that helps.

It was a good week for cooking variety. I prepared lots of ingredients last weekend for Cobb salad and an assortment of burger toppings, and we turned leftovers into pizza. I like this new habit we’re building. Cutting up ingredients in advance makes complex meals easier to throw together.

We took advantage of the warm and sunny spring weather to rake the yard and start the garden. The strawberries and sorrel have already started coming back. I planted some peas, bitter melon, and coriander. Maybe in a week or two, when frost becomes much less likely, I’ll buy a few cherry tomato starters. I wonder if I can get lettuce and spinach growing this year, or if there are other things I can grow for salads and herbs.

I joined the babywearing walk in High Park, but bailed halfway through because A- was getting a bit fussy. Good timing, actually, as she had one of those big poops when I got home. It’s starting to become hat weather, too. I tried making her a hat, but the dome was too shallow and the brim wasn’t stiff enough. Fortunately, I have lots of spare fabric, so I can just try again. I’ll probably start by trying a stiffer brim.

Quite a few other social things, too. W-‘s mom brought some soup over, and I visited Jen, Ewan, and E-. Lola and Lolo also virtually dropped in via Facebook video calling, and A- cooed at them for a while. =)

I took some time to systematically think about kaizen: continuous, small improvements. One of the little improvements I’ve been planning was making Emacs survive X freezes a little more gracefully. I got emacs --daemon working on my system and I managed to write a blog post about it. Hooray for being able to tinker! I also tweaked my tracker a little bit more. Now that I save the state on the server, I can use other apps without worrying about losing the start of my nursing timer, which means I can read stuff in Google Play Books or Overdrive while nursing. Yay!

Also, while updating some paperwork, I noticed that I’d used a 25% gross up rate instead of 18% for the past two years. It turns out that there’s a straightforward web interface for updating both T5s and personal tax returns. Yay Canada Revenue Agency!

I’ll probably pull back a little on social things next week as I sort out communications and return various calls, although I’d like to make it out to the Hacklab members’ meeting on Wednesday.

Slowly making things better!

2016-04-24a Week ending 2016-04-22 -- index card #journal #weekly

output

Blog posts

Sketches

Focus areas and time review

  • Business (1.3h – 0%)
    • ☐ Pay myself a dividend
    • Earn (0.0h – 0% of Business)
    • Build (0.6h – 43% of Business)
      • Drawing (0.0h)
      • Paperwork (0.5h)
    • Connect (0.7h – 56% of Business)
  • Relationships (2.0h – 1%)
    • ☑ Take pictures of baby clothes from Jen
    • ☑ Have W-‘s mom over
    • ☑ Maybe check out babywearing social
    • A-
      • ☑ Ask breastfeeding clinic for other places that take patients
      • ☑ Call cardio nurse and ask about slow weight gain and possibly fortifying
      • ☑ Follow up with Eye Clinic
      • ☑ 2-month appointment with pediatrician
      • ☑ Call Four Villages
      • ☑ Call midwives and ask for other referrals
      • ☐ Call TD and ask about RESP
  • Discretionary – Productive (15.3h – 9%)
    • Coding
      • ☑ Plot baby weight
      • ☑ Add bath note
      • ☑ Add duration column
      • ☑ Label axis nicely
      • ☑ Set up search engine
      • ☑ Add ending now / after start buttons
      • ☑ Move nursing timer to database
    • Emacs (0.6h – 0% of all)
      • ☑ [#A] Do another Emacs News review
      • ☑ Keep Emacs alive through X crashes by running it in the background with –daemon
      • ☐ [#A] Do another Emacs News review
    • Gardening
      • ☑ Clean up yard
      • ☑ Plant peas
    • Kaizen
      • ☑ Set up home screen shortcuts to things I’m reading, or organize them in apps
      • ☑ Line up better reading on my phone
      • ☑ Normalize recorded audio
      • ☑ Think about phone
      • ☑ Disable touchpad in init script
    • Sewing (2.3h)
      • ☑ Look for a baby sun hat pattern
      • ☑ Go to Fabricland
    • Writing (2.3h)
  • Discretionary – Play (0.8h – 0%)
  • Personal routines (31.1h – 18%)
  • Unpaid work (58.5h – 34%)
    • Childcare (50.7h – 30% of total)
  • Sleep (59.7h – 35% – average of 8.5 per day)

Keep Emacs alive through X crashes by running it in the background with –daemon

I periodically have to kill and restart my X server when it freezes. I probably have the wrong configuration, since it starts off in low-graphics mode until I manually restart the graphical login manager (I’m using sddm). Anyway, since it’s been hard to debug and fix that issue, I figured I’d address the part that really bugs me when I restart X: dealing with ungraceful Emacs exits. M-x recover-session does a decent job of restoring my modified files and I usually remember to call it from the scratch screen, but sometimes I forget, and then I end up losing changes.

I started taking advantage of the fact that I used (server-start) to enable other Emacs clients to connect to the same process. Whenever I needed to restart X, I’d first switch to a console, use emacsclient -c to connect to Emacs, and use M-x save-buffers-kill-emacs to close my Emacs neatly. Still, starting my Emacs from X meant that I had to restart Emacs each time I restarted X.

It turns out that you can run Emacs as a background process with emacs --daemon and then connect to it with emacsclient -c. When I did that, though, the emacsclient frame didn’t have my color theme applied. This after-make-frame-functions addition fixes that:

(defun my/setup-color-theme ()
  (interactive)
  (color-theme-solarized-dark)
  (set-face-foreground 'secondary-selection "darkblue")
  (set-face-background 'secondary-selection "lightblue")
  (set-face-background 'font-lock-doc-face "black")
  (set-face-foreground 'font-lock-doc-face "wheat")
  (set-face-background 'font-lock-string-face "black")
  (set-face-foreground 'org-todo "green")
  (set-face-background 'org-todo "black"))
(add-hook 'after-make-frame-functions
          (lambda (frame)
            (select-frame frame)
            (my/setup-color-theme)))

Once I got emacs --daemon and emacsclient -c working to my satisfaction, I decided to go one step further and get it to run automatically when I start my computer. I tried the init script at https://www.emacswiki.org/emacs/EmacsAsDaemon . My Linux install uses systemd, so enabling the init script resulted in a message about a missing service file. I removed the init script and created this ~/.config/systemd/user/emacs.service instead:

[Unit]
Description=Emacs: the extensible, self-documenting text editor

[Service]
Type=forking
ExecStart=/usr/local/bin/emacs --daemon
ExecStop=/usr/local/bin/emacsclient --eval "(progn (setq kill-emacs-hook 'nil) (kill-emacs))"
Restart=always
TimeoutStartSec=0

[Install]
WantedBy=default.target

and then I ran these commands as my regular user account:

systemctl --user enable emacs
systemctl --user start emacs

Then I changed the emacs in my ~/.xsession to emacsclient -c, so that a new X session would connect to the existing session instead of starting a new one. That way, Emacs automatically started as my user whenever I restarted the computer, and I connected to that process when I started X.

Still, restarting X caused the Emacs daemon to crash. This is a GTK-related bug which emacs --daemon warns you about. I recompiled Emacs using ./configure --with-x-toolkit=lucid; make; make install. It seems to work fine now; I can ungracefully restart X, and my Emacs stays the same. Bonus: because Emacs gets initialized when I start my computer and all I need to do is connect to that process, when I log in, it feels like Emacs starts up really quickly.

Final touches: I noticed that TRAMP couldn’t find my SSH keyring, so it got stuck waiting for my passphrase when I tried running remote scripts in Org Babel like so:

#+begin_src sh :dir [email protected]:~
perl library-new.pl Business
#+end_src

Because my SSH socket looks like /tmp/ssh-BLAHBLAHBLAH/agent.PROCESSID, the SSH_AUTH_SOCK setting (Environment=SSH_AUTH_SOCK=%t/keyring/ssh) described on EmacsWiki didn’t work for me. This snippet from https://github.com/nhoffman/.emacs.d/blob/master/init.org worked, though.

(defun my/ssh-refresh ()
  "Reset the environment variable SSH_AUTH_SOCK"
  (interactive)
  (let (ssh-auth-sock-old (getenv "SSH_AUTH_SOCK"))
    (setenv "SSH_AUTH_SOCK"
            (car (split-string
                  (shell-command-to-string
                   "ls -t $(find /tmp/ssh-* -user $USER -name 'agent.*' 2> /dev/null)"))))
    (message
     (format "SSH_AUTH_SOCK %s --> %s"
             ssh-auth-sock-old (getenv "SSH_AUTH_SOCK")))))
(my/ssh-refresh)

Also, emacs --daemon didn’t pick up the default browser I’d configured in KDE. Opening URL links from Org Mode started a separate Chromium process instead of using Google Chrome. I fixed that by switching from browse-url-default-browser to browse-url-generic, like so:

(setq browse-url-generic-program "google-chrome")
(setq browse-url-browser-function 'browse-url-generic)

Let’s see how this works!