<supersandro2000>
DigitalKiwi: you mean ycombinator news?
<DigitalKiwi>
orange site
<DigitalKiwi>
export PS1="\[\033[95m\]\u@\h \[\033[32m\]\W\[\033[33m\] [\$(git symbolic-ref --short HEAD 2>/dev/null)]\[\033[00m\]\$ "
<DigitalKiwi>
that one would probably be more of a problem but i don't notice it either :P
<DigitalKiwi>
...the one that gets me is i have a script that gets interrupted when gpg-agent hasn't been fed a passphrase in a while for this script i have running...
<DigitalKiwi>
gchristensen: i don't know haskell well enough to write all of the things i write with bash but i don't know bash well enough to write all of the things i do without shellcheck lol
<gchristensen>
:)
<danderson>
gchristensen: you're not alone - what kind of ephemeral identity?
<DigitalKiwi>
you it would be a lot easier for me to convince people haskell is used by people for anything other than compilers (and without resorting to the "everything's a compiler" angle) if people wouldn't write so many compilers :P
<DigitalKiwi>
you know* it would..
<samueldr>
maybe you could compile a convicing argument?
<DigitalKiwi>
like on my blog?
<samueldr>
I was only joking because of `compiling`:)
<DigitalKiwi>
my website is a compiler :(
<aaronjanse>
!?
<aaronjanse>
How?
<samueldr>
I guess it compiles a log of all visits?
<DigitalKiwi>
it's in nixpkgs. now it is anyway. wasn't when i started using nixos so i added it. took me months lol :(
<samueldr>
fun thing: my voip provider handles fax, if I configure it for
<samueldr>
I could, if I desired so, make a thing where you SMS a number, and it faxes back something... and I just realized how useless it would be because most numbers sending SMS can't handle faxes
<siraben>
DigitalKiwi: haha it's just so easy to write compilers and interpreters in Haskell!
waleee-cl has quit [Quit: Connection closed for inactivity]
evanjs has quit [Ping timeout: 240 seconds]
maljub01 has quit [Quit: maljub01]
evanjs has joined #nixos-chat
<DigitalKiwi>
ldlework: did you learn monads from uncle bob? lol no wonder you had trouble with haskell he doesn't know wtf he's talking about >.>
<ldlework>
DigitalKiwi, are you have a bad day?
<DigitalKiwi>
not particularly why
<DigitalKiwi>
having a bad year but today wasn't too bad...
<ashkitten>
samueldr: augh i still haven't done the thing to send/receive fax on phones
<ashkitten>
does ofono have a good api i could use for that
<samueldr>
if you said something about it beforehand, I probably forgot about it
<ashkitten>
probably not
maljub01 has joined #nixos-chat
<aaronjanse>
Hmm my disk IO mystery has escalated. I'm now writing ~100 GB/disk per day according to smartmontools, and I have no idea why
tomberek has quit [Ping timeout: 240 seconds]
<DigitalKiwi>
aaronjanse: what fs?
<DigitalKiwi>
do you have snapshotting ?
<aaronjanse>
ZFS. I do not have snapshotting
<DigitalKiwi>
oh, i have zfs, disk filled up on me, never really did figure out what caused it...
<aaronjanse>
`sudo iotop` says systemd has written 164 GB to disk, followed by Firefox (2 GB). I don't know over what time frames these stats are
<aaronjanse>
`journalctl | wc -l` is only 41k lines since last week, so I don't think that's the issue
<siraben>
DigitalKiwi: where did ldlework say he was learning monads from uncle bob?
<siraben>
uncle bob's understanding of FP concepts is... sketchy at best in general
<ldlework>
i never did, he randomly spewed that line as a reaction to someone else not learning fp
<siraben>
uh huh
<ldlework>
someone in different place: "I'm gonna study OO", me: "Clean code, bob, etc", kiwi here, "what'dja learn monads from bob and that's why you can't!"
<ldlework>
perfect sense
<siraben>
in any case, monads are easy to explain if one knows what endofunctors and adjoints are (every adjunction gives rise to a monad), there's also various examples in math: closure operators, free/forgetful adjunction of groups/rings/algebras, double dualization of a vector space and so on
<DigitalKiwi>
that is not what i said at all
<siraben>
I used those examples to explain monads to someone recently and everything made sense
<siraben>
but otherwise... it's quite a far removed concept from programming, I guess promises are a good analog
<ldlework>
<DigitalKiwi> ldlework: did you learn monads from uncle bob? lol no wonder you had trouble with haskell he doesn't know wtf he's talking about >.>
<DigitalKiwi>
dude i can't even explain monads to someone lol but the thing is... i know that and i don't try to and that's fine. but uncle bob doesn't know wtf he's talking about and spews the most idiotic bullshit on twitter and people eat it up and it's caused many people a great deal of mislearning
<siraben>
indeed
<ldlework>
if you are learning to write OO code in the style of the Microsoft/Java ecosystem, it's completely cromulent pedagogy.
<siraben>
ugh, doesn't sound like a fit for me then :P
<siraben>
brb writing an AbstractVisitorFactoryBeanDelegate
<ldlework>
your strange, baffling mixture of someone else being recommended uncle bob in their journey to learn OO, with my difficulty to learn monads is unexplainable
<ldlework>
also something in the past..
<siraben>
yes, how did monads even arise in the first place here lol
<ldlework>
"someone in my perceptual vacinity is not learning FP so I will have an autistic reaction, combining topics that have nothing to do with each other, while jabbing my friend in public"
<DigitalKiwi>
and i got interested in haskell like...12 years ago and only within the last few years did i 'get' it enough to really do much... some people it clicks right away some people it doesn't. i knew half a dozen languages before i learned haskell so that probably didn't help.
<ldlework>
"in a completely different community"
<siraben>
DigitalKiwi: what did you write in Haskell?
<DigitalKiwi>
mostly i write bash ;p
<siraben>
for me, learning Haskell after Standard ML was pretty natural
<siraben>
it's just lazy ML with ad-hoc polymorphism
<ldlework>
Function programming just clicking for you, but you're certain some guy famous for knowing what he's talking about in a different domain has no idea what he's talking about in an even more foreign domain than the one you actively practice
<DigitalKiwi>
it did NOT just click for me
<siraben>
ldlework: who said that quote
<ldlework>
i'm characterizing the situation..
<ldlework>
not quoting an utterance
<siraben>
ah right, re bob
<DigitalKiwi>
ldlework: clean code was one of the first books i read lol
<DigitalKiwi>
i'm sure it has done me great harm
<ldlework>
that totally explains "uncle bob and monads" and you've totally avoiding having to address the baffling combination of them to dig me in another community
<DigitalKiwi>
i wasn't digging you
<ldlework>
haha no wonder you're having a hard time you listen to idiots
<ldlework>
k
<DigitalKiwi>
??
endformationage has quit [Ping timeout: 260 seconds]
<siraben>
also I should just mention that deep understanding of the category theory behind monads is not necessary at all, I was just pointing out that the motivation is stronger in several areas of mathematics
<DigitalKiwi>
it's just an interface to me *shrug* i don
<DigitalKiwi>
't "know" monads...but i don't think that matters lol
<siraben>
yeah, of course.
<DigitalKiwi>
lots of languages have them they just call them different things the only reason it's scary is because it's a big math word and so much bullshit like fucking uncle bob spewing garbage takes that confuse people even more by giving them a bad understanding
<siraben>
cursed cycle: X person learns what a monad is (poorly), X proceeds to write a blog post or tweet about their incorrect understanding or analogy, repeat.
<aaronjanse>
This cycle is biting me
<DigitalKiwi>
siraben: yeah someone looked over it a while ago and gave a bunch of feedback but i haven't worked on it in a while
<aaronjanse>
I cannot tell to what extent I'm being bullshit-ed by blog posts
<siraben>
aaronjanse: how so?
cole-h has joined #nixos-chat
<aaronjanse>
I cannot evaluate to what extent blog posts are correct re monads
<aaronjanse>
My current understanding of monads is that they're kinda like Rust's `Option`, but higher-kinded and transforming between types like `Result::ok`??? But I'm fairly certain that this interpretation is missing *a lot*
<siraben>
it's like, many programers do not have the frame of reference to absorb the actual definition of a monad
<DigitalKiwi>
no no they're bash pipes! /s
<siraben>
so cling onto a poor analogy
<siraben>
DigitalKiwi: if you want i could try to explain haha
<siraben>
perhaps outside the channel to not clutter here
<aaronjanse>
I feel like I might need to understand the terms "functor" and "endofunctor" first
<siraben>
an endofunctor is just a functor from a category into itself
<siraben>
a functor can move between categories
<DigitalKiwi>
i think a lot of it is that people who are already programmers have to unlearn a lot
<siraben>
but in FP all functors are endofunctors pretty much
<aaronjanse>
Hmm. I don't think I have the background to evaluate any of this
<aaronjanse>
Ah, "a functor is a mapping between categories"
<siraben>
well you know the notion of mapping over lists/trees/a structure right?
<aaronjanse>
<siraben "an endofunctor is just a functor"> This makes sense now!
<aaronjanse>
Hmm I'm not sure what you're referring to, regarding a mapping over a tree/list/etc
<aaronjanse>
(I'm also willing to chat in DMs if people would prefer that we'd not talk here?)
<siraben>
A functor F from categories C to D is a mapping such that it assigns every object a ∈ C to an object F a ∈ D
<siraben>
yeah i'll continue there
<DigitalKiwi>
people who have no programming experience tend to have a much easier time. about the same difficultly level as python. middle schoolers learn it :P
<DigitalKiwi>
lmao If you are a more experienced developer with tooling set up, and you need a cabal file, shell.nix or stack.yaml to have working development tools, run the support/copy-tool-files.sh script from the root of the repository.
<srk>
I do have a thingie called haskcopysupport which basically does f=$( echo *.cabal | cut -d'.' -f1 ) && cp ~/git/haskell-project-template/{shell,default}.nix && sed -i "s~project.nix~$f.nix~g" default.nix
<srhb>
Wow, the stupidity of people never ceases to amaze.
<eyJhb>
I mean! I think the PDF generation part is cool. But everything else is ... yes, very stupid.
<eyJhb>
And of course it is a none-DK domain. Else they would get fucked so quick
<srhb>
I don't think that makes a difference, though I'm doubtful it's technically illegal anyway, just stupid. Using it would be, of course.
<eyJhb>
I somehow think they would try to put it under "you aided in document forgery" or something like that
<srhb>
Possibly, but being a dk domain or not makes no difference at all.
<srhb>
It's not like you can opt out of danish laws by setting up a site on a different TLD.
<eyJhb>
But using this and getting caught can result in quite some years of jail :p
<srhb>
Oh yes..
<eyJhb>
No no, but they are hiding a little more. I think there is a possibility they would have showed up at their doorstep otherwise. But not sure...
<eyJhb>
I think it is up to 10 years?
<srhb>
4, according to recent articles. 2 for not-terrible forgery, with doubling due to pandemic related excacerbating circumstances.
cole-h has quit [Ping timeout: 252 seconds]
supersandro2000 has quit [Remote host closed the connection]
<DigitalKiwi>
back when i used to be be productive :(
Irenes has joined #nixos-chat
dotdotok has joined #nixos-chat
__monty__ has joined #nixos-chat
<lukegb>
DigitalKiwi: tbf BB10 OS wasn't Android either, but some versions did have an Android compatibility layer
<eyJhb>
srhb: Remember the 2x for COVID-19 related crimes :p
<DigitalKiwi>
yeah someone else wrote the blackberry version of that i only did the android/iphone/tiger reverse geocoding system/postgresql and mysql/email servers/django admin UI/API for the apps and mobile website...
<samueldr>
booting a windows is so easily accidentally done
<cransom>
i think btrfs can upgrade from ext4, no? but zfs, i'm not sure it would be amenable to those hijinx.
<Ke>
not at runtime though
<Ke>
needs to be unmounted, also would not recommend it
<Ke>
at best it produces inferior btrfs
<eyJhb>
samueldr: Threw in my old SSD from a laptop that I used to play games with my GF :D
<eyJhb>
Didn't think it would be the first boot....
tazjin has quit [Quit: Byeee]
tazjin has joined #nixos-chat
tazjin has quit [Client Quit]
tazjin has joined #nixos-chat
<colemickens>
lost another enormous, vital, hours-of-research firefox session. thinking about just lighting my computer on fire instead of bothering to redone this again. I can't with this browser
<colemickens>
I guess if I were in Linux I'd have ZFS snapshots of the browser session but I'm on my gaming pc so.
<colemickens>
fun, fun fun fun computers are fun
<abathur>
session/tab loss is rough
<abathur>
I have my gripes about safari, but I'm fairly happy with how well it handles really big long-lived sessions with tons of tabs (not losing the session, tolerable resource use)
<elvishjerricco>
If Safari would just keep up with the damn standards, it'd be the best browser IMO. Chrome only narrowly beats it in perf, and I find Safari more friendly to use in pretty much every way
<abathur>
though to be fair some of that I think is just the general macOS window restore behavior; other browsers may be similarly good at this trick on macOS
<elvishjerricco>
Meanwhile, I use firefox because I dislike Google, and man does my hardware suffer for it.
<abathur>
I don't really use chrome or ff on macOS beyond occasional testing
<abathur>
yeah, I agree re: safari
dotlambda has joined #nixos-chat
<samueldr>
"keep up with the [...] standards" that's the point of a "living" standard: you can't
<elvishjerricco>
ff and chromium do just fine
<cole-h>
make part of the standard that it cannot evolve, ez
<samueldr>
or so you think
<elvishjerricco>
I mean I'm sure they're each behind in their own ways, but Safari is constantly way further behind
<samueldr>
(hopefully I'm not too condescending... especially since I don't know whether you are a web developer or not)
<elvishjerricco>
(I do some web dev, not much these days though)
<samueldr>
AFAIUI safari is not "behind", it's the others that are "too far in front"
<samueldr>
since... living standard and all...
<samueldr>
so even if in practice it acts like it's behind
<samueldr>
it's perfectly valid to be!
<elvishjerricco>
I pretty frequently encounter sites that only don't work in safari
<samueldr>
yep
<elvishjerricco>
but I suppose it's possible those sites are being irresponsible
<samueldr>
so many "new" things are also plain broken on safari because they just don't implement them
<samueldr>
like "fancier" html5 input, those old "new" things
<samueldr>
but it's totally okay to not
<samueldr>
except you know what's worse: you can't test safari without an apple-branded device
<samueldr>
and even on the simulator, it's different than on an actual device!!
<elvishjerricco>
Yea that's annoying.
<samueldr>
my pressure shot way down once I started dealing with misc. dead-ends of OEM android kernels and crap BSPs, compared to the web ;)
<eyJhb>
Is.. Is systemd-boot the new hip thing?
<gchristensen>
no
<elvishjerricco>
eyJhb: I believe nixos-generate-config defaults to it on efi systems.
<eyJhb>
elvishjerricco: YUP
<elvishjerricco>
but it's certainly not new
<eyJhb>
That is why I wondered about it
<gchristensen>
it is pretty great though
<elvishjerricco>
gchristensen: I don't know anything about it really. What makes it great?
<eyJhb>
gchristensen: Anything noteworthy you think is great?
<samueldr>
"meh", it's boring
<samueldr>
which is good
<gchristensen>
its configuration is nearly trivial. as samueldr says, it is boring
<elvishjerricco>
Yea that's great
<gchristensen>
it just works. on the serial port, on the desktop, everywhere
<elvishjerricco>
it is efi only though, right?
<samueldr>
yes
<gchristensen>
that is what lets it be boring :)
<samueldr>
is heavily relies on features of EFI
<elvishjerricco>
such as?
<samueldr>
AFAIUI it doesn't deal with the kernel at all, but only loads the EFISTUB kernel
<samueldr>
I might be totally wrong
<gchristensen>
efi deals with the serial port
<samueldr>
but if it does, that means systemd-boot does not have code to deal with the kernel
<elvishjerricco>
Oh so it could in theory chainload into any efi booted OS
<samueldr>
yes
<elvishjerricco>
that is quite cool
<samueldr>
indeed
<elvishjerricco>
How does it load the initrd?
<samueldr>
it doesn't I think?
<elvishjerricco>
Oh.
<elvishjerricco>
Huh
<samueldr>
I don't know about systemd-boot enough to be sure
<samueldr>
or maybe it does and I'm wrong about it not knowing about kernel things
<gchristensen>
I think it does actually
<samueldr>
(I shouldn't have said so since I'm not even sure about that)
* elvishjerricco
boots up the nixos ISO for the millionth installation experiment this week.
<samueldr>
that's using SYSLINUX on legacy boot; GRUB on EFI
* hodapp
rubs eyes
<hodapp>
syslinux? what year is it?
<samueldr>
hodapp: 2021
* hodapp
looks around for loadlin
<eyJhb>
Well.. Shit.
<samueldr>
it's still _the_ thing for legacy boot on usb
<samueldr>
(and iso combined)
<eyJhb>
I didn't copy my hardware config off my server before I did a reboot.
<srk>
recently I forgot to copy hardware config from qemu vm and was wondering why the nixus deployment always rolls back .. :D
<eyJhb>
srk: Joooys!
<eyJhb>
I have to create the Nixus config right now :p
<srk>
I'm switching to building qemu images with make-disk-image.nix so I don't have to deal with hw configs or installation
<srk>
+ declarative libvirt vms
<eyJhb>
WELL
<eyJhb>
I don't think that would help deploying a bare-metal machine? :D
<srk>
nope
<srk>
netboot is the best for bare-metal :)
<eyJhb>
well, I have IPMI, that makes it OK as well :D
<eyJhb>
Don't have to move that much
<gchristensen>
yay bare metal
<elvishjerricco>
gchristensen, samueldr: Hm. After a bare install, there's a 5M bzImage.efi and a 12M initrd.efi
<gchristensen>
hm
<elvishjerricco>
And the nixos-generation-1.conf file has different fields for kernel, initrd, and options
<elvishjerricco>
"initrd initramfs image (systemd-boot just adds this as option initrd=)"
<elvishjerricco>
wut
<elvishjerricco>
oh
<elvishjerricco>
I guess when the kernel is chainloaded with efistub, it looks for its initrd in the command line and just uses the ESP
<elvishjerricco>
neat
<elvishjerricco>
so systemd-boot is little more than just a common interface for configuring efi booting. That's nice
<samueldr>
right, so "it doesn't" seems right after all
srk has quit [Ping timeout: 248 seconds]
<eyJhb>
In whan world is this a success? `Cannot write to ‘nixos-20.09.zip’ (Success).`
<elvishjerricco>
Task failed successfully
<pie_>
make your time
aminechikhaoui7 has joined #nixos-chat
blueberrypie6 has joined #nixos-chat
aminechikhaoui has quit [Ping timeout: 268 seconds]
blueberrypie has quit [Ping timeout: 268 seconds]
blueberrypie6 is now known as blueberrypie
aminechikhaoui7 is now known as aminechikhaoui
<elvishjerricco>
So tempted to `nixfmt` my entire nixos config repo...
<eyJhb>
elvishjerricco: I am doing that with my nixus setup (ie. all my configs, servers, modules, etc)
<eyJhb>
But which one will you use?
<elvishjerricco>
There's multiple? I just know about pkgs.nixfmt
<eyJhb>
I use nixfmt. Not THAT big of a fan
<eyJhb>
Since it will split long lines into `somvar = \n "lalala";`
<elvishjerricco>
Yea that's a bit annoying, but not so bad
<eyJhb>
And will one line something you have nicely formatted, ie. a list with three items into a one liner
<eyJhb>
so adding new lines later will suck
<eyJhb>
It is a love/hate relationship honestly :p
<elvishjerricco>
I tried it on a worktree of the repo and... it made many modifications to pretty much every nix file :P I like it for the most part, but I don't want to have to review this big a change to make sure it didn't screw anything up
<gchristensen>
it probably didn't
<elvishjerricco>
key word: Probably :P
<eyJhb>
elvishjerricco: git commit before? :D
<eyJhb>
I feel like this reinstall of my server is a way for me to clean up in my configs. Am I weird for that?
<gchristensen>
yeah that is why it tookme 6months to swittch to this laptop
<gchristensen>
eventually i gave up and ditched my old config
<eyJhb>
gchristensen: Do you still use ` systemd.tmpfiles.rules` for managing your systems? (erase my darlings)
<gchristensen>
yep
<eyJhb>
Understandable. I just want to ditch a couple of services. ALso.. I am doing... rollback on boot now. So I have to find out where it stores files :D
<eyJhb>
Nice, will look at that. Might be better than other things. No imperdenance (/whatever) on your systems?
<eyJhb>
(I still use your naming for rpool/safe + rpool/local btw. <3)
<gchristensen>
cool :D
<gchristensen>
I tried something a bit different on this one w.r.t. optimizing for the nix db's write patterns, but it makes no difference on such a small machine :)
<eyJhb>
Seems likee tmpfiles.d should be able to do what I want for the most part. Seeing as my /home is non-persistent anyways.
<eyJhb>
I don't really need that on my server anyways (I think?)
<gchristensen>
I don't :)
<eyJhb>
gchristensen++ etu++ for using your guides each time I setup a NixOS system
<eyJhb>
hodapp: Speaking of `[srtoffee] This shouldn't occur, the status is unknown!`
nckx has joined #nixos-chat
<eyJhb>
*sigh* jellyfin will not work with tmpfiles.d
<samueldr>
love to have software that silently does nothing instead of loudly erroring out
<samueldr>
*when debug logging is turned on*
<samueldr>
or worse, feeding it invalid values is silently ignored
<aleph->
So I broke somewthing with pass somehow
<aleph->
Annoying
<elvishjerricco>
network-online.target doesn't seem to be working. I'm guessing that's because I haven't configured anything like networkmanager or networkd. What do you all like to use?
<supersandro2000>
multi-user.target or network.target
<supersandro2000>
actually if you try to achieve fast boot times you can disable network-online.target entirely
<elvishjerricco>
supersandro2000: Well network-online.target actually serves a function. It indicates that you've actually got an ip and a network connection. So if you need to actually be connected to the internet before your service starts, you enable something like networkmanager and order the service after network-online.target
<supersandro2000>
yeah sure but if I want my machine to boot up fast and show the login screen before I get an IP I can deactivate it
<elvishjerricco>
supersandro2000: Why would display-manager.service be ordered after network-online.target?
<supersandro2000>
elvishjerricco: for example IIRC docker requires it and also blocks multi-user.target
<supersandro2000>
waiting 15 seconds for network to come up literally sits there waiting and then starting 90 containers which all do not require network to be started or can fail two times until they start successful
<elvishjerricco>
supersandro2000: Does multi-user.target block display-manager.service?
<supersandro2000>
I think on laptops the most common boot delayer is the ntp service which by default is not async and just wait until it has time
<supersandro2000>
chrony does it async, not sure what the default on Debian/Ubuntu is
<supersandro2000>
elvishjerricco: tbh I don't know but it was faster after I turned it off by several seconds
dotdotok has joined #nixos-chat
<cole-h>
lovesegfault: reading now
<lovesegfault>
cole-h++
<{^_^}>
cole-h's karma got increased to 138
<lovesegfault>
Thanks :)
<lovesegfault>
cole-h: just fixed two typos, might want to refresh
<cole-h>
ack
<cole-h>
lovesegfault: might want to push first :P
<cole-h>
unless you force-pushed
<cole-h>
in which case ignore
<lovesegfault>
now
<lovesegfault>
My git was playing games
<cole-h>
oh wait my issue was because I was looking at the commit you sent, instead of the branch itself :D
<lovesegfault>
Ah, yes, that'll do ya :P
<lovesegfault>
my bad though
<cole-h>
allg
Synthetica has quit [Quit: Connection closed for inactivity]
supersandro2000 has quit [Disconnected by services]
supersandro2000 has joined #nixos-chat
<cole-h>
lovesegfault: lgtm but I kept getting distracted, so I wasn't that thorough 😬