[Pkg-jed-commit] r259 - trunk/packages/jed/debian
Guenter Milde
milde-guest at costa.debian.org
Thu Apr 13 15:38:16 UTC 2006
Author: milde-guest
Date: 2006-04-13 15:38:15 +0000 (Thu, 13 Apr 2006)
New Revision: 259
Modified:
trunk/packages/jed/debian/changelog
trunk/packages/jed/debian/defaults.sl
Log:
new function debian_startup() that evaluates the files in /etc/jed.d
that will be run by default but can also be used in a script.
changelog: Changed back my name spelling as I don not like it to be
G?\195?\188nter on non UTF-8 aware systems.
Modified: trunk/packages/jed/debian/changelog
===================================================================
--- trunk/packages/jed/debian/changelog 2006-04-13 13:27:45 UTC (rev 258)
+++ trunk/packages/jed/debian/changelog 2006-04-13 15:38:15 UTC (rev 259)
@@ -30,9 +30,16 @@
+ <to be written>
+ added code to support slang_load_path and doc_path for
/usr/share/slsh/ introduced with SLang2 [JS]
+ + new function debian_startup() that evaluates the files in /etc/jed.d
+ (This function is run by default with every startup, but not if
+ * disabled with the --skip-debian-startup command line argument
+ * jed is called via the `jed-script` symlink
+ If a script needs the standard debian initialization (e.g. for
+ functions in the jed-extra package), it can call debian_startup()
+ explicitely.
[JS] Jörg Sommer <joerg at alea.gnuu.de>
- [GM] Günter Milde
+ [GM] Guenter Milde
[RL] Rafael Laboissiere
-- Debian JED Group <pkg-jed-devel at lists.alioth.debian.org> Thu, 13 Apr 2006 13:39:55 +0200
Modified: trunk/packages/jed/debian/defaults.sl
===================================================================
--- trunk/packages/jed/debian/defaults.sl 2006-04-13 13:27:45 UTC (rev 258)
+++ trunk/packages/jed/debian/defaults.sl 2006-04-13 15:38:15 UTC (rev 259)
@@ -13,6 +13,18 @@
% with `jed --skip-debian-startup`
define skip_debian_startup() {}
+define debian_startup()
+{
+ variable file, dir = listdir("/etc/jed.d/");
+ foreach ( dir[array_sort(dir)] )
+ {
+ file = ();
+ if (path_extname(file) == ".sl")
+ () = evalfile(strcat("/etc/jed.d/", file));
+ }
+}
+
+% add the path for slsh scripts
foreach (["/usr/share/slsh", "/usr/share/slsh/local-packages"])
{
variable dir = ();
@@ -37,17 +49,9 @@
}
}
-if (andelse
- % skip startup scripts if jed is started as `jed-script`
- {BATCH != 2}
- % skip startup scripts if jed is started with --skip-debian-startup
- {wherefirst(__argv == "--skip-debian-startup") == NULL}
+if ( andelse {BATCH != 2}
+ % skip startup scripts if jed is started as `jed-script`
+ {wherefirst(__argv == "--skip-debian-startup") == NULL}
+ % skip startup scripts if jed is started with --skip-debian-startup
)
-{
- $1 = listdir("/etc/jed.d/");
- foreach ( $1[ array_sort($1) ] ) {
- $2 = ();
- if (path_extname($2) == ".sl")
- () = evalfile("/etc/jed.d/"+$2);
- }
-}
+ debian_startup();
More information about the Pkg-jed-commit
mailing list