-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Add test and publish workflows - Format codebase using StandardRB
- Loading branch information
Showing
17 changed files
with
225 additions
and
168 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,24 @@ | ||
name: Publish | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
build: | ||
name: Publish Packages | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
bundler-cache: true | ||
|
||
- name: Publish to RubyGems | ||
uses: dawidd6/action-publish-gem@v1 | ||
with: | ||
api_key: ${{secrets.RUBYGEMS_AUTH_TOKEN}} | ||
|
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,53 @@ | ||
name: Test | ||
|
||
on: | ||
pull_request: | ||
|
||
push: | ||
branches: [ develop, master ] | ||
|
||
env: | ||
GIT_COMMIT_SHA: ${{ github.sha }} | ||
GIT_BRANCH: ${{ github.ref }} | ||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | ||
|
||
jobs: | ||
|
||
lint: | ||
runs-on: ubuntu-latest | ||
name: lint ${{ matrix.ruby }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
ruby: [ '2.6.9', '2.7.5', '3.0.3', '3.1.1' ] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
|
||
- name: StandardRB | ||
continue-on-error: ${{ matrix.experimental }} | ||
run: bundle exec standardrb --parallel --format progress | ||
|
||
test: | ||
needs: [ lint ] | ||
runs-on: ubuntu-latest | ||
name: test ${{ matrix.ruby }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
ruby: [ '2.6.9', '2.7.5', '3.0.3', '3.1.1' ] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
|
||
- name: Test | ||
continue-on-error: ${{ matrix.experimental }} | ||
run: bundle exec rake |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 @@ | ||
ruby 3.1.1 |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# frozen_string_literal: true | ||
|
||
source 'https://rubygems.org' | ||
source "https://rubygems.org" | ||
|
||
# Specify your gem's dependencies in tate.gemspec | ||
gemspec |
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
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
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
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
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
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 |
---|---|---|
@@ -1,18 +1,18 @@ | ||
# frozen_string_literal: true | ||
|
||
lib = File.expand_path(File.dirname(__FILE__) + '/../lib') | ||
lib = File.expand_path(File.dirname(__FILE__) + "/../lib") | ||
$LOAD_PATH.unshift(lib) if File.directory?(lib) && !$LOAD_PATH.include?(lib) | ||
|
||
require 'tate/version' | ||
require 'i18n' | ||
require 'yaml' | ||
require "tate/version" | ||
require "i18n" | ||
require "yaml" | ||
|
||
I18n.load_path << Dir[File.expand_path("#{lib}/config/locales/*.yml")] | ||
I18n.enforce_available_locales = false | ||
I18n.default_locale = :en | ||
|
||
module Tate | ||
def self.transliterate(string, language = nil, _replacement = '?') | ||
def self.transliterate(string, language = nil, _replacement = "?") | ||
I18n.transliterate(string, locale: language) | ||
end | ||
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
module Tate | ||
VERSION = '1.6.0' | ||
VERSION = "1.6.0" | ||
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 |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'simplecov' | ||
SimpleCov.start | ||
require "coveralls" | ||
Coveralls.wear! | ||
|
||
$LOAD_PATH.unshift File.expand_path('../lib', __dir__) | ||
require 'tate' | ||
$LOAD_PATH.unshift File.expand_path("../lib", __dir__) | ||
require "tate" |
Oops, something went wrong.