Git - Pushing Code to a Remote Computer

I needed to set up git for pushing into a non bare repo with a checked-out branch. Here is how I did it:
Read more →

Hugo, Asciidoctor & PlantUML

PlantUML is a great markup language for creating (not only) UML diagrams. Let’s try and make this tool work with Hugo + Asciidoc. Asciidoctor has an asciidoctor-diagram package in its toolset. This package should add support not only for PlantUML but also for GraphViz and other graphing markups. Cool. Asciidoctor-diagram was installed when setting up the platform, covered in the previous article If you try to add a simple PlantUML diagram now, you will probably get an empty picture.
Read more →

Spring (Boot) application.properties and Variables

Define an environment variable in environment export my_config=1337 To make a default value if the environment variable is not defined. application.properties 1 # Default value 2 my_config=666 3 4 # Take either a value from system environment or the default value. 5 my.config=${my_config} Consume the variable somewhere in the application. MyClass.java 1 @Component 2 public class MyClass { 3 @Value("${my.config}") 4 private int myValue; 5 6 // Consume myValue ad libitum 7 } Careful with the naming, it happened several times that I defined the default configuration with dot-notation and then the application did not work.
Read more →