Skip to content

Commit

Permalink
Merge pull request #104 from nikukyugamer/development
Browse files Browse the repository at this point in the history
v0.0.2
  • Loading branch information
nikukyugamer authored Mar 22, 2022
2 parents b61cf42 + ed40788 commit 207e665
Show file tree
Hide file tree
Showing 8 changed files with 117 additions and 41 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: 2
jobs:
build:
docker:
- image: circleci/ruby:2.7.1
- image: circleci/ruby:3.0.3
working_directory: ~/repo
steps:
- checkout
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@ jobs:
name: Prekin CI
runs-on: ubuntu-latest
container:
image: ruby:2.7.1
image: ruby:2.7.2
env:
BUNDLE_PATH: vendor/bundle
steps:
- uses: actions/checkout@v2
- name: Bundler の 最新版 を入れる
- uses: actions/checkout@v3
- name: Install the latest version's Bundler
run: |
gem install bundler --no-document
- name: RubyGems のキャッシュを復元する
uses: actions/cache@v1
- name: Restore caches of RubyGems
uses: actions/cache@v3
id: rubygems-cache
with:
path: vendor/bundle
Expand All @@ -25,14 +25,14 @@ jobs:
run: |
bundle config set deployment 'true'
bundle install --jobs 4 --retry 3
- name: RSpec を実行する
- name: Execute RSpec
if: always()
run: |
bundle exec rspec
env:
POSTGRES_HOST: postgres
RAILS_ENV: test
- name: RuboCop を実行する
- name: Execute RuboCop
if: always()
run: |
bundle exec rubocop -D -E -S -P
2 changes: 1 addition & 1 deletion .github/workflows/release_drafter_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Release Drafter
on:
push:
branches:
- master
- main
jobs:
update_release_draft:
runs-on: ubuntu-latest
Expand Down
62 changes: 31 additions & 31 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6,48 +6,48 @@ PATH
GEM
remote: https://rubygems.org/
specs:
ast (2.4.1)
ast (2.4.2)
coderay (1.1.3)
diff-lcs (1.4.4)
diff-lcs (1.5.0)
method_source (1.0.0)
parallel (1.19.2)
parser (2.7.1.4)
parallel (1.21.0)
parser (3.1.1.0)
ast (~> 2.4.1)
pry (0.13.1)
pry (0.14.1)
coderay (~> 1.1)
method_source (~> 1.0)
rainbow (3.0.0)
rake (13.0.1)
regexp_parser (1.7.1)
rexml (3.2.4)
rspec (3.9.0)
rspec-core (~> 3.9.0)
rspec-expectations (~> 3.9.0)
rspec-mocks (~> 3.9.0)
rspec-core (3.9.2)
rspec-support (~> 3.9.3)
rspec-expectations (3.9.2)
rainbow (3.1.1)
rake (13.0.6)
regexp_parser (2.2.1)
rexml (3.2.5)
rspec (3.11.0)
rspec-core (~> 3.11.0)
rspec-expectations (~> 3.11.0)
rspec-mocks (~> 3.11.0)
rspec-core (3.11.0)
rspec-support (~> 3.11.0)
rspec-expectations (3.11.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.9.0)
rspec-mocks (3.9.1)
rspec-support (~> 3.11.0)
rspec-mocks (3.11.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.9.0)
rspec-support (3.9.3)
rspec_junit_formatter (0.4.1)
rspec-support (~> 3.11.0)
rspec-support (3.11.0)
rspec_junit_formatter (0.5.1)
rspec-core (>= 2, < 4, != 2.12.0)
rubocop (0.90.0)
rubocop (1.26.0)
parallel (~> 1.10)
parser (>= 2.7.1.1)
parser (>= 3.1.0.0)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.7)
regexp_parser (>= 1.8, < 3.0)
rexml
rubocop-ast (>= 0.3.0, < 1.0)
rubocop-ast (>= 1.16.0, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 1.4.0, < 2.0)
rubocop-ast (0.3.0)
parser (>= 2.7.1.4)
ruby-progressbar (1.10.1)
unicode-display_width (1.7.0)
unicode-display_width (>= 1.4.0, < 3.0)
rubocop-ast (1.16.0)
parser (>= 3.1.1.0)
ruby-progressbar (1.11.0)
unicode-display_width (2.1.0)

PLATFORMS
ruby
Expand All @@ -62,4 +62,4 @@ DEPENDENCIES
rubocop

BUNDLED WITH
2.1.4
2.2.22
21 changes: 21 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Security Policy

## Supported Versions

Use this section to tell people about which versions of your project are
currently being supported with security updates.

| Version | Supported |
| ------- | ------------------ |
| 5.1.x | :white_check_mark: |
| 5.0.x | :x: |
| 4.0.x | :white_check_mark: |
| < 4.0 | :x: |

## Reporting a Vulnerability

Use this section to tell people how to report a vulnerability.

Tell them where to go, how often they can expect to get an update on a
reported vulnerability, what to expect if the vulnerability is accepted or
declined, etc.
4 changes: 3 additions & 1 deletion lib/prekin.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
require 'prekin/version'
require 'prekin/extend_datetime_class'
require 'prekin/extend_string_class'
require 'prekin/extend_time_class'

module Prekin
class Error < StandardError; end
# Your code goes here...
end
23 changes: 23 additions & 0 deletions renovate.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:base",
":timezone(Asia/Tokyo)"
],
"labels": [
"dependencies",
"renovate"
],
"dependencyDashboard": true,
"pin": {
"automerge": true
},
"packageRules": [
{
"matchPackagePatterns": [
"^.*"
],
"automerge": true
}
]
}
30 changes: 30 additions & 0 deletions spec/prekin_spec.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,27 @@
# 10月 2020
# 日 月 火 水 木 金 土
# 1 2 3
# 4 5 6 7 8 9 10
# 11 12 13 14 15 16 17
# 18 19 20 21 22 23 24
# 25 26 27 28 29 30 31
#
# 1月 2020
# 日 月 火 水 木 金 土
# 1 2 3 4
# 5 6 7 8 9 10 11
# 12 13 14 15 16 17 18
# 19 20 21 22 23 24 25
# 26 27 28 29 30 31

# 10月 2019
# 日 月 火 水 木 金 土
# 1 2 3 4 5
# 6 7 8 9 10 11 12
# 13 14 15 16 17 18 19
# 20 21 22 23 24 25 26
# 27 28 29 30 31

RSpec.describe Prekin do
it 'has a version number' do
expect(Prekin::VERSION).not_to be nil
Expand All @@ -6,4 +30,10 @@
it 'does something useful' do
expect(false).to eq(false)
end

it 'returns true in case of prekin' do
# FIXME: 日本時間へ
target_day = DateTime.new(2020, 10, 30)
expect(target_day.prekin?).to eq true
end
end

0 comments on commit 207e665

Please sign in to comment.