-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Initial extract from archive-tar-minitar.
- Loading branch information
0 parents
commit ddadb9e
Showing
21 changed files
with
1,239 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# -*- ruby -*- | ||
|
||
require 'autotest/bundler' | ||
require 'autotest/restart' | ||
require 'autotest/timestamp' | ||
|
||
def require_plugin(resource) | ||
require resource | ||
rescue LoadError | ||
false | ||
end | ||
|
||
require_plugin 'autotest/clear' | ||
|
||
Autotest.add_hook :initialize do |at| | ||
# at.testlib = "minitest/unit" | ||
# | ||
# 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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
--- | ||
service_name: travis-ci |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
*.md | ||
*.swp | ||
*~ | ||
.rake_tasks~ | ||
.source_index | ||
.vagrant | ||
Gemfile.lock | ||
Vagrantfile | ||
coverage | ||
doc | ||
html | ||
pkg | ||
publish | ||
test/cache.tst |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
exclude: !ruby/regexp '/ | ||
\.(tmp|swp)$ | ||
| | ||
CVS/ | ||
| | ||
(?i:TAGS) | ||
| | ||
\.(svn|git|hg|DS_Store|idea|vagrant)\/ | ||
| | ||
Gemfile(?:\.lock)? | ||
| | ||
type-lists\/ | ||
| | ||
\.(coveralls|pullreview|travis).yml$ | ||
| | ||
\.gemspec | ||
| | ||
Vagrantfile | ||
/x' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
--- | ||
languages: | ||
- ruby | ||
excludes: | ||
- data | ||
- docs | ||
- type-lists | ||
- .minitest.rb | ||
- lib/mime-types.rb | ||
rules: | ||
documentation: | ||
except: | ||
- test/** | ||
- support/** | ||
style: | ||
except: | ||
- db/** | ||
duplication: | ||
except: | ||
- test/** | ||
complexity: | ||
except: | ||
- test/** | ||
ignore: | ||
- space_inside_square_brackets_detected | ||
# - add_underscores_to_large_numeric | ||
# - avoid_using_curly_braces_for_multi-line_blocks | ||
# - don_t_use_parentheses_around_the_condition | ||
# - extra_blank_line_detected | ||
# - extra_blank_line_detected_at_body_end | ||
# - extra_blank_line_detected_at_body_beginning | ||
# - indent_when_as_deep_as_case | ||
# - missing_class_documentation | ||
# - missing_method_documentation | ||
# - prefer_map_over_collect | ||
# - prefer_reduce_over_inject | ||
# - prefer_ruby_19_new_hash_syntax | ||
# - prefer_ruby_19_new_lambda_syntax | ||
# - prefer_single_quoted_strings | ||
# - space_between_curly_brace_and_pipe_missing | ||
# - space_inside_parentheses_detected | ||
# - space_inside_opening_curly_brace_missing | ||
# - space_inside_closing_curly_brace_missing | ||
# - space_missing_inside_opening_curly_brace | ||
# - space_missing_inside_closing_curly_brace | ||
# - space_missing_after_hash_sign | ||
# - surrounding_space_missing_for_opening_curly_brace | ||
# - use_def_with_parentheses_when_there_are_arguments |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
--- | ||
language: ruby | ||
rvm: | ||
- 2.1.0 | ||
- 2.0.0 | ||
- 1.9.3 | ||
- 1.8.7 | ||
- ree | ||
- ruby-head | ||
- jruby-19mode | ||
- jruby-head | ||
- rbx-2 | ||
matrix: | ||
allow_failures: | ||
- rvm: rbx-2 | ||
- rvm: jruby-head | ||
- rvm: ruby-head | ||
- rvm: 1.8.7 | ||
- rvm: ree | ||
gemfile: | ||
- Gemfile | ||
before_script: | ||
- | | ||
case "${TRAVIS_RUBY_VERSION}" in | ||
rbx*) | ||
gem install psych | ||
;; | ||
esac | ||
- rake travis:before -t | ||
script: rake travis | ||
after_script: | ||
- rake travis:after -t | ||
notifications: | ||
email: | ||
recipients: | ||
- austin@rubyforge.org | ||
on_success: change | ||
on_failure: always | ||
sudo: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
== Contributing | ||
|
||
I value any contribution to minitar-cli you can provide: a bug report, a | ||
feature request, or code contributions. | ||
|
||
As minitar is a mature codebase, there are a few guidelines: | ||
|
||
* Code changes *will* *not* be accepted without tests. The test suite is | ||
written with {Minitest}[https://github.com/seattlerb/minitest]. | ||
* Match my coding style. | ||
* Use a thoughtfully-named topic branch that contains your change. Rebase your | ||
commits into logical chunks as necessary. | ||
* Use {quality commit messages}[http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html]. | ||
* Do not change the version number; when your patch is accepted and a release | ||
is made, the version will be updated at that point. | ||
* Submit a GitHub pull request with your changes. | ||
* New or changed behaviours require new or updated documentation. | ||
|
||
=== Test Dependencies | ||
|
||
minitar-cli uses Ryan Davis’s {Hoe}[https://github.com/seattlerb/hoe] to manage | ||
the release process, and it adds a number of rake tasks. You will mostly be | ||
interested in: | ||
|
||
$ rake | ||
|
||
which runs the tests the same way that: | ||
|
||
$ rake test | ||
$ rake travis | ||
|
||
will do. | ||
|
||
To assist with the installation of the development dependencies for | ||
minitar-cli, I have provided the simplest possible Gemfile pointing to the | ||
(generated) +minitar-cli.gemspec+ file. This will permit you to do: | ||
|
||
$ bundle install | ||
|
||
to get the development dependencies. If you aleady have +hoe+ installed, you | ||
can accomplish the same thing with: | ||
|
||
$ rake newb | ||
|
||
This task will install any missing dependencies, run the tests/specs, and | ||
generate the RDoc. | ||
|
||
=== Workflow | ||
|
||
Here's the most direct way to get your work merged into the project: | ||
|
||
* Fork the project. | ||
* Clone down your fork (<tt>git clone git://github.com/<username>/minitar-cli.git</tt>). | ||
* Create a topic branch to contain your change (<tt>git checkout -b my\_awesome\_feature</tt>). | ||
* Hack away, add tests. Not necessarily in that order. | ||
* Make sure everything still passes by running +rake+. | ||
* If necessary, rebase your commits into logical chunks, without errors. | ||
* Push the branch up (<tt>git push origin my\_awesome\_feature</tt>). | ||
* Create a pull request against halostatue/minitar-cli and describe what your | ||
change does and the why you think it should be merged. | ||
|
||
=== Contributors | ||
|
||
* Austin Ziegler created minitar-cli, extraced from Archive::Tar::Minitar. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# -*- ruby -*- | ||
|
||
# NOTE: This file is present to keep Travis CI happy. Edits to it will not | ||
# be accepted. | ||
|
||
source "https://rubygems.org/" | ||
|
||
if RUBY_VERSION < "1.9" | ||
gem 'mime-types', '~> 1.25' | ||
end | ||
|
||
gemspec | ||
|
||
# vim: syntax=ruby |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
== 0.6 / YYYY-MM-DD | ||
|
||
* Hello, minitar-cli. This is a new gem containing code originally from | ||
archive-tar-minitar. | ||
|
||
* Enhancements: | ||
* Extracted <tt>bin/minitar</tt> from | ||
{minitar}[https://github.com/halostatue/minitar]. | ||
* Replaced Satoru Takabayashi’s | ||
{Ruby Progress Bar}[namazu.org/~satoru/ruby-progressbar/] with | ||
{busyloop/powerbar}[https://github.com/busyloop/powerbar]. | ||
|
||
* Bugs: | ||
|
||
* Development: | ||
* Modernized minitar tooling around Hoe. | ||
* Added travis and coveralls. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
== Licence | ||
|
||
minitar-cli is free software that may be redistributed and/or modified under | ||
the terms of Ruby’s licence or the Simplified BSD licence. | ||
|
||
* Copyright 2004–2014 Austin Ziegler. | ||
|
||
=== Simplified BSD Licence | ||
See the file docs/bsdl.txt in the main distribution. | ||
|
||
=== Ruby’s Licence | ||
See the file docs/ruby.txt in the main distribution. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
.autotest | ||
.gemtest | ||
.gitignore | ||
.hoerc | ||
Contributing.rdoc | ||
History.rdoc | ||
Licence.rdoc | ||
Manifest.txt | ||
README.rdoc | ||
Rakefile | ||
bin/minitar | ||
docs/bsdl.txt | ||
docs/ruby.txt | ||
lib/minitar-cli.rb | ||
lib/minitar/cli.rb | ||
test/minitest_helper.rb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
= minitar-cli | ||
|
||
home :: https://github.com/halostatue/minitar-cli/ | ||
code :: https://github.com/halostatue/minitar-cli/ | ||
bugs :: https://github.com/halostatue/minitar-cli/issues | ||
rdoc :: http://rdoc.info/gems/minitar-cli/ | ||
continuous integration :: {<img src="https://travis-ci.org/halostatue/minitar-cli.png" />}[https://travis-ci.org/halostatue/minitar-cli] | ||
test coverage :: {<img src="https://coveralls.io/repos/halostatue/minitar-cli/badge.png" alt="Coverage Status" />}[https://coveralls.io/r/halostatue/minitar-cli] | ||
|
||
== Description | ||
|
||
<tt>minitar-cli</tt> is a pure-Ruby command-line tool that uses | ||
{minitar}[https://github.com/halostatue/minitar] to provide a command-line | ||
tool, +minitar+, for working with POSIX tar(1) archive files. | ||
|
||
This is release 0.6, extracted from {minitar}[https://halostatue.ca/minitar], | ||
with modernizations. | ||
|
||
== Synopsis | ||
|
||
Using <tt>minitar-cli</tt> is easy. | ||
|
||
… | ||
|
||
== minitar-cli Semantic Versioning | ||
|
||
The minitar-cli tool uses a {Semantic Versioning}[http://semver.org/] scheme | ||
with one change: | ||
|
||
* When PATCH is zero (+0+), it will be omitted from version references. | ||
|
||
:include: Contributing.rdoc | ||
|
||
:include: Licence.rdoc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# -*- ruby encoding: utf-8 -*- | ||
|
||
require 'rubygems' | ||
require 'hoe' | ||
require 'rake/clean' | ||
|
||
Hoe.plugin :doofus | ||
Hoe.plugin :gemspec2 | ||
Hoe.plugin :git | ||
Hoe.plugin :minitest | ||
Hoe.plugin :travis | ||
Hoe.plugin :email unless ENV['CI'] or ENV['TRAVIS'] | ||
|
||
spec = Hoe.spec 'minitar-cli' do | ||
developer('Austin Ziegler', 'halostatue@gmail.com') | ||
self.need_tar = true | ||
|
||
self.require_ruby_version '>= 1.8' | ||
|
||
self.history_file = 'History.rdoc' | ||
self.readme_file = 'README.rdoc' | ||
self.extra_rdoc_files = FileList["*.rdoc"].to_a | ||
self.licenses = ["Ruby", "BSD-2-Clause"] | ||
|
||
self.extra_deps << ['archive-tar-minitar', '~> 0.6.0'] | ||
self.extra_deps << ['powerbar', '~> 1.0'] | ||
|
||
self.extra_dev_deps << ['hoe-doofus', '~> 1.0'] | ||
self.extra_dev_deps << ['hoe-gemspec2', '~> 1.1'] | ||
self.extra_dev_deps << ['hoe-git', '~> 1.6'] | ||
self.extra_dev_deps << ['hoe-rubygems', '~> 1.0'] | ||
self.extra_dev_deps << ['hoe-travis', '~> 1.2'] | ||
self.extra_dev_deps << ['minitest', '~> 5.3'] | ||
self.extra_dev_deps << ['minitest-autotest', ['>= 1.0.b', '<2']] | ||
self.extra_dev_deps << ['rake', '~> 10.0'] | ||
self.extra_dev_deps << ['simplecov', '~> 0.7'] | ||
self.extra_dev_deps << ['coveralls', '~> 0.7'] | ||
end | ||
|
||
if RUBY_VERSION >= "1.9" | ||
namespace :test do | ||
task :coveralls do | ||
spec.test_prelude = [ | ||
'require "psych"', | ||
'require "simplecov"', | ||
'require "coveralls"', | ||
'SimpleCov.formatter = Coveralls::SimpleCov::Formatter', | ||
'SimpleCov.start("test_frameworks") { command_name "Minitest" }', | ||
'gem "minitest"' | ||
].join('; ') | ||
Rake::Task['test'].execute | ||
end | ||
|
||
desc 'Run test coverage' | ||
task :coverage do | ||
spec.test_prelude = [ | ||
'require "simplecov"', | ||
'SimpleCov.start("test_frameworks") { command_name "Minitest" }', | ||
'gem "minitest"' | ||
].join('; ') | ||
Rake::Task['test'].execute | ||
end | ||
end | ||
|
||
Rake::Task['travis'].prerequisites.replace(%w(test:coveralls)) | ||
end |
Oops, something went wrong.