Skip to content

Instantly share code, notes, and snippets.

View mantono's full-sized avatar

Anton Österberg mantono

View GitHub Profile
@mantono
mantono / gist:a53538c834dcdf970cfdc315ec87dfd6
Created February 24, 2017 07:36
Install Intellij & Kotlin on Ubuntu
# Add ubuntu-make repo
sudo add-apt-repository ppa:ubuntu-desktop/ubuntu-make
sudo apt-get update
# Install ubuntu-make
sudo apt-get install ubuntu-make
#Install kotlin
umake kotlin
@mantono
mantono / gpg2_pass_ssh_github.txt
Last active January 26, 2023 12:25
GPG / SmartCard / Yubikey / pass in Ubuntu
# Ubuntu
sudo apt install libpam-yubico yubikey-personalization yubioath-desktop gnupg2 gnupg-agent pcscd libpcsclite1 opensc gpgsm
# Arch - https://wiki.archlinux.org/index.php/yubikey
pacman -S gnupg opensc yubico-c yubico-c-client yubico-pam yubikey-personalization yubikey-personalization-gui pcsc-tools
# Gentoo
# Use flag should be persisted in make.conf to keep this
USE="security-key smartcard" emerge yubikey-manager sys-auth/polkit sys-apps/dbus

Keybase proof

I hereby claim:

  • I am mantono on github.
  • I am mantono (https://keybase.io/mantono) on keybase.
  • I have a public key whose fingerprint is CCC9 3356 F7FC 9645 A926 9F98 B885 6A47 8477 6497

To claim this, I am signing this object:

@mantono
mantono / arch_install_guide.sh
Last active September 24, 2017 12:31
Install Arch - Basic commands adjusted for my need
#!/bin/zsh
# Set Swedish keymap
loadkeys sv-latin1
# Verfiy that we are using UEFI
ls /sys/firmware/efi/efivars
# Check that internet works
ping archlinux.org
@mantono
mantono / i3_move_workspaces.sh
Last active October 16, 2017 14:06
Move all i3 workspaces to connected monitor
#!/bin/bash
MONITORS=$(xrandr|grep -c " connected")
if [[ "$MONITORS" == 1 ]]
then
xrandr --output eDP-1 --primary
for i in {1..10}
do
i3-msg workspace $i
i3-msg move workspace to output $(xrandr|grep connected|grep -v disconnected|cut -d " " -f 1)
@mantono
mantono / disks
Created September 24, 2017 12:32
Disks/partitions fenchurch pre arch install
Filesystem Size Used Avail Use% Mounted on
udev 12G 0 12G 0% /dev
tmpfs 2,4G 34M 2,4G 2% /run
/dev/sde1 52G 35G 14G 72% /
tmpfs 12G 64M 12G 1% /dev/shm
tmpfs 5,0M 4,0K 5,0M 1% /run/lock
tmpfs 12G 0 12G 0% /sys/fs/cgroup
/dev/sdf1 55G 42G 12G 78% /home
/dev/sdg1 917G 539G 374G 60% /media/bilder1
/dev/sdh1 917G 507G 406G 56% /media/bilder1_
@mantono
mantono / aur
Created October 16, 2017 20:16
Stupid simple way of installing packages from https://aur.archlinux.org/
#!/bin/bash -l
/etc/profile.d/perlbin.sh # Maybe not needed
cd /tmp &&
git clone --progress https://aur.archlinux.org/$1.git
cd $1 &&
makepkg -si
@mantono
mantono / lsmod
Created March 13, 2018 09:24
Dell XPS 13 - Hardware devices
Module Size Used by
btusb 45056 0
btrtl 16384 1 btusb
xt_nat 16384 34
xt_tcpudp 16384 38
veth 16384 0
qmi_wwan 32768 0
uas 24576 0
cdc_wdm 20480 1 qmi_wwan
usbnet 45056 1 qmi_wwan
[[auth_providers]]
name = "open-broker-integrations"
type = "basic_auth"
[auth_providers.basic_auth_users]
good-cash-se = "3df8232404be55d2d6b85be79b99316e028676b69efa2ce91d9094dd18dd3502"
collector-se = "c45441cb346b69e247711e9c86405ce9de964bb89c68ad02b8eb2f55912c58ba"
lendify-se = "abb9eca0af80e9f321af97b2952ca035edfdc63d5118299e32047156339955b3"
[[auth_providers]]
name = "internal-auth"
#!/bin/sh
cd ~/code/zensum
ALL_CONF=$(echo $(find . -maxdepth 2 -name "docker-compose.yml" -exec ls "{}" \;|egrep -v '(dev-env/|meta/)'|sed 's/^/-f ./'))
cd dev-env &&
docker-compose $ALL_CONF -f docker-compose.yml --project-directory . $*