Skip to content

Commit 50a3d73

Browse files
authored
Gemspec update (#166)
2 parents fb310df + fbcab7b commit 50a3d73

File tree

9 files changed

+79
-152
lines changed

9 files changed

+79
-152
lines changed

.rock.yml

Lines changed: 0 additions & 5 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,20 @@
11
Changelog
22
=========
33

4+
## Next
5+
6+
### Breaking
7+
8+
- Remove mongoid extension
9+
- Remove monkeypatch for ruby 1.8
10+
- Make `eql?` behare like `==`
11+
12+
### Added
13+
14+
- Add allocate() method
15+
- Add IPv4 and IPv6 subnet validation
16+
17+
418
## 0.8.3 - 2016-02-17
519

620
### Added

CONTRIBUTING.md

Lines changed: 12 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,26 @@
1-
# Contributing to the IPAddress Gem
1+
# Contributing
22

33
[![Build Status](https://travis-ci.org/ipaddress-gem/ipaddress.svg?branch=master)](https://travis-ci.org/ipaddress-gem/ipaddress) [![Code Climate](https://codeclimate.com/github/ipaddress-gem/ipaddress/badges/gpa.svg)](https://codeclimate.com/github/ipaddress-gem/ipaddress) [![Dependency Status](https://www.versioneye.com/user/projects/57001305fcd19a0051853bde/badge.svg?style=flat)](https://www.versioneye.com/user/projects/57001305fcd19a0051853bde)
44

5-
This gem is run by people who have jobs. So please understand if we can't always prioritize PRs and issues.
5+
This gem is run by people who have jobs. So please understand if we can't always prioritize PRs and issues.
66

7-
You can help by making your code submissions. We can't promise a specific turnaround time, or that your code will be incorporated but all submissions are appreciated.
7+
You can help by making your code submissions. We can't promise a specific turnaround time, or that your code will be incorporated but all submissions are appreciated.
88

9-
## Steps to Submit a Pull Request
9+
## Steps to submit a Pull Request
1010

11-
* [Fork](https://help.github.com/articles/fork-a-repo) the project on GitHub.
12-
* Make your feature addition or bug fix [in a feature branch](https://github.com/Kunena/Kunena-Forum/wiki/Create-a-new-branch-with-git-and-manage-branches). (Include a description of your changes in the PR)
11+
* Fork the project on GitHub.
12+
* Make your feature addition or bug fix in a feature branch.
13+
* Include a description of your changes in the PR.
1314
* Push your feature branch to GitHub.
14-
* Send a [Pull Request](https://help.github.com/articles/using-pull-requests)
15+
* Send a Pull Request.
1516

1617
## Style Guide
1718

18-
We will require that you adhere to the [ruby-style-guide](https://github.com/bbatsov/ruby-style-guide) for your code submissions.
19+
We will require that you adhere to the [ruby-style-guide](https://rubystyle.guide/) for your code submissions.
1920

2021
## Test Coverage
2122

22-
All submissions of code must include test coverage which describes intent and expected behavior. The test suite used by this gem is [Minitest](https://github.com/seattlerb/minitest)
23+
All submissions of code must include test coverage which describes intent and expected behavior.
24+
The test suite used by this gem is [Minitest](https://github.com/seattlerb/minitest)
2325

24-
Unit tests are expected to execute quickly. We will ask you to revise any long-running tests.
25-
26-
We intend to add [Travis CI](https://travis-ci.org/) for automatic execution of branch tests.
27-
28-
## Versioning: Jeweler and Semantic Versioning
29-
30-
This repo uses [semantic versioning](http://semver.org/) implemented by the [Jeweler Gem](https://github.com/technicalpickles/jeweler). Please do not update the version by editting files, instead, you may increment or modify the version using the Rake tasks added by Jeweler.
31-
32-
```
33-
$ rake -T | grep version
34-
rake version # Displays the current version
35-
rake version:bump:major # Bump the major version by 1
36-
rake version:bump:minor # Bump the a minor version by 1
37-
rake version:bump:patch # Bump the patch version by 1
38-
rake version:write # Writes out an explicit version
39-
```
26+
Unit tests are expected to execute quickly. We will ask you to revise any long-running tests.

Gemfile

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
1-
source "https://rubygems.org"
1+
# frozen_string_literal: true
2+
3+
source 'https://rubygems.org'
4+
5+
# Only development and test dependencies should be listed here.
6+
# Runtime dependencies should be listed in the gemspec.
7+
gemspec
28

39
group :development do
4-
gem 'bundler', '>= 1.0'
5-
gem 'rake', '10.5.0'
6-
gem 'minitest', '~> 5.8', '>= 5.8.4'
710
gem 'pry', '>= 0.10.1'
811
gem 'travis', '>= 1.8.2'
9-
gem 'jeweler', '>=2.0.1'
12+
end
13+
14+
group :test do
15+
gem 'minitest', '~> 5.8', '>= 5.8.4'
1016
gem 'codeclimate-test-reporter'
1117
gem 'simplecov'
1218
end

LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2009-2015 Marco Ceresa
1+
Copyright (c) 2009-today Marco Ceresa
22

33
Permission is hereby granted, free of charge, to any person obtaining
44
a copy of this software and associated documentation files (the

Rakefile

Lines changed: 5 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
require 'rubygems'
22
require 'rake'
33
require 'rake/clean'
4-
require "bundler/gem_tasks"
5-
6-
4+
require 'bundler/gem_tasks'
75
require 'rake/testtask'
6+
87
Rake::TestTask.new(:test) do |test|
98
test.libs << 'lib' << 'test'
109
test.pattern = 'test/**/*_test.rb'
@@ -21,11 +20,10 @@ begin
2120
end
2221
rescue LoadError
2322
task :rcov do
24-
abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
23+
abort 'RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov'
2524
end
2625
end
2726

28-
2927
task :default => :test
3028

3129
require 'rdoc/task'
@@ -43,27 +41,9 @@ Rake::RDocTask.new do |rdoc|
4341
rdoc.rdoc_files.include('lib/**/*.rb')
4442
end
4543

46-
desc "Open an irb session preloaded with this library"
44+
desc 'Open an irb session preloaded with this library'
4745
task :console do
48-
sh "irb -rubygems -I lib -r ipaddress.rb"
49-
end
50-
51-
desc "Look for TODO and FIXME tags in the code"
52-
task :todo do
53-
def egrep(pattern)
54-
Dir['**/*.rb'].each do |fn|
55-
count = 0
56-
open(fn) do |f|
57-
while line = f.gets
58-
count += 1
59-
if line =~ pattern
60-
puts "#{fn}:#{count}:#{line}"
61-
end
62-
end
63-
end
64-
end
65-
end
66-
egrep /(FIXME|TODO|TBD)/
46+
sh 'irb -rubygems -I lib -r ipaddress.rb'
6747
end
6848

6949
Dir["#{File.dirname(__FILE__)}/tasks/*.rake"].sort.each { |raketask| load raketask }

ipaddress.gemspec

Lines changed: 35 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -1,81 +1,41 @@
1-
# Generated by jeweler
2-
# DO NOT EDIT THIS FILE DIRECTLY
3-
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4-
# -*- encoding: utf-8 -*-
5-
# stub: ipaddress 0.8.3 ruby lib
1+
require_relative 'lib/ipaddress/version'
62

73
Gem::Specification.new do |s|
8-
s.name = "ipaddress"
9-
s.version = "0.8.3"
4+
s.name = 'ipaddress'
5+
s.version = IPAddress::VERSION
106

11-
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12-
s.require_paths = ["lib"]
13-
s.authors = ["bluemonk", "mikemackintosh"]
14-
s.date = "2016-03-23"
15-
s.description = "IPAddress is a Ruby library designed to make manipulation\n of IPv4 and IPv6 addresses both powerful and simple. It maintains\n a layer of compatibility with Ruby's own IPAddr, while\n addressing many of its issues."
16-
s.email = "ceresa@gmail.com"
17-
s.extra_rdoc_files = [
18-
"CHANGELOG.md",
19-
"LICENSE.txt",
20-
"README.md"
21-
]
22-
s.files = [
23-
".document",
24-
".rock.yml",
25-
".travis.yml",
26-
"CHANGELOG.md",
27-
"CONTRIBUTING.md",
28-
"Gemfile",
29-
"LICENSE.txt",
30-
"README.md",
31-
"Rakefile",
32-
"VERSION",
33-
"ipaddress.gemspec",
34-
"lib/ipaddress.rb",
35-
"lib/ipaddress/ipv4.rb",
36-
"lib/ipaddress/ipv6.rb",
37-
"lib/ipaddress/prefix.rb",
38-
"lib/ipaddress/version.rb",
39-
"tasks/jeweler.rake",
40-
"test/ipaddress/ipv4_test.rb",
41-
"test/ipaddress/ipv6_test.rb",
42-
"test/ipaddress/prefix_test.rb",
43-
"test/ipaddress_test.rb",
44-
"test/test_helper.rb"
45-
]
46-
s.homepage = "https://github.com/bluemonk/ipaddress"
47-
s.licenses = ["MIT"]
48-
s.rubygems_version = "2.4.6"
49-
s.summary = "IPv4/IPv6 address manipulation library"
7+
s.summary = 'A library for working with IPv4 and IPv6 addresses.'
8+
s.description = <<-EOF
9+
A Ruby library designed to make manipulation of IPv4 and IPv6 addresses both powerful and simple.
10+
It maintains a layer of compatibility with Ruby's built-in IPAddr, while addressing many of its issues.
11+
EOF
5012

51-
if s.respond_to? :specification_version then
52-
s.specification_version = 4
13+
s.authors = ['bluemonk', 'mikemackintosh']
14+
s.email = 'ceresa@gmail.com'
15+
s.homepage = 'https://github.com/ipaddress-gem/ipaddress'
16+
s.license = 'MIT'
5317

54-
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
55-
s.add_development_dependency(%q<bundler>, [">= 1.0"])
56-
s.add_development_dependency(%q<rake>, [">= 0"])
57-
s.add_development_dependency(%q<minitest>, [">= 5.8.4", "~> 5.8"])
58-
s.add_development_dependency(%q<pry>, [">= 0.10.1"])
59-
s.add_development_dependency(%q<travis>, [">= 1.8.2"])
60-
s.add_development_dependency(%q<jeweler>, [">= 2.0.1"])
61-
s.add_development_dependency(%q<codeclimate-test-reporter>, [">= 0"])
62-
else
63-
s.add_dependency(%q<bundler>, [">= 1.0"])
64-
s.add_dependency(%q<rake>, [">= 0"])
65-
s.add_dependency(%q<minitest>, [">= 5.8.4", "~> 5.8"])
66-
s.add_dependency(%q<pry>, [">= 0.10.1"])
67-
s.add_dependency(%q<travis>, [">= 1.8.2"])
68-
s.add_dependency(%q<jeweler>, [">= 2.0.1"])
69-
s.add_dependency(%q<codeclimate-test-reporter>, [">= 0"])
70-
end
71-
else
72-
s.add_dependency(%q<bundler>, [">= 1.0"])
73-
s.add_dependency(%q<rake>, [">= 0"])
74-
s.add_dependency(%q<minitest>, [">= 5.8.4", "~> 5.8"])
75-
s.add_dependency(%q<pry>, [">= 0.10.1"])
76-
s.add_dependency(%q<travis>, [">= 1.8.2"])
77-
s.add_dependency(%q<jeweler>, [">= 2.0.1"])
78-
s.add_dependency(%q<codeclimate-test-reporter>, [">= 0"])
79-
end
80-
end
18+
s.extra_rdoc_files = %w[README.md CHANGELOG.md LICENSE.txt]
19+
s.require_paths = ['lib']
20+
21+
# TODO enable this when bumping the major version of this gem
22+
# s.required_ruby_version = '>= 3.1.0'
8123

24+
s.files = Dir[
25+
'lib/**/*.rb',
26+
'.document',
27+
'CHANGELOG.md',
28+
'CONTRIBUTING.md',
29+
'LICENSE.txt',
30+
'README.md',
31+
'Rakefile',
32+
]
33+
34+
s.metadata = {
35+
'homepage_uri' => 'https://github.com/ipaddress-gem/ipaddress',
36+
'bug_tracker_uri' => 'https://github.com/ipaddress-gem/ipaddress/issues',
37+
'changelog_uri' => 'https://github.com/ipaddress-gem/ipaddress/blob/master/CHANGELOG.md',
38+
'documentation_uri' => 'https://github.com/ipaddress-gem/ipaddress/blob/master/README.md',
39+
'source_code_uri' => 'https://github.com/ipaddress-gem/ipaddress',
40+
}
41+
end

lib/ipaddress/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
module Ipaddress
1+
module IPAddress
22
VERSION = "0.8.3"
33
end

tasks/jeweler.rake

Lines changed: 0 additions & 15 deletions
This file was deleted.

0 commit comments

Comments
 (0)