Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Changed versioning approach.
Now version is bumped on every commit to `develop` and `release/vX.X.Xsomething` branch.
Files are no longer blocked from getting downloaded from github.
Version is not updated in all files, only in `ut_utils` and `VERSION` file.
For develop branch, the version is automatically set to be:
- `vX.Y.Z-develop` in VERSION file
- `vX.Y.Z.B-develop` in `ut_utils`
When building on a release branch, the version is automatically be derived from **release branch name** and the `-develop` suffix is not added for release branches.
  • Loading branch information
jgebal committed Nov 28, 2017
commit 68923ba4a3b8fe6139c052e2b9e7cf76e0aeef8c
13 changes: 11 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,11 @@
* export-ignore
^docs/* linguist-documentation
.gitattributes export-ignore
.gitignore export-ignore
.gitmodules export-ignore
.travis.yml export-ignore
mkdocs.yml export-ignore
.travis export-ignore
sonar-project.properties export-ignore
tests export-ignore
development export-ignore
node_modules export-ignore
^docs/* linguist-documentation
11 changes: 0 additions & 11 deletions .gitattributes.release

This file was deleted.

22 changes: 11 additions & 11 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ env:
- CURRENT_BRANCH=${TRAVIS_BRANCH}
- UTPLSQL_REPO="utPLSQL/utPLSQL"
- UTPLSQL_BUILD_NO="${TRAVIS_BUILD_NUMBER:-0}"
- UTPLSQL_VERSION_PATTERN='v?([0-9X]+\.){3}[0-9X]+'
- UTPLSQL_VERSION_PATTERN="v?([0-9]+\.){3}[0-9]+[^']*"
- UTPLSQL_VERSION=$(. .travis/get_project_version.sh)
- UTPLSQL_BUILD_VERSION=$(. .travis/get_project_build_version.sh)
- UTPLSQL_SOURCES_DIR='source'
Expand Down Expand Up @@ -84,22 +84,22 @@ install:
- bash .travis/install_sqlcl.sh
- sudo mkdir -p /dev/pdbs
- sudo chmod -R 777 /dev/pdbs
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/start_db.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/start_db.sh; fi
- df -h

before_script:
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/install.sh; fi
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/install_utplsql_release.sh; fi
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/create_additional_grants_for_old_tests.sh; fi
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/run_examples.sh; fi
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/run_old_tests.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/install.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/install_utplsql_release.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/create_additional_grants_for_old_tests.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/run_examples.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/run_old_tests.sh; fi

script:
- if [ "${TRAVIS_TAG}" = "" ]; then bash test/install_and_run_tests.sh; fi
- if [ "${TRAVIS_TAG}" = "" ] && [ "${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then sonar-scanner; fi
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/coveralls_uploader.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash test/install_and_run_tests.sh; fi
- if [[ ! $TRAVIS_TAG ]] && [ "${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then sonar-scanner; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/coveralls_uploader.sh; fi
- bash .travis/build_docs.sh
- if [ "${TRAVIS_TAG}" = "" ]; then bash .travis/push_release_version.sh; fi
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/push_release_version.sh; fi
- bash .travis/push_docs_to_gh_pages.sh

before_deploy:
Expand Down
1 change: 0 additions & 1 deletion .travis/build_release_archive.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ rm -rf docs/*
# and replace it with generated html documentation from the ignored site folder
cp -r -v site/* docs

mv -f .gitattributes.release .gitattributes
git add .
git commit -m "tmp commit for building a release archive"

Expand Down
10 changes: 7 additions & 3 deletions .travis/get_project_version.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
#!/usr/bin/env bash
#If building a new version from a release branch - then version is taken from release branch name

#When building a new version from a release branch, the version is taken from release branch name
if [[ "${CURRENT_BRANCH}" =~ ^release/v[0-9]+\.[0-9]+\.[0-9]+.*$ ]]; then
version=${CURRENT_BRANCH#release\/}
elif [[ "${TRAVIS_TAG}" =~ ^v[0-9]+\.[0-9]+\.[0-9]+.*$ ]]; then
version=${TRAVIS_TAG}
else
#Otherwise, version is taken from the VERSION file
version=`cat VERSION`
#When on develop branch, add "-develop" to the version text
if [[ "${CURRENT_BRANCH}" == "develop" ]]; then
version=`sed -r "s/(v?[0-9]+\.[0-9]+\.[0-9]+).*/\1-develop/" <<< "${version}"`
fi
fi
echo ${version}
21 changes: 12 additions & 9 deletions .travis/push_release_version.sh
Original file line number Diff line number Diff line change
@@ -1,20 +1,23 @@
#!/usr/bin/env bash

echo Current branch is "${CURRENT_BRANCH}"
if [[ "${CURRENT_BRANCH}" =~ ^release/v[0-9]+\.[0-9]+\.[0-9]+.*$ ]]; then

# We are updating version number only when:
# - not a pull request
# - branch name is = develop or branch name is like release/vX.X.X...
if [ "${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && [[ "${CURRENT_BRANCH}" =~ ^(release/v[0-9]+\.[0-9]+\.[0-9]+.*|develop)$ ]]; then
echo Current branch is "${CURRENT_BRANCH}"
echo Current job number is "${TRAVIS_JOB_NUMBER}"
#The publishing is done only once (for first job on a build matrix)
if [[ "${TRAVIS_JOB_NUMBER}" =~ \.1$ ]]; then
echo Publishing will be done for a job no. "${TRAVIS_JOB_NUMBER}"
echo "Committing version & buildNo into branch (${CURRENT_BRANCH})"
git add sonar-project.properties
git add VERSION
git commit -m 'Updated project version after building a release [skip ci]'

echo Pushing to origin
git add source/*
git commit -m 'Updated project version after build [skip ci]'
echo "Pushing to origin"
git push --quiet origin HEAD:${CURRENT_BRANCH}
else
echo Publishing will not be done for a job no.: "${TRAVIS_JOB_NUMBER}"
echo "Publishing of version skipped for job No.: ${TRAVIS_JOB_NUMBER}"
fi
else
echo Not on a release branch - skipping publishing of version
echo "Publishing of version skipped for branch ${CURRENT_BRANCH}, pull request ${TRAVIS_PULL_REQUEST}"
fi
2 changes: 1 addition & 1 deletion source/api/ut.pkb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
create or replace package body ut is

/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/api/ut.pks
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
create or replace package ut authid current_user as

/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/api/ut_runner.pkb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
create or replace package body ut_runner is

/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/api/ut_runner.pks
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
create or replace package ut_runner authid current_user is

/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotated_object.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create type ut_annotated_object as object(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotated_objects.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create type ut_annotated_objects as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create type ut_annotation as object(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_cache.sql
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create table ut_annotation_cache (
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project
Licensed under the Apache License, Version 2.0 (the "License"):
you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_cache_info.sql
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create table ut_annotation_cache_info (
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project
Licensed under the Apache License, Version 2.0 (the "License"):
you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_cache_manager.pkb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package body ut_annotation_cache_manager as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_cache_manager.pks
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package ut_annotation_cache_manager authid definer as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_cache_seq.sql
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create sequence ut_annotation_cache_seq
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project
Licensed under the Apache License, Version 2.0 (the "License"):
you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_manager.pkb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package body ut_annotation_manager as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_manager.pks
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package ut_annotation_manager authid current_user as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_obj_cache_info.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create type ut_annotation_obj_cache_info as object(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_objs_cache_info.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create type ut_annotation_objs_cache_info as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_parser.pkb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package body ut_annotation_parser as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotation_parser.pks
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package ut_annotation_parser authid current_user as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/annotations/ut_annotations.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create type ut_annotations
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/coverage/ut_coverage.pkb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package body ut_coverage is
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/coverage/ut_coverage.pks
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package ut_coverage authid current_user is
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/coverage/ut_coverage_helper.pkb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package body ut_coverage_helper is
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/coverage/ut_coverage_helper.pks
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace package ut_coverage_helper authid definer is
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/coverage/ut_coverage_reporter_base.tpb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type body ut_coverage_reporter_base is
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/coverage/ut_coverage_reporter_base.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type ut_coverage_reporter_base under ut_reporter_base(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
4 changes: 2 additions & 2 deletions source/core/coverage/ut_coverage_sources_tmp.sql
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create global temporary table ut_coverage_sources_tmp$(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project
Licensed under the Apache License, Version 2.0 (the "License"):
you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -38,7 +38,7 @@ begin
end;
v_view_source := ' ut_coverage_sources_tmp as
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project
Licensed under the Apache License, Version 2.0 (the "License"):
you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion source/core/types/ut_console_reporter_base.tpb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type body ut_console_reporter_base is
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/types/ut_console_reporter_base.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type ut_console_reporter_base under ut_reporter_base(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/types/ut_coverage_options.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type ut_coverage_options as object (
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/types/ut_event_listener.tpb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type body ut_event_listener is
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/types/ut_event_listener.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type ut_event_listener under ut_event_listener_base(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
2 changes: 1 addition & 1 deletion source/core/types/ut_event_listener_base.tps
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
create or replace type ut_event_listener_base authid current_user as object(
/*
utPLSQL - Version X.X.X.X
utPLSQL - Version 3
Copyright 2016 - 2017 utPLSQL Project

Licensed under the Apache License, Version 2.0 (the "License"):
Expand Down
Loading