jets 2.0.5 → 2.0.6
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/.circleci/config.yml +0 -28
- data/CHANGELOG.md +3 -0
- data/lib/jets/controller/base.rb +6 -0
- data/lib/jets/router/helpers/core_helper.rb +10 -0
- data/lib/jets/version.rb +1 -1
- metadata +2 -3
- data/.circleci/bin/commit_docs.sh +0 -26
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cdb8cb528f7e05335c066a9239d76b06a57b198cd2fce9fe653aa4a351f8b12b
|
4
|
+
data.tar.gz: d31c7c09ec2e31be38578d0bdfbeb8a687b3df47b0b728e8ab8e3f9e400bcaaf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 174ef5bc4919d1bb6b9ae6eba16dfdebbebfec44d0501750ada68dfc03fcd119a43de47f85acfbe9a198e3d32eb9b7303f20769f9672a56575e6367520394634
|
7
|
+
data.tar.gz: a540230d02d1570fffc08df01ea0f109994984f242afaf61bbec8d539e24c69996de533e048fff454a608dc32dfe2b7bafe1938bbf7e5d24db8f469c92a230cf
|
data/.circleci/config.yml
CHANGED
@@ -84,34 +84,6 @@ jobs:
|
|
84
84
|
|
85
85
|
bundle exec rspec
|
86
86
|
|
87
|
-
# commit_docs.sh requires this
|
88
|
-
- run:
|
89
|
-
name: configure git
|
90
|
-
command: |
|
91
|
-
git config --global user.email "tongueroo@gmail.com"
|
92
|
-
git config --global user.name "Tung Nguyen"
|
93
|
-
|
94
|
-
- run:
|
95
|
-
name: commit cli reference docs
|
96
|
-
command: |
|
97
|
-
chmod a+x -R .circleci/bin
|
98
|
-
.circleci/bin/commit_docs.sh
|
99
|
-
|
100
|
-
- run:
|
101
|
-
name: install awscli
|
102
|
-
command: sudo apt-get update && sudo apt-get install -y awscli groff
|
103
|
-
|
104
|
-
- run:
|
105
|
-
name: configure awscli
|
106
|
-
command: |
|
107
|
-
mkdir ~/.aws
|
108
|
-
|
109
|
-
cat >~/.aws/config <<EOL
|
110
|
-
[default]
|
111
|
-
region = ${AWS_REGION}
|
112
|
-
output = json
|
113
|
-
EOL
|
114
|
-
|
115
87
|
# collect reports
|
116
88
|
- store_test_results:
|
117
89
|
path: /tmp/test-results
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,9 @@
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
4
4
|
This project *loosely tries* to adhere to [Semantic Versioning](http://semver.org/).
|
5
5
|
|
6
|
+
## [2.0.6]
|
7
|
+
- #344 controller `helper_method` macro
|
8
|
+
|
6
9
|
## [2.0.5]
|
7
10
|
- #333 Always keep vendor directory
|
8
11
|
- #335 Controller action_name method
|
data/lib/jets/controller/base.rb
CHANGED
@@ -1,5 +1,7 @@
|
|
1
1
|
module Jets::Router::Helpers
|
2
2
|
module CoreHelper
|
3
|
+
extend ActiveSupport::Concern
|
4
|
+
|
3
5
|
# Used for form_for helper
|
4
6
|
def polymorphic_path(record, _)
|
5
7
|
url_for(record)
|
@@ -13,5 +15,13 @@ module Jets::Router::Helpers
|
|
13
15
|
@_jets[:controller].send(meth)
|
14
16
|
end
|
15
17
|
end
|
18
|
+
|
19
|
+
class_methods do
|
20
|
+
def define_helper_method(name)
|
21
|
+
define_method(name) do
|
22
|
+
@_jets[:controller].send(name)
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
16
26
|
end
|
17
27
|
end
|
data/lib/jets/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jets
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tung Nguyen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-08-
|
11
|
+
date: 2019-08-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionmailer
|
@@ -538,7 +538,6 @@ executables:
|
|
538
538
|
extensions: []
|
539
539
|
extra_rdoc_files: []
|
540
540
|
files:
|
541
|
-
- ".circleci/bin/commit_docs.sh"
|
542
541
|
- ".circleci/config.yml"
|
543
542
|
- ".codebuild/README.md"
|
544
543
|
- ".codebuild/bin/jets"
|
@@ -1,26 +0,0 @@
|
|
1
|
-
#!/bin/bash -eux
|
2
|
-
|
3
|
-
# Even though specs also generate docs, lets run again to ensure clean slate
|
4
|
-
rake docs
|
5
|
-
|
6
|
-
out=$(git status docs)
|
7
|
-
if [[ "$out" = *"nothing to commit"* ]]; then
|
8
|
-
exit
|
9
|
-
fi
|
10
|
-
|
11
|
-
COMMIT_MESSAGE="docs updated by circleci"
|
12
|
-
|
13
|
-
# If the last commit already updated the docs, then exit.
|
14
|
-
# Preventable measure to avoid infinite loop.
|
15
|
-
if git log -1 --pretty=oneline | grep "$COMMIT_MESSAGE" ; then
|
16
|
-
exit
|
17
|
-
fi
|
18
|
-
|
19
|
-
# If reach here, we have some changes on docs that we should commit.
|
20
|
-
# Even though s
|
21
|
-
git add docs
|
22
|
-
git commit -m "$COMMIT_MESSAGE"
|
23
|
-
|
24
|
-
# https://makandracards.com/makandra/12107-git-show-current-branch-name-only
|
25
|
-
current_branch=$(git rev-parse --abbrev-ref HEAD)
|
26
|
-
git push origin "$current_branch"
|