Scala, Java, Unix, MacOS tutorials (page 2)

It was driving me crazy that the quality of the songs I was streaming from a website known as Bandcamp sounded better than the quality of the songs I was playing from my iTunes (now Music) collection. In my case, I recently bought a Marian Call CD named “Something Fierce”, and had imported the songs from that CD into iTunes. But the songs I streamed from Bandcamp sounded better than the songs I imported from the CD; how could this be?

I dug into the problem and found two simple fixes, both in iTunes. In this article I'll show you how to make those fixes to dramatically increase your iTunes sound/music quality.

I recently took an online “assessment” test with a company named SHL. In general it was good and interesting, but after thinking about it, one thing it really lacked was a concept of “context.”

For instance, one question was something like, “Are you comfortable talking to strangers?” Well, that depends on the context of the situation. In the context of being at a grocery store I generally have my earbuds in and leave strangers alone until I talk to the cashier, but in the context of work, I pretty much talk to everyone. Two different contexts, two totally different answers.

So as I’m answering the questions I keep asking myself, “What’s the context?” Unfortunately I didn’t share this at the end of the SHL test when they give you a little room to comment, so I thought I’d share that here in hopes someone there might see this.

As I wrote in Different meditation/mindfulness practices, different cultures, and they all talk about witnessing/noting, mindfulness and meditation masters (teachers) from different cultures, countries, and styles of practice often teach the same thing in different ways: a style of mindfulness meditation known as witnessing or noting.

To me, a simple way to think about this is that as your body goes along with its daily life, all you have to do is simply narrate what your body is doing at all times, in the present moment.

If you like, you can think of yourself as being the witness/soul, watching the body, and noting what it’s doing, like a birdwatcher does when they note what birds are doing in a forest. It’s that simple.

If you’re interested in logging in a ZIO application, the following example shows a collection of different ways you can write log messages. I also show how to create your own custom log format, so the output logging from this application looks like this:

I’m starting to publish my next free video course, called ZIO HTTP + Caliban. You can find it at that website, and it’s free, thanks to the people at Ziverge.

Free video training course: ZIO HTTP + Caliban

Here’s a comprehensive guide to implementing retry logic in ZIO 2 applications, using various scheduling strategies.

Please note that I haven’t double-checked that all of these examples compile as-is, but I do demonstrate many of these in my free Scala and ZIO 2 training videos. (I also added a complete working example at the end.)

“Enlightenment always comes after the road of thinking is blocked.”

Lindsey: Don’t tell me you’re seeing inside them again. (long pause) What are people like, on the inside?

Jeremy: Inside most people there’s a feeling of being separate, separated from everything.

Lindsey: And?

Jeremy: And they’re not. They’re part of absolutely everyone, and everything.

Lindsey: Everything? I’m part of this tree? Part of my dog barking over fences? You’re telling me that I’m part of some fisherman in Italy, on some ocean I’ve never even heard of? There’s some guy, sitting on death row, I’m part of him, too?

Jeremy: You don’t believe me.

Lindsey: It’s hard to believe that. All of that.

Jeremy: That’s because you have this spot that you can’t see past. (Putting his finger on her forehead.) My grams and gramps had it, a spot where they were taught they were disconnected from everything.

Lindsey: So that’s what they’d see if they could? That they’re connected?

Jeremy: And how beautiful they really are. And that there’s no need to hide, or lie. And that it’s possible to talk to someone without any lies, with no sarcasms, no deceptions, no exaggerations or any of the things that people use to confuse the truth.

~ a conversation from the movie Powder

“He’s more myself than I am. Whatever our souls are made of, his and mine are the same.”

“Goddamnit!”

Every so often a woman in a lucid dream this morning yelled out like that, so after the fourth or fifth time I had to ask her about it. “Why do you keep saying that?,” I asked.

“Gets your attention, doesn’t it?”

“Yeah, I guess so.”

“There you have it.”

“There I have what?”

“Your ego is writing checks your body can’t cash.”

~ from the movie, Top Gun

As a brief note today, here’s some skeleton code for a ZIO (ZIO 2) application that needs to run forever. It (a) does what it needs to do, then (b) sleeps for a minute, and then (c) goes back to Step A, doing whatever it needs to do, forever.

I wanted to share this code because I think it’s probably a very common pattern and need in the ZIO world — writing an application that needs to run forever, on a schedule.

Also note that the code is written using Scala 3, but the syntax can be changed to use Scala 2, if you need to. I also added a layer/ZLayer to the code to make it a little more “real world.”

All that being said, here’s the ZIO “run forever” code:

If you’re ever interested in meditation, I promise that if you work hard enough, you can achieve this kind of intensity, where you feel like Eleven in Stranger Things. I’m fortunate that it happens to me from time to time now.

As Ramana Maharshi said, “Proper meditation is so intense it doesn’t even allow thinking, ‘I am meditating.’”

Meditate like Eleven giving her all

This page contains a list of my favorite mindfulness quotes. Most of these are short, concise quotes that help bring me back to the present moment, and work well with my “Just Be” mobile app.

Update: I have replaced my Just Be application — which was written for Android only — with a new application I call Back To Now, which runs on both Android and iOS.

Background: Just Be

Just Be was a mobile mindfulness app that I created for Android users. This is what the reminders/notifications look like when you receive them on an Android phone or tablet:

Just Be, a mindfulness reminders app

I rarely listen to music from this century, but in late 2020 I became a fan of Let Me Love You Like a Woman, by Lana Del Rey.

Really, I don’t think I liked a new song from 2013 to 2020, and then in December, 2020, I had my radio on an “alternative music” station, and this song came on and it was like time just stopped.

The tv series Becker was one of my favorites back in the day, and I always wondered why it wasn’t available on DVD. I just looked, and it’s now available at Amazon, just released in 2018.

A favorite episode that helped me snap out of a personal funk was when Becker finally got to be with his long-lost love — a woman he pined for for many years. When he finally had a chance to reunite with her it turned out she was out-of-control-wild, crazy, ran up his credit card bill, and then took off.

In its own way, that episode helped me get over someone I had felt the same way about. It was like seeing a comedic version of your own life that turned out to be a great “slap in the face” moment for me.

(Some time after I wrote that last paragraph, I was able to spend more time with the woman I had those feelings for, and while it wasn’t quite that comedic, our time together helped me realize that this woman wasn’t the perfect human being I thought she was. She was still great, but with human flaws, just like the rest of us.)

Becker TV series now on DVD

“On one occasion of my own practice, nearing deep samadhi, I happened to notice that the stage of my mind was quietly turning and a new scene was appearing. In this new scene no wandering thought popped up its head; there was absolute stillness and silence, as if one had landed on the Moon.”

~ Zen Training

“I am in the world, but not concerned with the world. I am going through the marketplace, but not as a purchaser.”

~ Ram Dass, quoting Maharaji, quoting Kabir, in Miracle of Love, one of his best books

“You got the gift, but it looks like you’re waiting for something ... your next life, maybe.”

~ The Matrix

You got the gift, but it looks like you’re waiting for something ...