diff --git a/.github/workflows/documentation.yaml b/.github/workflows/documentation.yaml index 8dc5227..f5f553a 100644 --- a/.github/workflows/documentation.yaml +++ b/.github/workflows/documentation.yaml @@ -40,7 +40,7 @@ jobs: run: bundle exec bake utopia:project:static --force no - name: Upload documentation artifact - uses: actions/upload-pages-artifact@v2 + uses: actions/upload-pages-artifact@v3 with: path: docs @@ -55,4 +55,4 @@ jobs: steps: - name: Deploy to GitHub Pages id: deployment - uses: actions/deploy-pages@v3 + uses: actions/deploy-pages@v4 diff --git a/.github/workflows/test-external.yaml b/.github/workflows/test-external.yaml index 18efa2c..21898f5 100644 --- a/.github/workflows/test-external.yaml +++ b/.github/workflows/test-external.yaml @@ -20,7 +20,6 @@ jobs: - macos ruby: - - "3.0" - "3.1" - "3.2" - "3.3" diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 1dca864..0769a98 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -21,7 +21,6 @@ jobs: - macos ruby: - - "3.0" - "3.1" - "3.2" - "3.3" diff --git a/console.gemspec b/console.gemspec index 78cb1dd..2c76c83 100644 --- a/console.gemspec +++ b/console.gemspec @@ -13,11 +13,15 @@ Gem::Specification.new do |spec| spec.cert_chain = ['release.cert'] spec.signing_key = File.expand_path('~/.gem/release.pem') - spec.homepage = "https://socketry.github.io/console/" + spec.homepage = "https://socketry.github.io/console" + + spec.metadata = { + "documentation_uri" => "https://socketry.github.io/console/", + } spec.files = Dir.glob(['{bake,lib}/**/*', '*.md'], File::FNM_DOTMATCH, base: __dir__) - spec.required_ruby_version = ">= 3.0" + spec.required_ruby_version = ">= 3.1" spec.add_dependency "fiber-annotation" spec.add_dependency "fiber-storage" diff --git a/fixtures/console/captured_output.rb b/fixtures/console/captured_output.rb index 3c539bf..f22a4ba 100644 --- a/fixtures/console/captured_output.rb +++ b/fixtures/console/captured_output.rb @@ -1,3 +1,8 @@ +# frozen_string_literal: true + +# Released under the MIT License. +# Copyright, 2024, by Samuel Williams. + require 'sus/shared' module Console diff --git a/gems.rb b/gems.rb index 21fc5f5..937d201 100644 --- a/gems.rb +++ b/gems.rb @@ -1,24 +1,22 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. source "https://rubygems.org" -# Specify your gem's dependencies in console.gemspec gemspec group :maintenance, optional: true do gem "bake-gem" gem "bake-modernize" - gem "bake-github-pages" gem "utopia-project" end group :test do - gem "covered", "~> 0.18.1" - gem "sus", "~> 0.14" + gem "sus" + gem "covered" gem "bake-test" gem "bake-test-external" diff --git a/lib/console.rb b/lib/console.rb index 3255322..7397722 100644 --- a/lib/console.rb +++ b/lib/console.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2019, by Bryan Powell. # Copyright, 2020, by Michael Adams. # Copyright, 2021, by Cédric Boutillier. diff --git a/lib/console/adapter.rb b/lib/console/adapter.rb index 5be0514..b483ae1 100644 --- a/lib/console/adapter.rb +++ b/lib/console/adapter.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2023, by Samuel Williams. +# Copyright, 2023-2024, by Samuel Williams. module Console # This namespace is reserved for logging adapters provided by other gems. diff --git a/lib/console/capture.rb b/lib/console/capture.rb index 0fb522e..fabeb55 100644 --- a/lib/console/capture.rb +++ b/lib/console/capture.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. require_relative 'filter' diff --git a/lib/console/compatible/logger.rb b/lib/console/compatible/logger.rb index 816ea31..2a4b5d5 100644 --- a/lib/console/compatible/logger.rb +++ b/lib/console/compatible/logger.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2022-2023, by Samuel Williams. +# Copyright, 2022-2024, by Samuel Williams. require 'logger' diff --git a/lib/console/event.rb b/lib/console/event.rb index c0fed6a..e5cc113 100644 --- a/lib/console/event.rb +++ b/lib/console/event.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. require_relative 'event/spawn' require_relative 'event/failure' diff --git a/lib/console/event/failure.rb b/lib/console/event/failure.rb index 5a9d5dc..eb3d80e 100644 --- a/lib/console/event/failure.rb +++ b/lib/console/event/failure.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2021, by Robert Schulze. require_relative 'generic' @@ -11,8 +11,8 @@ module Event # Represents a failure event. # # ```ruby - # Console.error(self, **Console::Event::Failure.for(exception)) - # ```` + # Console::Event::Failure.for(exception).emit(self) + # ``` class Failure < Generic def self.default_root Dir.getwd diff --git a/lib/console/event/generic.rb b/lib/console/event/generic.rb index 309c6eb..594a061 100644 --- a/lib/console/event/generic.rb +++ b/lib/console/event/generic.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. module Console module Event diff --git a/lib/console/event/spawn.rb b/lib/console/event/spawn.rb index 8ec1442..89fb820 100644 --- a/lib/console/event/spawn.rb +++ b/lib/console/event/spawn.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. require_relative 'generic' require_relative '../clock' diff --git a/lib/console/filter.rb b/lib/console/filter.rb index 3fd782c..1163c30 100644 --- a/lib/console/filter.rb +++ b/lib/console/filter.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2019, by Bryan Powell. # Copyright, 2020, by Michael Adams. # Copyright, 2021, by Robert Schulze. diff --git a/lib/console/format.rb b/lib/console/format.rb index 6512dbd..8b04972 100644 --- a/lib/console/format.rb +++ b/lib/console/format.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2023, by Samuel Williams. +# Copyright, 2023-2024, by Samuel Williams. require_relative 'format/safe' diff --git a/lib/console/logger.rb b/lib/console/logger.rb index 5f2dd3b..8e4078a 100644 --- a/lib/console/logger.rb +++ b/lib/console/logger.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2021, by Bryan Powell. # Copyright, 2021, by Robert Schulze. diff --git a/lib/console/output.rb b/lib/console/output.rb index 5c01189..ee8754a 100644 --- a/lib/console/output.rb +++ b/lib/console/output.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2021-2023, by Samuel Williams. +# Copyright, 2021-2024, by Samuel Williams. require_relative 'output/default' require_relative 'output/serialized' diff --git a/lib/console/output/default.rb b/lib/console/output/default.rb index d7820d5..2dbcabb 100644 --- a/lib/console/output/default.rb +++ b/lib/console/output/default.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2021-2022, by Samuel Williams. +# Copyright, 2021-2024, by Samuel Williams. require_relative 'terminal' require_relative 'serialized' diff --git a/lib/console/output/null.rb b/lib/console/output/null.rb index 2605484..9067e0c 100644 --- a/lib/console/output/null.rb +++ b/lib/console/output/null.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2023, by Samuel Williams. +# Copyright, 2023-2024, by Samuel Williams. module Console module Output diff --git a/lib/console/output/sensitive.rb b/lib/console/output/sensitive.rb index 168ad30..7d91ac3 100644 --- a/lib/console/output/sensitive.rb +++ b/lib/console/output/sensitive.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2021-2022, by Samuel Williams. +# Copyright, 2021-2024, by Samuel Williams. require_relative 'wrapper' diff --git a/lib/console/output/serialized.rb b/lib/console/output/serialized.rb index 7df0630..4042219 100644 --- a/lib/console/output/serialized.rb +++ b/lib/console/output/serialized.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. require_relative '../format' require 'time' diff --git a/lib/console/output/split.rb b/lib/console/output/split.rb index 33bcbfb..d3c3691 100644 --- a/lib/console/output/split.rb +++ b/lib/console/output/split.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2022-2023, by Samuel Williams. +# Copyright, 2022-2024, by Samuel Williams. module Console module Output diff --git a/lib/console/output/terminal.rb b/lib/console/output/terminal.rb index b5da231..4126698 100644 --- a/lib/console/output/terminal.rb +++ b/lib/console/output/terminal.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2021, by Robert Schulze. require_relative '../clock' diff --git a/lib/console/output/wrapper.rb b/lib/console/output/wrapper.rb index f37d447..045fec0 100644 --- a/lib/console/output/wrapper.rb +++ b/lib/console/output/wrapper.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2023, by Samuel Williams. +# Copyright, 2021-2024, by Samuel Williams. module Console module Output @@ -19,4 +19,4 @@ def call(...) end end end -end \ No newline at end of file +end diff --git a/lib/console/progress.rb b/lib/console/progress.rb index 5eaeed6..d8ab8af 100644 --- a/lib/console/progress.rb +++ b/lib/console/progress.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2020-2023, by Samuel Williams. +# Copyright, 2020-2024, by Samuel Williams. # Copyright, 2022, by Anton Sozontov. require_relative 'clock' diff --git a/lib/console/terminal.rb b/lib/console/terminal.rb index f86515d..4232520 100644 --- a/lib/console/terminal.rb +++ b/lib/console/terminal.rb @@ -1,8 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. -# Copyright, 2021, by Robert Schulze. +# Copyright, 2019-2024, by Samuel Williams. require_relative 'terminal/text' require_relative 'terminal/xterm' diff --git a/lib/console/terminal/formatter/failure.rb b/lib/console/terminal/formatter/failure.rb index e7755cf..14c2a2f 100644 --- a/lib/console/terminal/formatter/failure.rb +++ b/lib/console/terminal/formatter/failure.rb @@ -1,8 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. -# Copyright, 2021, by Robert Schulze. +# Copyright, 2024, by Samuel Williams. module Console module Terminal diff --git a/lib/console/terminal/formatter/progress.rb b/lib/console/terminal/formatter/progress.rb index b984b23..8a28de9 100644 --- a/lib/console/terminal/formatter/progress.rb +++ b/lib/console/terminal/formatter/progress.rb @@ -1,5 +1,7 @@ +# frozen_string_literal: true + # Released under the MIT License. -# Copyright, 2020-2022, by Samuel Williams. +# Copyright, 2024, by Samuel Williams. module Console module Terminal diff --git a/lib/console/terminal/formatter/spawn.rb b/lib/console/terminal/formatter/spawn.rb index 4d84fab..5374995 100644 --- a/lib/console/terminal/formatter/spawn.rb +++ b/lib/console/terminal/formatter/spawn.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. module Console module Terminal @@ -39,4 +39,4 @@ def chdir_string(options) end end end -end \ No newline at end of file +end diff --git a/lib/console/terminal/text.rb b/lib/console/terminal/text.rb index a011c06..dbaecac 100644 --- a/lib/console/terminal/text.rb +++ b/lib/console/terminal/text.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2022, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. require 'io/console' diff --git a/lib/console/terminal/xterm.rb b/lib/console/terminal/xterm.rb index 5e7b951..809c8d9 100644 --- a/lib/console/terminal/xterm.rb +++ b/lib/console/terminal/xterm.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. require 'io/console' diff --git a/lib/console/version.rb b/lib/console/version.rb index c21b621..e63dda3 100644 --- a/lib/console/version.rb +++ b/lib/console/version.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. module Console VERSION = "1.24.0" diff --git a/test.rb b/test.rb index 0401b4e..ef42c14 100755 --- a/test.rb +++ b/test.rb @@ -1,4 +1,8 @@ #!/usr/bin/env ruby +# frozen_string_literal: true + +# Released under the MIT License. +# Copyright, 2024, by Samuel Williams. require_relative 'lib/console' diff --git a/test/console.rb b/test/console.rb index 18e5bb4..58fdd25 100644 --- a/test/console.rb +++ b/test/console.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2019, by Bryan Powell. # Copyright, 2020, by Michael Adams. diff --git a/test/console/compatible/logger.rb b/test/console/compatible/logger.rb index 143fa2e..b7ff35b 100644 --- a/test/console/compatible/logger.rb +++ b/test/console/compatible/logger.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2022-2023, by Samuel Williams. +# Copyright, 2022-2024, by Samuel Williams. require 'console/compatible/logger' require 'console/output/terminal' diff --git a/test/console/event/failure.rb b/test/console/event/failure.rb index f54bccd..5a0ed39 100644 --- a/test/console/event/failure.rb +++ b/test/console/event/failure.rb @@ -2,7 +2,7 @@ # Released under the MIT License. # Copyright, 2021, by Robert Schulze. -# Copyright, 2021-2022, by Samuel Williams. +# Copyright, 2021-2024, by Samuel Williams. require 'console' require 'console/capture' diff --git a/test/console/event/progress.rb b/test/console/event/progress.rb index 7b266a2..ee8f021 100644 --- a/test/console/event/progress.rb +++ b/test/console/event/progress.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2020-2022, by Samuel Williams. +# Copyright, 2020-2024, by Samuel Williams. require 'console/progress' require 'console/captured_output' diff --git a/test/console/logger.rb b/test/console/logger.rb index 3d86433..2e199ac 100644 --- a/test/console/logger.rb +++ b/test/console/logger.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2019, by Bryan Powell. # Copyright, 2020, by Michael Adams. # Copyright, 2021, by Robert Schulze. diff --git a/test/console/output.rb b/test/console/output.rb index 356a97a..5714796 100644 --- a/test/console/output.rb +++ b/test/console/output.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2021-2023, by Samuel Williams. +# Copyright, 2021-2024, by Samuel Williams. require 'console/logger' require 'console/capture' diff --git a/test/console/output/default.rb b/test/console/output/default.rb index 11ee3a5..771afb9 100644 --- a/test/console/output/default.rb +++ b/test/console/output/default.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2021-2022, by Samuel Williams. +# Copyright, 2021-2024, by Samuel Williams. require 'console/logger' require 'console/capture' diff --git a/test/console/output/serialized.rb b/test/console/output/serialized.rb index 9505241..6c36aca 100644 --- a/test/console/output/serialized.rb +++ b/test/console/output/serialized.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. # Copyright, 2023, by Felix Yan. require 'console/output/serialized' diff --git a/test/console/output/terminal.rb b/test/console/output/terminal.rb index 279c9e1..380da04 100644 --- a/test/console/output/terminal.rb +++ b/test/console/output/terminal.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true # Released under the MIT License. -# Copyright, 2019-2023, by Samuel Williams. +# Copyright, 2019-2024, by Samuel Williams. require 'console/output/terminal' diff --git a/test/console/terminal/formatter/failure.rb b/test/console/terminal/formatter/failure.rb index d69448f..fda3c0b 100644 --- a/test/console/terminal/formatter/failure.rb +++ b/test/console/terminal/formatter/failure.rb @@ -1,3 +1,8 @@ +# frozen_string_literal: true + +# Released under the MIT License. +# Copyright, 2024, by Samuel Williams. + require 'console/terminal/formatter/failure' require 'console/event/failure' require 'console/terminal' @@ -20,4 +25,4 @@ expect(buffer.string).to be =~ /StandardError: It failed!/ end -end \ No newline at end of file +end diff --git a/test/console/terminal/formatter/progress.rb b/test/console/terminal/formatter/progress.rb index f9ac38b..780a34e 100644 --- a/test/console/terminal/formatter/progress.rb +++ b/test/console/terminal/formatter/progress.rb @@ -1,3 +1,8 @@ +# frozen_string_literal: true + +# Released under the MIT License. +# Copyright, 2024, by Samuel Williams. + require 'console/terminal/formatter/progress' require 'console/progress' require 'console/output/null' @@ -19,4 +24,4 @@ expect(buffer.string).to be =~ /0.00%/ end -end \ No newline at end of file +end