All Versions
10
Latest Version
Avg Release Cycle
0 days
Latest Release
1587 days ago
Changelog History
Changelog History
-
v0.6.0 Changes
May 31, 2019โ Added
- SugarUtils::File.append, which is explicitly for appending to a file. It will
also create a new file if it does not yet exist - SugarUtils::scrub_encoding, which is used for cleaning badly encoded
characters out of a string - SugarUtils::File.change_access, a wrapper for changing ownership and
permissions of a file - SugarUtils::File.atomic_write, to atomically write a file
โ Removed
- ๐ append support in SugarUtils::File.write (could have been specified by { mode: 'a })
๐ Changed
- :mode and :perm are now aliases for setting permissions on files in all the
related methods (i.e., .write, .write_json, .touch, .append) - convert SugarUtils::File.write_json to use .atomic_write
- SugarUtils::File.append, which is explicitly for appending to a file. It will
-
v0.5.0 Changes
May 31, 2019๐ Changed
- bring back :perm as option to set the permissions in SugarUtils::File.write and SugarUtils::File.touch methods
- ๐ :mode option in SugarUtils::File.write is now to be used for setting the file mode (e.g. read/write, append, etc). It can still be used for setting the permissions if it is an integer value for backwards compatibility purposes, but this usage has been deprecated.
-
v0.4.4 Changes
May 31, 2019๐ Changed
- ๐ fixed a bug in SugarUtils::File.read_json which it would raise an exception
instead of returning an empty Hash, when :raise_on_missing was disabled and
there was an error reading the file
- ๐ fixed a bug in SugarUtils::File.read_json which it would raise an exception
-
v0.4.3 Changes
May 31, 2019โ Added
- option to scrub character encoding in SugarUtils::File.read
- option to set mtime in SugarUtils::File.touch
-
v0.4.2 Changes
May 31, 2019๐ Changed
- 0๏ธโฃ default file creation permissions from 666 to 644.
-
v0.4.1 Changes
May 31, 2019โ Added
- options :owner, :group, :mode to SugarUtils::File.write and .touch
๐ Changed
- ๐ marked the :perm option as deprecated by :mode
-
v0.4.0 Changes
May 31, 2019โ Added
- SugarUtils::File.touch, which will ensure the directory before touching the
specified file
- SugarUtils::File.touch, which will ensure the directory before touching the
-
v0.3.0 Changes
May 31, 2019โ Added
- SugarUtils::File.read, with locking and error handling when reading a plain
text file - SugarUtils::File.write, with locking and error handling when writing a plain
text file
๐ Changed
- ๐ explicitly specify the Ruby v2.0.0 support limit
- divide SugarUtils::File.flock into .flock_shared and .flock_exclusive
- SugarUtils::File.read, with locking and error handling when reading a plain
-
v0.2.0 Changes
May 31, 2019โ Added
- โฑ SugarUtils::File.flock, for file locking with a timeout
- SugarUtils::File.read_json, with locking and error handling
- SugarUtils::File.write_json, with locking and error handling
- this CHANGELOG.md, following the http://keepachangelog.com/ guidelines
-
v0.1.0 Changes
May 31, 2019โ Added
- SugarUtils.ensure_boolean
- SugarUtils.ensure_integer