Saturday, December 3, 2022

Friday, September 30, 2022

Intellij loose search for text in files

If you enable the "regex" option on the far right of the "find in files" dialog, you can enter things like "TODO .* master" and this will find all the lines with both TODO and master . Small trick which can really save your life.

Wednesday, August 10, 2022

SLF4J caveat on formatting

this will simply log NOTHING: in, the first parameter if it's a String it should be a formatting string, like "{}" .... if there is no format, nothing is logged.
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.util.Arrays;
import java.util.List;

public class TestClass {
    public static void main(String[] args) {
        TestClass testClass = new TestClass();

    public void test() {
        Logger log = LoggerFactory.getLogger(this.getClass());
        List<String> responses = Arrays.asList("pippo", "pluto");"", responses);