- Download the latest ISO from https://www.archlinux.org/download
sudo dd if=archlinux-2019.11.01-x86_64.iso of=/dev/sda bs=4M status=progress oflag=sync
- Boot the ISO
- IF and ONLY IF you have a 4k or some HiDPI screen and fonts are super super small
ls /usr/share/kbd/consolefonts
setfont latarcyrheb-sun32
ls /sys/firmware/efi/efivars
verifies we booted in UEFI
This file contains 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
type MyType interface { | |
DoSomething() | |
} | |
crashproof.GoWithArgs(func(args ...interface{}) { | |
if p, ok := args[0].(MyType); ok { | |
p.DoSomething() | |
} | |
}, myTypeInstance) |
This file contains 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
package main | |
import ( | |
crashproof "github.com/codemodify/systemkit-crashproof" | |
) | |
func main() { | |
// 1. Catch crashes | |
crashproof.ConcurrentCodeCrashCatcher = reportCrash | |
crashproof.RunAppAndCatchCrashes(func() { |
This file contains 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
package main | |
import ( | |
"runtime/debug" | |
) | |
func main() { | |
// 1. set app crash handler | |
defer appCrashCatcher() | |
This file contains 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
package main | |
import ( | |
"encoding/json" | |
"errors" | |
"fmt" | |
"log" | |
"strings" | |
) |
This file contains 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
package main | |
import ( | |
"encoding/json" | |
"fmt" | |
"io/ioutil" | |
"log" | |
"net/http" | |
"sort" | |
) |
This file contains 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
# Do not turn off screen | |
sudo vi /etc/lightdm/lightdm.conf | |
# uncomment / add | |
xserver-command=X -s 0 dpms | |
This file contains 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
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' | |
} | |
parse_git_branch2() { git describe --contains --all HEAD 2>/dev/null; } | |
PS1="\n[\u | \d \@ | \e[38;0;41m\w\e[0m \e[30;1;47m\$(parse_git_branch)\e[0m] \n-> " |
This file contains 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
sudo curl https://raw.githubusercontent.com/codemodify/ArchLinux-Google-Titan-Security/master/1000-u2f.rules -o /etc/udev/rules.d/1000-u2f.rules | |
sudo udevadm control --reload |
This file contains 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
#import <Foundation/Foundation.h> | |
NSDictionary *headers = @{ @"Content-Type": @"application/json" }; | |
NSDictionary *parameters = @{ @"version": @"2.0", | |
@"key": @"rcd1JN+CkZo2+KKR802bXTujubMbiZARQcyTR8Ku8haqdyaz8pA8Z1kbrWJO2J2CiwFdnr", | |
@"gobSize": @10 }; | |
NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil]; |
NewerOlder