Skip to content

Instantly share code, notes, and snippets.

Avatar

Robert Fisher snltd

View GitHub Profile
View gist:edad5d2e7ddd5678b20684688723968b
$ uname -a
SunOS tornado 5.11 omnios-nfs-zone-9070d0fece i86pc i386 i86pc
$ pfecex pkg refresh
$ pfexec pkg update
$ pfexec pkg apply-hot-fix --be-name=nfs-zone https://hf.omnios.org/bloody/nfs-zone-20191018.p5p
$ pfexec reboot
After reboot, in the zone, created a ZFS dataset and
@snltd
snltd / challenge.rb
Created May 31, 2019
Friday challenge 2019-05-31
View challenge.rb
#!/usr/bin/env ruby
class String
def index
ord > 96 ? ord - 96 : ord - 64
end
def shift_by(other)
caser = ord > 96 ? :downcase : :upcase
i = self.index - other.index + 1
@snltd
snltd / gist:abb45854b1511e46fcc941f807804734
Last active Jan 17, 2019
Crystal does not run in an LX zone
View gist:abb45854b1511e46fcc941f807804734
$ uname -a
Linux 02fe7059-dc4d-4fea-d227-b846741ee4b3 4.3.0 BrandZ virtual linux x86_64 x86_64 x86_64 GNU/Linux
$ curl -sL "https://keybase.io/crystal/pgp_keys.asc" | sudo apt-key add -
$ echo "deb https://dist.crystal-lang.org/apt crystal main" | sudo tee /etc/apt/sources.list.d/crystal.list
$ sudo apt update
$ sudo apt install crystal
...
$ crystal
terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc