From 6ced74477b6013f888c4e5e0ad9365b91cf7906c Mon Sep 17 00:00:00 2001 From: ydah Date: Sat, 1 Feb 2025 02:10:15 +0900 Subject: [PATCH] Update changelog, README, and gemspec for initial release --- CHANGELOG.md | 6 ++++-- Gemfile | 1 - MIT | 21 +++++++++++++++++++++ README.md | 29 +++++++++++++++++++++++++++++ railroad_diagrams.gemspec | 28 +++++++++++----------------- 5 files changed, 65 insertions(+), 20 deletions(-) create mode 100644 MIT diff --git a/CHANGELOG.md b/CHANGELOG.md index 34a8d98..c295c55 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ -## [Unreleased] +# Changelog -## [0.1.0] - 2025-01-28 +## Unreleased + +## 0.1.0 - 2025-02-01 - Initial release diff --git a/Gemfile b/Gemfile index c318cce..0ca3e7d 100644 --- a/Gemfile +++ b/Gemfile @@ -2,7 +2,6 @@ source "https://rubygems.org" -# Specify your gem's dependencies in railroad_diagrams.gemspec gemspec gem "rake", "~> 13.0" diff --git a/MIT b/MIT new file mode 100644 index 0000000..9b6259d --- /dev/null +++ b/MIT @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2025 Yudai Takada + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/README.md b/README.md index 5e76e3e..36613fb 100644 --- a/README.md +++ b/README.md @@ -1 +1,30 @@ # RailroadDiagrams + +A tiny Ruby+SVG library for drawing railroad syntax diagrams. + +# Installation + +Add this line to your application's Gemfile: +```ruby +gem 'railroad_diagrams' +``` + +Add then execute: +```bash +bundle install +``` + +Or install it yourself as: +```bash +gem install railroad_diagrams +``` + +## Development + +After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment. + +To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org). + +## Contributing + +Bug reports and pull requests are welcome on GitHub at https://github.com/ydah/railroad_diagrams. diff --git a/railroad_diagrams.gemspec b/railroad_diagrams.gemspec index 8c86641..269e5ec 100644 --- a/railroad_diagrams.gemspec +++ b/railroad_diagrams.gemspec @@ -8,20 +8,20 @@ Gem::Specification.new do |spec| spec.authors = ['Yudai Takada'] spec.email = ['t.yudai92@gmail.com'] - spec.summary = 'TODO: Write a short summary, because RubyGems requires one.' - spec.description = 'TODO: Write a longer description or delete this line.' - spec.homepage = "TODO: Put your gem's website or public repo URL here." + spec.summary = '🛤️ A tiny Ruby+SVG library for drawing railroad syntax diagrams like JSON.org.' + spec.description = 'Generate SVG railroad syntax diagrams, like on JSON.org.' + spec.homepage = "https://github.com/ydah/railroad_diagrams" spec.license = 'MIT' spec.required_ruby_version = '>= 3.1.0' spec.metadata['allowed_push_host'] = "TODO: Set to your gem server 'https://example.com'" - spec.metadata['homepage_uri'] = spec.homepage - spec.metadata['source_code_uri'] = "TODO: Put your gem's public repo URL here." - spec.metadata['changelog_uri'] = "TODO: Put your gem's CHANGELOG.md URL here." + spec.metadata["homepage_uri"] = spec.homepage + spec.metadata["source_code_uri"] = spec.homepage + spec.metadata["changelog_uri"] = "#{spec.homepage}/releases" + spec.metadata["bug_tracker_uri"] = "#{spec.homepage}/issues" + spec.metadata['rubygems_mfa_required'] = 'true' - # Specify which files should be added to the gem when it is released. - # The `git ls-files -z` loads the files in the RubyGem that have been added into git. gemspec = File.basename(__FILE__) spec.files = IO.popen(%w[git ls-files -z], chdir: __dir__, err: IO::NULL) do |ls| ls.readlines("\x0", chomp: true).reject do |f| @@ -29,14 +29,8 @@ Gem::Specification.new do |spec| f.start_with?(*%w[bin/ test/ spec/ features/ .git .github appveyor Gemfile]) end end - spec.bindir = 'exe' - spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) } - spec.require_paths = ['lib'] - - # Uncomment to register a new dependency of your gem - # spec.add_dependency "example-gem", "~> 1.0" - # For more information and examples about making a new gem, check out our - # guide at: https://bundler.io/guides/creating_gem.html - spec.metadata['rubygems_mfa_required'] = 'true' + spec.bindir = 'exe' + spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) } + spec.require_paths = ['lib'] end