middleware_apm 0.2.0 → 1.0.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/.github/workflows/feature.yaml +44 -0
- data/.github/workflows/master.yaml +8 -17
- data/lib/middleware/ruby_gem/version.rb +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ad28c40852ef3fd824d47742883cf910ce305c57c62cbb0c47765bc0cf2ff79e
|
4
|
+
data.tar.gz: 4205d07c5c010676801f7b410e598fe063ebf512d68eea695ed9a8febdb1b5b9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a3be852df1c385273368376d61acdaf74a28eabd51f6af9d6e368a2df647814ab4a7dab7e73723c1bbdefe0eb676da42b0c94aad46001e8445256bea53347caa
|
7
|
+
data.tar.gz: 9451a456e11db47b0dfe942bec215b2c55d54189208ea609f2d44e56a4bbdb084fe90a84a81f29eee56c11b9e141f37226c6f5afd152102467814937d7b40c50
|
@@ -0,0 +1,44 @@
|
|
1
|
+
name: Build and Checks of Gem Package
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
branches:
|
6
|
+
- '*'
|
7
|
+
- '!master'
|
8
|
+
|
9
|
+
jobs:
|
10
|
+
build_and_checks:
|
11
|
+
runs-on: ubuntu-latest
|
12
|
+
|
13
|
+
steps:
|
14
|
+
- name: Checkout Repository
|
15
|
+
uses: actions/checkout@v2
|
16
|
+
|
17
|
+
- name: Set Up Ruby
|
18
|
+
uses: actions/setup-ruby@v1
|
19
|
+
with:
|
20
|
+
ruby-version: 3.0
|
21
|
+
|
22
|
+
- name: Install Dependencies
|
23
|
+
run: |
|
24
|
+
gem install bundler
|
25
|
+
bundle install
|
26
|
+
|
27
|
+
- name: Build Gem Package
|
28
|
+
run: |
|
29
|
+
gem build middleware_rubygem.gemspec
|
30
|
+
|
31
|
+
- name: Check for Version Change
|
32
|
+
id: version_check
|
33
|
+
run: |
|
34
|
+
# Get the latest version from the main branch
|
35
|
+
LATEST_VERSION=$(git fetch origin master && git show origin/master:lib/middleware/ruby_gem/version.rb | grep 'VERSION =' | awk '{print $3}' | tr -d '"')
|
36
|
+
|
37
|
+
# Get the current version from the current commit
|
38
|
+
NEW_VERSION=$(git show HEAD:lib/middleware/ruby_gem/version.rb | grep 'VERSION =' | awk '{print $3}' | tr -d '"')
|
39
|
+
|
40
|
+
if [ "$LATEST_VERSION" != "$NEW_VERSION" ]; then
|
41
|
+
echo "Version changed from $LATEST_VERSION to $NEW_VERSION"
|
42
|
+
else
|
43
|
+
echo "::warning file=version.rb::Version remains unchanged"
|
44
|
+
fi
|
@@ -4,7 +4,6 @@ on:
|
|
4
4
|
push:
|
5
5
|
branches:
|
6
6
|
- master
|
7
|
-
- github-workflow
|
8
7
|
|
9
8
|
jobs:
|
10
9
|
release_version:
|
@@ -28,23 +27,14 @@ jobs:
|
|
28
27
|
run: |
|
29
28
|
gem build middleware_rubygem.gemspec
|
30
29
|
|
31
|
-
- name:
|
32
|
-
id:
|
30
|
+
- name: Get the new Version
|
31
|
+
id: get_new_version
|
33
32
|
run: |
|
34
|
-
# Extract the
|
35
|
-
OLD_VERSION=$(git show HEAD^:lib/middleware/ruby_gem/version.rb | grep 'VERSION =' | awk '{print $3}' | tr -d '"')
|
33
|
+
# Extract the new version from the commit
|
36
34
|
NEW_VERSION=$(git show HEAD:lib/middleware/ruby_gem/version.rb | grep 'VERSION =' | awk '{print $3}' | tr -d '"')
|
37
|
-
|
38
|
-
if [ "$OLD_VERSION" != "$NEW_VERSION" ]; then
|
39
|
-
echo "Version changed from $OLD_VERSION to $NEW_VERSION"
|
40
|
-
echo "::set-output name=version_changed::true"
|
41
|
-
else
|
42
|
-
echo "Version remains unchanged"
|
43
|
-
echo "::set-output name=version_changed::false"
|
44
|
-
fi
|
35
|
+
echo "::set-output name=version::$NEW_VERSION"
|
45
36
|
|
46
37
|
- name: Publish Gem Package
|
47
|
-
if: steps.version_check.outputs.version_changed == 'true'
|
48
38
|
env:
|
49
39
|
GEM_HOST_API_KEY: ${{ secrets.RUBY_GEMS_API_KEY }}
|
50
40
|
run: |
|
@@ -56,13 +46,14 @@ jobs:
|
|
56
46
|
gem push *.gem
|
57
47
|
|
58
48
|
- name: Create Release
|
59
|
-
if: steps.version_check.outputs.version_changed == 'true'
|
60
49
|
id: create_release
|
61
50
|
uses: actions/create-release@v1
|
62
51
|
env:
|
63
52
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
64
53
|
with:
|
65
|
-
tag_name: v${{ steps.
|
66
|
-
release_name: Release ${{ steps.
|
54
|
+
tag_name: v${{ steps.get_new_version.outputs.version }}
|
55
|
+
release_name: Release ${{ steps.get_new_version.outputs.version }}
|
56
|
+
body: |
|
57
|
+
Release ${{ steps.get_new_version.outputs.version }}
|
67
58
|
draft: false
|
68
59
|
prerelease: false
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: middleware_apm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- middleware-dev
|
@@ -23,6 +23,7 @@ executables: []
|
|
23
23
|
extensions: []
|
24
24
|
extra_rdoc_files: []
|
25
25
|
files:
|
26
|
+
- ".github/workflows/feature.yaml"
|
26
27
|
- ".github/workflows/master.yaml"
|
27
28
|
- ".gitignore"
|
28
29
|
- ".rubocop.yml"
|