diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..782a4be --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,27 @@ +name: Ruby + +on: + push: + branches: + - initial-implementation + + pull_request: + +jobs: + build: + runs-on: ubuntu-latest + name: Ruby ${{ matrix.ruby }} + strategy: + matrix: + ruby: + - '2.6.8' + + steps: + - uses: actions/checkout@v3 + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ matrix.ruby }} + bundler-cache: true + - name: Run the default task + run: bundle exec rake diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9106b2a --- /dev/null +++ b/.gitignore @@ -0,0 +1,8 @@ +/.bundle/ +/.yardoc +/_yardoc/ +/coverage/ +/doc/ +/pkg/ +/spec/reports/ +/tmp/ diff --git a/.rubocop.yml b/.rubocop.yml new file mode 100644 index 0000000..e3462a7 --- /dev/null +++ b/.rubocop.yml @@ -0,0 +1,13 @@ +AllCops: + TargetRubyVersion: 2.6 + +Style/StringLiterals: + Enabled: true + EnforcedStyle: double_quotes + +Style/StringLiteralsInInterpolation: + Enabled: true + EnforcedStyle: double_quotes + +Layout/LineLength: + Max: 120 diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..3b42514 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + + + +\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)* diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000..b923589 --- /dev/null +++ b/Gemfile @@ -0,0 +1,10 @@ +# frozen_string_literal: true + +source "https://rubygems.org" + +# Specify your gem's dependencies in vmpooler-dns-google-clouddns.gemspec +gemspec + +gem "rake", "~> 13.0" + +gem "rubocop", "~> 1.21" diff --git a/README.md b/README.md index 42e2aef..b1277b1 100644 --- a/README.md +++ b/README.md @@ -1 +1,35 @@ -# vmpooler-dns-google-clouddns \ No newline at end of file +# Vmpooler::Dns::Google::Clouddns + +TODO: Delete this and the text below, and describe your gem + +Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/vmpooler/dns/google/clouddns`. To experiment with that code, run `bin/console` for an interactive prompt. + +## Installation + +TODO: Replace `UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG` with your gem name right after releasing it to RubyGems.org. Please do not do it earlier due to security reasons. Alternatively, replace this section with instructions to install your gem from git if you don't plan to release to RubyGems.org. + +Install the gem and add to the application's Gemfile by executing: + + $ bundle add UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG + +If bundler is not being used to manage dependencies, install the gem by executing: + + $ gem install UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG + +## Usage + +TODO: Write usage instructions here + +## Development + +After checking out the repo, run `bin/setup` to install dependencies. 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 the created tag, 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/[USERNAME]/vmpooler-dns-google-clouddns. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/[USERNAME]/vmpooler-dns-google-clouddns/blob/initial-implementation/CODE_OF_CONDUCT.md). + +## Code of Conduct + +Everyone interacting in the Vmpooler::Dns::Google::Clouddns project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/vmpooler-dns-google-clouddns/blob/initial-implementation/CODE_OF_CONDUCT.md). diff --git a/Rakefile b/Rakefile new file mode 100644 index 0000000..1924143 --- /dev/null +++ b/Rakefile @@ -0,0 +1,8 @@ +# frozen_string_literal: true + +require "bundler/gem_tasks" +require "rubocop/rake_task" + +RuboCop::RakeTask.new + +task default: :rubocop diff --git a/bin/console b/bin/console new file mode 100755 index 0000000..677aabe --- /dev/null +++ b/bin/console @@ -0,0 +1,15 @@ +#!/usr/bin/env ruby +# frozen_string_literal: true + +require "bundler/setup" +require "vmpooler/dns/google/clouddns" + +# You can add fixtures and/or initialization code here to make experimenting +# with your gem easier. You can also use a different console, if you like. + +# (If you use this, don't forget to add pry to your Gemfile!) +# require "pry" +# Pry.start + +require "irb" +IRB.start(__FILE__) diff --git a/bin/setup b/bin/setup new file mode 100755 index 0000000..dce67d8 --- /dev/null +++ b/bin/setup @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +set -euo pipefail +IFS=$'\n\t' +set -vx + +bundle install + +# Do any other automated setup that you need to do here diff --git a/lib/vmpooler/dns/google/clouddns.rb b/lib/vmpooler/dns/google/clouddns.rb new file mode 100644 index 0000000..6b9bf8b --- /dev/null +++ b/lib/vmpooler/dns/google/clouddns.rb @@ -0,0 +1,14 @@ +# frozen_string_literal: true + +require_relative "clouddns/version" + +module Vmpooler + module Dns + module Google + module Clouddns + class Error < StandardError; end + # Your code goes here... + end + end + end +end diff --git a/lib/vmpooler/dns/google/clouddns/version.rb b/lib/vmpooler/dns/google/clouddns/version.rb new file mode 100644 index 0000000..6cc436b --- /dev/null +++ b/lib/vmpooler/dns/google/clouddns/version.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +module Vmpooler + module Dns + module Google + module Clouddns + VERSION = "0.1.0" + end + end + end +end diff --git a/sig/vmpooler/dns/google/clouddns.rbs b/sig/vmpooler/dns/google/clouddns.rbs new file mode 100644 index 0000000..ee79317 --- /dev/null +++ b/sig/vmpooler/dns/google/clouddns.rbs @@ -0,0 +1,10 @@ +module Vmpooler + module Dns + module Google + module Clouddns + VERSION: String + # See the writing guide of rbs: https://github.com/ruby/rbs#guides + end + end + end +end diff --git a/vmpooler-dns-google-clouddns.gemspec b/vmpooler-dns-google-clouddns.gemspec new file mode 100644 index 0000000..9529191 --- /dev/null +++ b/vmpooler-dns-google-clouddns.gemspec @@ -0,0 +1,38 @@ +# frozen_string_literal: true + +require_relative "lib/vmpooler/dns/google/clouddns/version" + +Gem::Specification.new do |spec| + spec.name = "vmpooler-dns-google-clouddns" + spec.version = Vmpooler::Dns::Google::Clouddns::VERSION + spec.authors = ["TODO: Write your name"] + spec.email = ["TODO: Write your email address"] + + 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.required_ruby_version = ">= 2.6.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." + + # 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. + spec.files = Dir.chdir(__dir__) do + `git ls-files -z`.split("\x0").reject do |f| + (f == __FILE__) || f.match(%r{\A(?:(?:bin|test|spec|features)/|\.(?:git|circleci)|appveyor)}) + 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 +end