[SOLVED] Persistent switch (even after full reboot/shutdown)

Greetings,
i have been searching for the easiest way to make my own switch. Let’s say for vacation, to switch the surveilance mode or to lower the window blinds. The easyest that i could find is through MQTT.But i made easier

So i would like to share my solution (if i’m the first one :smiley: )

  - platform: command_line
    switches:
        switch1:
            command_on: "echo -e '1' > sw1.ini"
            command_off: "echo -e '0' > sw1.ini"
            command_state: "cat sw1.ini"
            value_template: "{{ value == '1' }}"