Debian Codegraph @

debian/patches/default-dir

raw
1 Create directories in ~/.gap
2 Index: gap-atlasrep-2.1.11/init.g
3 ===================================================================
4 --- gap-atlasrep-2.1.11.orig/init.g
5 +++ gap-atlasrep-2.1.11/init.g
6 @@ -3,6 +3,24 @@
7 #W init.g GAP 4 package AtlasRep Thomas Breuer
8 ##
9
10 +if UserPreference( "AtlasRep", "AtlasRepDataDirectory") = fail then
11 + CallAndInstallPostRestore(function()
12 + Perform(["datagens", "dataword", "dataext"], function(dirname)
13 + local package, l, dir;
14 + package := "AtlasRep";
15 + dir := GAPInfo.UserGapRoot;
16 + for l in ["","pkg",package,dirname] do
17 + dir := Concatenation([dir,"/",l]);
18 + if not IsDirectoryPath(dir) then
19 + CreateDir(dir);
20 + fi;
21 + od;
22 + return 0;
23 + end);
24 + SetUserPreference( "AtlasRep", "AtlasRepDataDirectory",Concatenation(GAPInfo.UserGapRoot,"/pkg/AtlasRep/"));
25 + end);
26 +fi;
27 +
28 # Read the declaration part.
29 ReadPackage( "atlasrep", "gap/userpref.g" );
30 ReadPackage( "atlasrep", "gap/bbox.gd" );