This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudoedit /etc/apt/apt.conf.d/50unattended-upgrades | |
Aktivera följande rader (ta bort "//") | |
Unattended-Upgrade::AutoFixInterruptedDpkg "true"; | |
Unattended-Upgrade::MinimalSteps "true"; | |
Unattended-Upgrade::InstallOnShutdown "false"; | |
Unattended-Upgrade::Remove-Unused-Kernel-Packages "true"; | |
Unattended-Upgrade::Remove-New-Unused-Dependencies "true"; | |
Unattended-Upgrade::Remove-Unused-Dependencies "false"; | |
Unattended-Upgrade::Automatic-Reboot-WithUsers "true"; | |
Aktivera och ändra följande rader (ta bort "//" och ändra inställningen) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Feather serial port forwarder | |
[Service] | |
ExecStart=socat TCP-LISTEN:55232,fork /dev/feather,rawer | |
[Install] | |
WantedBy=default.target |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> from firmware import hotp | |
>>> secret = b"12345678901234567890" | |
>>> for i in range(3): | |
... print(hotp(secret, i)) | |
... | |
755224 | |
287082 | |
359152 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
if (( $# != 1 )); then | |
echo "Usage: $0 <session-name>" | |
exit 1 | |
fi | |
session_name="$1" | |
shift |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# INSTALLING (Running the meter poller as a user service) | |
# Put the script in ~/.local/bin/run_in_loop.sh (and make it executable) and the service description in ~.config/systemd/user/meter-poller.service . | |
# Allow your user to run service while not logged in (only needed once this computer) | |
sudo loginctl enable-linger $USER | |
# Tell systemd to start meter-poller.service at boot (done by installing symlinks) | |
systemctl --user enable meter-poller.service |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=tmux - Terminal Multiplexer Server | |
[Service] | |
Type=forking | |
ExecStartPre=/usr/bin/grep -qs "set-option -s exit-empty off" %h/.tmux.conf | |
ExecStart=/usr/bin/tmux start-server | |
ExecStop=/usr/bin/tmux kill-server | |
Restart=on-failure |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ 12.372028] ata5: softreset failed (device not ready) | |
[ 22.400066] ata5: softreset failed (device not ready) | |
[ 22.705854] rfkill: input handler enabled | |
[ 26.126282] rfkill: input handler disabled | |
[ 32.943984] ata5: link is slow to respond, please be patient (ready=0) | |
[ 56.924278] ata5: SATA link up 3.0 Gbps (SStatus 123 SControl 300) | |
[ 61.940151] ata5.00: qc timeout (cmd 0xec) | |
[ 61.940213] ata5.00: failed to IDENTIFY (I/O error, err_mask=0x5) | |
[ 71.955985] ata5: softreset failed (device not ready) | |
[ 81.967574] ata5: softreset failed (device not ready) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Start Weechat in a screen at boot | |
[Service] | |
ExecStart=/usr/bin/screen -D -m -S weechat -U weechat | |
# -D -m Start detached, do not fork | |
# -S weechat Set name of session to "weechat" | |
# -U UTF-8 mode | |
# weechat Command to run |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <avr/io.h> | |
#include <util/delay.h> | |
#include <stdbool.h> | |
#include <stdint.h> | |
#define IR_FREQ 38000uL | |
#define IR_ADDRESS 0x00u | |
#define IR_DATA_ON 0x80u | |
#define IR_DATA_OFF 0x90u |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "Keyboard.h" | |
void setup() { | |
pinMode(6, INPUT_PULLUP); | |
pinMode(13, OUTPUT); | |
Keyboard.begin(); | |
} | |
void loop() { | |
waitForStart(); |