Scenario I have a bunch of Linux hosts to perform actions on. Updates, certificates, cleanup, you name it. I do all my work over “ssh” but for that to work the hosts must be trusted. Of course I can use “ssh-keyscan” to get the keys but my own “known_hosts” file gets pretty messed up when… Continue reading Automate with ssh
Get installed packages
Assuming one needs to setup a LAMP server identically to a existing machine and it is important that all the specific packages are installed in order to guarantee a stable execution of the application. the following command prints out a single line list of installed packages for the provided search terms: Just change “apache|mysql|php” (RegEx!)… Continue reading Get installed packages
Build your application outside your IDE
This is a short introduction into building applications like Visual Studio solutions, Gradle/Ant/Maven- or Makefile projects. What does building mean in general? Transfering your project from one state to another. This means for example one takes the source files and derives binaries from them or creating a pdf documentation from the contained markdown files. Thus… Continue reading Build your application outside your IDE
Get latest version from GitHub API
I am writing automated updaters for certain applications but I don’t want the update to be executed every day. Instead it should only run in case a new version is available. One key component to achieve this is to find out what the latest version is. If a software distributor is using GitHub and if… Continue reading Get latest version from GitHub API
Keeping credentials out of your project
Imaging you are working on a project that has database access, API access secured with tokens or uses other credentials that should not be stored in a version control system like git because it would allow everyone with access to get the credentials and access the systems. I’d like to show in a small example… Continue reading Keeping credentials out of your project
Migrating commits to open branch
I recently had the problem that I was accidentally working on a local branch that was tracking a protected remote branch. In simple words: I was working on the main branch but was not allowed to push to origin/main. This is a good thing because I see the main branch as stable and I would… Continue reading Migrating commits to open branch
Fix ssh Git connection against Azure DevOps
I recently had the issue against my on premise Azure DevOps server, that the clone via ssh would fail with the message: The error can look different depending on if you already have a configuration file for SSH or not. But in any case, if a error is thrown, it is likely that the keys… Continue reading Fix ssh Git connection against Azure DevOps
Easy PDF form parsing and data handling
Recently I got a employee registration form in “docx” format and I can only assume that after I wrote all my information into the form HR copied it from there into the corresponding system. I thought to myself: That could be done easier. So I wrote a SpringBoot application, that offers a downloadable PDF form… Continue reading Easy PDF form parsing and data handling
Apply changes to multiple development branches
Let’s assume you have a simplified agile development process like this one: During planing the version numbers are specified and during development branches (like “release/1.5.10”) are used to collect all changes developed in development branches (like “bugfix/reference/1.5.10” where “reference” stands for a ticket number, a short description or any other reference to a in depth… Continue reading Apply changes to multiple development branches
Using quotes in remote commands
In my previous tutorial I showed how to escape quotes in Bash and PowerShell commands. So far so good. Now what if you want to execute a Bash command via SSH from a PowerShell instance? Let’s start with the plain Bash command we want to execute: This executed on Bash includes a single quote in… Continue reading Using quotes in remote commands