Skip to content

Commit

Permalink
Merge c590941 into 1979089
Browse files Browse the repository at this point in the history
  • Loading branch information
GRISHNOV committed Mar 10, 2023
2 parents 1979089 + c590941 commit f072b79
Show file tree
Hide file tree
Showing 6 changed files with 33 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .github/workflows/packaging.yml
Expand Up @@ -10,8 +10,20 @@ on:
- '*'

jobs:
# Run not only on tags, otherwise dependent job will skip.
version-check:
runs-on: ubuntu-20.04
steps:
- name: Check module version
# We need this step to run only on push with tag.
if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') }}
uses: tarantool/actions/check-module-version@master
with:
module-name: 'http.server'

package:
runs-on: ubuntu-latest
needs: version-check

strategy:
fail-fast: false
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/publish.yaml
Expand Up @@ -6,6 +6,16 @@ on:
tags: ['*']

jobs:
version-check:
# We need this job to run only on push with tag.
if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') }}
runs-on: ubuntu-20.04
steps:
- name: Check module version
uses: tarantool/actions/check-module-version@master
with:
module-name: 'http.server'

publish-scm-1:
if: github.ref == 'refs/heads/master'
runs-on: ubuntu-latest
Expand All @@ -18,6 +28,7 @@ jobs:

publish-tag:
if: startsWith(github.ref, 'refs/tags/')
needs: version-check
runs-on: ubuntu-latest
steps:
# Create a source tarball for the release (.src.rock).
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Expand Up @@ -6,6 +6,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [Unreleased]

### Added

- Add versioning support.

## [1.4.0] - 2022-12-30

### Added
Expand Down
1 change: 1 addition & 0 deletions http/CMakeLists.txt
Expand Up @@ -13,5 +13,6 @@ set_target_properties(httpd
# Install
install(TARGETS httpd LIBRARY DESTINATION ${TARANTOOL_INSTALL_LIBDIR}/http)
install(FILES server.lua DESTINATION ${TARANTOOL_INSTALL_LUADIR}/http)
install(FILES version.lua DESTINATION ${TARANTOOL_INSTALL_LUADIR}/http)
install(FILES mime_types.lua DESTINATION ${TARANTOOL_INSTALL_LUADIR}/http)
install(FILES codes.lua DESTINATION ${TARANTOOL_INSTALL_LUADIR}/http)
1 change: 1 addition & 0 deletions http/server.lua
Expand Up @@ -1294,6 +1294,7 @@ local function httpd_start(self)
end

local exports = {
_VERSION = require('http.version'),
DETACHED = DETACHED,

new = function(host, port, options)
Expand Down
4 changes: 4 additions & 0 deletions http/version.lua
@@ -0,0 +1,4 @@
-- Сontains the module version.
-- Requires manual update in case of release commit.

return '1.4.0'

0 comments on commit f072b79

Please sign in to comment.