2019-12-04T00:14:22 #kisslinux why the heredoc and subsequently necessary tabs and editorconfig instead of just like printf '%sn' >"$ssid.psk"? 2019-12-04T00:16:37 #kisslinux I know I know 2019-12-04T00:16:43 #kisslinux Quick question. 2019-12-04T00:17:11 #kisslinux yeah? 2019-12-04T00:17:22 #kisslinux When you disconnect from a network explicitly, do you expect autoconnection to then be disabled? 2019-12-04T00:17:34 #kisslinux ie, it won't auto connect back to it. 2019-12-04T00:17:48 #kisslinux I think that's what iwctl does 2019-12-04T00:18:18 #kisslinux > if (station->state == STATION_STATE_DISCONNECTED && autoconnect) 2019-12-04T00:18:24 #kisslinux > station_enter_state(station, STATION_STATE_AUTOCONNECT_QUICK); 2019-12-04T00:18:32 #kisslinux That's what iwd does currently. 2019-12-04T00:18:45 #kisslinux Though this is implicit me thinks 2019-12-04T00:20:18 #kisslinux https://git.kernel.org/pub/scm/network/wireless/iwd.git/tree/client/station.c#n280 2019-12-04T00:20:23 #kisslinux That's iwctl 2019-12-04T00:21:42 #kisslinux * E5ten sent a long message: < https://matrix.org/_matrix/media/r0/download/matrix.org/ENVCPoJIhGJGnjZskmxgytHm > 2019-12-04T00:21:51 #kisslinux 2610 src/station.c 2019-12-04T00:21:55 #kisslinux ye 2019-12-04T00:21:59 #kisslinux Trying to load the page 2019-12-04T00:22:42 #kisslinux so yeah, if the user explicitly disconnects it disables autoconnect, which makes sense to me 2019-12-04T00:22:47 #kisslinux Yup 2019-12-04T00:27:10 #kisslinux isn't the creation of the fd for current a memory leak cuz you l_strdup_printf within the fopen call instead of assigning it to something and using l_free on that after? 2019-12-04T00:28:04 #kisslinux stream not fd 2019-12-04T00:28:16 #kisslinux Good catch 2019-12-04T00:34:57 #kisslinux Fixed 2019-12-04T00:35:14 #kisslinux 👍️ 2019-12-04T02:05:08 #kisslinux other l_strdup_printf's that are used in fopen directly and so aren't assigned to something that's then freed in station.c and main.c 2019-12-04T03:05:32 #kisslinux so for some reason eudev-3.2.9 might be slower than eudev-3.2.7 2019-12-04T04:22:25 #kisslinux Hi guys. I was wondering if someone could help me with getting an image to display properly with neofetch? 2019-12-04T04:48:11 #kisslinux fire away 2019-12-04T04:59:15 #kisslinux so i tried editing config.conf under .config/neofetch and set the image backend to w3m and the image source to wallpaper but neofetch still only displays ascii text 2019-12-04T04:59:49 #kisslinux any logs? 2019-12-04T05:01:22 #kisslinux i can try. im kin da new to linux so sorry if i dont get it a first 2019-12-04T05:02:11 #kisslinux i just need to type neofetch -v right? 2019-12-04T05:03:23 #kisslinux neofetch -vv 2>log 2019-12-04T05:03:36 #kisslinux then upload log somewhere, preferably a pastebin service 2019-12-04T05:04:44 #kisslinux alright 2019-12-04T05:15:42 #kisslinux sorry im new to this, what would the log file's name be? 2019-12-04T05:15:54 #kisslinux also it would be in var/log right? 2019-12-04T05:18:08 #kisslinux https://pastebin.com/4tbn3uLu 2019-12-04T05:18:11 #kisslinux like that? 2019-12-04T05:18:49 #kisslinux two secs 2019-12-04T05:20:03 #kisslinux yep 2019-12-04T05:20:27 #kisslinux since dylan is offline it's likely that you won't see his response immediately, but he'll see the backlogs in /topic 2019-12-04T05:20:37 #kisslinux alright 2019-12-04T10:02:10 #kisslinux E5ten: Disconnect now works thanks to a little C code in iwd. 2019-12-04T10:06:45 #kisslinux iwc will move network configs to disconnect/ on disconnect. iwd will then "clean up" this directory on start/exit, moving the disconnected networks back into the regular directory. 2019-12-04T10:06:49 #kisslinux Simple enough. 2019-12-04T10:37:20 #kisslinux Pheyder: [!] Image: Imagemagick not found, falling back to ascii mode. 2019-12-04T10:37:25 #kisslinux You need imagemagick installed. 2019-12-04T12:21:37 #kisslinux https://github.com/dylanaraps/eiwd/releases/tag/0.2.0 2019-12-04T12:21:41 #kisslinux eiwd now has a simple client. 2019-12-04T12:54:43 #kisslinux Anyone here doing the advent of code? I just finished catching up with POSIX awk. 2019-12-04T12:56:36 #kisslinux Nope, what is it? 2019-12-04T12:56:49 #kisslinux There's a coding challenge everyday for December 2019-12-04T12:56:56 #kisslinux https://adventofcode.com 2019-12-04T13:05:55 #kisslinux It's pretty fun, and so far, totally doable in Bash and such. The difficulty is supposed to ramp up, though 2019-12-04T13:32:31 #kisslinux Huh cool 2019-12-04T15:49:53 #kisslinux dylanaraps, the tmux thing got resolved. I had to rebuild libevent 2019-12-04T15:59:40 #kisslinux Ah 2019-12-04T16:10:39 #kisslinux hi :) 2019-12-04T16:17:19 #kisslinux Hello 2019-12-04T16:17:30 #kisslinux I'm happy to answer any questions you may have. :) 2019-12-04T16:21:45 #kisslinux I know getkiss.org says you're only targetting x86-64, but do you have any plans of possibly supporting arm in the future? 2019-12-04T17:23:45 #kisslinux killmanen: I don't have any plans no. I don't have any ARM hardware either. Nothing is stopping someone from releasing KISS tarballs for ARM though as is the case with ppc64le https://github.com/jdavies-dev/kiss-ppc64le 2019-12-04T17:30:13 #kisslinux howdy 2019-12-04T17:30:48 #kisslinux dylanaraps: saw your post about iwd at all, great job :D 2019-12-04T17:30:55 #kisslinux *et al. 2019-12-04T17:30:59 #kisslinux Thanks :) 2019-12-04T17:31:17 #kisslinux i understand that iwctl isn't working because that's what required dbus? 2019-12-04T17:31:25 #kisslinux Yup 2019-12-04T17:31:40 #kisslinux dbus acts as the bridge between both. 2019-12-04T17:32:13 #kisslinux alright, sounds clear enough, I will see if I will have time to get it working over something else, shouldn't be as complicated, the dbus functionality did look pretty isolated :D 2019-12-04T17:32:34 #kisslinux It kinda was and wasn't isolated. 2019-12-04T17:33:18 #kisslinux We'll need a new IPC method and most likely an entirely new client. 2019-12-04T17:34:14 #kisslinux I've written a temporary client (iwc) until this happens. 2019-12-04T17:34:18 #kisslinux See usage in the README: https://github.com/dylanaraps/eiwd/ 2019-12-04T17:34:46 #kisslinux I see, sounds good 2019-12-04T17:35:32 #kisslinux The iwc client abuses the fact that iwd watches its config directory basically. 2019-12-04T17:36:03 #kisslinux I also added a little bit of C code to iwd to make this into something usable. 2019-12-04T17:36:21 #kisslinux (outputting current network and scan results to files for example) 2019-12-04T17:46:36 #kisslinux i see, looks pretty neat nonetheless 2019-12-04T17:47:10 #kisslinux as far as other IPC methods go, I would consider either unix sockets or systemv message queues 2019-12-04T17:47:29 #kisslinux although my fingers are twitching at the thought of 9p, haha 2019-12-04T17:47:50 #kisslinux but yea, this is probably not what 9p should be used for 2019-12-04T17:48:25 #kisslinux in other news, I was out and about looking for a new irc client 2019-12-04T17:48:50 #kisslinux saw this tiny client which looked pretty neat, then I open the dependency list and voila, `libdbus` 2019-12-04T18:06:15 #kisslinux belfry_: haha, i had to restrain myself from suggesting 9p, too 2019-12-04T18:07:06 #kisslinux mforney: fancy seeing you here, haha 2019-12-04T18:07:19 #kisslinux im a fan of your stuff 2019-12-04T18:08:42 #kisslinux thanks :) 2019-12-04T19:27:58 #kisslinux dylanaraps: nice! 2019-12-04T19:38:05 #kisslinux mforney: I wanna switch to samurai, but I really like the ninja feature of continuously replacing one line for output, any chance you'd consider adding that? 2019-12-04T20:11:51 #kisslinux E5ten: i'm hesitant to because it would require detection of a terminal with isatty (POSIX-specific), and non-standard TTY ioctls (TIOCGWINSZ) to determine the window width to make sure the command fits on one line 2019-12-04T20:12:42 #kisslinux i already require some POSIX functions, but i'm trying to keep that set as small as possible to making porting to other operating systems easy 2019-12-04T20:14:22 #kisslinux have you thought about implementing a small tool that does this, that you can use in a pipeline? 2019-12-04T20:15:02 #kisslinux like samu | lastline 2019-12-04T20:15:42 #kisslinux I haven't, I don't really know how I'd go about doing it 2019-12-04T20:16:29 #kisslinux probably would be really easy 2019-12-04T20:57:33 #kisslinux E5ten: http://ix.io/23zk seems do the job, but requires changing samurai to make its output line-buffered, even when not connected to a terminal: setvbuf(stdout, NULL, _IOLBF, 0) 2019-12-04T20:58:45 #kisslinux probably could be improved by listening for SIGWINCH to detect a changed window size. i believe ninja queries the window size every time it prints a line 2019-12-04T21:02:27 #kisslinux I'll try it out when I get to my computer, thanks 2019-12-04T21:31:36 #kisslinux nice, it also works with make(1) with no changes :) 2019-12-04T21:58:06 #kisslinux Oh, I didn't realize you were the Samurai dev. :P 2019-12-04T22:00:49 #kisslinux Because autotools is the devil if I cmaked eiwd odds you'd accept it? 2019-12-04T22:02:11 #kisslinux Alongside autotools, sure. 2019-12-04T22:02:35 #kisslinux A plain Makefile could probably work too. 2019-12-04T22:04:14 #kisslinux I prefer cmake cuz then I can skip GNU make and I prefer building things with no GNU ;) 2019-12-04T22:05:36 #kisslinux I'll try to do it tonight, from then on lemme know about any build system changes so I can match them in cmake 2019-12-04T22:07:35 #kisslinux Will do 2019-12-04T22:34:22 #kisslinux Behold: https://github.com/dylanaraps/eiwd/blob/master/iwc#L51-L73 2019-12-04T22:34:33 #kisslinux Scan results are now aligned as a table in pure shell. 2019-12-04T22:35:21 #kisslinux Example: https://termbin.com/lzj2 2019-12-04T22:36:22 #kisslinux oooo nice 2019-12-04T22:36:56 #kisslinux Can't set IFS without a subshell though :( 2019-12-04T22:37:39 #kisslinux Can't you just put an actual tab? 2019-12-04T22:38:02 #kisslinux Maybe 2019-12-04T22:38:11 #kisslinux I think so 2019-12-04T22:39:04 #kisslinux Yup 2019-12-04T22:39:07 #kisslinux :D 2019-12-04T22:39:09 #kisslinux Is the || [ "$ssid" ] in case read fails because the file is missing a trailing newline? 2019-12-04T22:39:42 #kisslinux Yup 2019-12-04T22:39:48 #kisslinux We *may* be OK without it. 2019-12-04T22:39:51 #kisslinux Don't you control the contents lol 2019-12-04T22:40:09 #kisslinux Yeah... 2019-12-04T22:40:20 #kisslinux OK 2019-12-04T22:40:22 #kisslinux It's fine. 2019-12-04T22:40:24 #kisslinux lol 2019-12-04T22:40:28 #kisslinux So it couldn't be missing the trailing newline unless a bad user modified it right? 2019-12-04T22:40:44 #kisslinux Lol 2019-12-04T22:40:51 #kisslinux Yup 2019-12-04T22:41:06 #kisslinux In which case, iwd would update it at some stage anyway. 2019-12-04T22:42:35 #kisslinux For ssid(), to avoid the [ call which could theoretically be not builtin, you could do the read command || the die command and then have the log command underneath ;) 2019-12-04T22:43:38 #kisslinux ooo 2019-12-04T22:43:40 #kisslinux Nice 2019-12-04T22:43:43 #kisslinux Let me test it 2019-12-04T22:45:15 #kisslinux Nice 2019-12-04T22:45:16 #kisslinux Works 2019-12-04T22:46:45 #kisslinux I guess you could also do the same with any -n -z or string comparison using cases instead of [ cuz case has to be builtin, these are clearly super worthwhile changes with tangible performance benefits 😏 2019-12-04T22:47:18 #kisslinux I swapped from cases to ifs since they're shorter lol 2019-12-04T22:47:23 #kisslinux time to swap back 2019-12-04T22:47:28 #kisslinux :^) 2019-12-04T22:48:08 #kisslinux At least I think cases have to be built in, they're keywords not builtin commands right? 2019-12-04T22:48:12 #kisslinux Yup 2019-12-04T22:48:18 #kisslinux Just tested in mrsh 2019-12-04T22:48:26 #kisslinux Which is 100% POSIX (no extensions) 2019-12-04T22:48:40 #kisslinux So even [ is external? 2019-12-04T22:48:42 #kisslinux Wild 2019-12-04T22:48:50 #kisslinux Yup 2019-12-04T22:48:58 #kisslinux Kinda dumb I know 2019-12-04T22:49:02 #kisslinux Even echo/printf 2019-12-04T22:49:29 #kisslinux A shell which doesn't expose anything built-in to print with... 2019-12-04T22:49:57 #kisslinux I understand the whole 100% POSIX aspect but some extensions make 100% sense. 2019-12-04T22:50:04 #kisslinux I wish printf was mandated builtin 2019-12-04T22:50:09 #kisslinux Same 2019-12-04T22:50:13 #kisslinux Also sleep 2019-12-04T22:50:19 #kisslinux Why isn't sleep builtin? 2019-12-04T22:50:29 #kisslinux Ikr 2019-12-04T22:51:26 #kisslinux Cuz like fuck echo, that shit's broken and I'm not gonna use it, but guaranteed builtin printf would make making scripts that are 100% no external commands, as specified by POSIX and not just as common in shells, wayyy easier 2019-12-04T22:51:43 #kisslinux Cuz printf is honestly like the king builtin, so fucking useful 2019-12-04T22:52:05 #kisslinux (not counting keywords) 2019-12-04T22:52:42 #kisslinux Yup 2019-12-04T22:52:56 #kisslinux It makes sense for performance regardless though. 2019-12-04T22:53:29 #kisslinux Yeah 2019-12-04T22:54:14 #kisslinux Imagine needing to fork and exec each time you want to print something. 2019-12-04T22:55:01 #kisslinux The thought makes me sad 2019-12-04T22:56:54 #kisslinux https://github.com/dylanaraps/eiwd/commit/34cfbd9fa3e0a4541e3b11bf9443f80a747adaf0#diff-0c760aac26fadb53c593bfa94f2c82d4R68 2019-12-04T22:57:11 #kisslinux Removed [ from while loop 2019-12-04T22:58:10 #kisslinux When it comes to shell scripting, meaningless microoptimization is the best kind of optimization :)) 2019-12-04T22:58:14 #kisslinux Of course 2019-12-04T22:58:40 #kisslinux > real 0m 0.00s (iwc scan) 2019-12-04T22:59:36 #kisslinux Mmmmm 2019-12-04T22:59:39 #kisslinux Love that 2019-12-04T23:00:14 #kisslinux That check for $pass being empty is just begging to be a case ;) 2019-12-04T23:02:07 #kisslinux Hang on, I'm removing the need to pass some arguments around. :^) 2019-12-04T23:02:12 #kisslinux Gotta remove that overhead. 2019-12-04T23:04:30 #kisslinux Of course 2019-12-04T23:05:12 #kisslinux On the topic of built-ins, the inability to sort arrays in pure bash frustrates me so much 2019-12-04T23:05:38 #kisslinux Yup 2019-12-04T23:05:44 #kisslinux It's a tacked on feature. 2019-12-04T23:06:19 #kisslinux I wish zsh was as ubiquitous as bash so I could script in it, I don't know much about zsh scripting but I do know it has builtin array sorting 2019-12-04T23:07:11 #kisslinux zsh has some nice features 2019-12-04T23:07:16 #kisslinux too bad it's.. zsh 2019-12-04T23:07:44 #kisslinux https://github.com/dylanaraps/eiwd/commit/4c24a4d92200ff1be5c5e74106e883fb0b386b19 2019-12-04T23:07:46 #kisslinux 10/10 change 2019-12-04T23:09:47 #kisslinux I mean genuinely that's a valid change if only because on seeing the parameter passing in the case it'd be initially unclear why a parameter was being passed 2019-12-04T23:10:07 #kisslinux Yup 2019-12-04T23:10:10 #kisslinux https://github.com/dylanaraps/eiwd/commit/20b86709dfbf877690018da0026704754831bf24 2019-12-04T23:10:32 #kisslinux No need to run stty after each invocation of iwc either. 2019-12-04T23:10:48 #kisslinux Nice 2019-12-04T23:11:11 #kisslinux How does stty actually control that stuff? 2019-12-04T23:11:19 #kisslinux Escape sequences? 2019-12-04T23:11:39 #kisslinux No no 2019-12-04T23:11:49 #kisslinux Were it escape sequences I'd do it myself. 2019-12-04T23:12:10 #kisslinux Then how? 2019-12-04T23:12:21 #kisslinux Cuz it kinda feels like magic 2019-12-04T23:12:22 #kisslinux It sends signals to the terminal itself. 2019-12-04T23:13:04 #kisslinux > stty sets or reports the terminal I/O characteristics for the standard input device. 2019-12-04T23:14:01 #kisslinux How does it send messages to the terminal itself though? I'm having a tough time wrapping my head around stty 2019-12-04T23:15:32 #kisslinux Time to do some digging. 2019-12-04T23:16:40 #kisslinux Actually. Most likely the TTY device through the kernel. 2019-12-04T23:44:14 #kisslinux You can remove the check for $2 and do ssid_encode "${2:?Missing [said] argument}" I think 2019-12-04T23:44:20 #kisslinux ssid* 2019-12-04T23:47:02 #kisslinux Nic 2019-12-04T23:47:05 #kisslinux e 2019-12-04T23:54:15 #kisslinux Down to 135 LOC: https://github.com/dylanaraps/eiwd/blob/master/iwc 2019-12-04T23:54:19 #kisslinux Looking good now.