Up to [cvs.NetBSD.org] / pkgsrc / devel / ruby-tins
Request diff between arbitrary revisions
Keyword substitution: kv
Default branch: MAIN
devel/ruby-tins: update to 1.62.0 1.62.0 (2026-11-06) Features * Added Tins::EnumJoined module providing #joined for human-friendly sentence-style joining of Enumerable objects. * Added Tins::Duration#to_human for generating human-readable duration strings with configurable styles and connectors. * Added Tins::Duration.parse_human class method to parse human-readable duration strings (inverse of #to_human). * Added Tins::Duration.from_string class method to create a Duration instance from a parsed string. * Tins::Duration.parse now accepts an Array of template strings, trying them in order until a match is found. * Added Tins::Duration::HUMAN_CONNECTORS constant with :none, :spaces, and :prose presets. * Added Tins::Duration::STYLE_DEFAULT_CONNECTOR constant mapping styles to default connector presets. Fixes * Tins::Duration.parse: Fixed a bug where a literal mismatch raised a RuntimeError instead of Tins::Duration::ParserError. * Tins::Null: Fixed documentation example to correctly show user.name.to_s instead of user.name. Improvements * Tins::Duration: Refactored parsing logic to extract parse_template as a private method. * Tins::Duration: Updated to_f documentation to clarify that it returns the magnitude (always non-negative) and that sign is tracked via negative?. * Tins::Duration: Changed template: default in parse to nil to support multi-template detection. * Tins::Duration: Extracted connector resolution logic into a private ConnectorResolver module. Build & CI * Bumped development dependency gem_hadar to require version 2.21.0 or later. Testing * Added tests for Tins::EnumJoined#joined covering empty, single, multiple elements, custom connectors, and type coercion. * Added tests for Tins::Duration#to_human covering styles, connectors, max units, and negative durations. * Added tests for Tins::Duration.parse_human covering roundtrips, custom connectors, and error cases. * Added tests for Tins::Duration.from_string covering default and custom templates. * Added tests for Tins::Duration.parse with template arrays, including order sensitivity and error handling. * Added tests for Tins::Duration::ParserError inheritance and specific mismatch scenarios. Documentation * Tins::Attempt: Rewrote documentation using YARD tags and added examples for fixed sleep, exponential backoff, and return-value mode. * Tins::EnumSqueeze: Added module-level documentation explaining squeeze/squeeze! semantics and usage examples. * Tins::DslKit: Fixed documentation examples for Eigenclass, ClassMethod, ThreadGlobal, Delegate, Scope, DynamicScope, and Deflect to accurately reflect API usage.
devel/ruby-tins: update to 1.61.0
1.60.0 (2026-10-02)
* Add unpadded %H, %M, and %u format directives to Duration#format for
unpadded hours, minutes, and seconds, complementing the existing
zero-padded %h, %m, and %s
* Update the directive regex in format from /%[DdhmSs%]/ to /%[DdHhMmuSs%]/
to match the new directives
1.60.1 (2026-10-08)
* Fix Limited shutdown race and busy-spin
- Move @tg.add to the executor thread to close a @count/@tg race
- Replace wait until done? + @executor.kill with sentinel, join, wait
- Remove unused done?
1.61.0 (2026-10-11)
* Tins::Once#only_once and Tins::Once#try_only_once now accept a touch:
option to automatically create the lock file via FileUtils.touch,
preventing Errno::ENOENT errors on first boot.
* Removed stale @raise [Errno::EAGAIN] and @raise [SystemCallError]
documentation, as flock returns false rather than raising an exception.
* Updated module examples to use the or idiom instead of rescue.
devel/ruby-tins: update to 1.59.0 1.58.0 (2026-09-24) * Add Tins::EnumSqueeze module providing squeeze and squeeze! methods that collapse consecutive duplicate elements, mirroring String#squeeze semantics. * Freeze the UNSET sentinel constant in Tins::Delegate to prevent accidental mutation of the shared Object.new instance. 1.59.0 (2026-09-25) * Add *sels and &block parameters to squeeze and squeeze!, allowing squeezing to be restricted to elements matching case-equality (===) selectors or a predicate block * Raise ArgumentError when both *sels and &block are provided * Change hot-loop comparison to item != prev || !block.(item) so non-matching elements are never collapsed * Forward (*sels, &block) from squeeze! to squeeze
devel/ruby-tins: update to 1.57.0 1.57.0 (2026-09-14) * Add keyword and block forwarding to Expose#expose * Add keyword argument support to Full#full? * Add keyword argument support to AskAndSend
devel/ruby-tins: update to 1.56.0 1.55.0 (2026-07-23) * Introduced the Tins::DeepTransform module, providing a stack-safe, iterative engine for deep transformations via the deep_transform method. * Added support for flexible lambda arity (1, 2, or 3) within deep_transform to allow access to the node, key/index, and parent container context. * Implemented a core extension in tins/xt/deep_transform that integrates DeepTransform into the Hash and Array classes. * Refactored Tins::HashSymbolizeKeysRecursive to utilize the new iterative engine instead of recursive logic. 1.56.0 (2026-07-25) * Added irb as a runtime dependency
devel/ruby-tins: update to 1.54.0
1.54.0 (2026-05-20)
* Tins::GO.go
- Improved handling of missing arguments: the system now issues a
warning when an option requiring an argument is missing its value and
prevents subsequent flags from being consumed as arguments.
- Added protection against overlapping flag definitions; flags defined
as both boolean and value-requiring are now disabled, and a warning is
issued.
- Expanded documentation for the go method to include pattern syntax,
ambiguity handling, side effects, and the in-place modification of the
_args_ array.
devel/ruby-tins: update to 1.53.0
1.53.0 (2026-04-14)
* Added stringify_keys_recursive and stringify_keys_recursive! methods to
* convert hash keys from symbols to strings
- Renamed _symbolize_keys_recursive to _transform_keys_recursive to
support both :to_sym and :to_s transformations
- Updated symbolize_keys_recursive to use the new
_transform_keys_recursive with transform: :to_sym
- Added comprehensive tests for the new stringify_keys_recursive
methods including circular reference handling
- Updated YARD documentation for all new and modified methods
* Made Token#bits immutable from outside by changing attr_accessor :bits to
attr_reader :bits and using direct instance variable assignment
* Bump s.rubygems_version from 4.0.3 to 4.0.10 in tins.gemspec
devel/ruby-tins: update to 1.52.0 1.52.0 (2026-02-23) * Renamed BASE32_EXTENDED_HEX_ALPHABET to BASE32_EXTENDED_UPPERCASE_HEX_ALPHABET for clarity. * Added BASE32_EXTENDED_LOWERCASE_HEX_ALPHABET constant for lowercase hex alphabet. * Updated BASE32_EXTENDED_HEX_ALPHABET to default to the uppercase variant. * Updated comment for BASE32_ALPHABET to specify RFC4648 compliance. * Improved maintainability by separating uppercase and lowercase hex alphabet variants. * Added require 'tins/hash_dfs' to lib/tins.rb and lib/tins/xt.rb. * Renamed thread‑local flag in HashBFS from :seen to :bfs_seen and updated all references. * Replaced calls to convert_to_hash_or_ary with bfs_convert_to_hash_or_ary in HashBFS. * Added bfs_convert_to_hash_or_ary method to HashBFS. * Added new module Tins::HashDFS providing depth‑first traversal with * thread‑local dfs_seen and dfs_convert_to_hash_or_ary. * Mixed HashDFS into ::Hash via lib/tins/xt/hash_dfs.rb. * Added tests/hash_dfs_test.rb with DFS tests mirroring BFS tests. * Updated YARD documentation for HashBFS#bfs with an example. * Optimized token analysis bit calculation by using a direct computation with Math.log2 instead of large exponentiation, improving performance and numerical stability for large token lengths.
devel/ruby-tins: update to 1.51.1
1.46.0 (2025-11-10)
* Updated s.rubygems_version from 3.6.9 to 3.7.2 in gemspec
* In Tins::GO
- Extended string defaults with EnumerableExtension transformation
- Modified v.transform_values! to check and extend strings that aren't
already EnumerableExtension
- Applied w << w to properly initialize the extension on default strings
- Updated tests to verify EnumerableExtension instances for both v and w
options
- Set default value for ?w option to 'baz' in test cases
- Maintained backward compatibility while normalizing string handling
- Ensured consistent behavior between ARGV strings and default strings
1.47.0 (2025-11-14)
* Tins::GO
- Renamed EnumerableExtension module to ArrayExtension throughout the
codebase
- Updated method calls from << to push for consistency with
ArrayExtension
- Modified to_a method implementation to return @arguments directly
- Updated test assertions to expect ArrayExtension instead of
EnumerableExtension
- Changed documentation comments to reflect the new ArrayExtension name
- Updated type checking from EnumerableExtension to ArrayExtension in
conditional logic
1.48.0 (2025-12-05)
* Added Tins::Token.analyze class method to calculate bit strength
* Moved bit calculation logic from initialize to analyze method for reuse
* Implemented bit strength calculation using formula: length ×
log₂(alphabet_size)
* Added comprehensive tests for the analyze method with various alphabets
* Support both token string and length-based analysis
* Implemented proper error handling for required parameters
* Updated initialize method to use the new analyze method
* Test cases verify bit strength for BASE16, BASE64, and BASE32 alphabets
* Method returns integer bit strength for cryptographic token analysis
1.49.0 (2025-12-18)
* Added support for IEC binary prefixes (Ki, Mi, Gi, etc.) via new :iec_uc
* and :iec_uppercase identifiers in the prefixes method
* Introduced PREFIX_IEC_UC constant for uppercase binary prefixes based on
1024-step increments
* Added SI prefix aliases :si_greek, :si_uc, and :si_uppercase for improved
usability
* Updated documentation to clarify that PREFIX_SI_UC is based on 1000-step
increments
* Enhanced the prefixes method to support new aliases while maintaining
backward compatibility
* Added comprehensive test cases for new prefix functionality
* Updated bundle update command to bundle update --all in CI configuration
* to ensure all dependencies are updated recursively
* Bumped RubyGems version from 3.7.2 to 4.0.2 in gemspec
1.50.0 (2025-12-19)
* Updated gem_hadar development dependency version to 2.10
* Added ruby:4.0-rc-alpine image to the images section in .all_images.yml
* Updated s.rubygems_version from 3.7.2 to 4.0.2 in gemspec
1.51.0 (2025-12-20)
* Added readline as a runtime dependency in both Rakefile and tins.gemspec
* The readline dependency version is set to >= 0 in tins.gemspec
* The readline dependency is added to the GemHadar block in Rakefile
1.51.1 (2026-01-14)
* Simplified lru_cache implementation to not need NOT_EXIST
* Updated rubygems_version from 4.0.2 to 4.0.3
* Changed gem_hadar development dependency from "~> 2.10" to ">= 2.16.3"
* Updated Ruby image version from 4.0-rc-alpine to 4.0-alpine in CI pipeline
* Added comprehensive module documentation for DSLKit explaining its purpose
and features
* Added CHANGES.md file to gem release process using GemHadar
devel/ruby-tins: update to 1.45.0 1.45.0 (2025-10-16) * Added patch alias for build and build= methods to align with SemVer terminology * Updated LEVELS mapping to support :patch as alias for :build index * Added patch and patch= aliases using the alias method * Added tests for patch getter and setter functionality * Updated gem_hadar development dependency from version 2.5 to 2.8 * Added openssl-dev to Docker build dependencies * Added github_workflows configuration to Rakefile for static.yml workflow * Removed .byebug_history from .gitignore file * Removed .byebug_history from ignore list in Rakefile * Removed duplicate mize entry from code indexer configuration
devel/ruby-tins: update to 1.44.1 1.43.0 (2025-09-05) * Added new dsl_lazy_accessor method that creates lazy-loaded accessors with * support for default blocks and dynamic block assignment * Removed support for Ruby versions 3.1 and 3.0 from image definitions 1.44.0 (2025-09-12) Documentation Improvements * Added extensive YARD documentation to all modules and methods throughout the library * Included usage examples and detailed parameter descriptions for better * developer experience * Updated README.md with clearer project information Code Modernization * Removed support for Ruby 1.8 and 1.9, focusing on modern Ruby versions * Eliminated deprecated compatibility modules and methods * Cleaned up unused requires and dependencies Technical Enhancements * Improved error handling in various modules (Attempt, Bijection, etc.) * Enhanced method signatures with proper parameter documentation * Added comprehensive test coverage for all functionality File Structure Changes * Updated gemspec to reflect modern Ruby standards * Modified Rakefile and .gitignore to exclude documentation directories * Removed obsolete test files and deprecated code paths 1.44.1 (2025-09-12) * Updated documentation link in README.md to point to GitHub.io instead of * RubyDoc.info * Added graceful handling for missing gem_hadar/simplecov gem by wrapping * require and start in begin/rescue block to catch LoadError * Modified gem packaging to include all files in .github and .contexts * directories using FileList for dynamic inclusion * Created static.yml file
devel/ruby-tins: update to 1.42.0 1.40.0 (2025-08-18) * Added Tins::StringNamedPlaceholders module with named_placeholders and named_placeholders_assign methods for string template substitution * Implemented support for both static and dynamic default values using Proc objects * Extended String class with tins/xt/string to include the new named placeholders functionality * Enhanced test coverage with comprehensive tests for all named placeholders functionality including error handling and duplicate placeholder management * Replaced manual SimpleCov setup with GemHadar::SimpleCov.start in test helper 1.41.0 (2025-08-18) * Added new named_placeholders_interpolate method for template substitution * Method supports both static and dynamic default values via Proc * Maintains backward compatibility with existing named_placeholders_assign method * Includes comprehensive tests for all functionality and error handling * Uses named_placeholders_assign internally for consistent implementation 1.42.0 (2025-08-19) * Improved core class extension safety by using respond_to? checks to avoid overriding existing methods such as deep_dup, camelize, and underscore * Simplified GitHub directory ignore patterns in Rakefile by removing recursive glob pattern for .github directory and directly specifying it as a single entry * Added documentation context files and YARD cheatsheet, including .contexts/ directory with code comment examples and updated Rakefile and tins.gemspec to include context files and context_spook dependency
devel/ruby-tins: update to 1.39.1 1.39.0 (2025-07-30) * Update utilsrc to remove binary option - Removed binary option from discover block in .utilsrc * Add support for thread naming in Limited class. - Added name parameter to Limited#initialize - Set @name attribute when provided - Set executor name with @name if available - Updated tests to use named threads * Update gemspec to use RubyGems version 3.6.9 - Update s.rubygems_version from 3.6.2 to 3.6.9 - Update s.add_development_dependency :gem_hadar from '~> 1.19' to '~> 1.21' 1.39.1 (2025-07-30) * Update gem_hadar dependency to version **1.22** - Updated gem_hadar development dependency to '~> **1.22**' - No other changes in the file
devel/ruby-tins: update to 1.38.0 1.38.0 (2025-01-04) Improved Tins::Limited concurrency handling: * Added execute method for task submission with a block * Changed process method to manage thread execution and queue management * Introduced stop method to signal processing termination * Modified test cases in limited_test.rb to accommodate new functionality * Added ensure clause to decrement counter and signal continuation after block execution Added support for Ruby 3.4 Alpine image: * Updated .all_images.yml to include Ruby 3.4-alpine environment * Added ruby:3.4-alpine to the list of supported images * Now uses 3.4 instead of 3.3, 3.2, and 3.1 for ruby versions
devel/ruby-tins: update to 1.37.1 1.37.1 (2024-12-13) * Renamed ZERO and BINARY constants to ZERO_RE and BINARY_RE to avoid collisions with Logger/File constants.
devel/ruby-tins: update to 1.37.0
1.37.0 (2024-10-19)
* Add support for module prepended blocks in Tins::Concern:
- Added prepend_features method to Tins concern
- Updated ConcernTest to test prepend feature
- Raise StandardError for duplicate block definitions for included and
prepended blocks
* Added class_methods method to Tins concern:
- Added class_methods method to lib/tins/concern.rb
o Creates or retrieves ClassMethods module for defining class-level
methods
- Updated tests in tests/concern_test.rb
o Added test for new baz1 and baz2 methods
o Tested availability of bar, baz1, and baz2 methods on A
devel/ruby-tins: update to 1.36.1
1.34.0 (2024-09-30)
* Secure write functionality updated
- Added support for Pathname objects in secure_write
- Updated File.new call to use to_s method on filename
- New test case added for secure_write with Pathname object
* Refactor version comparisons in various modules
- Added Tins::StringVersion.compare method to compare Ruby versions with
operators.
- Replaced direct version comparisons with compare method in multiple
modules.
* Deprecate deep_const_get and const_defined_in? methods
- Add deprecation notice for const_defined_in? for ruby >= 1.8
- Add deprecation notice for deep_const_get method with a new method name
const_get for ruby >= 2.0
* Refactor deprecation logic and tests
- Update Tins::Deprecate#deprecate method to allow for optional new_method
parameter.
- Modify tests/deprecate_test.rb to test deprecated methods with and
without messages.
* Prepare count_by method for deprecation
- Suggest using count with block instead in newer Rubies
* Prepare uniq_by / uniq_by! method for deprecation
- Suggest using uniq / uniq! with block instead in newer Rubies
1.35.0 (2024-10-10)
New Features
* Implemented breadth-first search in hashes using the Tins::HashBFS module.
- Added tests for the Tins::HashBFS module.
Refactoring and Cleanup
* Reformatted code.
* Removed TODO note from the TODO file.
* Cleaned up test requirements:
- Added require 'tins' to tests/test_helper.rb.
- Removed unnecessary require 'tins' lines from test files.
* Refactored BASE16 constants and alphabet:
- Added BASE16_LOWERCASE_ALPHABET constant.
- Added BASE16_UPPERCASE_ALPHABET constant.
Tool Updates
* Updated bundler command to use full index:
- Added --full-index flag to bundle install.
- Replaced bundle update with bundle install --full-index.
1.36.0 (2024-10-11)
Significant Changes
* Refactor bfs method in hash_bfs.rb:
- Rename include_nodes variable to visit_internal
- Update test cases in hash_bfs_test.rb to use new method signature
- Update method signature and docstring to reflect new behavior
* Update hash conversion logic:
- Rename method parameter from v to object
- Use object instead of v consistently throughout the method
- Add documentation for new method name and behavior
1.36.1 (2024-10-11)
* Fixed a typo in the code
devel/ruby-tins: update to 1.33.0 1.33.0 (2024-04-17) * test process convenience method * Support ruby 3.3
devel/ruby-tins: update to 1.32.1 No release note nor changes, so quote from commit log. 1.32.0 (2022-11-17) 02:26 * attempt method now supports passing of previously caught exception into the called block to let the handling behaviour depend on it. * Also some smaller changes to make debugging on multiple ruby releases, easier via all_images. 1.32.1 (2022-11-22) * Remove mutex for finalizer, let ruby take care of it
devel/ruby-tins: update to 1.31.1 1.31.1 (2022-04-26) * Create codeql-analysis.yml * Remove some hidden/unneeded files from gem
devel/ruby-tins: update to 1.31.0 Quote from commit logs. 1.29.1 (2021-05-20) * Reraise the same exception object for exceptions with additional methods. 1.30.0 (2021-12-27) * Fix for upcoming ruby 3.1.0. 1.31.0 (2022-01-07) * Add small LRU cache implementation.
devel/ruby-tins: update to 1.29.1 1.29.1 (2021-05-20) * Reraise the same exception object for exceptions with additional methods. * Readme: Remove homepage section, the link shows a 404.
devel/ruby-tins: update to 1.29.0 1.29.0 (2021-05-07) * Add more ways to reraise exceptions in attempt.
devel/ruby-tins: update to 1.28.0 No changes, but it adds support for Ruby 3.0.
devel/ruby-tins: update to 1.26.0 1.26.0 (2020-09-30) * Add shortcut that automatically waits.
devel/ruby-tins: update to 1.25.0 Update ruby-tins to 1.25.0. No release note nor changes. * Use ruby-sync. * Allow waiting for limited threads.
devel/ruby-tins: update to 1.24.1 Update ruby-tins to 1.24.1. No proper changes are available but it looks like better support for Ruby 2.6 and later. Please refer <https://github.com/flori/tins/compare/v1.20.2...v1.24.1>.
devel/ruby-tins: udpate to 1.20.2 * 2018-11-14 Release 1.20.2 - Fix ~x options * 2018-11-14 Release 1.20.1 - Add disabling boolean options in Tins::GO#go method. * 2018-11-14 Release 1.20.0 - Support default arguments in Tins::GO#go method. * 2018-11-07 Release 1.19.0 - Allow annotations without arguments * 2018-11-02 Release 1.18.0 - `thread_local` and `thread_global` with default block * 2018-10-15 Release 1.17.0 - Add Tins::TempIO::Enum class to wrap `temp_io` into Enumerator.
devel/ruby-tins: update to 1.16.3 2017-12-05 Release 1.16.3 * Improve temp_io method by not changing working dir. 2017-12-05 Release 1.16.2 * Improve temp_io method with a given name. 2017-12-05 Release 1.16.1 * Improve temp_io method with block 2017-11-29 Release 1.16.0 * Prove temp_io method with block
Update ruby-tinsto 1.15.0. 2017-06-29 Release 1.15.0 * Add support for smart duration formats with %D directive
Update ruby-tinsto 1.14.0. 2017-05-16 Release 1.14.0 * Add visit proc to determine if file should be visited.
Update ruby-tins to 1.13.2. 2016-11-23 Release 1.13.0 * Add expose method mostly for testing hidden methods.
Update ruby-tins to 1.12.0. 2016-08-04 Release 1.12.0 * Add Tins::Unit.parse? method to check for units in strings. 2016-07-12 Release 1.11.0 * Provide Tins::Unit.format and Tins::Unit.parse methods. 2016-05-25 Release 1.10.2 * Avoid some warnings. 2016-04-15 Release 1.10.1 * Fix bug in go if a concatenated argument comes last. 2016-04-12 Release 1.10.0 * Support mixed rest arguments in go argument parsing.
Update ruby-tins to 1.9.0. Add Tins::Duration class to display time durations.
Update ruby-tins to 1.8.2. 2016-01-18 Release 1.8.2 * Implement Tins::StringVersion::Version#dup and Tins::StringVersion::Version#clone.
Update ruby-tins to 1.8.1. * 2015-12-03 Release 1.8.1 - Remove some backports already existant in the newer supported rubies.
Update ruby-tins to 1.8.0.
* 2015-12-01 Release 1.8.0
- Add `foo_of` and `foo_annotations` methods to instances of classes with
annotated methods.
Update ruby-tins to 1.7.0. 2015-11-09 Release 1.7.0 * Officially require ruby >= 2.0 and use new hash syntax. * New feature attempt: sleep:-30 sleeps upto 30 seconds while retrying with an exponential waiting pattern. * Remove rotate and shuffle, recent rubies all support them. * Add an object oriented view on method signatures and use it to create method descriptions.
Update ruby-tins to 1.6.0. * 2015-08-13 Release 1.6.0 - Add complete method for readline completion * 2015-06-21 Release 1.5.4 - Avoid %i syntax for now * 2015-06-17 Release 1.5.3 - Make it run on 1.9 again. - Avoid a warning in Time.dummy implementation.
Update ruby-tins to 1.5.2. Changes are not available except commit log. <https://github.com/flori/tins/commits/master>
Update ruby-tins to 1.3.5.
* 2015-03-03 Release 1.3.5
- Don't automatically include #to method into Object, this can lead to some
confusion.
Update ruby-tins to 1.3.4. * 2015-02-04 Release 1.3.4 - Add some default alphabets to Tins::Token, e. g. Base64 - Add changes to Readme
Update ruby-tins to 1.3.3. * Add json support. * Avoid conflict with Rails.
Add ruby-tins package version 1.0.0. Approved by wiz@. All the stuff that isn't good/big enough for a real library.