Skip to content

Commit f504da1

Browse files
Migrate to solidus_dev_support@0.5.0
Migrate all the gem files to use this template[1] as a guide. Some of the new RuboCop rules introduced in solidus_dev_support have been disabled to let the build pass but will be fixed in a new PR. [1] https://github.com/solidusio/solidus_dev_support/tree/v0.5.0/lib/solidus_dev_support/templates/extension
1 parent 76189f7 commit f504da1

18 files changed

+236
-249
lines changed

.gem_release.yml

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
bump:
2+
recurse: false
3+
file: 'lib/solidus_graphql_api/version.rb'
4+
message: Bump SolidusGraphqlApi to %{version}
5+
tag: true

.github/stale.yml

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Number of days of inactivity before an issue becomes stale
2+
daysUntilStale: 60
3+
# Number of days of inactivity before a stale issue is closed
4+
daysUntilClose: 7
5+
# Issues with these labels will never be considered stale
6+
exemptLabels:
7+
- pinned
8+
- security
9+
# Label to use when marking an issue as stale
10+
staleLabel: wontfix
11+
# Comment to post when marking an issue as stale. Set to `false` to disable
12+
markComment: >
13+
This issue has been automatically marked as stale because it has not had
14+
recent activity. It will be closed if no further activity occurs. Thank you
15+
for your contributions.
16+
# Comment to post when closing a stale issue. Set to `false` to disable
17+
closeComment: false

.gitignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
*~
44
.#*
55
.DS_Store
6+
.Gemfile
67
.idea
78
.project
89
.sass-cache
@@ -12,5 +13,5 @@ coverage
1213
nbproject
1314
pkg
1415
spec/dummy
16+
spec/examples.txt
1517
tmp
16-
.Gemfile

.rspec

+2-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
--color
1+
--color
2+
--require spec_helper

.rubocop-https---relaxed-ruby-style-rubocop-yml

-174
This file was deleted.

.rubocop.yml

+62-14
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,62 @@
1-
inherit_from:
2-
- https://relaxed.ruby.style/rubocop.yml
3-
4-
AllCops:
5-
Exclude:
6-
- 'node_modules/**/*'
7-
- 'vendor/**/*'
8-
- '.git/**/*'
9-
- 'bin/rake'
10-
- 'spec/dummy/**/*'
11-
12-
Metrics/BlockLength:
13-
Exclude:
14-
- 'spec/**/*_spec.rb'
1+
require:
2+
- solidus_dev_support/rubocop
3+
4+
Style/ExpandPathArguments:
5+
Enabled: false
6+
7+
Metrics/LineLength:
8+
Enabled: false
9+
10+
Performance/RegexpMatch:
11+
Enabled: false
12+
13+
RSpec/MessageSpies:
14+
Enabled: false
15+
16+
RSpec/NotToNot:
17+
Enabled: false
18+
19+
RSpec/NamedSubject:
20+
Enabled: false
21+
22+
RSpec/VerifiedDoubles:
23+
Enabled: false
24+
25+
RSpec/LeadingSubject:
26+
Enabled: false
27+
28+
RSpec/ContextWording:
29+
Enabled: false
30+
31+
RSpec/NestedGroups:
32+
Enabled: false
33+
34+
RSpec/PredicateMatcher:
35+
Enabled: false
36+
37+
RSpec/DescribeClass:
38+
Enabled: false
39+
40+
RSpec/DescribedClass:
41+
Enabled: false
42+
43+
RSpec/LeakyConstantDeclaration:
44+
Enabled: false
45+
46+
RSpec/AnyInstance:
47+
Enabled: false
48+
49+
RSpec/LetSetup:
50+
Enabled: false
51+
52+
RSpec/HookArgument:
53+
Enabled: false
54+
55+
Layout/AlignArguments:
56+
Enabled: false
57+
58+
Rails/RakeEnvironment:
59+
Enabled: false
60+
61+
Rails/HttpStatus:
62+
Enabled: false

CONTRIBUTING.md

+57
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# How to contribute
2+
3+
Third-party patches are essential to any great open source project. We want
4+
to keep it as easy as possible to contribute changes that get things working
5+
in your environment. There are a few guidelines that we need contributors to
6+
follow so that we can have a chance of keeping on top of things.
7+
8+
## Getting Started
9+
10+
* Make sure you have a [GitHub account](https://github.com/signup/free)
11+
* Submit a ticket for your issue, assuming one does not already exist.
12+
* Clearly describe the issue including steps to reproduce when it is a bug.
13+
* Make sure you fill in the earliest version that you know has the issue.
14+
* Fork the repository on GitHub
15+
16+
## Making Changes
17+
18+
* Create a topic branch from where you want to base your work.
19+
* This is usually the master branch.
20+
* Only target release branches if you are certain your fix must be on that
21+
branch.
22+
* To quickly create a topic branch based on master; `git branch
23+
fix/master/my_contribution master` then checkout the new branch with `git
24+
checkout fix/master/my_contribution`. Please avoid working directly on the
25+
`master` branch.
26+
* Make commits of logical units.
27+
* Check for unnecessary whitespace with `git diff --check` before committing.
28+
* Make sure your commit messages are in the proper format.
29+
30+
````
31+
(#99999) Make the example in CONTRIBUTING imperative and concrete
32+
33+
Without this patch applied the example commit message in the CONTRIBUTING
34+
document is not a concrete example. This is a problem because the
35+
contributor is left to imagine what the commit message should look like
36+
based on a description rather than an example. This patch fixes the
37+
problem by making the example concrete and imperative.
38+
39+
The first line is a real life imperative statement with a ticket number
40+
from our issue tracker. The body describes the behavior without the patch,
41+
why this is a problem, and how the patch fixes the problem when applied.
42+
````
43+
44+
* Make sure you have added the necessary tests for your changes.
45+
* Run _all_ the tests to assure nothing else was accidentally broken.
46+
47+
## Submitting Changes
48+
49+
* Push your changes to a topic branch in your fork of the repository.
50+
* Submit a pull request to the extensions repository.
51+
* Update any Github issues to mark that you have submitted code and are ready for it to be reviewed.
52+
* Include a link to the pull request in the ticket
53+
54+
# Additional Resources
55+
56+
* [General GitHub documentation](http://help.github.com/)
57+
* [GitHub pull request documentation](http://help.github.com/send-pull-requests/)

Gemfile

+11-5
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,26 @@
11
# frozen_string_literal: true
22

33
source 'https://rubygems.org'
4+
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
45

5-
git_source(:github) { |name| "https://github.com/#{name}.git" }
6+
branch = ENV.fetch('SOLIDUS_BRANCH', 'master')
7+
gem 'solidus', github: 'solidusio/solidus', branch: branch
68

7-
solidus_branch = ENV.fetch('SOLIDUS_BRANCH', 'master')
9+
# Needed to help Bundler figure out how to resolve dependencies,
10+
# otherwise it takes forever to resolve them.
11+
# See https://github.com/bundler/bundler/issues/6677
12+
gem 'rails', '>0.a'
813

9-
gem 'solidus', github: 'solidusio/solidus', branch: solidus_branch
1014
# Provides basic authentication functionality for testing parts of your engine
1115
gem 'solidus_auth_devise'
1216

1317
case ENV['DB']
1418
when 'mysql'
15-
gem 'mysql2', '~> 0.4.10'
19+
gem 'mysql2'
1620
when 'postgresql'
17-
gem 'pg', '~> 0.21'
21+
gem 'pg'
22+
else
23+
gem 'sqlite3'
1824
end
1925

2026
# Add your own local gems

LICENSE.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ are permitted provided that the following conditions are met:
99
* Redistributions in binary form must reproduce the above copyright notice,
1010
this list of conditions and the following disclaimer in the documentation
1111
and/or other materials provided with the distribution.
12-
* Neither the name Spree nor the names of its contributors may be used to
12+
* Neither the name Solidus nor the names of its contributors may be used to
1313
endorse or promote products derived from this software without specific
1414
prior written permission.
1515

0 commit comments

Comments
 (0)