renamr 1.0.13 → 1.0.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f657e80309f9cc61d62888976e8b02c2fa3b6990b93419d212f4d9e5c037f4e9
4
- data.tar.gz: 2818d9489523bc8319a60cf5d7a564161a09e37361843c1ad026afa672ce6b6c
3
+ metadata.gz: b39e4e5a0e8eb0a2858888181609bcdddfdc71ab315de810bb7c23b6fb626ff0
4
+ data.tar.gz: 40d581dd0b0351db79c896ced04446bf5cf5d2af0ec2ae186f044bb499b09cff
5
5
  SHA512:
6
- metadata.gz: 29f4e5281074587a662ed8ab26a0755c655522b77984b7b58ee57d363709f9755fb7f00baa78ecbad9f387dabee7078e3585e27482e38eab5ae0055051f1151e
7
- data.tar.gz: f75da05cc1aac4028b2895f8cb6e75539d199b3b7e22509a0228324df0efb631585fba7a9780f3f507dcc2c509aa20b0cd3f4aee990989f0532f3ef761f9f014
6
+ metadata.gz: 03b888d15545d19a1e7ad552ebf416d51cf0d0c8dd3c11a547e2b07d467aa733bc64b888340aa7886136d1eadae811b2210db973f38e6c6f4301756c22daa83d
7
+ data.tar.gz: ad1d1388214aa414ee34fa7f73823f82ff240d31695453fb920f09a218aa8c144754b38f669c7b4f06f43735719e8b1433cb32447d5994a1528847abb01a4e34
@@ -0,0 +1,25 @@
1
+ # SPDX-FileCopyrightText: 2025 David Rabkin
2
+ # SPDX-License-Identifier: 0BSD
3
+ ---
4
+ name: actionlint
5
+ # yamllint disable rule:line-length
6
+ 'on':
7
+ push:
8
+ branches:
9
+ - master
10
+ pull_request:
11
+ branches:
12
+ - master
13
+ jobs:
14
+ actionlint:
15
+ timeout-minutes: 15
16
+ runs-on: ubuntu-24.04
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+ - name: Download actionlint
20
+ id: get_actionlint
21
+ run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
22
+ shell: bash
23
+ - name: Check workflow files
24
+ run: ${{ steps.get_actionlint.outputs.executable }} -color
25
+ shell: bash
@@ -0,0 +1,27 @@
1
+ # SPDX-FileCopyrightText: 2025 David Rabkin
2
+ # SPDX-License-Identifier: 0BSD
3
+ ---
4
+ name: rake
5
+ 'on':
6
+ push:
7
+ branches:
8
+ - master
9
+ pull_request:
10
+ branches:
11
+ - master
12
+ jobs:
13
+ rake:
14
+ strategy:
15
+ matrix:
16
+ os: [ubuntu-24.04, macos-15, windows-2022]
17
+ ruby: [3.2, 3.3, 3.4]
18
+ runs-on: ${{ matrix.os }}
19
+ steps:
20
+ - uses: actions/checkout@v4
21
+ - uses: ruby/setup-ruby@v1
22
+ with:
23
+ ruby-version: ${{ matrix.ruby }}
24
+ bundler-cache: true
25
+ - run: bundle config set --global path "$(pwd)/vendor/bundle"
26
+ - run: bundle install --no-color
27
+ - run: bundle exec rake
@@ -14,7 +14,7 @@ jobs:
14
14
  - uses: actions/checkout@v4
15
15
  - uses: ruby/setup-ruby@472790540115ce5bd69d399a020189a8c87d641f
16
16
  with:
17
- ruby-version: 3.0
17
+ ruby-version: 3.2
18
18
  - name: Install Code Scanning integration
19
19
  run: bundle add code-scanning-rubocop --version 0.6.1 --skip-install
20
20
  - name: Install dependencies
data/.travis.yml CHANGED
@@ -3,7 +3,7 @@
3
3
  ---
4
4
  language: ruby
5
5
  rvm:
6
- - ~>3.0
6
+ - ~>3.2
7
7
  branches:
8
8
  only:
9
9
  - master
data/README.adoc CHANGED
@@ -5,7 +5,7 @@
5
5
  :img-gem: https://badge.fury.io/rb/renamr.svg
6
6
  :img-hoc: https://hitsofcode.com/github/rdavid/renamr?branch=master&label=hits%20of%20code
7
7
  :img-license: https://img.shields.io/github/license/rdavid/renamr?color=blue&labelColor=gray&logo=freebsd&logoColor=lightgray&style=flat
8
- :img-maintainability: https://api.codeclimate.com/v1/badges/406f1433b0b9e0509a6e/maintainability
8
+ :img-rake: https://github.com/rdavid/renamr/actions/workflows/rake.yml/badge.svg
9
9
  :img-rubocop: https://github.com/rdavid/renamr/actions/workflows/rubocop.yml/badge.svg
10
10
  :img-style: https://img.shields.io/badge/code_style-rubocop-brightgreen.svg
11
11
  :img-test: https://github.com/rdavid/renamr/actions/workflows/test.yml/badge.svg
@@ -13,7 +13,7 @@
13
13
  :url-gem: https://badge.fury.io/rb/renamr
14
14
  :url-hoc: https://hitsofcode.com/view/github/rdavid/renamr?branch=master
15
15
  :url-license: https://github.com/rdavid/renamr/blob/master/LICENSES/0BSD.txt
16
- :url-maintainability: https://codeclimate.com/github/rdavid/renamr/maintainability
16
+ :url-rake: https://github.com/rdavid/renamr/actions/workflows/rake.yml
17
17
  :url-reuse: https://github.com/fsfe/reuse-action
18
18
  :url-rubocop: https://github.com/rdavid/renamr/actions/workflows/rubocop.yml
19
19
  :url-ruby: https://www.ruby-lang.org/en/documentation/installation
@@ -24,9 +24,9 @@
24
24
 
25
25
  = Renamr
26
26
 
27
+ image:{img-rake}[rake,link={url-rake}]
27
28
  image:{img-rubocop}[rubocop,link={url-rubocop}]
28
29
  image:{img-gem}[gem version,link={url-gem}]
29
- // image:{img-maintainability}[maintainability,link={url-maintainability}]
30
30
  image:{img-style}[code style,link={url-style}]
31
31
  image:{img-test}[test,link={url-test}]
32
32
  image:{img-hoc}[hits of code,link={url-hoc}]
@@ -41,7 +41,7 @@ toc::[]
41
41
  == Installation
42
42
  The tool is designed to operate on macOS, GNU/Linux, Windows, and Unix-like
43
43
  operating systems.
44
- It is packaged as a Gem and requires Ruby version 3.0 or later.
44
+ It is packaged as a Gem and requires Ruby version 3.2 or later.
45
45
  If you do not have the appropriate version on your platform, refer to
46
46
  {url-ruby}[Installing Ruby].
47
47
 
@@ -11,7 +11,7 @@ module Renamr
11
11
  # Automatic localization.
12
12
  class AutoLocalizationAction < Action
13
13
  def initialize
14
- super
14
+ super()
15
15
  I18n.config.available_locales = :en
16
16
  end
17
17
 
data/lib/renamr/char.rb CHANGED
@@ -4,7 +4,6 @@
4
4
  # SPDX-FileCopyrightText: 2018-2025 David Rabkin
5
5
  # SPDX-License-Identifier: 0BSD
6
6
 
7
- require 'set'
8
7
  require_relative 'action'
9
8
 
10
9
  module Renamr
data/lib/renamr/date.rb CHANGED
@@ -10,7 +10,7 @@ require_relative 'action'
10
10
  module Renamr
11
11
  # Replaces any valid date, e.g. 2020-11-02 or 02-11-2020 with 20201102.
12
12
  class DateAction < Action
13
- REG = /(\d+)-(\d+)-(\d+)/.freeze
13
+ REG = /(\d+)-(\d+)-(\d+)/
14
14
  PAT = ['%m-%d-%Y', '%d-%m-%Y', '%Y-%m-%d', '%Y-%d-%m'].freeze
15
15
 
16
16
  def validate(dat)
data/lib/renamr/omit.rb CHANGED
@@ -10,7 +10,7 @@ module Renamr
10
10
  # Omits file names shorter than limit.
11
11
  class OmitAction < Action
12
12
  def initialize(lim)
13
- super
13
+ super()
14
14
  raise 'lim cannot be nil.' if lim.nil?
15
15
 
16
16
  @lim = lim
@@ -10,7 +10,7 @@ module Renamr
10
10
  # Prepends file modification datestamp.
11
11
  class PrependDateAction < Action
12
12
  def initialize(dir)
13
- super
13
+ super()
14
14
  @dir = dir
15
15
  end
16
16
 
data/lib/renamr/remove.rb CHANGED
@@ -10,7 +10,7 @@ module Renamr
10
10
  # Removes symbols between left and right positions.
11
11
  class RemoveAction < Action
12
12
  def initialize(pos, len)
13
- super
13
+ super()
14
14
  raise 'len cannot bi nil.' if len.nil?
15
15
  raise 'pos cannot be nil.' if pos.nil?
16
16
  raise 'pos has to be positive.' unless pos.to_i.positive?
@@ -10,7 +10,7 @@ module Renamr
10
10
  # Substitutes a string with a string.
11
11
  class SubstituteAction < Action
12
12
  def initialize(src, dst)
13
- super
13
+ super()
14
14
  raise 'src cannot be nil.' if src.nil?
15
15
 
16
16
  # The action works after PointAction. All points are replaces with minus.
@@ -5,6 +5,6 @@
5
5
  # SPDX-License-Identifier: 0BSD
6
6
 
7
7
  module Renamr
8
- VERSION = '1.0.13'
9
- DATE = '2025-07-21'
8
+ VERSION = '1.0.15'
9
+ DATE = '2025-07-23'
10
10
  end
data/renamr.gemspec CHANGED
@@ -9,7 +9,7 @@ require 'renamr'
9
9
 
10
10
  Gem::Specification.new do |s|
11
11
  s.required_rubygems_version = Gem::Requirement.new('>= 0') if s.respond_to? :required_rubygems_version=
12
- s.required_ruby_version = '>=3.0'
12
+ s.required_ruby_version = '>=3.2'
13
13
  s.name = 'renamr'
14
14
  s.version = Renamr::VERSION
15
15
  s.date = Renamr::DATE
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: renamr
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.13
4
+ version: 1.0.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Rabkin
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-07-21 00:00:00.000000000 Z
10
+ date: 2025-07-23 00:00:00.000000000 Z
11
11
  dependencies: []
12
12
  description: " Renamr organises multiple files and directories.\n"
13
13
  email: david@rabkin.co.il
@@ -19,6 +19,8 @@ extra_rdoc_files:
19
19
  - README.adoc
20
20
  files:
21
21
  - ".github/dependabot.yml"
22
+ - ".github/workflows/actionlint.yml"
23
+ - ".github/workflows/rake.yml"
22
24
  - ".github/workflows/rubocop.yml"
23
25
  - ".github/workflows/test.yml"
24
26
  - ".gitignore"
@@ -69,7 +71,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
69
71
  requirements:
70
72
  - - ">="
71
73
  - !ruby/object:Gem::Version
72
- version: '3.0'
74
+ version: '3.2'
73
75
  required_rubygems_version: !ruby/object:Gem::Requirement
74
76
  requirements:
75
77
  - - ">="