Git push all tags from a local repository

I use temporary branches and permanent tags in my Git repos.  This post demonstrates how to create a “y-shaped” local repository with no remotes and then push all tags from that local repository to a new bare remote.

  • mkdir local
  • cd local
  • git init
  • echo "dummy text" > abc.txt
  • git add abc.txt
  • git commit -m "Add first file"
  • echo "more text" >> abc.txt
  • git commit -a -m "Mod first file"
  • git tag tagA
  • git log (note the SHA1 for the first commit)
  • git checkout <SHA1 of first commit> -B master
  • echo "different second line" >> abc.txt
  • git commit -a -m "Take things in a different direction"
  • git tag tagB
  • git checkout <SHA1 of first commit> -B master

Here’s what the “y-shaped” local repo looks like in gitk --all:

Continue reading “Git push all tags from a local repository”

Cat 5e fan switch prep

Note: I neither receive nor seek affiliate commissions for any of the tools used in this post. I chose these tools based on favorable reviews from other customers.

I’m not a network engineer, and I don’t regularly crimp Ethernet cables, although I’ve done it successfully in the past. I needed two RJ45 connectors installed at either end of a Cat 5e cable that my electrician ran for a fan I’m installing in my garage. Especially if you do this job infrequently like me, I recommend practicing and testing crimps before doing the real job. Hat tip Switched On Network for the excellent guide on crimping Cat 5e with standard RJ45 plugs.

tools for the job
Continue reading “Cat 5e fan switch prep”

installing Catch2 v3 to the system

I previously struggled with this, because I was failing to properly use Catch2’s top level CMakeLists.txt file. These exact steps worked for me from WSL2:

  1. wget https://github.com/catchorg/Catch2/archive/refs/tags/v3.4.0.tar.gz
  2. tar xf v3.4.0.tar.gz
  3. cmake -S ./Catch2-3.4.0 -B ./build
  4. cmake --build ./build
  5. cmake --install ./build --prefix /some/install/directory

Windows Console app from VS Code using WSL 2 and CMake

I have the following already installed:

ToolVersion
Visual Studio Code1.81.1
MSVC19.37.32822 for x64
WSL 2
CMake3.26.4-msvc4
Visual Studio2022
  1. From Windows Terminal, open “Developer PowerShell for VS 2022”
  2. cd to desired project directory, e.g. cd \temp
  3. code . (must do it this way to pick up VS 2022’s cl.exe and cmake.exe)
  4. new folder src
  5. under src, put a simple hello.cpp file that outputs to stdout
  6. also under src, put simplest possible CMakeLists.txt file:
    cmake_minimum_required(VERSION 3.14)

    project(hello LANGUAGES CXX)

    add_executable(hello hello.cpp)
  7. from WSL 2 terminal in VS Code:
    cmake.exe -S ./src -B ./build
    cmake.exe --build ./build

Git unrelated histories

My team presented me with a Git learning opportunity last week. I didn’t know it before, but multiple unrelated Git histories can be mingled easily (like it or not). Here’s one way:

  1. First repo in wanted
  2. Second repo in unwanted
  3. Inside wanted working area, create an undesirable remote:
    git remote add unwanted ../unwanted
  4. git fetch --tags

That’s it! Now your wanted repo is polluted with unwanted‘s history.

Continue reading “Git unrelated histories”

bullshit by any other name

For your aromatic “delight”, I’ve arranged a charcuterie board of flavors you’re force-fed every single day in alphabetic order.

happy bullshit
  • carbon capture – it’s what the 2023-era billionaire smarties like Bill Gates do. But plant trees? Well, just listen to Bill-science directly: “But I don’t use some of the less proven approaches. I don’t plant trees. […] I mean, are we the science people or are we the idiots? Which one do we want to be?” Trees capturing carbon is “less proven”. Stay hypnotized, people. It’s for the good of the planet, after all, and Bill’s private jet guilt.
  • carbon credit – a.k.a. “carbon offset“, a.k.a. a virtue signal purchased by very wealthy private jet types to voluntarily humble brag about their hypocrisy. The hot chicks on said private jets were wowed.
  • carbon footprint – carbon credits are used to offset your carbon footprint which moves all us carbon lifeform do-gooders towards a carbon neutral bullshitopia. Got it? That NatGeo link declares “it’s not clear how much weight we should put on [carbon footprints]”. Sounds sciency.
  • carbon neutral – very fashionable bullshit, circa 2007.
  • clean energy – the kind still hawked by IRS racketeering tools in 2023, damn the torpedoes, full speed ahead.
  • climate challenge – what the “climate grift” is called in polite company.
  • climate change – back in pristine times before the GOP existed, climate didn’t change. When dinosaurs roamed the earth, for example. Climate was always steady Eddie back in Dino’s day.
  • corporate responsibility and sustainability – because we want our “responsible” corporations – yo, they’re all around us today – to “sustain”. You know, keep the grift afloat.
  • diversity, equity, inclusion – all you gotta be is “diverse”. Merit? Bah. No, what you want for your life threatening illness is an “inclusive” brain surgeon.
  • environmental social governance – yes, add “governance” to the bullshit stew. That’ll spice it up.
  • global boiling – sorry about that, I just snot-laughed into my milk.
  • green energy – good. Chartreuse energy? Baaad. Anyway, that NASA link reassures the reader with “Though accurate at the time of publication, ” caveat, caveat, caveat.
  • legacy carbon – as opposed to the other kind.
  • peak oil – the greenies trying real hard to wish their big lies into existence.
  • renewable energy – as opposed to the other kind. How does this square with conservation of energy? Man, without this 13th century Dutch technology to save us, where would we be today?
  • sustainable company – wow, those windmills sure are “pretty“.
  • sustainable energy – perpetual motion is a thing, people. I swear. I saw it on YouTube.

I’m originally writing this in August 2023. Guaranteed many of the above links will break in the coming months as the cowardly grifters cover their tracks with “new” horse hockey. It’ll still smell the same, though.

acoustical isolation in the works

I just finished installing QuietPutty from atsacoustics.com (with which I have no affiliation) onto my outlet boxes and data conduit for my office remodel. The stuff is pretty easy to work with, cuts to size with regular scissors, and is only a minor inconvenience for cleanup. The putty leaves a greasy residue on your hands which I removed using dishwasher soap and a bit of persistence.

Continue reading “acoustical isolation in the works”

modern age, meet iron age

A third party vendor doesn’t have the same vested interest as you to properly destroy end-of-life data infrastructure. Industrial hardware shredders, acid baths, compactors, and incinerators are dangerous, expensive, and highly regulated. You need a simpler, yet still safe defense-in-depth method for asset destruction “in the small”.

Photo 37485127 | Hard Drive Destruction © Kewuwu | Dreamstime.com
two eras collide

Keep reading for the steps I use for occasional sensitive data hardware destruction…

Continue reading “modern age, meet iron age”

“tell me true, tell me why…”*

Take your latest paycheck. For that week, two weeks, whatever, take the Federal withholding. Add the Social Security withholding. Then add the Medicare withholding. Look at that total. Just look at it. Now remember that the US Federal debt is currently $23.2 trillion, which given a current US population of 329 million is $70,517 in historically epic spendclownery per American.

keep ’em locked

Look me in the eye. Check that, I can’t see squat, my cataracts are still in for another couple weeks. Look your kid in the eye. Don’t tell me, tell your kid that one about how we “don’t pay our fair share.” Then tell your kid how that’s the problem. Good luck with that.

* post title comes from Pink Floyd’s “The Post War Dream”

easily track car maintenance

Newsflash: cars are really expensive these days. Take care of the car you’ve already got by tracking its critical maintenance items in a simple spreadsheet. My wife and I have 4 cars with a total of over 800K miles on them. My oldest car will trip 300K miles very soon, and it’s still going strong.

get a good mechanic

Use a mechanic you trust, and spread the word among your local friends and family to bring that mechanic lots of good business. Keep in mind: your mechanic hones skill in physical and electrical vehicle fixes and maintenance. Don’t expect your mechanic to track your maintenance schedule – you should manage that part of the job. You’re perfectly capable of reading the recommended maintenance schedule in your owner’s manual and bird dogging it.

Feel free to use the spreadsheet I built to track maintenance on our vehicles. I set it up with 3 tabs per vehicle:

  1. History – past fixes to your car
  2. Schedule – planned maintenance schedule
  3. Instruction – sheet to print/hand to your mechanic

Optionally, the schedule tab is set up to allow slick “Advanced Filter” usage. Don’t be intimidated by “Advanced” in the name, it’s not that hard. Here are good Excel and LibreOffice Calc instructions.

Take good care of your girl!