summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAbhishek Amit <abhishek@gentoo.org>2003-11-15 02:18:00 +0000
committerAbhishek Amit <abhishek@gentoo.org>2003-11-15 02:18:00 +0000
commit15b458d75cb71184023c259c4452fefd661f5089 (patch)
tree3c26c2c9121db7bf72c3d2e41edc6c819358f614 /x11-misc/dsx
parentInitial import. (diff)
downloadgentoo-2-15b458d75cb71184023c259c4452fefd661f5089.tar.gz
gentoo-2-15b458d75cb71184023c259c4452fefd661f5089.tar.bz2
gentoo-2-15b458d75cb71184023c259c4452fefd661f5089.zip
Initial import.
Diffstat (limited to 'x11-misc/dsx')
-rw-r--r--x11-misc/dsx/ChangeLog11
-rw-r--r--x11-misc/dsx/Manifest4
-rw-r--r--x11-misc/dsx/dsx-0.1.ebuild19
-rw-r--r--x11-misc/dsx/files/digest-dsx-0.10
-rw-r--r--x11-misc/dsx/files/dsx-0.172
5 files changed, 104 insertions, 2 deletions
diff --git a/x11-misc/dsx/ChangeLog b/x11-misc/dsx/ChangeLog
new file mode 100644
index 000000000000..bf2e95edf845
--- /dev/null
+++ b/x11-misc/dsx/ChangeLog
@@ -0,0 +1,11 @@
+# ChangeLog for x11-misc/dsx
+# Copyright 2000-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/x11-misc/dsx/ChangeLog,v 1.1 2003/11/15 02:17:58 abhishek Exp $
+
+*dsx-0.1 (14 Nov 2003)
+
+ 14 Nov 2003; Abhishek Amit <abhishek@gentoo.org> dsx-0.1.ebuild,
+ files/dsx-0.1:
+ Inital import. Thanks to Ryan Grange <ryangrange@netscape.net> for porting
+ Xstart. Xtart is (c) 2001 civilme@mandrakesoft, released under GPL v2
+
diff --git a/x11-misc/dsx/Manifest b/x11-misc/dsx/Manifest
index 100a7f9d8cbe..0b66eac4075c 100644
--- a/x11-misc/dsx/Manifest
+++ b/x11-misc/dsx/Manifest
@@ -1,4 +1,4 @@
-MD5 f47031a03386d11e09ba16b7018ed19a dsx-0.1.ebuild 377
-MD5 47cadfc9b8f61e8e0f4b30a1033b0267 ChangeLog 329
+MD5 8e31b046335d3e4dba6fffaacf836ca3 dsx-0.1.ebuild 468
+MD5 7a0ef1cb49a0429baf0bb141afd92660 ChangeLog 466
MD5 852f6bfd9b06ad7fdae0d53fa4db2c04 files/dsx-0.1 2218
MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-dsx-0.1 0
diff --git a/x11-misc/dsx/dsx-0.1.ebuild b/x11-misc/dsx/dsx-0.1.ebuild
new file mode 100644
index 000000000000..1a5762e3970d
--- /dev/null
+++ b/x11-misc/dsx/dsx-0.1.ebuild
@@ -0,0 +1,19 @@
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/x11-misc/dsx/dsx-0.1.ebuild,v 1.1 2003/11/15 02:17:58 abhishek Exp $
+
+DESCRIPTION="dsx - command line selection of your X desktop environment"
+LICENSE="GPL-2"
+SLOT="0"
+
+KEYWORDS="~x86"
+
+IUSE=""
+DEPEND=""
+RDEPEND="x11-base/xfree
+>=dev-lang/python-2.1"
+
+src_install() {
+ exeinto /usr/bin
+ newexe ${FILESDIR}/${P} dsx
+}
diff --git a/x11-misc/dsx/files/digest-dsx-0.1 b/x11-misc/dsx/files/digest-dsx-0.1
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/x11-misc/dsx/files/digest-dsx-0.1
diff --git a/x11-misc/dsx/files/dsx-0.1 b/x11-misc/dsx/files/dsx-0.1
new file mode 100644
index 000000000000..d8f5e7192928
--- /dev/null
+++ b/x11-misc/dsx/files/dsx-0.1
@@ -0,0 +1,72 @@
+#!/usr/bin/env python
+# dsx is Mandrakesoft's Xtart modified to work with a Gentoo Linux system.
+# Gentoo doesn't use a wmsession.d directory, so we're going to accept the
+# /etc/X11/Sessions executables as our menu and our command parameters.
+# I also tried to increase the robustness of the entry checking and make the
+# error messages less condescending.
+# The 0 option for "no wm" was removed. I altered it to run option 1 instead.
+
+### Original copyright / license message from Xtart... ###
+# This is an official linux-mandrake extension of the X windowing system for
+# the benefit of Declan Moriarty Copyright 2001 by civileme@mandrakesoft all
+# rights reserved. Use is hereby granted under the GNU General Publoic
+# License version 2 or any future version of said license at the user's option
+#
+# No Warranty of course.
+# This program is designed for those who want to work in concole and
+# occasionally boot into window managers or who want to avoid theme
+# persistence from one WM to another.
+################
+import sys
+import os
+import popen2
+import string
+import math
+def complain():
+ print 'X initiation aborted on invalid selection.'
+ sys.exit(0)
+ return
+print
+print 'Welcome to the Desktop Selector for X'
+print
+fspc=os.path.expanduser('~')+'/'
+io=popen2.Popen3('ls /etc/X11/Sessions',1)
+L=io.fromchild.readlines()
+Sessions={}
+Sessionkeys=[]
+primekey=0
+for k in L:
+ primekey+=1
+ name=k[:-1]
+ command='/etc/X11/Sessions/'+k[:-1]
+ Sessions[primekey]=(name, command)
+Sessionkeys=Sessions.keys()
+Sessionkeys.sort()
+for j in Sessionkeys:
+ if os.system('[ -x '+Sessions[j][1]+' ]') == 0:
+ print j, Sessions[j][0]
+ pass
+print
+sys.stdin.flush()
+s=raw_input('Enter the number of your desired desktop environment [1]: ')
+if len(s)==0:
+ s='1'
+if s=='0':
+ s='1'
+for j in range(len(s)):
+ if string.find(string.digits,s[j]) == -1:
+ print "'" + s[j] + "' isn't a digit."
+ complain()
+if len(s)>int(math.log10(primekey))+1:
+ print "That number is too big."
+ complain()
+well=int(s)
+wellformed=Sessions.has_key(well)
+if wellformed:
+ os.execvp('xinit',Sessions[well])
+else:
+ print
+ print 'Your selection was invalid.'
+ print
+ complain()
+