diff options
author | kate.ward <kate.ward@forestent.com> | 2009-04-01 02:49:51 +0000 |
---|---|---|
committer | kate.ward <kate.ward@forestent.com> | 2009-04-01 02:49:51 +0000 |
commit | 812aeaed18af8de804b7cf4c8b7edcf950345250 (patch) | |
tree | f7ba83c0b65e4dc82b6674ee1493e5114fd1be85 /source/1.0/doc | |
parent | c521068ebb95298c61d714d1961d577ff86c58a7 (diff) | |
download | shflags-812aeaed18af8de804b7cf4c8b7edcf950345250.tar.gz |
fixed some stdandard vs. enhanced testing issues
Diffstat (limited to 'source/1.0/doc')
-rw-r--r-- | source/1.0/doc/CHANGES-1.0.txt | 17 | ||||
-rw-r--r-- | source/1.0/doc/RELEASE_NOTES-1.0.3.txt | 10 |
2 files changed, 16 insertions, 11 deletions
diff --git a/source/1.0/doc/CHANGES-1.0.txt b/source/1.0/doc/CHANGES-1.0.txt index f1375ac..4bbcbd6 100644 --- a/source/1.0/doc/CHANGES-1.0.txt +++ b/source/1.0/doc/CHANGES-1.0.txt @@ -4,22 +4,23 @@ Changes in shFlags 1.0.x Changes with 1.0.3 ------------------ -MAJOR CHANGE! FLAGS_ARGC is now obsolete, and is replaced by FLAGS_ARGV. +MAJOR CHANGE! ``FLAGS_ARGC`` is now obsolete, and is replaced by +``FLAGS_ARGV``. Fixed issue# 7 where long flags defined with '=' (e.g. --abc=123) made it impossible for the user to know how many non-flag command-line arguments were -available because the value returned by FLAGS_ARGC was wrong. The FLAGS_ARGC -value is now obsolete, but will be maintained for backwards compatibility. The -new method of getting the non-flag arguments is by executing 'eval set -- -"${FLAGS_ARGV}"' after the FLAGS command. The arguments will then be available -using the standard shell $#, $@, $*, $1, etc. variables. +available because the value returned by ``FLAGS_ARGC`` was wrong. The +``FLAGS_ARGC`` value is now obsolete, but will be maintained for backwards +compatibility. The new method of getting the non-flag arguments is by executing +``eval set -- "${FLAGS_ARGV}"`` after the **FLAGS** call. The arguments will +then be available using the standard shell $#, $@, $*, $1, etc. variables. Due to above fix for issue# 7, there is now proper support for mixing flags with non-flag arguments on the command-line. Previously, all non-flag arguments had to be at the end of the command-line. -Renamed _flags_standardGetopt() and _flags_enhancedGetopt() functions to -_flags_getoptStandard() and _flags_getoptEnhanced(). +Renamed ``_flags_standardGetopt()`` and ``_flags_enhancedGetopt()`` functions to +``_flags_getoptStandard()`` and ``_flags_getoptEnhanced()``. Took out the setting and restoration of the '-u' shell flag to treat unset variables as an error. No point in having it in this library as it is verified diff --git a/source/1.0/doc/RELEASE_NOTES-1.0.3.txt b/source/1.0/doc/RELEASE_NOTES-1.0.3.txt index 637a18d..10bfaca 100644 --- a/source/1.0/doc/RELEASE_NOTES-1.0.3.txt +++ b/source/1.0/doc/RELEASE_NOTES-1.0.3.txt @@ -27,8 +27,11 @@ wrong when flag and non-flag arguments are mixed together on the command-line. To gain access to the non-flag arguments, replace the following snippet of code in your scripts with the updated version. -:old: shift ${FLAGS_ARGC} -:new: eval set -- "${FLAGS_ARGV}" +old :: + shift ${FLAGS_ARGC} + +new :: + eval set -- "${FLAGS_ARGV}" Please see the CHANGES-1.0.txt file for a complete list of changes. @@ -78,7 +81,8 @@ Known Issues The **getopt** version provided by default with all versions of Mac OS X (up to and including 10.5.6) is the standard version. As such, only short flags are -supported. +supported. Additionally, the version supplied does not support intermixing flag +and non-flag arguments on the command-line. The **getopt** version provided by default with all versions of Solaris (up to and including Solaris 10 and OpenSolaris) is the standard version. As such, |