-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
22 lines (13 loc) · 850 Bytes
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
This gem contains the TomUtil module:
require 'tomutil/parallel'
include TomUtil
parallel_each(list, &block): A function that runs the associated block each in its own thread for each item in the list.
launch_threads(count, &block): A function that launches N threads with the same block.
prepend_exec(str, exec_str): a function that will execute the exec_str and will prepend it's stdout output with str.
require 'tomutil/padder'
include TomUtil
Padder: a class that I made for padding strings with spaces. It takes a list of strings and will pad any string to the max of the lengths of the strings in the list.
require 'tomutil/hash'
include TomUtil
Added subset(keys) to Hash. Pass it a list of keys and you get a new Hash with only those keys and their values in it.
HashComparer: a class for examining two hashes based on their keys.