With USC losing to Utah, we are one TCU loss away from a Big10 vs. SEC show down in the college football playoffs.
Welcome to My Blog.
Here, you will find posts, links, and more about code (primarily Ruby), business (bootstrapped SaaS), and a little of everything in between.
I have not had much use for Sizzy in while, but fired it up today and was instantly re-impressed. One of the more indispensable tools for frontend web development.
Friday Five: Getting Fit in 2023
Below is roughly what I have done for the last 500 or so days. I lucked into this progression, but I am hoping it will help others in the future.
-
Start today. Do not wait until January 1, your birthday, etc. Just start.
-
Start simple. I recommend committing to a daily walk for a couple of weeks. One 20-minute per day is plenty. You can not commit to 20 minutes? How about a 10-minute walk after lunch and dinner? Don't worry about a gym membership, a new diet, etc., for the first couple of weeks. Focus on moving more and more for a couple of weeks.
-
Pick a diet that works for you. Low calorie, or low/no-carb, keto, Mediterranean, whatever. Chances are any remotely sensible diet is an improvement over the typical (especially American) diet.
-
After a couple of weeks of moving and eating better, find some exercise you enjoy. The exercise could be playing a sport, riding a bike, lifting weights, etc. Remember, you do not have to love the activity, but it should be something you can stick with for a while.
-
Most importantly, be consistent. You do not have to be perfect. We all slip up from time to time or need a break. That's not a problem. Your goal (hopefully) is not to achieve some arbitrary data point. Instead, it should be to improve your long-term health. In a perfect world, you can continue at this for the rest of your life. Treat it like a journey and not some kind of destination.
I could go on and on about this. Each point could easily be another post. But with the new year approaching, I wanted to get something like this out there ASAP.
Once eating better, consistent movement and exercise becomes staples of your daily routine, it is far easier to tune them (and experiment).
Quick Hat Tip: I am very much riffing on Tim Ferris's 5 Bullet Friday. It is excellent and you should check it out.
Why Micro.Blog
Before I settled on Micro.Blog, here is what I considered:
Writing my Own - many developers build to-do list apps. I build blogging apps. There is a flow and experience I would like to get to. I may revisit the idea if I can get myself back into consistently writing. However, there are plenty of other things I want to build. The features I would like to be different in Micro.Blog are not my obstacle.
**blogstatic **- Looks promising but a bit overly simple for my goals. The inability to write posts without titles and no markdown support were dealbreakers. Built-in newsletters are great, and it does have a very clean interface. If you like WYSIWYG writing, you may want to check it out. The other gotcha is the $19/year price point. It feels a bit unsustainable.
WordPress - never the answer for me.
Static sites generator - Choose your favorite (mine is Eleventy , and I want to spend some time with Bridgetown. For longer-form writing with lots of images/charts/etc, this is where I would go. However, for short, consistent writing, it has become an obstacle.
Tumblr - I thought this was where I was going to go. From afar, it has the features I want, but it feels like a hot mess these days, and the ads are too in your face. I am OK paying to remove the ads, but as far as I can tell, I can only stop myself from seeing ads and only some people visiting my site. If you need a sizeable built-in community to keep you writing, check them out.
Mastodon is certainly more friendly today than Twitter, but it still suffers from your content being completely siloed in someone else’s content world. I am also concerned about the long time viability of each community. Twitter has a lousy business model today. Thousands of mini-Twitters are not going to do any better. Syncing content to Mastodon feels like the better long term answer than just writing there.
Post.news looks interesting, but I do not see how this is any different long term than Twitter/etc.
On to why Micro.Blog
-
You can write short or long pieces. Titles are optional, and posts can be syndicated to Twitter and Mastodon. Even better, they look like Tweets if they are small enough.
-
Clean and straightforward interface with native tools for both iOS and OS X. Full markdown support, my URL, and more.
-
If, for some reason, Micro.Blog goes away; it looks like with some minor tinkering, I could be up and running on Hugo
-
It is not free but not overly expensive. I went with the $ 10-a-month plan. I doubt I need much from podcasting or videos, but it is nice to have them and be able to support the tools I plan on using.
Bare Metal FizzBuzz
If I were deploying this somewhere, I would lean towards something that looks more like the readable_solution
below.
But for the sake of the challenge:
def solution(number)
"#{"Fizz" if (number % 3).zero?}#{"Buzz" if (number % 5).zero?}"
end
raise unless solution(3) == "Fizz"
raise unless solution(5) == "Buzz"
raise unless solution(15) == "FizzBuzz"
puts "It works!"
If this were a one-liner competition, I would like my chances. 😄
def readable_solution(number)
modulo_3 = (number % 3).zero?
modulo_5 = (number % 5).zero?
if modulo_3 && modulo_5
"FizzBuzz"
elsif modulo_3
"Fizz"
elsif modulo_5
"Buzz"
end
end
Today I Learned: You can split a string in Ruby and request an array with a maximum number of values.
Example:
img_url = “d3aa8b1gak9v1d.cloudfront.net/assets/1/640d75f6-c607-4825-b23e-c4bd0e283c42/xwzxe02c76m3oxo00gil/mac-os-xspaces-options.png”
bucket, file_path = img_url.split(“/“, 2)
This will populate bucket with d3aa8b1gak9v1d.cloudfront.net
and put the rest of the string in file_path.
Full Details: https://ruby-doc.org/core-3.1.2/String.html#method-i-split
I was convinced there was a bug with OS X Spaces on Ventura or Command-Tab Plus. My spaces were constantly not what I remembered.
Turns out, I forgot to enable this option which keeps them from moving around.
I have seen and generated plenty of errors over the past 20+ years on software development, but this is the first I have seen this one.
Hanging out at Micro.blog
I have been experimenting a some Twitter alternatives and for now I have settled on Micro.blog.
Micro.blog has a good mix of simple features and nice apps that I hope over time will let me get back into more writing and sharing.
My old site is still available and will be used for longer forms of writing (if/when I can convince myself to do so).
I also set up a Mastodon account at https://ruby.social.com/@scottw (well, technically, I have had one for years :))
Is this thing on?