Skip to content
Merged
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
9 changes: 9 additions & 0 deletions .claude/settings.local.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"permissions": {
"allow": [
"Bash(ruby:*)"
],
"deny": [],
"ask": []
}
}
19 changes: 19 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: CI
on: [push]
jobs:
tests:
runs-on: ubuntu-latest
strategy:
matrix:
ruby-version: ['3.2', '3.3', '3.4']

steps:
- uses: actions/checkout@v4

- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}

- name: Run tests & linters
run: bundle install && bundle exec rake
24 changes: 0 additions & 24 deletions .github/workflows/main.yml

This file was deleted.

37 changes: 37 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Release

on:
push:
branches:
- master

permissions:
contents: write
id-token: write
pull-requests: write

jobs:
release:
runs-on: ubuntu-latest

steps:
- name: Release Please
uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.GH_TOKEN }}

- uses: actions/checkout@v4
if: ${{ steps.release.outputs.release_created }}
with:
fetch-tags: true

- name: Set up Ruby
uses: ruby/setup-ruby@v1
if: ${{ steps.release.outputs.release_created }}
with:
bundler-cache: true
ruby-version: 3.4

- uses: rubygems/release-gem@v1
if: ${{ steps.release.outputs.release_created }}
3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "0.2.0"
}
24 changes: 0 additions & 24 deletions .rubocop.yml

This file was deleted.

7 changes: 0 additions & 7 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
# frozen_string_literal: true

source "https://rubygems.org"

# Specify your gem's dependencies in gemfather.gemspec
gemspec

gem "rake", "~> 13.0"
gem "rspec", "~> 3.0"
gem "rubocop", "~> 1.21"
62 changes: 45 additions & 17 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,27 @@ PATH
specs:
gemfather-cli (0.2.0)
tty-prompt (~> 0.23)
zeitwerk (~> 2.6)

GEM
remote: https://rubygems.org/
specs:
ast (2.4.2)
ast (2.4.3)
diff-lcs (1.5.0)
json (2.6.2)
parallel (1.22.1)
parser (3.1.2.1)
json (2.16.0)
language_server-protocol (3.17.0.5)
lint_roller (1.1.0)
parallel (1.27.0)
parser (3.3.10.0)
ast (~> 2.4.1)
racc
pastel (0.8.0)
tty-color (~> 0.5)
prism (1.6.0)
racc (1.8.1)
rainbow (3.1.1)
rake (13.0.6)
regexp_parser (2.6.0)
rexml (3.2.5)
regexp_parser (2.11.3)
rspec (3.12.0)
rspec-core (~> 3.12.0)
rspec-expectations (~> 3.12.0)
Expand All @@ -32,19 +37,37 @@ GEM
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.12.0)
rspec-support (3.12.0)
rubocop (1.38.0)
rubocop (1.80.2)
json (~> 2.3)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.1.0)
parallel (~> 1.10)
parser (>= 3.1.2.1)
parser (>= 3.3.0.2)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.8, < 3.0)
rexml (>= 3.2.5, < 4.0)
rubocop-ast (>= 1.23.0, < 2.0)
regexp_parser (>= 2.9.3, < 3.0)
rubocop-ast (>= 1.46.0, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 1.4.0, < 3.0)
rubocop-ast (1.23.0)
parser (>= 3.1.1.0)
ruby-progressbar (1.11.0)
unicode-display_width (>= 2.4.0, < 4.0)
rubocop-ast (1.47.1)
parser (>= 3.3.7.2)
prism (~> 1.4)
rubocop-performance (1.25.0)
lint_roller (~> 1.1)
rubocop (>= 1.75.0, < 2.0)
rubocop-ast (>= 1.38.0, < 2.0)
ruby-progressbar (1.13.0)
standard (1.51.0)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.0)
rubocop (~> 1.80.2)
standard-custom (~> 1.0.0)
standard-performance (~> 1.8)
standard-custom (1.0.2)
lint_roller (~> 1.0)
rubocop (~> 1.50)
standard-performance (1.8.0)
lint_roller (~> 1.1)
rubocop-performance (~> 1.25.0)
tty-color (0.6.0)
tty-cursor (0.7.1)
tty-prompt (0.23.1)
Expand All @@ -55,17 +78,22 @@ GEM
tty-screen (~> 0.8)
wisper (~> 2.0)
tty-screen (0.8.1)
unicode-display_width (2.3.0)
unicode-display_width (3.2.0)
unicode-emoji (~> 4.1)
unicode-emoji (4.1.0)
wisper (2.0.1)
zeitwerk (2.7.3)

PLATFORMS
arm64-darwin-24
x86_64-linux

DEPENDENCIES
bundler (~> 2.0)
gemfather-cli!
rake (~> 13.0)
rspec (~> 3.0)
rubocop (~> 1.21)
standard (= 1.51.0)

BUNDLED WITH
2.3.3
24 changes: 10 additions & 14 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
.PHONY: test
.PHONY: test install lint-fix install_gem remove_gem reinstall_gem start

start:
exe/gemfather

install:
bundle install

lint-fix:
bundle exec standardrb --fix

test:
@env $$(cat .env | xargs) bundle exec rspec $(filter-out $@,$(MAKECMDGOALS))

install_gem:
yes | rm -rf pkg/*
bundle exec rake build
Expand All @@ -12,16 +21,3 @@ remove_gem:
yes | gem uninstall gemfather

reinstall_gem: remove_gem install_gem

publish:
bundle exec rake build
gem push pkg/*.gem

start:
exe/gemfather

test:
bundle exec rspec

lint-fix:
bundle exec rubocop -A
8 changes: 2 additions & 6 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
# frozen_string_literal: true

require "bundler/gem_tasks"
require "rspec/core/rake_task"

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

require "rubocop/rake_task"

RuboCop::RakeTask.new
require "standard/rake"

task default: %i[spec rubocop]
task default: %i[spec standard]
1 change: 0 additions & 1 deletion bin/console
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require "bundler/setup"
require "gemfather/cli"
Expand Down
1 change: 0 additions & 1 deletion exe/gemfather
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require "bundler/setup"
require "gemfather/cli"
Expand Down
16 changes: 10 additions & 6 deletions gemfather.gemspec
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# frozen_string_literal: true

require_relative "lib/gemfather/cli/version"

Gem::Specification.new do |spec|
Expand All @@ -12,15 +10,21 @@ Gem::Specification.new do |spec|
spec.description = "Ask some questions & create a new gem template"
spec.homepage = "https://gitlab.com/k0va1/gemfather-cli"
spec.license = "MIT"
spec.required_ruby_version = ">= 2.6.0"
spec.required_ruby_version = ">= 3.2.0"

spec.metadata["homepage_uri"] = spec.homepage
spec.metadata["source_code_uri"] = "https://gitlab.com/k0va1/gemfather-cli"
spec.metadata["changelog_uri"] = "https://gitlab.com/k0va1/gemfather-cli"
spec.metadata["source_code_uri"] = spec.homepage
spec.metadata["changelog_uri"] = "#{spec.homepage}/blob/main/CHANGELOG.md"

spec.files = Dir.glob("{lib,templates}/**/*", File::FNM_DOTMATCH)
spec.files = Dir.glob("{lib,templates}/**/*", File::FNM_DOTMATCH) + %w[LICENSE.txt README.md CHANGELOG.md]
spec.bindir = "exe"
spec.executables = ["gemfather"]

spec.add_dependency "zeitwerk", "~> 2.6"
spec.add_runtime_dependency("tty-prompt", "~> 0.23")

spec.add_development_dependency "bundler", "~> 2.0"
spec.add_development_dependency "rake", "~> 13.0"
spec.add_development_dependency "rspec", "~> 3.0"
spec.add_development_dependency "standard", "1.51.0"
end
Loading