Skip to content

Commit

Permalink
better test for current file layout
Browse files Browse the repository at this point in the history
fixes issue #54
  • Loading branch information
DanGrayson committed Aug 25, 2014
1 parent 2e521cc commit 04d14f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions M2/Macaulay2/d/startup.m2.in
Original file line number Diff line number Diff line change
Expand Up @@ -306,8 +306,8 @@ initcurrentlayout := () -> (
issuffix := (s,t) -> t =!= null and s === substring(t,-#s);
bindir := dir exe | "/";
currentLayout = (
if issuffix(Layout#2#"bin",bindir) then Layout#2 else
if issuffix(Layout#1#"bin",bindir) then Layout#1
if issuffix(Layout#2#"bin","/"|bindir) then Layout#2 else
if issuffix(Layout#1#"bin","/"|bindir) then Layout#1
);
prefixDirectory = if currentLayout =!= null then substring(bindir,0,#bindir-#currentLayout#"bin");
if notify then stderr << "--prefixDirectory = " << prefixDirectory << endl;
Expand Down

0 comments on commit 04d14f8

Please sign in to comment.