appquery 0.3.0 → 0.4.0
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 +4 -4
- data/.irbrc +20 -0
- data/.yardopts +11 -0
- data/Appraisals +14 -4
- data/CHANGELOG.md +7 -2
- data/README.md +45 -253
- data/lib/app_query/render_helpers.rb +204 -0
- data/lib/app_query/version.rb +1 -1
- data/lib/app_query.rb +478 -40
- data/rakelib/gem.rake +25 -0
- data/rakelib/yard.rake +17 -0
- metadata +7 -2
data/rakelib/gem.rake
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
namespace :gem do
|
|
2
|
+
task "write_version", [:version] do |_task, args|
|
|
3
|
+
if args[:version]
|
|
4
|
+
version = args[:version].split("=").last
|
|
5
|
+
version_file = File.expand_path("../../lib/app_query/version.rb", __FILE__)
|
|
6
|
+
|
|
7
|
+
system(<<~CMD, exception: true)
|
|
8
|
+
ruby -pi -e 'gsub(/VERSION = ".*"/, %{VERSION = "#{version}"})' #{version_file}
|
|
9
|
+
CMD
|
|
10
|
+
Bundler.ui.confirm "Version #{version} written to #{version_file}."
|
|
11
|
+
else
|
|
12
|
+
Bundler.ui.warn "No version provided, keeping version.rb as is."
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
|
|
16
|
+
desc "Build [version]"
|
|
17
|
+
task "build", [:version] => %w[write_version] do
|
|
18
|
+
Rake::Task["build"].invoke
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
desc "Build and push [version] to rubygems"
|
|
22
|
+
task "release", [:version] => %w[build] do
|
|
23
|
+
Rake::Task["release:rubygem_push"].invoke
|
|
24
|
+
end
|
|
25
|
+
end
|
data/rakelib/yard.rake
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
require "yard"
|
|
2
|
+
|
|
3
|
+
YARD::Rake::YardocTask.new(:docs) do |t|
|
|
4
|
+
# Options defined in `.yardopts` are read first, then merged with
|
|
5
|
+
# options defined here.
|
|
6
|
+
#
|
|
7
|
+
# It's recommended to define options in `.yardopts` instead of here,
|
|
8
|
+
# as `.yardopts` can be read by external YARD tools, like the
|
|
9
|
+
# hot-reload YARD server `yard server --reload`.
|
|
10
|
+
|
|
11
|
+
# Use APPQUERY_VERSION env var (set from git tag in CI), or fall back to git describe
|
|
12
|
+
version = ENV["APPQUERY_VERSION"] || `git describe --tags --abbrev=0 2>/dev/null`.strip
|
|
13
|
+
version = nil if version.empty?
|
|
14
|
+
|
|
15
|
+
title = ["AppQuery", version, "API Documentation"].compact.join(" ")
|
|
16
|
+
t.options += ["--title", title]
|
|
17
|
+
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: appquery
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.4.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Gert Goet
|
|
@@ -40,8 +40,10 @@ executables: []
|
|
|
40
40
|
extensions: []
|
|
41
41
|
extra_rdoc_files: []
|
|
42
42
|
files:
|
|
43
|
+
- ".irbrc"
|
|
43
44
|
- ".rspec"
|
|
44
45
|
- ".standard.yml"
|
|
46
|
+
- ".yardopts"
|
|
45
47
|
- Appraisals
|
|
46
48
|
- CHANGELOG.md
|
|
47
49
|
- LICENSE.txt
|
|
@@ -49,6 +51,7 @@ files:
|
|
|
49
51
|
- Rakefile
|
|
50
52
|
- lib/app_query.rb
|
|
51
53
|
- lib/app_query/base.rb
|
|
54
|
+
- lib/app_query/render_helpers.rb
|
|
52
55
|
- lib/app_query/rspec.rb
|
|
53
56
|
- lib/app_query/rspec/helpers.rb
|
|
54
57
|
- lib/app_query/tokenizer.rb
|
|
@@ -61,6 +64,8 @@ files:
|
|
|
61
64
|
- lib/rails/generators/rspec/templates/query_spec.rb.tt
|
|
62
65
|
- mise.local.toml.example
|
|
63
66
|
- mise.toml
|
|
67
|
+
- rakelib/gem.rake
|
|
68
|
+
- rakelib/yard.rake
|
|
64
69
|
- sig/appquery.rbs
|
|
65
70
|
homepage: https://github.com/eval/appquery
|
|
66
71
|
licenses:
|
|
@@ -83,7 +88,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
83
88
|
- !ruby/object:Gem::Version
|
|
84
89
|
version: '0'
|
|
85
90
|
requirements: []
|
|
86
|
-
rubygems_version: 3.6.
|
|
91
|
+
rubygems_version: 3.6.9
|
|
87
92
|
specification_version: 4
|
|
88
93
|
summary: "raw SQL \U0001F966, cooked \U0001F372 or: make working with raw SQL queries
|
|
89
94
|
in Rails convenient by improving their introspection and testability."
|