Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate: 0.15に対応 #2

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 9 additions & 16 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ jobs:
matrix:
ruby_version:
- "3.0"
- "3.1"
- "3.2"
platform:
- "ubuntu-latest"
Expand All @@ -20,18 +19,13 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v3

- name: Download voicevox core (Windows)
if: matrix.platform == 'windows-latest'
run: |
curl https://github.com/VOICEVOX/voicevox_core/releases/download/0.14.0/download-windows-x64.exe -Lo download.exe
./download.exe

- name: Download voicevox core (Ubuntu)
if: matrix.platform == 'ubuntu-latest'
run: |
curl https://github.com/VOICEVOX/voicevox_core/releases/download/0.14.0/download-linux-x64 -Lo download
chmod +x download
./download
- name: Download voicevox core
id: download-voicevox-core
uses: sevenc-nanashi/[email protected]
with:
download-item: core
path: voicevox_core
version: 0.15.0-preview.8

- name: Setup Ruby
uses: ruby/setup-ruby@v1
Expand All @@ -43,6 +37,5 @@ jobs:
run: |
bundle exec rake spec
env:
LD_LIBRARY_PATH: voicevox_core
RUBY_DLL_PATH: voicevox_core
VOICEVOX_OPEN_JTALK_DICT: voicevox_core/open_jtalk_dic_utf_8-1.11
VOICEVOX_DLL_PATH: ${{ steps.download-voicevox-core.outputs.entrypoint }}
VOICEVOX_OPEN_JTALK_DIC_DIR: ${{ steps.download-voicevox-core.outputs.open_jtalk_dic_dir }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ Gemfile.lock
voicevox_core
download.ps1
download.sh
download-*
3 changes: 3 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,6 @@ Style/GuardClause:

Naming/MethodParameterName:
Enabled: false

Lint/MissingSuper:
Enabled: false
8 changes: 5 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
## [Unreleased]

## [0.1.0] - 2022-08-13

- Initial release
- 初期リリース

## [0.2.0] - 2023-08-13


2 changes: 2 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,5 @@ gem "syntax_tree", "~> 5.2"
gem "syntax_tree-rbs", "~> 0.5.1"

gem "rspec", "~> 3.11"

gem "typeprof", "~> 0.21.7"
22 changes: 22 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,28 @@

require "bundler/gem_tasks"
require "rspec/core/rake_task"
require "orthoses"
require "orthoses-yard"
task default: [:spec]

RSpec::Core::RakeTask.new(:spec)

namespace :rbs do
desc "build RBS to sig/orthoses"
task :build do
Orthoses::Builder
.new do
use Orthoses::LoadRBS, paths: Dir.glob("sig/**/*.rbs")
use Orthoses::CreateFileByName, depth: 2, to: "sig"
use Orthoses::Filter do |name|
name.start_with?("Voicevox")
end
use Orthoses::Mixin
use Orthoses::Constant
use Orthoses::Walk, root: "Voicevox"
use Orthoses::YARD, parse: ["lib/**/*.rb"]
run -> { require_relative "lib/voicevox" }
end
.call
end
end
4 changes: 2 additions & 2 deletions Steepfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ D = Steep::Diagnostic
target :lib do
signature "sig"

check "lib" # Directory name
# check "lib" # Directory name
# check "Gemfile" # File name
# check "app/models/**/*.rb" # Glob
check "lib/**/*.rb"
# ignore "lib/templates/*.rb"

# library "pathname", "set" # Standard libraries
Expand Down
7 changes: 5 additions & 2 deletions lib/voicevox.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@
require_relative "voicevox/error"
require_relative "voicevox/wrapper/utils"
require_relative "voicevox/wrapper/info"
require_relative "voicevox/wrapper/manager"
require_relative "voicevox/wrapper/audio_query"
require_relative "voicevox/wrapper/voice_model"
require_relative "voicevox/wrapper/open_jtalk"
require_relative "voicevox/wrapper/user_dict"
require_relative "voicevox/wrapper/synthesizer"

#
# voicevox_coreのラッパー。
#
class Voicevox # rubocop:disable Lint/EmptyClass
module Voicevox
end
Loading
Loading