Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modify filenames, readme format, etc to conform with Hoe-based Gem creation #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .autotest
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# -*- ruby -*-

require 'autotest/restart'

# Autotest.add_hook :initialize do |at|
# at.extra_files << "../some/external/dependency.rb"
#
# at.libs << ":../some/external"
#
# at.add_exception 'vendor'
#
# at.add_mapping(/dependency.rb/) do |f, _|
# at.files_matching(/test_.*rb$/)
# end
#
# %w(TestA TestB).each do |klass|
# at.extra_class_map[klass] = "test/test_misc.rb"
# end
# end

# Autotest.add_hook :run_command do |at|
# system "rake build"
# end
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
pkg
65 changes: 0 additions & 65 deletions ChangeLog

This file was deleted.

51 changes: 51 additions & 0 deletions History.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
=== Unreleased

* escape.rb (Escape.percent_encoding): remove duplicates in regex
character range to avoid a warning.

* escape.rb (Escape::MIMEParameter): new class.
(Escape.mime_token?): new method.
(Escape.rfc2822_quoted_string): ditto.
(Escape.mime_parameter_value): ditto.
(Escape.mime_parameter): ditto.
(Escape.http_token?): ditto.
(Escape.http_quoted_string): ditto.
(Escape.http_parameter_value): ditto.
(Escape.http_parameter): ditto.
(Escape.http_params_with_sep): ditto.
(Escape.http_params_with_pre): ditto.

* escape.rb (Escape::StringWrapper#escaped_string): New method.

* escape.rb: Escape.uri_path accepts an array of strings.

* escape.rb: Escape::PercentEncoded#split_html_form implemented.

* escape.rb: Escape.percent_encoding implemented.

=== 0.2 / 2007-02-28

* escape.rb: Escape::HTMLAttrValue defined.
Escape.html_attr_value returns it.

* escape.rb: make StringWrapper into class.
Escape::ShellEscaped, Escape::HTMLEscaped and Escape::PercentEncoded
inherit it.

* escape.rb: Escape::ShellEscaped defined.
Escape.shell_command and Escape.shell_single_word returns
Escape::ShellEscaped object instead of a string.

* escape.rb: Escape::HTMLEscaped defined.
Escape.html_text and Escape.html_attr_value returns
Escape::HTMLEscaped object instead of a string.

* escape.rb: Escape::PercentEncoded defined.
Escape.uri_segment, Escape.uri_path and Escape.html_form returns
Escape::PercentEncoded object instead of a string.

* escape.rb: rename Escape.html_attr to Escape.html_attr_value.

=== 0.1 / 2007-01-05

* Initial release
2 changes: 0 additions & 2 deletions Makefile

This file was deleted.

6 changes: 6 additions & 0 deletions Manifest.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.autotest
Manifest.txt
README.txt
Rakefile
lib/escape.rb
test/test_escape.rb
78 changes: 0 additions & 78 deletions README

This file was deleted.

113 changes: 113 additions & 0 deletions README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
= escape - HTML/URI/shell escaping utilities

* http://www.a-k-r.org/escape/

== AUTHOR:

Tanaka Akira <[email protected]>

== DESCRIPTION:

escape library provides several HTML/URI/shell escaping functions.

This library's shell escaping is more effective than that provided by the Ruby
standard library.

== FEATURES/PROBLEMS:

* several escaping/composing functions
* HTML text
* HTML attribute value
* HTML form (x-www-form-urlencoded)
* URI path
* shell command line
* dedicated classes for escaped strings
* escape and compose strongly related strings at once

== DEVELOPERS:

After checking out the source, run:

$ rake newb

This task will install any missing dependencies, run the tests/specs,
and generate the RDoc.

== FEATURES:

* several escaping/composing functions
* HTML text
* HTML attribute value
* HTML form (x-www-form-urlencoded)
* URI path
* shell command line
* dedicated classes for escaped strings
* escape and compose strongly related strings at once

== SYNOPSIS:

require 'rubygems'
require 'escape'

Escape.shell_command(["echo", "*"]) #=> #<Escape::ShellEscaped: echo '*'>
Escape.uri_path("a?b/c?d/e?f") #=> #<Escape::PercentEncoded: a%3Fb/c%3Fd/e%3Ff>
Escape.html_form([["a","b"], ["c","d"]]) #=> #<Escape::PercentEncoded: a=b&c=d>
Escape.html_form({"a"=>"b", "c"=>"d"}) #=> #<Escape::PercentEncoded: a=b&c=d>
Escape.html_text("a & b < c > d") #=> #<Escape::HTMLEscaped: a &amp; b &lt; c &gt; d>
Escape.html_attr_value("ab&<>\"c") #=> #<Escape::HTMLAttrValue: "ab&amp;&lt;&gt;&quot;c">

== REQUIREMENTS:

* ruby : http://www.ruby-lang.org/

== DOWNLOAD:

* latest release: ((<escape-0.2.tar.gz|URL:escape-0.2.tar.gz>))

* development version on github:

% git clone https://github.com/akr/escape

== INSTALL:

* rake install_gem

== DOCUMENTATION:

See rdoc/classes/Escape.html or
((<URL:http://www.a-k-r.org/escape/rdoc/classes/Escape.html>))

== DEVELOPERS:

After checking out the source, run:

$ rake newb

This task will install any missing dependencies, run the tests/specs,
and generate the RDoc.

== LICENSE:

The modified BSD licence

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. The name of the author may not be used to endorse or promote products
derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
OF SUCH DAMAGE.
10 changes: 10 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# -*- ruby -*-

require 'rubygems'
require 'hoe'

Hoe.spec 'escape' do
developer('Tanaka Akira', '[email protected]')
end

# vim: syntax=ruby
Loading