fieker-DuValspielwiese
Last change
on this file since 9a24da was
cf23209,
checked in by Hans Schönemann <hannes@…>, 19 years ago
|
*hannes: cleanup the temp files
git-svn-id: file:///usr/local/Singular/svn/trunk@7950 2c84dea3-7e68-4137-9b89-c4e89433aadc
|
-
Property mode set to
100644
|
File size:
1.0 KB
|
Rev | Line | |
---|
[b35b93] | 1 | ring r=32003,(x,y,z),dp; |
---|
| 2 | link l=":w example.txt"; // type is Ascii, mode is overwrite |
---|
| 3 | l; |
---|
| 4 | status(l, "name"); // name is example.txt |
---|
| 5 | status(l, "open", "yes"); // link is not yet opened |
---|
| 6 | ideal i=maxideal(2); |
---|
| 7 | write (l,1,";",2,";","ideal i=",i,";"); |
---|
| 8 | status(l, "open", "yes"); // now link is open |
---|
| 9 | status(l, "mode"); // for writing |
---|
| 10 | write("example.txt","int j=5;");// data is appended to file |
---|
| 11 | read("example.txt"); // data is returned as string |
---|
| 12 | close(l); // link is closed |
---|
[7bb71fa] | 13 | execute(read(l)); // read string is executed |
---|
[b35b93] | 14 | status(l, "open", "yes"); // now link is open |
---|
| 15 | status(l, "mode"); // in read mode |
---|
| 16 | close(l); // link is closed |
---|
| 17 | // dump vars overwriting previous file content: |
---|
| 18 | dump(":w example.txt"); |
---|
| 19 | kill r; |
---|
| 20 | getdump("example.txt"); // get dump from file |
---|
[008cb6] | 21 | LIB "general.lib"; |
---|
| 22 | killall("proc"); |
---|
[60a365f] | 23 | kill killall; |
---|
[b35b93] | 24 | dump(""); // dump to stdout |
---|
[cf23209] | 25 | system("sh","rm example.txt"); |
---|
[46976a6] | 26 | LIB "tst.lib";tst_status(1);$ |
---|
Note: See
TracBrowser
for help on using the repository browser.