[dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
Hello there, i changed my systems locales to de_DE.UTF-8 and now the command "uptime" is using "," instead of "." because of LC_NUMERIC now being set to German too. As a result of this the loadavg part of the default statusbar looks like "131 087 071" (no dots since commas are removed by sed). I have tried several things to make it work but I was not sucessful. LC_NUMERIC _must_ be exported to make it work correctly, since uptime is called from a subshell. Exporting LC_NUMERIC to an English locale is not an option. Now, I don't know how to make that status command respecting a different locale. Changing the sed command to something more complex would surely work but I am posting this here since this was no issue with wmii 3.6 yonks ago and maybe other people run into this too. Any suggestions how to handle this? Secondly, a small suggestion: I would like to have something like a small indication if there are any floating windows hidden "behind" the managed layer if the latter is toggled active (currently there is none and it's quite possible to forget about the floating windows ;) Maybe a "~" in the tags name like the "*" if a window is requesting attention. Don't know if this is possible but I hope you get what I mean. regards, nico
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
If you set locales to retarded values (anything other than C/UTF-8/en_US), shit will break. Stop this crap, locales are an abomination. uriel On Wed, Jul 14, 2010 at 2:08 PM, nico wrote: > Hello there, > > i changed my systems locales to de_DE.UTF-8 and now the command "uptime" > is using "," instead of "." because of LC_NUMERIC now being set to German > too. As a result of this the loadavg part of the default statusbar looks > like "131 087 071" (no dots since commas are removed by sed). > I have tried several things to make it work but I was not sucessful. > LC_NUMERIC _must_ be exported to make it work correctly, since uptime is > called from a subshell. Exporting LC_NUMERIC to an English locale is not an > option. > > Now, I don't know how to make that status command respecting a different > locale. > Changing the sed command to something more complex would surely work but I > am posting this here since this was no issue with wmii 3.6 yonks ago and > maybe other people run into this too. Any suggestions how to handle this? > > Secondly, a small suggestion: > I would like to have something like a small indication if there are any > floating windows hidden "behind" the managed layer if the latter is toggled > active (currently there is none and it's quite possible to forget about the > floating windows ;) Maybe a "~" in the tags name like the "*" if a window > is requesting attention. Don't know if this is possible but I hope you get > what I mean. > > regards, > nico > >
Re: [dev] merp is a loneliness mitigation device written in python and Tk
On Tue, Jul 13, 2010 at 1:33 PM, Uriel wrote: > The ircfs site t is up now: > > http://www.ueber.net/code/r/ircfs > > ircfs is great, and its gui is great too, and mjl is a great hacker. Thanks for linking this. > > And does the world really need yet another python irc client? And I'm > not sure what makes merp particularly 'suckless' (whatever anything > written in Python can be 'suckless' is very questionable). I agree that python requires relatively more infrastructure and is not suckless. I never claimed merp is suckless in terms of implementation as it was only meant to be a prototype and had to work in Windows, but I think its minimal interface makes it conducive to a suckless implementation in some simpler language. I was thinking that when the Go graphics package becomes more usable, I'd like to try to make a Go version. > > But I do praise the choice of Tk for the gui. > > uriel > > On Mon, Jul 12, 2010 at 4:24 PM, hiro <23h...@googlemail.com> wrote: >> The old wmii community probably knows that one well enough, but for >> all the others I'd like to promote ircfs from Mechiel Lukkien. It runs >> on inferno and includes a 9p server and tk client. >> Sadly his site is currently down, but here's a paper from him: >> http://4e.iwp9.org/papers/ircfs.pdf >> >> > >
Re: [dev] merp is a loneliness mitigation device written in python and Tk
On 14 Jul 2010, at 14:28, Joseph Xu wrote: On Tue, Jul 13, 2010 at 1:33 PM, Uriel wrote: The ircfs site t is up now: http://www.ueber.net/code/r/ircfs ircfs is great, and its gui is great too, and mjl is a great hacker. Thanks for linking this. And does the world really need yet another python irc client? And I'm not sure what makes merp particularly 'suckless' (whatever anything written in Python can be 'suckless' is very questionable). I agree that python requires relatively more infrastructure and is not suckless. I never claimed merp is suckless in terms of implementation as it was only meant to be a prototype and had to work in Windows, but I think its minimal interface makes it conducive to a suckless implementation in some simpler language. I was thinking that when the Go graphics package becomes more usable, I'd like to try to make a Go version. I do like the minimal interface, especially sending messages entered in the server console straight to the server rather than using / commands. But I do praise the choice of Tk for the gui. uriel On Mon, Jul 12, 2010 at 4:24 PM, hiro <23h...@googlemail.com> wrote: The old wmii community probably knows that one well enough, but for all the others I'd like to promote ircfs from Mechiel Lukkien. It runs on inferno and includes a 9p server and tk client. Sadly his site is currently down, but here's a paper from him: http://4e.iwp9.org/papers/ircfs.pdf
Re: [dev] merp is a loneliness mitigation device written in python and Tk
On 14 Jul 2010, at 06:30, Uriel wrote: Copy-paste with the host doesn't work by default because apparently making people's lives miserable is the main task of Inferno. As Kris pointed out, this work fine in acme-sac, and all that really is required is a single command (mounting the host's clipboard) in your startup scripts. hahahahaha! I really should know to look for things like this by now. Inferno looks polished enough that I got into the state of mind of sitting back and expecting everything to be all there. Granted it _is_ almost all there if what you want from Inferno is isolation from the host environment. Heh. But don't expect this to be fixed in the next ten years, so just use acme-sac ;) uriel On Wed, Jul 14, 2010 at 4:33 AM, Ethan Grammatikidis wrote: Sorry, clicked in the wrong place & sent a blank reply. On 14 Jul 2010, at 03:03, Uriel wrote: Also if somebody doesn't like the Inferno GUI for ircfs, it should be trivial enough to write another one. Running ircfs on a server, and attaching to it from different clients should work fine. uriel On Wed, Jul 14, 2010 at 1:08 AM, hiro <23h...@googlemail.com> wrote: Ok, I thought you were talking about wm/ircfs which extraordinarily uses classic plan9 chording commands If that's the case, it's not wm/ircfs I need to write a new GUI for. Maybe I should look into writing one for wm/sh. I really hope it's as trivial as Uriel says. There is still the issue of no copy/paste with the host.. heh, I can try to see if I can do anything about that.
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
On 14 Jul 2010, at 13:31, Uriel wrote: If you set locales to retarded values (anything other than C/UTF-8/en_US), shit will break. Stop this crap, locales are an abomination. *nods* The output of unix commands is just as much API as UI, so applying locale conversions to them is hairy at best. uriel On Wed, Jul 14, 2010 at 2:08 PM, nico wrote: Hello there, i changed my systems locales to de_DE.UTF-8 and now the command "uptime" is using "," instead of "." because of LC_NUMERIC now being set to German too. As a result of this the loadavg part of the default statusbar looks like "131 087 071" (no dots since commas are removed by sed). I have tried several things to make it work but I was not sucessful. LC_NUMERIC _must_ be exported to make it work correctly, since uptime is called from a subshell. Exporting LC_NUMERIC to an English locale is not an option. Now, I don't know how to make that status command respecting a different locale. Changing the sed command to something more complex would surely work but I am posting this here since this was no issue with wmii 3.6 yonks ago and maybe other people run into this too. Any suggestions how to handle this? Secondly, a small suggestion: I would like to have something like a small indication if there are any floating windows hidden "behind" the managed layer if the latter is toggled active (currently there is none and it's quite possible to forget about the floating windows ;) Maybe a "~" in the tags name like the "*" if a window is requesting attention. Don't know if this is possible but I hope you get what I mean. regards, nico
[dev] plumb 1.0
Hello all, here I am advertising my own personal project. (Technically it's a complete rewrite, the old version was announced here once before.) Home page: http://repo.hu/projects/plumb/ Plumb is a program that runs multiple processes and lets you define arbitrary pipes between them (it uses libevent to manage the data transfer). The major new feature in the rewrite is that it has a fairly comfy "control language" that it can also read from pipes in runtime; this means that a program running under Plumb can start new processes, shut down old ones, create or kill pipes. The simplest, most common application would be to start two processes and connect them in a "69" configuration - STDIN to STDOUT of the other. This is how you can use Animator (http://repo.hu/projects/animator/) to write simple interactive apps. A slightly more complex application: I wrote an interactive, graphical Gopher client in AWK. It uses Animator for the display, and spawns nc for downloads as needed. Multiple downloads can be ongoing at the same time. It manages all this from a simple AWK script that does nothing else but read from STDIN and write to STDOUT. There's another tool that is part of the "Plumb package", called plumbnet. It's a TCP server that listens on a port and accepts multiple connections at once (again, using libevent). It writes lines received from connections to STDOUT, and reads lines to send on its STDIN. Connections are distinguished by integer connection ID prefixes in either direction. You'd tipically use plumbnet by wiring it together with your program using Plumb. It may be a good alternative to inetd, when you want to accept multiple TCP connections but there is common state (so you'd have to do some sort of IPC, or write a complete network daemon from scratch). Plumb basically lets you use STDIN/STDOUT in new and flexible ways. Most of this was possible to do before by hand (e.g. by using mkfifo), but with Plumb, it should be much more comfortable. I don't know, it might even serve to connect a controlling script with a window manager, so the wm logic is moved outside the core wm :) The core use case is probably the "hack up something fast" "i really like AWK" "i'm at a programming compo" scenario. Suggestions/complaints/bug reports/flame is very welcome as usual (except regarding the license or VCS ;) Thanks for reading, Mate
Re: [dev] plumb 1.0
While this seems like an interesting project, I would strongly urge you to change the name, "Plumb" is already used by a way too similar project and will just cause confusion: http://doc.cat-v.org/plan_9/4th_edition/papers/plumb uriel On Wed, Jul 14, 2010 at 6:00 PM, Mate Nagy wrote: > Hello all, > > here I am advertising my own personal project. (Technically it's a > complete rewrite, the old version was announced here once before.) > > Home page: http://repo.hu/projects/plumb/ > > Plumb is a program that runs multiple processes and lets you define > arbitrary pipes between them (it uses libevent to manage the data > transfer). > > The major new feature in the rewrite is that it has a fairly comfy > "control language" that it can also read from pipes in runtime; this > means that a program running under Plumb can start new processes, shut > down old ones, create or kill pipes. > > The simplest, most common application would be to start two processes > and connect them in a "69" configuration - STDIN to STDOUT of the other. > This is how you can use Animator (http://repo.hu/projects/animator/) > to write simple interactive apps. > > A slightly more complex application: I wrote an interactive, graphical > Gopher client in AWK. It uses Animator for the display, and spawns nc > for downloads as needed. Multiple downloads can be ongoing at the same > time. It manages all this from a simple AWK script that does nothing > else but read from STDIN and write to STDOUT. > > There's another tool that is part of the "Plumb package", called > plumbnet. It's a TCP server that listens on a port and accepts > multiple connections at once (again, using libevent). > It writes lines received from connections to STDOUT, and reads > lines to send on its STDIN. Connections are distinguished by > integer connection ID prefixes in either direction. > > You'd tipically use plumbnet by wiring it together with your program > using Plumb. It may be a good alternative to inetd, when you > want to accept multiple TCP connections but there is common state > (so you'd have to do some sort of IPC, or write a complete network > daemon from scratch). > > Plumb basically lets you use STDIN/STDOUT in new and flexible ways. > Most of this was possible to do before by hand (e.g. by using mkfifo), > but with Plumb, it should be much more comfortable. I don't know, > it might even serve to connect a controlling script with a window > manager, so the wm logic is moved outside the core wm :) > > The core use case is probably the "hack up something fast" "i really > like AWK" "i'm at a programming compo" scenario. > > Suggestions/complaints/bug reports/flame is very welcome as usual > (except regarding the license or VCS ;) > > Thanks for reading, > Mate > >
Re: [dev] plumb 1.0
On Wed, Jul 14, 2010 at 07:25:56PM +0200, Uriel wrote: > http://doc.cat-v.org/plan_9/4th_edition/papers/plumb well darn, should've expected it from plan9 :) yeah, i'll consider the name change, it's no problem at this point - any suggestions for names? :) Mate
Re: [dev] plumb 1.0
On Wed, Jul 14, 2010 at 1:28 PM, Mate Nagy wrote: > well darn, should've expected it from plan9 :) > yeah, i'll consider the name change, it's no problem at this point - > any suggestions for names? :) I'd just leave it. The five guys who use plan9 will be able to differentiate them. -- # Kurt H Maier
Re: [dev] plumb 1.0
On Wed, Jul 14, 2010 at 07:28:16PM +0200, Mate Nagy wrote: > well darn, should've expected it from plan9 :) > yeah, i'll consider the name change, it's no problem at this point - > any suggestions for names? :) Ouroboros? Maybe "ouro" for short? -POLM
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
Hmm, actually I never had problems setting the locale. I always have LANG and LC_MESSAGES set to en_US.UTF-8 so language is still english and the other variables are set to de_DE.UTF-8 so information many apps do rely on like paper size, currency, punctuation (the fail in my case), address format and stuff like that is correct. So I'm just going to use a different uptime parsing method or is anyone having a better idea? Am 14.07.2010 17:44, schrieb Ethan Grammatikidis: On 14 Jul 2010, at 13:31, Uriel wrote: If you set locales to retarded values (anything other than C/UTF-8/en_US), shit will break. Stop this crap, locales are an abomination. *nods* The output of unix commands is just as much API as UI, so applying locale conversions to them is hairy at best. uriel On Wed, Jul 14, 2010 at 2:08 PM, nico wrote: Hello there, i changed my systems locales to de_DE.UTF-8 and now the command "uptime" is using "," instead of "." because of LC_NUMERIC now being set to German too. As a result of this the loadavg part of the default statusbar looks like "131 087 071" (no dots since commas are removed by sed). I have tried several things to make it work but I was not sucessful. LC_NUMERIC _must_ be exported to make it work correctly, since uptime is called from a subshell. Exporting LC_NUMERIC to an English locale is not an option. Now, I don't know how to make that status command respecting a different locale. Changing the sed command to something more complex would surely work but I am posting this here since this was no issue with wmii 3.6 yonks ago and maybe other people run into this too. Any suggestions how to handle this? Secondly, a small suggestion: I would like to have something like a small indication if there are any floating windows hidden "behind" the managed layer if the latter is toggled active (currently there is none and it's quite possible to forget about the floating windows ;) Maybe a "~" in the tags name like the "*" if a window is requesting attention. Don't know if this is possible but I hope you get what I mean. regards, nico -- regards, nico
Re: [dev] plumb 1.0
2010/7/14 Mate Nagy : > any suggestions for names? :) Get morphological; "plumber", "plumbing". -- Samuel Baldwin - logik.li
Re: [dev] plumb 1.0
On 14 July 2010 18:28, Mate Nagy wrote: > On Wed, Jul 14, 2010 at 07:25:56PM +0200, Uriel wrote: >> http://doc.cat-v.org/plan_9/4th_edition/papers/plumb > > well darn, should've expected it from plan9 :) > yeah, i'll consider the name change, it's no problem at this point - > any suggestions for names? :) Since German is the new world language, I propose: klempner 1.0 Kind regards, Anselm
Re: [dev] plumb 1.0
On Wed, Jul 14, 2010 at 07:28:16PM +0200, Mate Nagy wrote: > On Wed, Jul 14, 2010 at 07:25:56PM +0200, Uriel wrote: > > http://doc.cat-v.org/plan_9/4th_edition/papers/plumb > > well darn, should've expected it from plan9 :) > yeah, i'll consider the name change, it's no problem at this point - > any suggestions for names? :) > > Mate > Name it prune since plum(b) was already taken.
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
On 14 Jul 2010, at 18:56, nico wrote: Hmm, actually I never had problems setting the locale. I always have LANG and LC_MESSAGES set to en_US.UTF-8 so language is still english and the other variables are set to de_DE.UTF-8 so information many apps do rely on like paper size, currency, punctuation (the fail in my case), address format and stuff like that is correct. So I'm just going to use a different uptime parsing method or is anyone having a better idea? I'm not sure how practical it would be for you to change all your wmii scripts, but isn't there a script set for it written in rc instead of bourne shell? Those would use the p9p or 9base commands which don't respond to locale. Am 14.07.2010 17:44, schrieb Ethan Grammatikidis: On 14 Jul 2010, at 13:31, Uriel wrote: If you set locales to retarded values (anything other than C/UTF-8/en_US), shit will break. Stop this crap, locales are an abomination. *nods* The output of unix commands is just as much API as UI, so applying locale conversions to them is hairy at best. uriel On Wed, Jul 14, 2010 at 2:08 PM, nico wrote: Hello there, i changed my systems locales to de_DE.UTF-8 and now the command "uptime" is using "," instead of "." because of LC_NUMERIC now being set to German too. As a result of this the loadavg part of the default statusbar looks like "131 087 071" (no dots since commas are removed by sed). I have tried several things to make it work but I was not sucessful. LC_NUMERIC _must_ be exported to make it work correctly, since uptime is called from a subshell. Exporting LC_NUMERIC to an English locale is not an option. Now, I don't know how to make that status command respecting a different locale. Changing the sed command to something more complex would surely work but I am posting this here since this was no issue with wmii 3.6 yonks ago and maybe other people run into this too. Any suggestions how to handle this? Secondly, a small suggestion: I would like to have something like a small indication if there are any floating windows hidden "behind" the managed layer if the latter is toggled active (currently there is none and it's quite possible to forget about the floating windows ;) Maybe a "~" in the tags name like the "*" if a window is requesting attention. Don't know if this is possible but I hope you get what I mean. regards, nico -- regards, nico
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
On Wed, Jul 14, 2010 at 7:56 PM, nico wrote: > Hmm, actually I never had problems setting the locale. I always have LANG > and LC_MESSAGES set to en_US.UTF-8 so language is still english and the > other variables are set to de_DE.UTF-8 so information many apps do rely on > like paper size, currency, punctuation (the fail in my case), address format > and stuff like that is correct. So I'm just going to use a different uptime > parsing method or is anyone having a better idea? Again, stop trying to 'use' the PoSix locale system for anything, it is completely broken and totally antithetical to how Unix is designed to work. An option would be to use p9p's user space instead of the usual GNU crap. uriel > > Am 14.07.2010 17:44, schrieb Ethan Grammatikidis: >> >> On 14 Jul 2010, at 13:31, Uriel wrote: >> >>> If you set locales to retarded values (anything other than >>> C/UTF-8/en_US), shit will break. >>> >>> Stop this crap, locales are an abomination. >> >> *nods* The output of unix commands is just as much API as UI, so applying >> locale conversions to them is hairy at best. >> >>> >>> uriel >>> >>> On Wed, Jul 14, 2010 at 2:08 PM, nico wrote: Hello there, i changed my systems locales to de_DE.UTF-8 and now the command "uptime" is using "," instead of "." because of LC_NUMERIC now being set to German too. As a result of this the loadavg part of the default statusbar looks like "131 087 071" (no dots since commas are removed by sed). I have tried several things to make it work but I was not sucessful. LC_NUMERIC _must_ be exported to make it work correctly, since uptime is called from a subshell. Exporting LC_NUMERIC to an English locale is not an option. Now, I don't know how to make that status command respecting a different locale. Changing the sed command to something more complex would surely work but I am posting this here since this was no issue with wmii 3.6 yonks ago and maybe other people run into this too. Any suggestions how to handle this? Secondly, a small suggestion: I would like to have something like a small indication if there are any floating windows hidden "behind" the managed layer if the latter is toggled active (currently there is none and it's quite possible to forget about the floating windows ;) Maybe a "~" in the tags name like the "*" if a window is requesting attention. Don't know if this is possible but I hope you get what I mean. regards, nico >>> >> >> > > > -- > regards, > nico > > >
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
Uriel writes: > On Wed, Jul 14, 2010 at 7:56 PM, nico wrote: >> Hmm, actually I never had problems setting the locale. I always have LANG >> and LC_MESSAGES set to en_US.UTF-8 so language is still english and the >> other variables are set to de_DE.UTF-8 so information many apps do rely on >> like paper size, currency, punctuation (the fail in my case), address format >> and stuff like that is correct. So I'm just going to use a different uptime >> parsing method or is anyone having a better idea? > > Again, stop trying to 'use' the PoSix locale system for anything, it > is completely broken and totally antithetical to how Unix is designed > to work. > > An option would be to use p9p's user space instead of the usual GNU > crap. What should you do if you don't want all your programs to write brain-dead US units and punctuation? -- \ Troels /\ Henriksen
Re: [dev] plumb 1.0
On 10-07-14 01:25 PM, Uriel wrote: While this seems like an interesting project, I would strongly urge you to change the name, "Plumb" is already used by a way too similar project and will just cause confusion: http://doc.cat-v.org/plan_9/4th_edition/papers/plumb how about "piper" ? djp
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
On Wed, Jul 14, 2010 at 10:32:43PM +0100, Ethan Grammatikidis wrote: On 14 Jul 2010, at 18:56, nico wrote: Hmm, actually I never had problems setting the locale. I always have LANG and LC_MESSAGES set to en_US.UTF-8 so language is still english and the other variables are set to de_DE.UTF-8 so information many apps do rely on like paper size, currency, punctuation (the fail in my case), address format and stuff like that is correct. So I'm just going to use a different uptime parsing method or is anyone having a better idea? In my experience, most programs default to A4 no matter your locale. I'm not sure how practical it would be for you to change all your wmii scripts, but isn't there a script set for it written in rc instead of bourne shell? Those would use the p9p or 9base commands which don't respond to locale. Ah, sadly not. p9p does not, unfortunately, provide any way of obtaining load averages. It gets it from the system uptime command the same as the sh script. -- Kris Maglione A language that doesn't have everything is actually easier to program in than some that do. --Dennis M. Ritchie
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
On Wed, Jul 14, 2010 at 11:39:59PM +0200, Troels Henriksen wrote: Uriel writes: Again, stop trying to 'use' the PoSix locale system for anything, it is completely broken and totally antithetical to how Unix is designed to work. An option would be to use p9p's user space instead of the usual GNU crap. What should you do if you don't want all your programs to write brain-dead US units and punctuation? At the rist of feeding a troll, don't be an idiot. Decimal and thousands separators are arbitrary. Neither has any advantage over the other, they're simply a matter of custom. As for units, POSIX locales have no influence on them whatever. -- Kris Maglione Mostly, when you see programmers, they aren't doing anything. One of the attractive things about programmers is that you cannot tell whether or not they are working simply by looking at them. Very often they're sitting there seemingly drinking coffee and gossiping, or just staring into space. What the programmer is trying to do is get a handle on all the individual and unrelated ideas that are scampering around in his head. --Charles M. Strauss
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
On Wed, Jul 14, 2010 at 02:08:32PM +0200, nico wrote: > Changing the sed command to something more complex would surely work ...and not generate all this noise. noah
Re: [dev] [wmii] Locale problem with "uptime" (loadavg in status bar) and a suggestion
On Wed, Jul 14, 2010 at 09:36:07PM -0700, Noah Birnel wrote: On Wed, Jul 14, 2010 at 02:08:32PM +0200, nico wrote: Changing the sed command to something more complex would surely work ...and not generate all this noise. Ah, but we're a very noisy list. You can't half throw a stone without generating these many echoes. -- Kris Maglione Correctness is clearly the prime quality. If a system does not do what it is supposed to do, then everything else about it matters little. --Bertrand Meyer
Re: [dev] plumb 1.0
On 14.07.2010 19:28, Mate Nagy wrote: On Wed, Jul 14, 2010 at 07:25:56PM +0200, Uriel wrote: http://doc.cat-v.org/plan_9/4th_edition/papers/plumb well darn, should've expected it from plan9 :) yeah, i'll consider the name change, it's no problem at this point - any suggestions for names? :) For something that tinkers with pipes? Mario, what else? PS: The next release could be named super-mario :D with 8bit greetings stefan