Kajetan Jasztal | 22 Oct 00:14 2014

[dmenu] dmenu based directory browser

Hi there!
Just want to share super-simple, crappy written yet quite useful (at
least for me) script I've written while ago.
I run it via bind with Ctrl+O

bind '"\C-o":". ~/.dbdb.sh\C-m"'

and the script

CHOSEN="just for not being empty"
DMENU="dmenu -i -fn -*-terminus-medium-r-*-*-14-*-*-*-*-*-*-*"
COLORS=" -nb #000000 -nf #706c9a -sb #000000 -sf #dddddd"
while [ "$CHOSEN" != "" ]; do
   clear && pwd && ls -X
   CHOSEN=`( ( echo "../" && ls -1p ) | grep "/" ) | $DMENU $COLORS`
   cd "$CHOSEN"

great job with suckless!

orangeprince | 20 Oct 02:14 2014

Re: SGI Irix look (4Dwm)

> Why not patch dwm it to draw the appropriate decorations around windows? It can't be that difficult to do, 
and the code base is easy enough to navigate...

Thanks, I'll look into it.

> I, for one,  am glad they didn't succeed.  More commercial workstations may have slowed the development for
free alternatives. Think about how Apple's dominance has drawn people away from GNU/linux and the BSDs
(noting of course, that OSX has some roots in FreeBSD), for instance.

I don't think their success would have had much of an impact on us regular folks. SGI were only for
governments, research institutions and the super rich.

If anything, Apple's dominance has made people familiar with the Unix command-line, which is certainly
better than had they been using Windows.


On 19. oktober 2014 at 7:08 PM, "Andrew Gwozdziewycz" <lists <at> apgwoz.com> wrote:On October 19, 2014
1:51:37 PM EDT, orangeprince <at> hushmail.com wrote:
>>I don't know why you would want that.
>Partly because I want to keep things simple, partly because of
>nostalgia, and partly because I think SGI Irix was coolest thing ever.

Why not patch dwm it to draw the appropriate decorations around windows? It can't be that difficult to do, 
and the code base is easy enough to navigate...

>They were about to take over the world with their massive super
>computers and cameo appearances in movies like Jurassic Park. But,
>unfortunately, their leadership failed.
(Continue reading)

orangeprince | 19 Oct 15:20 2014

SGI Irix look (4Dwm)


Is there any way to get that old classic SGI Irix look (4Dwm) in dwm?




ale rimoldi | 17 Oct 18:14 2014

vis: small patch placing the cursor the text inserted from the register

hi marc

here a small to place the cursor after the text inserted with ctrl-r


diff --git a/config.def.h b/config.def.h
index 9ecb018..685c787 100644
--- a/config.def.h
+++ b/config.def.h
 <at>  <at>  -921,7 +925,9  <at>  <at>  static void delete(const Arg *arg) {

 static void insert_register(const Arg *arg) {
 	Register *reg = &vis->registers[arg->i];
-	editor_insert(vis, window_cursor_get(vis->win->win),
reg->data, reg->len);
+	int pos = window_cursor_get(vis->win->win);
+	editor_insert(vis, pos, reg->data, reg->len);
+	window_cursor_to(vis->win->win, pos + reg->len);

 static void prompt(const Arg *arg) {

Brandon Mulcahy | 16 Oct 23:31 2014

[PATCH] [sbase] Add logname(1)

Another easy one. One of the context lines will have to be updated in Makefile
to apply after the link(1) patch.
Attachment (0001-Add-logname-1.patch): text/x-diff, 1381 bytes
Markus Teich | 16 Oct 22:12 2014

[PATCH][sbase] add link utility



there you go, pretty simple, but it was still missing so here you go.


 Makefile |  1 +
 README   |  1 +
 TODO     |  1 -
 link.1   | 14 ++++++++++++++
 link.c   | 16 ++++++++++++++++
 5 files changed, 32 insertions(+), 1 deletion(-)
 create mode 100644 link.1
 create mode 100644 link.c

diff --git a/Makefile b/Makefile
index 6f995be..5ff507e 100644
--- a/Makefile
+++ b/Makefile
 <at>  <at>  -57,6 +57,7  <at>  <at>  SRC = \
 	head.c     \
 	hostname.c \
 	kill.c     \
+	link.c     \
 	ln.c       \
 	ls.c       \
 	md5sum.c   \
diff --git a/README b/README
(Continue reading)

k0ga | 16 Oct 11:25 2014

[ubase][PATCH] Update only the modified objects in util.a

From: "Roberto E. Vargas Caballero" <k0ga <at> shike2.com>

$? is expanded to all the requisites that are newer than the current target,
so we can avoid update files that were not modified since last time
the library was built.
 Makefile |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 07c2de0..f172c7c 100644
--- a/Makefile
+++ b/Makefile
 <at>  <at>  -163,7 +163,7  <at>  <at>  config.h:

 util.a: $(LIB)
 	 <at> echo AR $ <at> 
-	 <at> $(AR) -r -c $ <at>  $(LIB)
+	 <at> $(AR) -r -c $ <at>  $?
 	 <at> ranlib $ <at> 

 lastb: last


k0ga | 16 Oct 11:25 2014

[ubase][PATCH] Add last and lastb

From: "Roberto E. Vargas Caballero" <k0ga <at> shike2.com>

 Makefile     |    6 +++++-
 config.def.h |    2 ++
 last.c       |   59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 66 insertions(+), 1 deletion(-)
 create mode 100644 last.c

diff --git a/Makefile b/Makefile
index 3989a77..07c2de0 100644
--- a/Makefile
+++ b/Makefile
 <at>  <at>  -33,6 +33,7  <at>  <at>  LIB = \

 SRC = \
+	last.c              \
 	lastlog.c           \
 	chvt.c              \
 	clear.c             \
 <at>  <at>  -131,7 +132,7  <at>  <at>  MAN8 = \

 OBJ = $(SRC:.c=.o) $(LIB)
-BIN = $(SRC:.c=)
+BIN = $(SRC:.c=) lastb

 all: options binlib

(Continue reading)

Jeffrey Picard | 16 Oct 02:35 2014

[PATCH] [sbase] Adding human readable output to du

Hey all,

I was poking around at du recently and noticed it doesn’t support human readable output. This is pretty
easy to add however, at least in a simple form which just rounds the number of bytes down to the nearest
increment of the highest power of 1024 that’s appropriate. If there’s interest in this, I’d also be
happy to implement it in for df in ubase.

—Jeffrey Picard

diff --git a/du.c b/du.c
index 4e94cc5..d27ca1f 100644
--- a/du.c
+++ b/du.c
 <at>  <at>  -16,6 +16,7  <at>  <at>  static char file[PATH_MAX];
 static bool aflag = false;
 static bool sflag = false;
 static bool kflag = false;
+static bool hflag = false;

 static long du(const char *);
 static void print(long n, char *path);
 <at>  <at>  -53,6 +54,9  <at>  <at>  main(int argc, char *argv[])
        case 'k':
                kflag = true;
+       case 'h':
+               hflag = true;
+               break;
(Continue reading)

Quentin Rameau | 16 Oct 00:42 2014

[PATCH] [st] Avoid failing when embedding with a Window id of 0

I'd like to let st run with its own window when trying to embed it to a window with id 0 instead of exiting with an error.

 st.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/st.c b/st.c
index bcf96e9..23dd7f1 100644
--- a/st.c
+++ b/st.c
 <at>  <at>  -3136,8 +3136,8  <at>  <at>  xinit(void) {
 		| ButtonMotionMask | ButtonPressMask | ButtonReleaseMask;
 	xw.attrs.colormap = xw.cmap;

-	parent = opt_embed ? strtol(opt_embed, NULL, 0) : \
-			XRootWindow(xw.dpy, xw.scr);
+	if (!(opt_embed && (parent = strtol(opt_embed, NULL, 0))))
+		parent = XRootWindow(xw.dpy, xw.scr);
 	xw.win = XCreateWindow(xw.dpy, parent, xw.l, xw.t,
 			xw.w, xw.h, 0, XDefaultDepth(xw.dpy, xw.scr), InputOutput,
 			xw.vis, CWBackPixel | CWBorderPixel | CWBitGravity


Evan Gates | 15 Oct 23:40 2014

[sbase] [test] [patch] fix specific 3 argument case

After writing my own test[0] I checked and sbase already has test. I'm
including a patch to remove test from the TODO. I also noticed that
sbase's test handles a few specific cases incorrectly (documentation
at [1]).

test ! = foo
When there are 3 arguments and the second is a valid binary primary
test should perform that binary test. Only if the second argument is
not a valid binary primary and the first is ! should test negate the
two argument test. I've attached a patch that should fix this.

test ! ! !
test ! ! ! !
When there are 3 arguments and the second is not a valid primary and
the first is !, test should return the negation of the remaining two
argument test. In this case sbase's test works correctly for ! and ! !
but fails afterwards as it's not recursive. I don't yet have a patch
for this but I'm working on one.

Then again both of these areas may be places in which worse is better.


[0] https://bitbucket.org/emg/tidbits/src/11329f3834caad03f619f17c11cf3f530052ae74/test.c?at=master
[1] http://pubs.opengroup.org/onlinepubs/9699919799/utilities/test.html
diff --git a/TODO b/TODO
index 132dabe..969a09c 100644
--- a/TODO
(Continue reading)