Author Archives: bullgare

golang banchmarks with benchstat

Here I will show how to run a benchmark in go1.24 and compare 2 implementations.

Cheapest VPS hostings (could be suitable for VPN)

https://lowendbox.com/blog/1-vps-1-usd-vps-per-month/

Improve your MacOS experience while using external displays

A couple of apps: https://github.com/waydabber/BetterDisplay — free https://displaybuddy.app/ — about $20 for one license.

Install Mac OS from a flash stick

Useful links: https://www.macworld.com/article/671308/how-to-create-a-bootable-usb-macos-installer.html https://support.apple.com/en-us/101578 https://support.apple.com/en-us/102662 https://support.apple.com/en-us/102655 To create a bootable flash drive for a system that is not supported on your current system, you can use one of those: https://github.com/ninxsoft/Mist?tab=readme-ov-file (I prefer this one) and https://dortania.github.io/OpenCore-Legacy-Patcher/INSTALLER.html#downloading-the-installer

Go code reviews best practices

https://go.dev/wiki/CodeReviewComments https://google.github.io/styleguide/go/decisions

MacOS issue — a lot of purgeable disk space

I used to have an issue — about 300Gb of extra disk space occupied on my MacBook labeled as «pergeable» (on my MacOS Sonoma). There are a lot of suggestion on the internet, but only 2 of them worked for me. First, I synced my backups with 2 of my TimeMachines (one of them was …

Read more

Golang’s sync.Map internals

Great article on the topic — https://victoriametrics.com/blog/go-sync-map/index.html. The whole series of articles is solid, so please take a look if you are interested. Let me share the most important insights. How it works Internal structure is:

MVC, MVP, MVVM, MVVM-C, and VIPER architecture patterns comparison

Great diagram comparing MVC, MVP, MVVM, MVVM-C, and VIPER architecture patterns from ByteByteGo: They also provide the following description: — MVC, the oldest pattern, dates back almost 50 years — Every pattern has a «view» (V) responsible for displaying content and receiving user input — Most patterns include a «model» (M) to manage business data …

Read more

Cleanlinter — my first golang linter

I’ve implemented my first go linter, called cleanlinter — https://github.com/bullgare/cleanlinter. It’s a simplistic linter to check golang project internal imports according to Clean Architecture pattern. Installation

Usage

To be honest, writing proper integration tests made much more time than just writing the linter. Articles, discussions, examples that helped me: https://developer20.com/custom-go-linter/ https://stackoverflow.com/questions/72933175/go-get-filepath-from-ast-file https://github.com/bkielbasa/cyclop/blob/master/pkg/analyzer/analyzer.go https://github.com/alingse/asasalint/blob/main/asasalint_test.go

Heroes 3 on a Steam Deck

That’s how you install it: original — https://www.reddit.com/r/heroes3/comments/18xql2r/heroes_of_might_and_magic_iii_horn_of_the_abyss/ copy (better structured but a bit less detailed) — https://heroes3wog.net/steam-deck-installation-guide-heroes-iii-horn-of-the-abyss-v1-7/ That’s how you add a Jebus Outcast template — https://www.h3templates.com/templates/jebus-outcast.