I previously played around with MongoDB in a few containers. Recently, I tried IBM Db2 Community Edition and learnt a few new things about containers along the way. The challenge was rolling my own Db2 Data Server Manager container, working around the background process that the startup script kicks off.
I really don’t know how to explain today’s post. In short: I want to copy drawings and images out of Microsoft Office in PNG format. On macOS, copy-and-paste seems to prefer the TIFF format, resulting in large Office files. I’d rather the images be converted to PNG, preserving transparency but providing high compression. However, this is more complicated than it seems, because of limitations in Office and PowerPoint in particular...
Just sharing some Automator scripts I use for Touch Bar Quick Actions showcasing three different methods - using pre-defined Actions, using AppleScripts and using Shell scripts.
Starting with Windows 10 May 2019 update, there is a new Windows Sandbox feature, which, despite its name, is based on Windows Containers.
Most Mac users would use at least a few keyboard shortcuts (if not, check out Apple’s Mac Keyboard Shortcuts list), but here are a few additional key combinations that I find useful. These are less well-known and many are not in Apple’s list.
A few posts ago, I described how to set Dark Mode with the
prefs-color-scheme Media Query. The browser will detect the OS Dark Mode setting (set in the Windows Control Panel or macOS System Preferences) and use the appropriate CSS Media Query rule. But what if you want to programmatically set either Dark or Light mode irrespective of the OS setting?
Here’s are a few short tips - to toggle Dark Mode on macOS without opening System Preferences. Useful when designing your Dark Mode enabled web site using
prefers-color-shemeMedia Query, like I did.
For a while now, I’ve been posting about compiling Wine on macOS, starting with Wine 1.9 in October 2016, then automating the compile for Wine 2.9 32-bit in May 2017. Now it’s July 2019, and this is probably my last post on the subject - a fully automated script to download and compile Wine 4.12.1 (released 7 July 2019) 32-bit and 64-bit on macOS.
Dark Mode is all the rage with desktop and mobile OS’es right now. Interestingly, modern browsers can detect the OS dark mode preference, and use a different set of CSS styles respectively for light or dark modes! Here’s how I updated My custom Grav theme.
I recently wanted to test a web app written in Node.js and exposed via fixed port. The instructions asked me to install Node.js locally, which I resist! So, here is how I built my Docker container to run the code.
If you've had fun with Docker containers, I now introduce you to Kubernetes and wish you the best of luck. I'm still learning myself! I decided to install IBM Cloud Private Community Edition following the Installation guide at IBM's Knowledge Center.
If the preceding posts on Node.js and MongoDB have been too complex for you, let me introduce you to a simpler drag-and-drop “flow-editor,” Node-RED.. It was developed and open-sourced by IBM, and is now hosted by the OpenJS Foundation (the same foundation that hosts projects like jQuery, and Dojo). I’ve used Node-RED for quick prototypes and demos, as it’s easy to explain each step of the flow. It saves a lot of coding effort and reduces errors buy providing built-in and pre-built third-party “nodes”.
Previously, I described my development environment setup using Docker containers. I do it in a totally different way from most tutorials, which I don’t believe leverage containers and complicate things by having to build images for development.
Here I explain how I wire up (i.e. network) a few containers - a MongoDB database, a Mongo Express User Interface to manage the database, and a Node.js container using JSON Web Tokens (JWT) to authenticate users against the database.
My requirement is to do all development debugging in a container, so I am assured of consistent behaviour in any environment. I do not want to install Node.js or npm locally on my mac! I cannot be bothered to use a Makefile or Dockerfile to build images - this is only required in the final stage for production!
I’m usually quite pedantic when it comes to minimizing code and optimizing web page performance. I was a bit surprised to find that this blog’s page speed was far from ideal! Google PageSpeed Insights returned a very low score for this blog. Back when I started this blow, I must’ve neglected optimization, as I was too busy learning Grav, modifying my template, etc.
If, like me, you use Parallels Desktop Lite, then I have bad news for you. It's no longer free to run macOS or Linux, so DON'T update it if you still want to use it!