stdlib: Protect some functions using "--".
[goals.git] / docs / Goalfile.pod
index 37f3c07..85d19ba 100644 (file)
@@ -30,6 +30,14 @@ For example:
 
 Returns the directory part of the path.
 
+=head3 error (msg)
+
+For example:
+
+ error ("this should not happen")
+
+This prints the error message and causes goals to exit.
+
 =head3 extension (filename)
 
 For example:
@@ -56,6 +64,23 @@ Concatenate C<list1> and C<list2>.  It's not usually necessary to use
 this function since goals automatically flattens lists within lists
 into simple lists in many cases.
 
+=head3 read (filename)
+
+For example:
+
+ read ("filename") => "this is the content of filename"
+
+Read the contents of C<filename> and return it as a single string.
+If there is a trailing C<\n> in the file it is truncated.
+
+=head3 readlines (filename)
+
+For example:
+
+ readlines ("filename") => ["line1", "line2", "line3"]
+
+Read the lines in C<filename> returning a list of strings.
+
 =head3 realpath (filename)
 
 For example: