Skip to content

Commit

Permalink
Fix script to create workspace for gapL
Browse files Browse the repository at this point in the history
In GAP 4.12. gap is always started without readline when standard
input is not a terminal.
Instead of redirecting input we now read a file.
  • Loading branch information
frankluebeck committed Aug 22, 2022
1 parent f9cafdd commit b604859
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 25 deletions.
30 changes: 5 additions & 25 deletions gapsync/CreateWorkspace.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,33 +6,13 @@
# containing 'bin', 'lib', 'pkg' and so on as subdirectories) to
# generate a workspace file:
# bin/wsgap4
#

wsname=wsgap4

./gap -l `pwd`"/local;"`pwd` -r > /dev/null <<EOF
# load here all packages you want to include in the standard workspace
for nam in [ "atlasrep", "autpgrp", "browse", "cohomolo", "crisp", "cryst",
"crystcat", "ctbllib", "datastructures", "edim", "factint", "format",
"grape", "grpconst", "guava", "kbmag", "laguna", "quagroup", "zeromq" ]
do
LoadPackage(nam);
od;
Unbind(nam);
# load help book infos with a dummy help query
??blablfdfhskhks
# The file reads gapsync/dostartforws.g before saving the workspace.
#
# You can customize the content of the workspace by copying
# gapsync/CreateWorkspace.sh to local/bin/CreateWorkspace.

# a small trick to make everything sensible available to the TAB completion
function() local a; for a in NamesGVars() do if ISB_GVAR(a) then
VAL_GVAR(a); fi;od;end;
last();

# save the workspace
SaveWorkspace("bin/$wsname");

quit;
EOF
./gap -l `pwd`"/local;"`pwd` -r gapsync/dostartforws.g > /dev/null


22 changes: 22 additions & 0 deletions gapsync/dostartforws.g
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@

# load here all packages you want to include in the standard workspace
for nam in [ "atlasrep", "autpgrp", "browse", "cohomolo", "crisp", "cryst",
"crystcat", "ctbllib", "datastructures", "edim", "factint", "format",
"grape", "grpconst", "guava", "kbmag", "laguna", "quagroup", "zeromq",
"standardff" ]
do
LoadPackage(nam);
od;
Unbind(nam);

# load help book infos with a dummy help query
??blablfdfhskhks

# a small trick to make everything sensible available to the TAB completion
function() local a; for a in NamesGVars() do if ISB_GVAR(a) then VAL_GVAR(a); fi;od;end();

# save the workspace
SaveWorkspace("bin/wsgap4");

QUIT;

0 comments on commit b604859

Please sign in to comment.