mack-facets 0.8.2 → 0.8.3
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/gems.rb +5 -1
- data/lib/gems/activesupport-2.2.2/lib/active_support.rb +61 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/base64.rb +33 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/basic_object.rb +24 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/buffered_logger.rb +122 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/cache.rb +223 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/cache/compressed_mem_cache_store.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/cache/drb_store.rb +15 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/cache/file_store.rb +72 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/cache/mem_cache_store.rb +127 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/cache/memory_store.rb +52 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/cache/synchronized_memory_store.rb +47 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/callbacks.rb +280 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext.rb +4 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/array.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/array/access.rb +53 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/array/conversions.rb +183 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/array/extract_options.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/array/grouping.rb +106 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/array/random_access.rb +12 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/base64.rb +4 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/base64/encoding.rb +16 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/benchmark.rb +12 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/bigdecimal.rb +6 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/bigdecimal/conversions.rb +37 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/blank.rb +58 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/cgi.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/cgi/escape_skipping_slashes.rb +14 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/class.rb +4 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/class/attribute_accessors.rb +54 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/class/delegating_attributes.rb +46 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/class/inheritable_attributes.rb +140 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/class/removal.rb +50 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/date.rb +10 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/date/behavior.rb +42 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/date/calculations.rb +230 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/date/conversions.rb +107 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/date_time.rb +12 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/date_time/calculations.rb +126 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/date_time/conversions.rb +96 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/duplicable.rb +43 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/enumerable.rb +107 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/exception.rb +41 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/file.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/file/atomic.rb +46 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/float.rb +7 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/float/rounding.rb +24 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/float/time.rb +27 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash.rb +14 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/conversions.rb +259 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/deep_merge.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/diff.rb +19 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/except.rb +25 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/indifferent_access.rb +137 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/keys.rb +52 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/reverse_merge.rb +35 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/hash/slice.rb +33 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/integer.rb +9 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/integer/even_odd.rb +29 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/integer/inflections.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/integer/time.rb +45 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel/agnostics.rb +11 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel/daemonizing.rb +7 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel/debugger.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel/reporting.rb +59 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel/requires.rb +24 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/load_error.rb +38 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/logger.rb +143 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/aliasing.rb +74 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/attr_accessor_with_default.rb +31 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/attr_internal.rb +32 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/attribute_accessors.rb +58 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/delegation.rb +95 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/inclusion.rb +30 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/introspection.rb +90 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/loading.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/model_naming.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/module/synchronization.rb +39 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/name_error.rb +17 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/numeric.rb +9 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/numeric/bytes.rb +44 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/numeric/conversions.rb +19 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/numeric/time.rb +81 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/object.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/object/conversions.rb +14 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/object/extending.rb +80 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/object/instance_variables.rb +74 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/object/metaclass.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/object/misc.rb +74 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/pathname.rb +7 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/pathname/clean_within.rb +14 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/proc.rb +12 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/process.rb +1 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/process/daemon.rb +25 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/range.rb +11 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/range/blockless_step.rb +32 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/range/conversions.rb +27 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/range/include_range.rb +30 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/range/overlaps.rb +15 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/rexml.rb +36 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string.rb +22 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/access.rb +82 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/behavior.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/conversions.rb +28 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/filters.rb +26 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/inflections.rb +167 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/iterators.rb +21 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/multibyte.rb +81 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/starts_ends_with.rb +35 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/string/xchar.rb +11 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/symbol.rb +14 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/time.rb +42 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/time/behavior.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/time/calculations.rb +303 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/time/conversions.rb +90 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/core_ext/time/zones.rb +86 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/dependencies.rb +621 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/deprecation.rb +243 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/duration.rb +96 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/gzip.rb +25 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/inflections.rb +55 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/inflector.rb +397 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/decoding.rb +63 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/date.rb +21 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/date_time.rb +21 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/enumerable.rb +12 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/false_class.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/hash.rb +47 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/nil_class.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/numeric.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/object.rb +6 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/regexp.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/string.rb +36 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/symbol.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/time.rb +21 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoders/true_class.rb +5 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/encoding.rb +37 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/json/variable.rb +10 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/locale/en.yml +32 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/memoizable.rb +82 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/multibyte.rb +33 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/multibyte/chars.rb +679 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/multibyte/exceptions.rb +8 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/multibyte/unicode_database.rb +71 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/option_merger.rb +17 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/ordered_hash.rb +58 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/ordered_options.rb +19 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/rescuable.rb +108 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/secure_random.rb +197 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/string_inquirer.rb +21 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/test_case.rb +24 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/testing/core_ext/test.rb +6 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/testing/core_ext/test/unit/assertions.rb +72 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/testing/default.rb +9 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/testing/performance.rb +452 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/testing/setup_and_teardown.rb +120 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/time_with_zone.rb +328 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/values/time_zone.rb +403 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/values/unicode_tables.dat +0 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor.rb +34 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/blankslate.rb +113 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/builder.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/builder/blankslate.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/builder/css.rb +250 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/builder/xchar.rb +115 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/builder/xmlbase.rb +139 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/builder/xmlevents.rb +63 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/builder-2.1.2/builder/xmlmarkup.rb +328 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n.rb +194 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n/backend/simple.rb +216 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n/exceptions.rb +53 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/memcache-client-1.5.1/memcache.rb +849 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo.rb +33 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/data_timezone.rb +47 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/data_timezone_info.rb +228 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Africa/Algiers.rb +55 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Africa/Cairo.rb +219 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Africa/Casablanca.rb +40 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Africa/Harare.rb +18 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Africa/Johannesburg.rb +25 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Africa/Monrovia.rb +22 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Africa/Nairobi.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Argentina/Buenos_Aires.rb +166 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Argentina/San_Juan.rb +86 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Bogota.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Caracas.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Chicago.rb +283 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Chihuahua.rb +136 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Denver.rb +204 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Godthab.rb +161 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Guatemala.rb +27 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Halifax.rb +274 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Indiana/Indianapolis.rb +149 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Juneau.rb +194 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/La_Paz.rb +22 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Lima.rb +35 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Los_Angeles.rb +232 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Mazatlan.rb +139 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Mexico_City.rb +144 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Monterrey.rb +131 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/New_York.rb +282 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Phoenix.rb +30 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Regina.rb +74 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Santiago.rb +205 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Sao_Paulo.rb +171 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/St_Johns.rb +288 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/America/Tijuana.rb +196 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Almaty.rb +67 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Baghdad.rb +73 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Baku.rb +161 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Bangkok.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Chongqing.rb +33 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Colombo.rb +30 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Dhaka.rb +27 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Hong_Kong.rb +87 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Irkutsk.rb +165 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Jakarta.rb +30 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Jerusalem.rb +163 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Kabul.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Kamchatka.rb +163 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Karachi.rb +30 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Katmandu.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Kolkata.rb +25 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Krasnoyarsk.rb +163 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Kuala_Lumpur.rb +31 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Kuwait.rb +18 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Magadan.rb +163 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Muscat.rb +18 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Novosibirsk.rb +164 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Rangoon.rb +24 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Riyadh.rb +18 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Seoul.rb +34 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Shanghai.rb +35 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Singapore.rb +33 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Taipei.rb +59 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Tashkent.rb +47 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Tbilisi.rb +78 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Tehran.rb +121 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Tokyo.rb +30 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Ulaanbaatar.rb +65 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Urumqi.rb +33 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Vladivostok.rb +164 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Yakutsk.rb +163 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Yekaterinburg.rb +165 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Asia/Yerevan.rb +165 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Atlantic/Azores.rb +270 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Atlantic/Cape_Verde.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Atlantic/South_Georgia.rb +18 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Australia/Adelaide.rb +187 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Australia/Brisbane.rb +35 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Australia/Darwin.rb +29 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Australia/Hobart.rb +193 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Australia/Melbourne.rb +185 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Australia/Perth.rb +37 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Australia/Sydney.rb +185 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Etc/UTC.rb +16 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Amsterdam.rb +228 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Athens.rb +185 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Belgrade.rb +163 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Berlin.rb +188 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Bratislava.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Brussels.rb +232 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Bucharest.rb +181 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Budapest.rb +197 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Copenhagen.rb +179 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Dublin.rb +276 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Helsinki.rb +163 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Istanbul.rb +218 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Kiev.rb +168 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Lisbon.rb +268 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Ljubljana.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/London.rb +288 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Madrid.rb +211 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Minsk.rb +170 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Moscow.rb +181 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Paris.rb +232 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Prague.rb +187 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Riga.rb +176 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Rome.rb +215 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Sarajevo.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Skopje.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Sofia.rb +173 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Stockholm.rb +165 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Tallinn.rb +172 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Vienna.rb +183 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Vilnius.rb +170 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Warsaw.rb +212 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Europe/Zagreb.rb +13 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Auckland.rb +202 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Fiji.rb +23 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Guam.rb +22 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Honolulu.rb +28 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Majuro.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Midway.rb +25 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Noumea.rb +25 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Pago_Pago.rb +26 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Port_Moresby.rb +20 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/definitions/Pacific/Tongatapu.rb +27 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/info_timezone.rb +52 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/linked_timezone.rb +51 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/linked_timezone_info.rb +44 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/offset_rationals.rb +98 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/ruby_core_support.rb +56 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/time_or_datetime.rb +292 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/timezone.rb +508 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/timezone_definition.rb +56 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/timezone_info.rb +40 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/timezone_offset_info.rb +94 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/timezone_period.rb +198 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/tzinfo-0.3.12/tzinfo/timezone_transition_info.rb +129 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/vendor/xml-simple-1.0.11/xmlsimple.rb +1021 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/version.rb +9 -0
- data/lib/gems/activesupport-2.2.2/lib/active_support/whiny_nil.rb +58 -0
- data/lib/gems/activesupport-2.2.2/lib/activesupport.rb +1 -0
- data/lib/gems/extlib-0.9.9/Rakefile +182 -0
- data/lib/gems/extlib-0.9.9/lib/extlib.rb +56 -0
- data/lib/gems/{extlib-0.9.8 → extlib-0.9.9}/lib/extlib/assertions.rb +0 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/blank.rb +89 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/boolean.rb +11 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/class.rb +175 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/datetime.rb +27 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/dictionary.rb +433 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/hash.rb +442 -0
- data/lib/gems/{extlib-0.9.8 → extlib-0.9.9}/lib/extlib/hook.rb +0 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/inflection.rb +434 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/lazy_array.rb +397 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/logger.rb +202 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/mash.rb +148 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/module.rb +41 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/nil.rb +5 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/numeric.rb +5 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/object.rb +162 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/object_space.rb +13 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/pathname.rb +15 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/pooling.rb +231 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/rubygems.rb +38 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/simple_set.rb +66 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/string.rb +175 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/struct.rb +17 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/symbol.rb +21 -0
- data/lib/gems/{extlib-0.9.8 → extlib-0.9.9}/lib/extlib/tasks/release.rb +0 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/time.rb +41 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/version.rb +3 -0
- data/lib/gems/extlib-0.9.9/lib/extlib/virtual_file.rb +10 -0
- data/lib/mack-facets.rb +11 -15
- data/lib/mack-facets/1_9/test/unit/error.rb +15 -0
- data/lib/mack-facets/extensions/array.rb +0 -5
- data/lib/mack-facets/extensions/date_time.rb +5 -2
- data/lib/mack-facets/extensions/duration.rb +85 -0
- data/lib/mack-facets/extensions/kernel.rb +8 -0
- data/lib/mack-facets/extensions/string.rb +7 -86
- data/lib/mack-facets/utils/method_list.rb +49 -0
- metadata +413 -511
- data/lib/gems/extlib-0.9.8/lib/extlib.rb +0 -56
- data/lib/gems/extlib-0.9.8/lib/extlib/blank.rb +0 -59
- data/lib/gems/extlib-0.9.8/lib/extlib/boolean.rb +0 -11
- data/lib/gems/extlib-0.9.8/lib/extlib/class.rb +0 -175
- data/lib/gems/extlib-0.9.8/lib/extlib/datetime.rb +0 -9
- data/lib/gems/extlib-0.9.8/lib/extlib/dictionary.rb +0 -433
- data/lib/gems/extlib-0.9.8/lib/extlib/hash.rb +0 -419
- data/lib/gems/extlib-0.9.8/lib/extlib/inflection.rb +0 -435
- data/lib/gems/extlib-0.9.8/lib/extlib/lazy_array.rb +0 -106
- data/lib/gems/extlib-0.9.8/lib/extlib/logger.rb +0 -202
- data/lib/gems/extlib-0.9.8/lib/extlib/mash.rb +0 -148
- data/lib/gems/extlib-0.9.8/lib/extlib/module.rb +0 -41
- data/lib/gems/extlib-0.9.8/lib/extlib/nil.rb +0 -5
- data/lib/gems/extlib-0.9.8/lib/extlib/numeric.rb +0 -5
- data/lib/gems/extlib-0.9.8/lib/extlib/object.rb +0 -175
- data/lib/gems/extlib-0.9.8/lib/extlib/object_space.rb +0 -13
- data/lib/gems/extlib-0.9.8/lib/extlib/pathname.rb +0 -5
- data/lib/gems/extlib-0.9.8/lib/extlib/pooling.rb +0 -239
- data/lib/gems/extlib-0.9.8/lib/extlib/rubygems.rb +0 -38
- data/lib/gems/extlib-0.9.8/lib/extlib/simple_set.rb +0 -39
- data/lib/gems/extlib-0.9.8/lib/extlib/string.rb +0 -132
- data/lib/gems/extlib-0.9.8/lib/extlib/struct.rb +0 -8
- data/lib/gems/extlib-0.9.8/lib/extlib/symbol.rb +0 -17
- data/lib/gems/extlib-0.9.8/lib/extlib/time.rb +0 -19
- data/lib/gems/extlib-0.9.8/lib/extlib/version.rb +0 -3
- data/lib/gems/extlib-0.9.8/lib/extlib/virtual_file.rb +0 -10
- data/lib/gems/facets-2.4.5/VERSION +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets-live.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets-load.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets.rb +0 -11
- data/lib/gems/facets-2.4.5/lib/core/facets/array.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/array/combination.rb +0 -59
- data/lib/gems/facets-2.4.5/lib/core/facets/array/conjoin.rb +0 -58
- data/lib/gems/facets-2.4.5/lib/core/facets/array/delete.rb +0 -61
- data/lib/gems/facets-2.4.5/lib/core/facets/array/index.rb +0 -48
- data/lib/gems/facets-2.4.5/lib/core/facets/array/indexable.rb +0 -73
- data/lib/gems/facets-2.4.5/lib/core/facets/array/merge.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/array/not_empty.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/array/only.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/array/pad.rb +0 -41
- data/lib/gems/facets-2.4.5/lib/core/facets/array/permutation.rb +0 -30
- data/lib/gems/facets-2.4.5/lib/core/facets/array/product.rb +0 -57
- data/lib/gems/facets-2.4.5/lib/core/facets/array/recursively.rb +0 -30
- data/lib/gems/facets-2.4.5/lib/core/facets/array/rotate.rb +0 -42
- data/lib/gems/facets-2.4.5/lib/core/facets/array/select.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/array/splice.rb +0 -30
- data/lib/gems/facets-2.4.5/lib/core/facets/array/stackable.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/array/traverse.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/binding.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/binding/caller.rb +0 -54
- data/lib/gems/facets-2.4.5/lib/core/facets/binding/defined.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/binding/eval.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/binding/local_variables.rb +0 -15
- data/lib/gems/facets-2.4.5/lib/core/facets/binding/self.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/bitmask.rb +0 -104
- data/lib/gems/facets-2.4.5/lib/core/facets/blank.rb +0 -60
- data/lib/gems/facets-2.4.5/lib/core/facets/boolean.rb +0 -156
- data/lib/gems/facets-2.4.5/lib/core/facets/callstack.rb +0 -52
- data/lib/gems/facets-2.4.5/lib/core/facets/cattr.rb +0 -2
- data/lib/gems/facets-2.4.5/lib/core/facets/class.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/class/cattr.rb +0 -115
- data/lib/gems/facets-2.4.5/lib/core/facets/class/cattr_accessor.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/class/cattr_reader.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/class/cattr_writer.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/class/descendents.rb +0 -36
- data/lib/gems/facets-2.4.5/lib/core/facets/class/methodize.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/class/pathize.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/class/prepend.rb +0 -50
- data/lib/gems/facets-2.4.5/lib/core/facets/class/subclasses.rb +0 -2
- data/lib/gems/facets-2.4.5/lib/core/facets/class/to_proc.rb +0 -42
- data/lib/gems/facets-2.4.5/lib/core/facets/comparable.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/comparable/bound.rb +0 -65
- data/lib/gems/facets-2.4.5/lib/core/facets/comparable/cmp.rb +0 -38
- data/lib/gems/facets-2.4.5/lib/core/facets/comparable/comparable.rb +0 -42
- data/lib/gems/facets-2.4.5/lib/core/facets/dir.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/dir/ascend.rb +0 -59
- data/lib/gems/facets-2.4.5/lib/core/facets/dir/descend.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/dir/multiglob.rb +0 -92
- data/lib/gems/facets-2.4.5/lib/core/facets/dir/parent.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/dir/recurse.rb +0 -29
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/accumulate.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/cluster_by.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/collect.rb +0 -54
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/commonality.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/count.rb +0 -26
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/divide.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/duplicates.rb +0 -38
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/each_by.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/entropy.rb +0 -37
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/frequency.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/group_by.rb +0 -27
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/inject.rb +0 -31
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/map_send.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/mash.rb +0 -32
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/mode.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/modulate.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/none.rb +0 -31
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/occur.rb +0 -38
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/one.rb +0 -38
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/probability.rb +0 -36
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/split.rb +0 -27
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/sum.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/enumerable/uniq_by.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/exception.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/exception/detail.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/exception/suppress.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/file.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/file/append.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/file/create.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/file/null.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/file/read.rb +0 -41
- data/lib/gems/facets-2.4.5/lib/core/facets/file/rewrite.rb +0 -88
- data/lib/gems/facets-2.4.5/lib/core/facets/file/rootname.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/file/split_root.rb +0 -10
- data/lib/gems/facets-2.4.5/lib/core/facets/file/write.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/file/writelines.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/filetest.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/filetest/root.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/float.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/float/round.rb +0 -2
- data/lib/gems/facets-2.4.5/lib/core/facets/functor.rb +0 -77
- data/lib/gems/facets-2.4.5/lib/core/facets/hash.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/alias.rb +0 -31
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/argumentize.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/at.rb +0 -8
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/autonew.rb +0 -42
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/collate.rb +0 -45
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/delete.rb +0 -47
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/diff.rb +0 -11
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/except.rb +0 -27
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/insert.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/inverse.rb +0 -27
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/join.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/keys.rb +0 -45
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/mash.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/merge.rb +0 -30
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/op.rb +0 -7
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/op_add.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/op_and.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/op_mul.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/op_or.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/op_push.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/op_sub.rb +0 -26
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/recursive_merge.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/recursively.rb +0 -29
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/rekey.rb +0 -59
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/select.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/slice.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/swap.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/to_h.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/to_proc.rb +0 -41
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/to_struct.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/traverse.rb +0 -41
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/update.rb +0 -81
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/weave.rb +0 -81
- data/lib/gems/facets-2.4.5/lib/core/facets/hash/zipnew.rb +0 -2
- data/lib/gems/facets-2.4.5/lib/core/facets/indexable.rb +0 -251
- data/lib/gems/facets-2.4.5/lib/core/facets/integer.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/integer/even.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/integer/factorial.rb +0 -30
- data/lib/gems/facets-2.4.5/lib/core/facets/integer/multiple.rb +0 -15
- data/lib/gems/facets-2.4.5/lib/core/facets/integer/odd.rb +0 -35
- data/lib/gems/facets-2.4.5/lib/core/facets/integer/of.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/integer/ordinal.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/__callee__.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/__class__.rb +0 -9
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/__dir__.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/__get__.rb +0 -10
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/__method__.rb +0 -36
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/__set__.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/as.rb +0 -100
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/ask.rb +0 -27
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/attr_singleton.rb +0 -62
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/complete.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/constant.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/d.rb +0 -26
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/deep_copy.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/demo.rb +0 -23
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/ergo.rb +0 -42
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/here.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/in.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/instance.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/instance_assign.rb +0 -41
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/instance_class.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/instance_exec.rb +0 -40
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/instance_send.rb +0 -7
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/instance_variables.rb +0 -99
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/maybe.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/not_nil.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/object_class.rb +0 -10
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/object_hexid.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/object_send.rb +0 -32
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/p.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/populate.rb +0 -73
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/qua_class.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/require_all.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/require_local.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/resc.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/respond.rb +0 -23
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/returning.rb +0 -23
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/silence.rb +0 -75
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/singleton_class.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/tap.rb +0 -32
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/try.rb +0 -23
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/val.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/kernel/with.rb +0 -20
- data/lib/gems/facets-2.4.5/lib/core/facets/lazy.rb +0 -238
- data/lib/gems/facets-2.4.5/lib/core/facets/matchdata.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/matchdata/match.rb +0 -15
- data/lib/gems/facets-2.4.5/lib/core/facets/matchdata/matchset.rb +0 -44
- data/lib/gems/facets-2.4.5/lib/core/facets/metaid.rb +0 -94
- data/lib/gems/facets-2.4.5/lib/core/facets/module.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/module/abstract.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/module/alias_accessor.rb +0 -45
- data/lib/gems/facets-2.4.5/lib/core/facets/module/alias_method_chain.rb +0 -50
- data/lib/gems/facets-2.4.5/lib/core/facets/module/alias_module_function.rb +0 -30
- data/lib/gems/facets-2.4.5/lib/core/facets/module/ancestor.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/module/basename.rb +0 -31
- data/lib/gems/facets-2.4.5/lib/core/facets/module/can.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/module/class.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/module/conflict.rb +0 -63
- data/lib/gems/facets-2.4.5/lib/core/facets/module/include_function_module.rb +0 -25
- data/lib/gems/facets-2.4.5/lib/core/facets/module/instance_methods.rb +0 -40
- data/lib/gems/facets-2.4.5/lib/core/facets/module/integrate.rb +0 -2
- data/lib/gems/facets-2.4.5/lib/core/facets/module/is.rb +0 -57
- data/lib/gems/facets-2.4.5/lib/core/facets/module/methodize.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/module/modspace.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/module/module_load.rb +0 -56
- data/lib/gems/facets-2.4.5/lib/core/facets/module/nesting.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/module/op.rb +0 -95
- data/lib/gems/facets-2.4.5/lib/core/facets/module/pathize.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/module/prepend.rb +0 -26
- data/lib/gems/facets-2.4.5/lib/core/facets/module/redefine_method.rb +0 -35
- data/lib/gems/facets-2.4.5/lib/core/facets/module/redirect_method.rb +0 -45
- data/lib/gems/facets-2.4.5/lib/core/facets/module/rename_method.rb +0 -20
- data/lib/gems/facets-2.4.5/lib/core/facets/module/revise.rb +0 -62
- data/lib/gems/facets-2.4.5/lib/core/facets/module/spacename.rb +0 -25
- data/lib/gems/facets-2.4.5/lib/core/facets/module/wrap_method.rb +0 -28
- data/lib/gems/facets-2.4.5/lib/core/facets/nilclass.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/nilclass/ergo.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/nilclass/to_f.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/numeric.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/numeric/approx.rb +0 -15
- data/lib/gems/facets-2.4.5/lib/core/facets/numeric/distance.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/numeric/round.rb +0 -72
- data/lib/gems/facets-2.4.5/lib/core/facets/proc.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/proc/bind.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/proc/compose.rb +0 -42
- data/lib/gems/facets-2.4.5/lib/core/facets/proc/curry.rb +0 -31
- data/lib/gems/facets-2.4.5/lib/core/facets/proc/to_method.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/proc/update.rb +0 -9
- data/lib/gems/facets-2.4.5/lib/core/facets/range.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/range/combine.rb +0 -47
- data/lib/gems/facets-2.4.5/lib/core/facets/range/overlap.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/range/to_r.rb +0 -26
- data/lib/gems/facets-2.4.5/lib/core/facets/range/umbrella.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/range/within.rb +0 -66
- data/lib/gems/facets-2.4.5/lib/core/facets/regexp.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/regexp/arity.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/regexp/to_re.rb +0 -28
- data/lib/gems/facets-2.4.5/lib/core/facets/stackable.rb +0 -86
- data/lib/gems/facets-2.4.5/lib/core/facets/string.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/string/align.rb +0 -106
- data/lib/gems/facets-2.4.5/lib/core/facets/string/bracket.rb +0 -105
- data/lib/gems/facets-2.4.5/lib/core/facets/string/bytes.rb +0 -15
- data/lib/gems/facets-2.4.5/lib/core/facets/string/camelcase.rb +0 -26
- data/lib/gems/facets-2.4.5/lib/core/facets/string/capitalized.rb +0 -46
- data/lib/gems/facets-2.4.5/lib/core/facets/string/chars.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/string/chomp.rb +0 -33
- data/lib/gems/facets-2.4.5/lib/core/facets/string/cleave.rb +0 -36
- data/lib/gems/facets-2.4.5/lib/core/facets/string/divide.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/string/each_char.rb +0 -29
- data/lib/gems/facets-2.4.5/lib/core/facets/string/each_word.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/string/end_with.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/string/fold.rb +0 -39
- data/lib/gems/facets-2.4.5/lib/core/facets/string/interpolate.rb +0 -20
- data/lib/gems/facets-2.4.5/lib/core/facets/string/line_wrap.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/string/lines.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/string/methodize.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/string/modulize.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/string/mscan.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/string/natcmp.rb +0 -88
- data/lib/gems/facets-2.4.5/lib/core/facets/string/nchar.rb +0 -28
- data/lib/gems/facets-2.4.5/lib/core/facets/string/op_sub.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/core/facets/string/pathize.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/string/range.rb +0 -77
- data/lib/gems/facets-2.4.5/lib/core/facets/string/rewrite.rb +0 -28
- data/lib/gems/facets-2.4.5/lib/core/facets/string/shatter.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/string/snakecase.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/string/splice.rb +0 -37
- data/lib/gems/facets-2.4.5/lib/core/facets/string/start_with.rb +0 -32
- data/lib/gems/facets-2.4.5/lib/core/facets/string/subtract.rb +0 -4
- data/lib/gems/facets-2.4.5/lib/core/facets/string/tab.rb +0 -103
- data/lib/gems/facets-2.4.5/lib/core/facets/string/titlecase.rb +0 -15
- data/lib/gems/facets-2.4.5/lib/core/facets/string/to_re.rb +0 -26
- data/lib/gems/facets-2.4.5/lib/core/facets/string/variablize.rb +0 -13
- data/lib/gems/facets-2.4.5/lib/core/facets/string/word_wrap.rb +0 -34
- data/lib/gems/facets-2.4.5/lib/core/facets/string/words.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/string/xor.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/chomp.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/generate.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/not.rb +0 -29
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/plain.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/query.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/re_s.rb +0 -18
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/setter.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/succ.rb +0 -19
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/to_proc.rb +0 -38
- data/lib/gems/facets-2.4.5/lib/core/facets/symbol/variablize.rb +0 -12
- data/lib/gems/facets-2.4.5/lib/core/facets/time.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/time/advance.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/time/ago.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/core/facets/time/change.rb +0 -41
- data/lib/gems/facets-2.4.5/lib/core/facets/time/elapse.rb +0 -16
- data/lib/gems/facets-2.4.5/lib/core/facets/time/hence.rb +0 -94
- data/lib/gems/facets-2.4.5/lib/core/facets/time/round.rb +0 -17
- data/lib/gems/facets-2.4.5/lib/core/facets/time/set.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/time/stamp.rb +0 -44
- data/lib/gems/facets-2.4.5/lib/core/facets/time/to_time.rb +0 -21
- data/lib/gems/facets-2.4.5/lib/core/facets/time/trunc.rb +0 -15
- data/lib/gems/facets-2.4.5/lib/core/facets/to_hash.rb +0 -87
- data/lib/gems/facets-2.4.5/lib/core/facets/unboundmethod.rb +0 -6
- data/lib/gems/facets-2.4.5/lib/core/facets/unboundmethod/arguments.rb +0 -44
- data/lib/gems/facets-2.4.5/lib/core/facets/unboundmethod/name.rb +0 -25
- data/lib/gems/facets-2.4.5/lib/lore/facets/basicobject.rb +0 -14
- data/lib/gems/facets-2.4.5/lib/lore/facets/cgi.rb +0 -50
- data/lib/gems/facets-2.4.5/lib/lore/facets/continuation.rb +0 -57
- data/lib/gems/facets-2.4.5/lib/lore/facets/date.rb +0 -396
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils.rb +0 -27
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils/head.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils/safe_ln.rb +0 -28
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils/slice.rb +0 -141
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils/tail.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils/wc.rb +0 -114
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils/whereis.rb +0 -64
- data/lib/gems/facets-2.4.5/lib/lore/facets/fileutils/which.rb +0 -101
- data/lib/gems/facets-2.4.5/lib/lore/facets/getoptlong.rb +0 -71
- data/lib/gems/facets-2.4.5/lib/lore/facets/logger.rb +0 -291
- data/lib/gems/facets-2.4.5/lib/lore/facets/ostruct.rb +0 -238
- data/lib/gems/facets-2.4.5/lib/lore/facets/pathname.rb +0 -172
- data/lib/gems/facets-2.4.5/lib/lore/facets/rbconfig.rb +0 -45
- data/lib/gems/facets-2.4.5/lib/lore/facets/set.rb +0 -27
- data/lib/gems/facets-2.4.5/lib/lore/facets/shellwords.rb +0 -89
- data/lib/gems/facets-2.4.5/lib/lore/facets/uri.rb +0 -249
- data/lib/gems/facets-2.4.5/lib/lore/facets/yaml.rb +0 -75
- data/lib/gems/facets-2.4.5/lib/lore/facets/zlib.rb +0 -38
- data/lib/gems/facets-2.4.5/lib/more/facets/1stclassmethod.rb +0 -140
- data/lib/gems/facets-2.4.5/lib/more/facets/advisable.rb +0 -162
- data/lib/gems/facets-2.4.5/lib/more/facets/annotations.rb +0 -302
- data/lib/gems/facets-2.4.5/lib/more/facets/ansicode.rb +0 -315
- data/lib/gems/facets-2.4.5/lib/more/facets/arguments.rb +0 -365
- data/lib/gems/facets-2.4.5/lib/more/facets/argvector.rb +0 -353
- data/lib/gems/facets-2.4.5/lib/more/facets/association.rb +0 -194
- data/lib/gems/facets-2.4.5/lib/more/facets/attr.rb +0 -208
- data/lib/gems/facets-2.4.5/lib/more/facets/autoarray.rb +0 -62
- data/lib/gems/facets-2.4.5/lib/more/facets/autoreload.rb +0 -150
- data/lib/gems/facets-2.4.5/lib/more/facets/basex.rb +0 -37
- data/lib/gems/facets-2.4.5/lib/more/facets/bbcode.rb +0 -397
- data/lib/gems/facets-2.4.5/lib/more/facets/bicrypt.rb +0 -265
- data/lib/gems/facets-2.4.5/lib/more/facets/binding/opvars.rb +0 -24
- data/lib/gems/facets-2.4.5/lib/more/facets/binreadable.rb +0 -221
- data/lib/gems/facets-2.4.5/lib/more/facets/blankslate.rb +0 -66
- data/lib/gems/facets-2.4.5/lib/more/facets/buildable.rb +0 -344
- data/lib/gems/facets-2.4.5/lib/more/facets/bytes.rb +0 -175
- data/lib/gems/facets-2.4.5/lib/more/facets/cachedecorator.rb +0 -117
- data/lib/gems/facets-2.4.5/lib/more/facets/capsule.rb +0 -258
- data/lib/gems/facets-2.4.5/lib/more/facets/chain.rb +0 -58
- data/lib/gems/facets-2.4.5/lib/more/facets/class_extension.rb +0 -114
- data/lib/gems/facets-2.4.5/lib/more/facets/classmethods.rb +0 -199
- data/lib/gems/facets-2.4.5/lib/more/facets/cloneable.rb +0 -76
- data/lib/gems/facets-2.4.5/lib/more/facets/command.rb +0 -439
- data/lib/gems/facets-2.4.5/lib/more/facets/consoleutils.rb +0 -113
- data/lib/gems/facets-2.4.5/lib/more/facets/coroutine.rb +0 -159
- data/lib/gems/facets-2.4.5/lib/more/facets/crypt.rb +0 -166
- data/lib/gems/facets-2.4.5/lib/more/facets/cssfilter.rb +0 -254
- data/lib/gems/facets-2.4.5/lib/more/facets/daemonize.rb +0 -44
- data/lib/gems/facets-2.4.5/lib/more/facets/dependency.rb +0 -151
- data/lib/gems/facets-2.4.5/lib/more/facets/dictionary.rb +0 -478
- data/lib/gems/facets-2.4.5/lib/more/facets/dictionarymatcher.rb +0 -136
- data/lib/gems/facets-2.4.5/lib/more/facets/downloader.rb +0 -281
- data/lib/gems/facets-2.4.5/lib/more/facets/duplicable.rb +0 -43
- data/lib/gems/facets-2.4.5/lib/more/facets/duration.rb +0 -540
- data/lib/gems/facets-2.4.5/lib/more/facets/elementor.rb +0 -133
- data/lib/gems/facets-2.4.5/lib/more/facets/elementwise.rb +0 -61
- data/lib/gems/facets-2.4.5/lib/more/facets/enumerablepass.rb +0 -217
- data/lib/gems/facets-2.4.5/lib/more/facets/equatable.rb +0 -120
- data/lib/gems/facets-2.4.5/lib/more/facets/eventhook.rb +0 -132
- data/lib/gems/facets-2.4.5/lib/more/facets/expirable.rb +0 -82
- data/lib/gems/facets-2.4.5/lib/more/facets/fileable.rb +0 -162
- data/lib/gems/facets-2.4.5/lib/more/facets/filelist.rb +0 -497
- data/lib/gems/facets-2.4.5/lib/more/facets/fileshell.rb +0 -202
- data/lib/gems/facets-2.4.5/lib/more/facets/hash/stringify_keys.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/more/facets/hash/symbolize_keys.rb +0 -94
- data/lib/gems/facets-2.4.5/lib/more/facets/heap.rb +0 -22
- data/lib/gems/facets-2.4.5/lib/more/facets/htmlfilter.rb +0 -595
- data/lib/gems/facets-2.4.5/lib/more/facets/infinity.rb +0 -193
- data/lib/gems/facets-2.4.5/lib/more/facets/inheritor.rb +0 -130
- data/lib/gems/facets-2.4.5/lib/more/facets/ini.rb +0 -264
- data/lib/gems/facets-2.4.5/lib/more/facets/instantiable.rb +0 -47
- data/lib/gems/facets-2.4.5/lib/more/facets/instantise.rb +0 -1
- data/lib/gems/facets-2.4.5/lib/more/facets/instantize.rb +0 -95
- data/lib/gems/facets-2.4.5/lib/more/facets/interval.rb +0 -282
- data/lib/gems/facets-2.4.5/lib/more/facets/ioredirect.rb +0 -130
- data/lib/gems/facets-2.4.5/lib/more/facets/iteration.rb +0 -65
- data/lib/gems/facets-2.4.5/lib/more/facets/kernel/meta.rb +0 -32
- data/lib/gems/facets-2.4.5/lib/more/facets/linkedlist.rb +0 -222
- data/lib/gems/facets-2.4.5/lib/more/facets/lrucache.rb +0 -157
- data/lib/gems/facets-2.4.5/lib/more/facets/main.rb +0 -70
- data/lib/gems/facets-2.4.5/lib/more/facets/memoize.rb +0 -116
- data/lib/gems/facets-2.4.5/lib/more/facets/methodspace.rb +0 -141
- data/lib/gems/facets-2.4.5/lib/more/facets/minitar.rb +0 -1063
- data/lib/gems/facets-2.4.5/lib/more/facets/multipliers.rb +0 -109
- data/lib/gems/facets-2.4.5/lib/more/facets/multiton.rb +0 -386
- data/lib/gems/facets-2.4.5/lib/more/facets/nackclass.rb +0 -41
- data/lib/gems/facets-2.4.5/lib/more/facets/net/smtp_tls.rb +0 -131
- data/lib/gems/facets-2.4.5/lib/more/facets/nilstatus.rb +0 -47
- data/lib/gems/facets-2.4.5/lib/more/facets/nullclass.rb +0 -74
- data/lib/gems/facets-2.4.5/lib/more/facets/opencascade.rb +0 -94
- data/lib/gems/facets-2.4.5/lib/more/facets/opencollection.rb +0 -43
- data/lib/gems/facets-2.4.5/lib/more/facets/openhash.rb +0 -39
- data/lib/gems/facets-2.4.5/lib/more/facets/openobject.rb +0 -267
- data/lib/gems/facets-2.4.5/lib/more/facets/opesc.rb +0 -60
- data/lib/gems/facets-2.4.5/lib/more/facets/orderedhash.rb +0 -37
- data/lib/gems/facets-2.4.5/lib/more/facets/overload.rb +0 -94
- data/lib/gems/facets-2.4.5/lib/more/facets/paramix.rb +0 -202
- data/lib/gems/facets-2.4.5/lib/more/facets/partial.rb +0 -37
- data/lib/gems/facets-2.4.5/lib/more/facets/pathlist.rb +0 -112
- data/lib/gems/facets-2.4.5/lib/more/facets/platform.rb +0 -192
- data/lib/gems/facets-2.4.5/lib/more/facets/pool.rb +0 -91
- data/lib/gems/facets-2.4.5/lib/more/facets/pqueue.rb +0 -449
- data/lib/gems/facets-2.4.5/lib/more/facets/progressbar.rb +0 -253
- data/lib/gems/facets-2.4.5/lib/more/facets/prototype.rb +0 -88
- data/lib/gems/facets-2.4.5/lib/more/facets/random.rb +0 -451
- data/lib/gems/facets-2.4.5/lib/more/facets/rbsystem.rb +0 -222
- data/lib/gems/facets-2.4.5/lib/more/facets/recorder.rb +0 -109
- data/lib/gems/facets-2.4.5/lib/more/facets/reference.rb +0 -99
- data/lib/gems/facets-2.4.5/lib/more/facets/reflection.rb +0 -145
- data/lib/gems/facets-2.4.5/lib/more/facets/registerable.rb +0 -35
- data/lib/gems/facets-2.4.5/lib/more/facets/rwdelegator.rb +0 -74
- data/lib/gems/facets-2.4.5/lib/more/facets/semaphore.rb +0 -92
- data/lib/gems/facets-2.4.5/lib/more/facets/settings.rb +0 -248
- data/lib/gems/facets-2.4.5/lib/more/facets/snapshot.rb +0 -209
- data/lib/gems/facets-2.4.5/lib/more/facets/string/mask.rb +0 -278
- data/lib/gems/facets-2.4.5/lib/more/facets/string/words.rb +0 -173
- data/lib/gems/facets-2.4.5/lib/more/facets/succ.rb +0 -44
- data/lib/gems/facets-2.4.5/lib/more/facets/syncarray.rb +0 -114
- data/lib/gems/facets-2.4.5/lib/more/facets/synchash.rb +0 -157
- data/lib/gems/facets-2.4.5/lib/more/facets/tagiter.rb +0 -366
- data/lib/gems/facets-2.4.5/lib/more/facets/thread.rb +0 -51
- data/lib/gems/facets-2.4.5/lib/more/facets/timer.rb +0 -274
- data/lib/gems/facets-2.4.5/lib/more/facets/times.rb +0 -431
- data/lib/gems/facets-2.4.5/lib/more/facets/tracepoint.rb +0 -209
- data/lib/gems/facets-2.4.5/lib/more/facets/tuple.rb +0 -325
- data/lib/gems/facets-2.4.5/lib/more/facets/typecast.rb +0 -261
- data/lib/gems/facets-2.4.5/lib/more/facets/uninheritable.rb +0 -50
- data/lib/gems/facets-2.4.5/lib/more/facets/uploadutils.rb +0 -464
- data/lib/gems/facets-2.4.5/lib/more/facets/version.rb +0 -136
- data/lib/gems/facets-2.4.5/lib/more/facets/xmlhash.rb +0 -112
- data/lib/gems/facets-2.4.5/lib/more/facets/xoxo.rb +0 -259
- data/lib/gems/facets-2.4.5/lib/more/facets/ziputils.rb +0 -349
- data/lib/mack-facets/utils/blank_slate.rb +0 -3
@@ -1,202 +0,0 @@
|
|
1
|
-
warn 'please use folio (gem install folio) for future versions'
|
2
|
-
|
3
|
-
# = File Shell
|
4
|
-
#
|
5
|
-
# Comprehensive file system access tool. FileShell acts as a "virtual"
|
6
|
-
# shell prompt.
|
7
|
-
#
|
8
|
-
# c = VirtualShell.new
|
9
|
-
# c.ls #=> ['ipso.txt']
|
10
|
-
#
|
11
|
-
# == NOTES
|
12
|
-
#
|
13
|
-
# * This is still expiremental library and is still undergoing rivision.
|
14
|
-
#
|
15
|
-
# Authors:: Trans
|
16
|
-
# Copying:: (c) 2007 Thomas Sawyer
|
17
|
-
# License:: Ruby License
|
18
|
-
|
19
|
-
require 'fileutils'
|
20
|
-
|
21
|
-
# = File Shell
|
22
|
-
#
|
23
|
-
# Comprehensive file system access tool. FileShell acts as a "virtual"
|
24
|
-
# shell prompt.
|
25
|
-
#
|
26
|
-
# c = VirtualShell.new
|
27
|
-
# c.ls #=> ['ipso.txt']
|
28
|
-
#
|
29
|
-
class FileShell
|
30
|
-
|
31
|
-
attr_reader :root
|
32
|
-
|
33
|
-
def initialize(*root_and_options)
|
34
|
-
@options = Hash === root_and_options ? root_and_options.pop : {}
|
35
|
-
@root = root_and_options.first || "/"
|
36
|
-
|
37
|
-
@dryrun = options[:dryrun]
|
38
|
-
@quiet = options[:quiet]
|
39
|
-
#@force = options[:force]
|
40
|
-
end
|
41
|
-
|
42
|
-
def dryrun? ; @dryrun ; end
|
43
|
-
def quiet? ; @quiet ; end
|
44
|
-
def verbose? ; !@quiet ; end
|
45
|
-
#def force? ; @force ; end
|
46
|
-
|
47
|
-
# Direct access to a directory or a file.
|
48
|
-
def [](name)
|
49
|
-
if File.directory?(name)
|
50
|
-
Dir.new(name)
|
51
|
-
elsif File.file?(name)
|
52
|
-
File.new(name)
|
53
|
-
else
|
54
|
-
nil
|
55
|
-
end
|
56
|
-
end
|
57
|
-
|
58
|
-
# Is a directory root?
|
59
|
-
def root?(dir=nil)
|
60
|
-
pth = File.expand_path(dir||work)
|
61
|
-
return true if pth == '/'
|
62
|
-
return true if pth =~ /^(\w:)?\/$/
|
63
|
-
false
|
64
|
-
end
|
65
|
-
|
66
|
-
# Present working directory.
|
67
|
-
def pwd; super; end
|
68
|
-
|
69
|
-
# Directory listing
|
70
|
-
def ls(dir, options=nil)
|
71
|
-
Dir.entries.collect do |f|
|
72
|
-
File.directory?(f) ? Dir.new(f) : File.new(f)
|
73
|
-
end
|
74
|
-
end
|
75
|
-
|
76
|
-
# Change directory.
|
77
|
-
#
|
78
|
-
# cd(dir, options)
|
79
|
-
# cd(dir, options) {|dir| .... }
|
80
|
-
def cd(dir, options=nil, &yld)
|
81
|
-
fu(options).cd(dir, &yld)
|
82
|
-
end
|
83
|
-
alias chdir cd
|
84
|
-
|
85
|
-
# mkdir(dir, options)
|
86
|
-
# mkdir(list, options)
|
87
|
-
def mkdir(dir, options=nil)
|
88
|
-
fu(options).mkdir(dir)
|
89
|
-
end
|
90
|
-
|
91
|
-
# mkdir_p(dir, options)
|
92
|
-
# mkdir_p(list, options)
|
93
|
-
def mkdir_p(dir, options=nil)
|
94
|
-
fu(options).mkdir_p(dir)
|
95
|
-
end
|
96
|
-
|
97
|
-
# rmdir(dir, options)
|
98
|
-
# rmdir(list, options)
|
99
|
-
def rmdir(dir, options=nil)
|
100
|
-
fu(options).rmdir(dir)
|
101
|
-
end
|
102
|
-
|
103
|
-
# ln(old, new, options)
|
104
|
-
# ln(list, destdir, options)
|
105
|
-
def ln(old, new, options=nil)
|
106
|
-
fu(options).ln(old, new)
|
107
|
-
end
|
108
|
-
|
109
|
-
# ln_s(old, new, options)
|
110
|
-
# ln_s(list, destdir, options)
|
111
|
-
def ln_s(old, new, options=nil)
|
112
|
-
fu(options).ln_s(old, new)
|
113
|
-
end
|
114
|
-
|
115
|
-
# ln_sf(src, dest, options)
|
116
|
-
def ln_sf(src, dest, options=nil)
|
117
|
-
fu(options).ln_sf(src, dest)
|
118
|
-
end
|
119
|
-
|
120
|
-
# cp(src, dest, options)
|
121
|
-
# cp(list, dir, options)
|
122
|
-
def cp(src, dest, options=nil)
|
123
|
-
fu(options).cp(src, dest)
|
124
|
-
end
|
125
|
-
|
126
|
-
# cp_r(src, dest, options)
|
127
|
-
# cp_r(list, dir, options)
|
128
|
-
def cp_r(src, dest, options=nil)
|
129
|
-
fu(options).cp_r(src, dest)
|
130
|
-
end
|
131
|
-
|
132
|
-
# mv(src, dest, options)
|
133
|
-
# mv(list, dir, options)
|
134
|
-
def mv(src, dest, options=nil)
|
135
|
-
fu(options).mv(src, dest)
|
136
|
-
end
|
137
|
-
alias move mv
|
138
|
-
|
139
|
-
# rm(list, options)
|
140
|
-
def rm(list, options=nil)
|
141
|
-
fu(options).rm(list)
|
142
|
-
end
|
143
|
-
|
144
|
-
# rm_r(list, options)
|
145
|
-
def rm_r(list, options=nil)
|
146
|
-
fu(options).rm_r(list)
|
147
|
-
end
|
148
|
-
|
149
|
-
# rm_rf(list, options)
|
150
|
-
def rm_rf(list, options=nil)
|
151
|
-
fu(options).rm_rf(list)
|
152
|
-
end
|
153
|
-
|
154
|
-
# install(src, dest, mode = <src's>, options)
|
155
|
-
def install(src, dest, mode=src, options=nil)
|
156
|
-
fu(options).install(src, dest, mode)
|
157
|
-
end
|
158
|
-
|
159
|
-
# chmod(mode, list, options)
|
160
|
-
def chmod(mode, list, options=nil)
|
161
|
-
fu(options).chmod(mode, list)
|
162
|
-
end
|
163
|
-
|
164
|
-
# chmod_R(mode, list, options)
|
165
|
-
def chmod_R(mode, list, options=nil)
|
166
|
-
fu(options).chmod_R(mode, list)
|
167
|
-
end
|
168
|
-
|
169
|
-
# chown(user, group, list, options)
|
170
|
-
def chown(user, group, list, options=nil)
|
171
|
-
fu(options).chown(user, group, list)
|
172
|
-
end
|
173
|
-
|
174
|
-
# chown_R(user, group, list, options)
|
175
|
-
def chown_R(user, group, list, options=nil)
|
176
|
-
fu(options).chown_R(user, group, list)
|
177
|
-
end
|
178
|
-
|
179
|
-
# touch(list, options)
|
180
|
-
def touch(list, options=nil)
|
181
|
-
fu(options).touch(list)
|
182
|
-
end
|
183
|
-
|
184
|
-
private
|
185
|
-
|
186
|
-
#
|
187
|
-
def fu(opts)
|
188
|
-
nowrite = opts[:nowrite] || opts[:dryrun] || opts[:noop] || dryrun?
|
189
|
-
verbose = opts[:verbose] || opts[:dryrun] || !opts[:quiet] || verbose?
|
190
|
-
|
191
|
-
if nowrite and verbose
|
192
|
-
FileUtils::Dryrun
|
193
|
-
elsif nowrite
|
194
|
-
FileUtils::NoWrite
|
195
|
-
elsif verbose
|
196
|
-
FileUtils::Verbose
|
197
|
-
else
|
198
|
-
FileUtils
|
199
|
-
end
|
200
|
-
end
|
201
|
-
|
202
|
-
end
|
@@ -1 +0,0 @@
|
|
1
|
-
require 'facets/hash/symbolize_keys'
|
@@ -1,94 +0,0 @@
|
|
1
|
-
require 'facets/hash/rekey'
|
2
|
-
|
3
|
-
class Hash
|
4
|
-
|
5
|
-
# Converts all keys in the Hash to Symbols, returning a new Hash.
|
6
|
-
# With a +filter+, limits conversion to only a certain selection of keys.
|
7
|
-
#
|
8
|
-
# foo = { :name=>'Gavin', 'wife'=>:Lisa }
|
9
|
-
# foo.symbolize_keys #=> { :name=>"Gavin", :wife=>:Lisa }
|
10
|
-
# foo.inspect #=> { "name" =>"Gavin", "wife"=>:Lisa }
|
11
|
-
#
|
12
|
-
# This method is considered archaic. Use #rekey instead.
|
13
|
-
|
14
|
-
def symbolize_keys(&filter)
|
15
|
-
if filter
|
16
|
-
rekey{ |k| filter[k] ? k.to_sym : nil }
|
17
|
-
else
|
18
|
-
rekey{ |k| k.to_sym }
|
19
|
-
end
|
20
|
-
end
|
21
|
-
|
22
|
-
#alias_method( :keys_to_sym, :symbolize_keys )
|
23
|
-
|
24
|
-
#--
|
25
|
-
# # Rails has these aliases too, but they are not very good for
|
26
|
-
# # gerenal use, IMHO. But perhaps someone can convince me otherwise.
|
27
|
-
# alias_method( :to_options, :symbolize_keys )
|
28
|
-
#++
|
29
|
-
|
30
|
-
# Synonym for Hash#symbolize_keys, but modifies the receiver in place and returns it.
|
31
|
-
# With a +filter+ parameter, limits conversion to only a certain selection of keys.
|
32
|
-
#
|
33
|
-
# foo = { 'name'=>'Gavin', 'wife'=>:Lisa }
|
34
|
-
# foo.symbolize_keys! #=> { :name=>"Gavin", :wife=>:Lisa }
|
35
|
-
# foo.inspect #=> { :name=>"Gavin", :wife=>:Lisa }
|
36
|
-
#
|
37
|
-
# This method is considered archaic. Use #rekey instead.
|
38
|
-
|
39
|
-
def symbolize_keys!(&filter)
|
40
|
-
if filter
|
41
|
-
rekey!{ |k| filter[k] ? k.to_sym : nil }
|
42
|
-
else
|
43
|
-
rekey!{ |k| k.to_sym }
|
44
|
-
end
|
45
|
-
|
46
|
-
end
|
47
|
-
|
48
|
-
#alias_method( :keys_to_sym!, :symbolize_keys! )
|
49
|
-
|
50
|
-
# Converts all keys in the Hash to Strings, returning a new Hash.
|
51
|
-
# With a +filter+ parameter, limits conversion to only a certain selection of keys.
|
52
|
-
#
|
53
|
-
# foo = { :name=>'Gavin', :wife=>:Lisa }
|
54
|
-
# foo.stringify_keys #=> { "name"=>"Gavin", "wife"=>:Lisa }
|
55
|
-
# foo.inspect #=> { :name =>"Gavin", :wife=>:Lisa }
|
56
|
-
#
|
57
|
-
# This method is considered archaic. Use #rekey instead.
|
58
|
-
|
59
|
-
def stringify_keys(&filter)
|
60
|
-
if filter
|
61
|
-
rekey{ |k| filter[k] ? k.to_s : nil }
|
62
|
-
else
|
63
|
-
rekey{ |k| k.to_s }
|
64
|
-
end
|
65
|
-
end
|
66
|
-
|
67
|
-
#alias_method(:keys_to_s, :stringify_keys)
|
68
|
-
|
69
|
-
# Synonym for Hash#stringify_keys, but modifies the receiver in place and returns it.
|
70
|
-
# With a +filter+ parameter, limits conversion to only a certain selection of keys.
|
71
|
-
#
|
72
|
-
# foo = { :name=>'Gavin', :wife=>:Lisa }
|
73
|
-
# foo.stringify_keys! #=> { "name"=>"Gavin", "wife"=>:Lisa }
|
74
|
-
# foo.inspect #=> { "name"=>"Gavin", "wife"=>:Lisa }
|
75
|
-
#
|
76
|
-
# This method is considered archaic. Use #rekey instead.
|
77
|
-
|
78
|
-
def stringify_keys!(&filter)
|
79
|
-
if filter
|
80
|
-
rekey!{ |k| filter[k] ? k.to_s : nil }
|
81
|
-
else
|
82
|
-
rekey!{ |k| k.to_s }
|
83
|
-
end
|
84
|
-
end
|
85
|
-
|
86
|
-
#alias_method( :keys_to_s!, :stringify_keys!)
|
87
|
-
|
88
|
-
#--
|
89
|
-
# # Rails has these aliases too.
|
90
|
-
# alias_method( :to_options!, :symbolize_keys! )
|
91
|
-
#++
|
92
|
-
|
93
|
-
end
|
94
|
-
|
@@ -1,22 +0,0 @@
|
|
1
|
-
# = Heap
|
2
|
-
#
|
3
|
-
# Another name for PQueue.
|
4
|
-
#
|
5
|
-
# == Copying
|
6
|
-
#
|
7
|
-
# Copyright (c) 2005 Thomas Sawyer, George Moschovitis
|
8
|
-
#
|
9
|
-
# Ruby License
|
10
|
-
#
|
11
|
-
# This module is free software. You may use, modify, and/or redistribute this
|
12
|
-
# software under the same terms as Ruby.
|
13
|
-
#
|
14
|
-
# This program is distributed in the hope that it will be useful, but WITHOUT
|
15
|
-
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
16
|
-
# FOR A PARTICULAR PURPOSE.
|
17
|
-
|
18
|
-
require 'facets/pqueue'
|
19
|
-
|
20
|
-
# Heap is PQueue.
|
21
|
-
Heap = PQueue
|
22
|
-
|
@@ -1,595 +0,0 @@
|
|
1
|
-
# = HTML Filter
|
2
|
-
#
|
3
|
-
# HTML Filter library can be used to sanitize and sterilize
|
4
|
-
# HTML. A good idea if you let users submit HTML in comments,
|
5
|
-
# for instance.
|
6
|
-
#
|
7
|
-
# HtmlFilter is a port of lib_filter.php, v1.15 by Cal Henderson <cal@iamcal.com>
|
8
|
-
#
|
9
|
-
# This code is licensed under a Creative Commons Attribution-ShareAlike 2.5 License
|
10
|
-
# http://creativecommons.org/licenses/by-sa/2.5/
|
11
|
-
#
|
12
|
-
# Thanks to Jang Kim for adding support for single quoted attributes.
|
13
|
-
#
|
14
|
-
# == Reference
|
15
|
-
#
|
16
|
-
# * http://iamcal.com/publish/articles/php/processing_html/
|
17
|
-
# * http://iamcal.com/publish/articles/php/processing_html_part_2/
|
18
|
-
#
|
19
|
-
# == Author(s)
|
20
|
-
#
|
21
|
-
# * TransNoumena
|
22
|
-
# * George Moschovitis
|
23
|
-
# * James Britt
|
24
|
-
# * Cal Henderson
|
25
|
-
# * Jang Kim
|
26
|
-
#
|
27
|
-
# == Authors
|
28
|
-
#
|
29
|
-
# * Trans
|
30
|
-
#
|
31
|
-
# == Copying
|
32
|
-
#
|
33
|
-
# Copyright (c) 2007 7rans
|
34
|
-
|
35
|
-
require 'facets/multiton'
|
36
|
-
|
37
|
-
# = HtmlFilter
|
38
|
-
#
|
39
|
-
# HTML Filter library can be used to sanitize and sterilize
|
40
|
-
# HTML. A good idea if you let users submit HTML in comments,
|
41
|
-
# for instance.
|
42
|
-
#
|
43
|
-
# lib_filter.php, v1.15 by Cal Henderson <cal@iamcal.com>
|
44
|
-
#
|
45
|
-
# This code is licensed under a Creative Commons Attribution-ShareAlike 2.5 License
|
46
|
-
# http://creativecommons.org/licenses/by-sa/2.5/
|
47
|
-
#
|
48
|
-
# Thanks to Jang Kim for adding support for single quoted attributes.
|
49
|
-
#
|
50
|
-
# == Reference
|
51
|
-
#
|
52
|
-
# * http://iamcal.com/publish/articles/php/processing_html/
|
53
|
-
# * http://iamcal.com/publish/articles/php/processing_html_part_2/
|
54
|
-
|
55
|
-
class HtmlFilter
|
56
|
-
|
57
|
-
include Multiton
|
58
|
-
|
59
|
-
# tags and attributes that are allowed
|
60
|
-
#
|
61
|
-
# Eg.
|
62
|
-
#
|
63
|
-
# {
|
64
|
-
# 'a' => ['href', 'target'],
|
65
|
-
# 'b' => [],
|
66
|
-
# 'img' => ['src', 'width', 'height', 'alt']
|
67
|
-
# }
|
68
|
-
attr_accessor :allowed
|
69
|
-
|
70
|
-
# tags which should always be self-closing (e.g. "<img />")
|
71
|
-
attr_accessor :no_close
|
72
|
-
|
73
|
-
# tags which must always have seperate opening and closing
|
74
|
-
# tags (e.g. "<b></b>")
|
75
|
-
attr_accessor :always_close
|
76
|
-
|
77
|
-
# attributes which should be checked for valid protocols
|
78
|
-
# (src,href)
|
79
|
-
attr_accessor :protocol_attributes
|
80
|
-
|
81
|
-
# protocols which are allowed (http, ftp, mailto)
|
82
|
-
attr_accessor :allowed_protocols
|
83
|
-
|
84
|
-
# tags which should be removed if they contain no content
|
85
|
-
# (e.g. "<b></b>" or "<b />")
|
86
|
-
attr_accessor :remove_blanks
|
87
|
-
|
88
|
-
# should we remove comments? (true, false)
|
89
|
-
attr_accessor :strip_comments
|
90
|
-
|
91
|
-
# should we try and make a b tag out of "b>" (true, false)
|
92
|
-
attr_accessor :always_make_tags
|
93
|
-
|
94
|
-
# entity control option (true, false)
|
95
|
-
attr_accessor :allow_numbered_entities
|
96
|
-
|
97
|
-
# entity control option (amp, gt, lt, quot, etc.)
|
98
|
-
attr_accessor :allowed_entities
|
99
|
-
|
100
|
-
# default settings
|
101
|
-
|
102
|
-
DEFAULT = {
|
103
|
-
'allowed' => {
|
104
|
-
'a' => ['href', 'target'],
|
105
|
-
'b' => [],
|
106
|
-
'i' => [],
|
107
|
-
'img' => ['src', 'width', 'height', 'alt']
|
108
|
-
},
|
109
|
-
'no_close' => ['img', 'br', 'hr'],
|
110
|
-
'always_close' => ['a', 'b'],
|
111
|
-
'protocol_attributes' => ['src', 'href'],
|
112
|
-
'allowed_protocols' => ['http', 'ftp', 'mailto'],
|
113
|
-
'remove_blanks' => ['a', 'b'],
|
114
|
-
'strip_comments' => true,
|
115
|
-
'always_make_tags' => true,
|
116
|
-
'allow_numbered_entities' => true,
|
117
|
-
'allowed_entities' => ['amp', 'gt', 'lt', 'quot']
|
118
|
-
}
|
119
|
-
|
120
|
-
# New html filter.
|
121
|
-
|
122
|
-
def initialize( options=nil )
|
123
|
-
if options
|
124
|
-
h = DEFAULT.dup
|
125
|
-
options.each do |k,v|
|
126
|
-
h[k.to_s] = v
|
127
|
-
end
|
128
|
-
options = h
|
129
|
-
else
|
130
|
-
options = DEFAULT.dup
|
131
|
-
end
|
132
|
-
|
133
|
-
options.each{ |k,v| send("#{k}=",v) }
|
134
|
-
end
|
135
|
-
|
136
|
-
# Filter html string.
|
137
|
-
|
138
|
-
def filter(data)
|
139
|
-
@tag_counts = {}
|
140
|
-
|
141
|
-
data = escape_comments(data)
|
142
|
-
data = balance_html(data)
|
143
|
-
data = check_tags(data)
|
144
|
-
data = process_remove_blanks(data)
|
145
|
-
data = validate_entities(data)
|
146
|
-
|
147
|
-
return data
|
148
|
-
end
|
149
|
-
|
150
|
-
private
|
151
|
-
|
152
|
-
#
|
153
|
-
# internal tag counter
|
154
|
-
#
|
155
|
-
|
156
|
-
attr_reader :tag_counts
|
157
|
-
|
158
|
-
#
|
159
|
-
#
|
160
|
-
#
|
161
|
-
|
162
|
-
def escape_comments(data)
|
163
|
-
data = data.gsub(/<!--(.*?)-->/s) do
|
164
|
-
'<!--' + escape_special_chars(strip_single($1)) + '-->'
|
165
|
-
end
|
166
|
-
|
167
|
-
return data
|
168
|
-
end
|
169
|
-
|
170
|
-
#
|
171
|
-
#
|
172
|
-
#
|
173
|
-
|
174
|
-
def balance_html(data)
|
175
|
-
data = data.dup
|
176
|
-
|
177
|
-
if always_make_tags
|
178
|
-
# try and form html
|
179
|
-
data.gsub!(/>>+/, '>')
|
180
|
-
data.gsub!(/<<+/, '<')
|
181
|
-
data.gsub!(/^>/, '')
|
182
|
-
data.gsub!(/<([^>]*?)(?=<|$)/, '<\1>')
|
183
|
-
data.gsub!(/(^|>)([^<]*?)(?=>)/, '\1<\2')
|
184
|
-
else
|
185
|
-
# escape stray brackets
|
186
|
-
data.gsub!(/<([^>]*?)(?=<|$)/, '<\1')
|
187
|
-
data.gsub!(/(^|>)([^<]*?)(?=>)/, '\1\2><')
|
188
|
-
# the last regexp causes '<>' entities to appear
|
189
|
-
# (we need to do a lookahead assertion so that the last bracket
|
190
|
-
# can be used in the next pass of the regexp)
|
191
|
-
data.gsub!('<>', '')
|
192
|
-
end
|
193
|
-
|
194
|
-
return data
|
195
|
-
end
|
196
|
-
|
197
|
-
#
|
198
|
-
#
|
199
|
-
#
|
200
|
-
|
201
|
-
def check_tags(data)
|
202
|
-
data = data.dup
|
203
|
-
|
204
|
-
data.gsub!(/<(.*?)>/s){
|
205
|
-
process_tag(strip_single($1))
|
206
|
-
}
|
207
|
-
|
208
|
-
tag_counts.each do |tag, cnt|
|
209
|
-
cnt.times{ data << "</#{tag}>" }
|
210
|
-
end
|
211
|
-
|
212
|
-
return data
|
213
|
-
end
|
214
|
-
|
215
|
-
#
|
216
|
-
#
|
217
|
-
#
|
218
|
-
|
219
|
-
def process_tag(data)
|
220
|
-
|
221
|
-
# ending tags
|
222
|
-
|
223
|
-
re = /^\/([a-z0-9]+)/si
|
224
|
-
|
225
|
-
if matches = re.match(data)
|
226
|
-
name = matches[1].downcase
|
227
|
-
if allowed.key?(name)
|
228
|
-
unless no_close.include?(name)
|
229
|
-
if tag_counts[name]
|
230
|
-
tag_counts[name] -= 1
|
231
|
-
return "</#{name}>"
|
232
|
-
end
|
233
|
-
end
|
234
|
-
else
|
235
|
-
return ''
|
236
|
-
end
|
237
|
-
end
|
238
|
-
|
239
|
-
# starting tags
|
240
|
-
|
241
|
-
re = /^([a-z0-9]+)(.*?)(\/?)$/si
|
242
|
-
|
243
|
-
if matches = re.match(data)
|
244
|
-
name = matches[1].downcase
|
245
|
-
body = matches[2]
|
246
|
-
ending = matches[3]
|
247
|
-
|
248
|
-
if allowed.key?(name)
|
249
|
-
params = ""
|
250
|
-
|
251
|
-
matches_2 = body.scan(/([a-z0-9]+)=(["'])(.*?)\2/si) # <foo a="b" />
|
252
|
-
matches_1 = body.scan(/([a-z0-9]+)(=)([^"\s']+)/si) # <foo a=b />
|
253
|
-
matches_3 = body.scan(/([a-z0-9]+)=(["'])([^"']*?)\s*$/si) # <foo a="b />
|
254
|
-
|
255
|
-
matches = matches_1 + matches_2 + matches_3
|
256
|
-
|
257
|
-
matches.each do |match|
|
258
|
-
pname = match[0].downcase
|
259
|
-
if allowed[name].include?(pname)
|
260
|
-
value = match[2]
|
261
|
-
if protocol_attributes.include?(pname)
|
262
|
-
value = process_param_protocol(value)
|
263
|
-
end
|
264
|
-
params += %{ #{pname}="#{value}"}
|
265
|
-
end
|
266
|
-
end
|
267
|
-
if no_close.include?(name)
|
268
|
-
ending = ' /'
|
269
|
-
end
|
270
|
-
if always_close.include?(name)
|
271
|
-
ending = ''
|
272
|
-
end
|
273
|
-
if ending.empty?
|
274
|
-
if tag_counts.key?(name)
|
275
|
-
tag_counts[name] += 1
|
276
|
-
else
|
277
|
-
tag_counts[name] = 1
|
278
|
-
end
|
279
|
-
end
|
280
|
-
unless ending.empty?
|
281
|
-
ending = ' /'
|
282
|
-
end
|
283
|
-
return '<' + name + params + ending + '>'
|
284
|
-
else
|
285
|
-
return ''
|
286
|
-
end
|
287
|
-
end
|
288
|
-
|
289
|
-
# comments
|
290
|
-
if /^!--(.*)--$/si =~ data
|
291
|
-
if strip_comments
|
292
|
-
return ''
|
293
|
-
else
|
294
|
-
return '<' + data + '>'
|
295
|
-
end
|
296
|
-
end
|
297
|
-
|
298
|
-
# garbage, ignore it
|
299
|
-
return ''
|
300
|
-
end
|
301
|
-
|
302
|
-
#
|
303
|
-
#
|
304
|
-
#
|
305
|
-
|
306
|
-
def process_param_protocol(data)
|
307
|
-
data = decode_entities(data)
|
308
|
-
|
309
|
-
re = /^([^:]+)\:/si
|
310
|
-
|
311
|
-
if matches = re.match(data)
|
312
|
-
unless allowed_protocols.include?(matches[1])
|
313
|
-
#data = '#'.substr(data, strlen(matches[1])+1)
|
314
|
-
data = '#' + data[0..matches[1].size+1]
|
315
|
-
end
|
316
|
-
end
|
317
|
-
|
318
|
-
return data
|
319
|
-
end
|
320
|
-
|
321
|
-
#
|
322
|
-
#
|
323
|
-
#
|
324
|
-
|
325
|
-
def process_remove_blanks(data)
|
326
|
-
data = data.dup
|
327
|
-
|
328
|
-
remove_blanks.each do |tag|
|
329
|
-
data.gsub!(/<#{tag}(\s[^>]*)?><\/#{tag}>/, '')
|
330
|
-
data.gsub!(/<#{tag}(\s[^>]*)?\/>/, '')
|
331
|
-
end
|
332
|
-
|
333
|
-
return data
|
334
|
-
end
|
335
|
-
|
336
|
-
#
|
337
|
-
#
|
338
|
-
#
|
339
|
-
|
340
|
-
def fix_case(data)
|
341
|
-
data_notags = strip_tags(data)
|
342
|
-
data_notags = data_notags.gsub(/[^a-zA-Z]/, '')
|
343
|
-
|
344
|
-
if data_notags.size < 5
|
345
|
-
return data
|
346
|
-
end
|
347
|
-
|
348
|
-
if /[a-z]/ =~ data_notags
|
349
|
-
return data
|
350
|
-
end
|
351
|
-
|
352
|
-
data = data.gsub(/(>|^)([^<]+?)(<|$)/s){
|
353
|
-
strip_single($1) +
|
354
|
-
fix_case_inner(strip_single($2)) +
|
355
|
-
strip_single($3)
|
356
|
-
}
|
357
|
-
|
358
|
-
return data
|
359
|
-
end
|
360
|
-
|
361
|
-
#
|
362
|
-
#
|
363
|
-
#
|
364
|
-
|
365
|
-
def fix_case_inner(data)
|
366
|
-
data = data.dup
|
367
|
-
|
368
|
-
data.downcase!
|
369
|
-
|
370
|
-
data.gsub!(/(^|[^\w\s\';,\\-])(\s*)([a-z])/){
|
371
|
-
strip_single("#{$1}#{$2}") + strip_single($3).upcase
|
372
|
-
}
|
373
|
-
|
374
|
-
return data
|
375
|
-
end
|
376
|
-
|
377
|
-
#
|
378
|
-
#
|
379
|
-
#
|
380
|
-
|
381
|
-
def validate_entities(data)
|
382
|
-
data = data.dup
|
383
|
-
|
384
|
-
# validate entities throughout the string
|
385
|
-
data.gsub!(%r!&([^&;]*)(?=(;|&|$))!){
|
386
|
-
check_entity(strip_single($1), strip_single($2))
|
387
|
-
}
|
388
|
-
|
389
|
-
# validate quotes outside of tags
|
390
|
-
data.gsub!(/(>|^)([^<]+?)(<|$)/s){
|
391
|
-
m1, m2, m3 = $1, $2, $3
|
392
|
-
strip_single(m1) +
|
393
|
-
strip_single(m2).gsub('\"', '"') +
|
394
|
-
strip_single(m3)
|
395
|
-
}
|
396
|
-
|
397
|
-
return data
|
398
|
-
end
|
399
|
-
|
400
|
-
#
|
401
|
-
#
|
402
|
-
#
|
403
|
-
|
404
|
-
def check_entity(preamble, term)
|
405
|
-
if term != ';'
|
406
|
-
return '&' + preamble
|
407
|
-
end
|
408
|
-
|
409
|
-
if is_valid_entity(preamble)
|
410
|
-
return '&' + preamble
|
411
|
-
end
|
412
|
-
|
413
|
-
return '&' + preamble
|
414
|
-
end
|
415
|
-
|
416
|
-
#
|
417
|
-
#
|
418
|
-
#
|
419
|
-
|
420
|
-
def is_valid_entity(entity)
|
421
|
-
re = /^#([0-9]+)$/i
|
422
|
-
|
423
|
-
if md = re.match(entity)
|
424
|
-
if (md[1].to_i > 127)
|
425
|
-
return true
|
426
|
-
end
|
427
|
-
return allow_numbered_entities
|
428
|
-
end
|
429
|
-
|
430
|
-
if allowed_entities.include?(entity)
|
431
|
-
return true
|
432
|
-
end
|
433
|
-
|
434
|
-
return nil
|
435
|
-
end
|
436
|
-
|
437
|
-
# within attributes, we want to convert all hex/dec/url
|
438
|
-
# escape sequences into their raw characters so that we can
|
439
|
-
# check we don't get stray quotes/brackets inside strings.
|
440
|
-
|
441
|
-
def decode_entities(data)
|
442
|
-
data = data.dup
|
443
|
-
|
444
|
-
data.gsub!(/(&)#(\d+);?/){ decode_dec_entity($1, $2) }
|
445
|
-
data.gsub!(/(&)#x([0-9a-f]+);?/i){ decode_hex_entity($1, $2) }
|
446
|
-
data.gsub!(/(%)([0-9a-f]{2});?/i){ decode_hex_entity($1, $2) }
|
447
|
-
|
448
|
-
data = validate_entities(data)
|
449
|
-
|
450
|
-
return data
|
451
|
-
end
|
452
|
-
|
453
|
-
#
|
454
|
-
#
|
455
|
-
#
|
456
|
-
|
457
|
-
def decode_hex_entity(*m)
|
458
|
-
return decode_num_entity(m[1], m[2].to_i.to_s(16))
|
459
|
-
end
|
460
|
-
|
461
|
-
#
|
462
|
-
#
|
463
|
-
#
|
464
|
-
|
465
|
-
def decode_dec_entity(*m)
|
466
|
-
return decode_num_entity(m[1], m[2])
|
467
|
-
end
|
468
|
-
|
469
|
-
#
|
470
|
-
#
|
471
|
-
#
|
472
|
-
|
473
|
-
def decode_num_entity(orig_type, d)
|
474
|
-
d = d.to_i
|
475
|
-
d = 32 if d < 0 # space
|
476
|
-
|
477
|
-
# don't mess with high chars
|
478
|
-
if d > 127
|
479
|
-
return '%' + d.to_s(16) if orig_type == '%'
|
480
|
-
return "&#{d};" if orig_type == '&'
|
481
|
-
end
|
482
|
-
|
483
|
-
return escape_special_chars(d.chr)
|
484
|
-
end
|
485
|
-
|
486
|
-
#
|
487
|
-
#
|
488
|
-
#
|
489
|
-
|
490
|
-
def strip_single(data)
|
491
|
-
return data.gsub('\"', '"').gsub('\0', 0.chr)
|
492
|
-
end
|
493
|
-
|
494
|
-
# Certain characters have special significance in HTML, and
|
495
|
-
# should be represented by HTML entities if they are to
|
496
|
-
# preserve their meanings. This function returns a string
|
497
|
-
# with some of these conversions made; the translations made
|
498
|
-
# are those most useful for everyday web programming.
|
499
|
-
|
500
|
-
def escape_special_chars(data)
|
501
|
-
data = data.dup
|
502
|
-
data.gsub! /&/n , '&'
|
503
|
-
data.gsub! /\"/n , '"'
|
504
|
-
data.gsub! />/n , '>'
|
505
|
-
data.gsub! /</n , '<'
|
506
|
-
data.gsub! /'/ , '''
|
507
|
-
return data
|
508
|
-
end
|
509
|
-
|
510
|
-
end
|
511
|
-
|
512
|
-
# Overload the standard String class for extra convienience.
|
513
|
-
|
514
|
-
class String
|
515
|
-
def html_filter(*opts)
|
516
|
-
HtmlFilter.new(*opts).filter(self)
|
517
|
-
end
|
518
|
-
end
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
=begin test
|
523
|
-
|
524
|
-
require 'test/unit'
|
525
|
-
|
526
|
-
class TestHtmlFilter < Test::Unit::TestCase
|
527
|
-
|
528
|
-
# core tests
|
529
|
-
|
530
|
-
def test_multiton_without_options
|
531
|
-
h1 = HtmlFilter.new
|
532
|
-
h2 = HtmlFilter.new
|
533
|
-
h3 = HtmlFilter.new( :strip_comments => false )
|
534
|
-
assert_equal( h1.object_id, h2.object_id )
|
535
|
-
assert_not_equal( h1.object_id, h3.object_id )
|
536
|
-
end
|
537
|
-
|
538
|
-
def test_multiton_with_options
|
539
|
-
h1 = HtmlFilter.new( :strip_comments => false )
|
540
|
-
h2 = HtmlFilter.new( :strip_comments => false )
|
541
|
-
h3 = HtmlFilter.new
|
542
|
-
assert_equal( h1.object_id, h2.object_id )
|
543
|
-
assert_not_equal( h1.object_id, h3.object_id )
|
544
|
-
end
|
545
|
-
|
546
|
-
def test_strip_single
|
547
|
-
hf = HtmlFilter.new
|
548
|
-
assert_equal( '"', hf.send(:strip_single,'\"') )
|
549
|
-
assert_equal( "\000", hf.send(:strip_single,'\0') )
|
550
|
-
end
|
551
|
-
|
552
|
-
# functional tests
|
553
|
-
|
554
|
-
def assert_filter(filtered, original)
|
555
|
-
assert_equal(filtered, original.html_filter)
|
556
|
-
end
|
557
|
-
|
558
|
-
def test_fix_quotes
|
559
|
-
assert_filter '<img src="foo.jpg" />', "<img src=\"foo.jpg />"
|
560
|
-
end
|
561
|
-
|
562
|
-
def test_basics
|
563
|
-
assert_filter '', ''
|
564
|
-
assert_filter 'hello', 'hello'
|
565
|
-
end
|
566
|
-
|
567
|
-
def test_balancing_tags
|
568
|
-
assert_filter "<b>hello</b>", "<<b>hello</b>"
|
569
|
-
assert_filter "<b>hello</b>", "<b>>hello</b>"
|
570
|
-
assert_filter "<b>hello</b>", "<b>hello<</b>"
|
571
|
-
assert_filter "<b>hello</b>", "<b>hello</b>>"
|
572
|
-
assert_filter "", "<>"
|
573
|
-
end
|
574
|
-
|
575
|
-
def test_tag_completion
|
576
|
-
assert_filter "hello", "hello<b>"
|
577
|
-
assert_filter "<b>hello</b>", "<b>hello"
|
578
|
-
assert_filter "hello<b>world</b>", "hello<b>world"
|
579
|
-
assert_filter "hello", "hello</b>"
|
580
|
-
assert_filter "hello", "hello<b/>"
|
581
|
-
assert_filter "hello<b>world</b>", "hello<b/>world"
|
582
|
-
assert_filter "<b><b><b>hello</b></b></b>", "<b><b><b>hello"
|
583
|
-
assert_filter "", "</b><b>"
|
584
|
-
end
|
585
|
-
|
586
|
-
def test_end_slashes
|
587
|
-
assert_filter '<img />', '<img>'
|
588
|
-
assert_filter '<img />', '<img/>'
|
589
|
-
assert_filter '', '<b/></b>'
|
590
|
-
end
|
591
|
-
|
592
|
-
end
|
593
|
-
|
594
|
-
=end
|
595
|
-
|