Skip to content

Commit

Permalink
Bump version to 1.2
Browse files Browse the repository at this point in the history
Added a version upgrade helper
  • Loading branch information
Farigh committed Mar 14, 2021
1 parent ab8e764 commit 590d720
Show file tree
Hide file tree
Showing 36 changed files with 178 additions and 34 deletions.
8 changes: 6 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@ All notable changes to the Memcheck-Cover project will be documented in this fil

## [Unreleased](https://github.com/Farigh/memcheck-cover/tree/HEAD)

[Full Changelog](https://github.com/Farigh/memcheck-cover/compare/release-1.1...HEAD)
[Full Changelog](https://github.com/Farigh/memcheck-cover/compare/release-1.2...HEAD)

## [v1.2](https://github.com/Farigh/memcheck-cover/releases/tag/release-1.2) (2021-03-14)

[Full Changelog](https://github.com/Farigh/memcheck-cover/compare/release-1.1...release-1.2)

**New features:**
- Add support for Valgrind's `--fullpath-after` option to the `memcheck_runner.sh` script
Expand Down Expand Up @@ -149,4 +153,4 @@ The `generate_html_report.sh` script highlights the following elements:
- Address 0x[0-9a-fA-F]+ is in the .\* segment of
- Address 0x[0-9a-fA-F]+ is in the brk data segment
- Address 0x[0-9a-fA-F]+ is .\* bytes after the brk data segment limit
- Address 0x[0-9a-fA-F]+ is in a .\* segment
- Address 0x[0-9a-fA-F]+ is in a .\* segment
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ memcheck_url_prefix_replacement_type["<path_prefix>"]="<repository_type>"

Where the key `path_prefix` is the file path prefix to the repository root directory.

The value `repository_url_prefix` is the source control server prefix to the repository.
The value `repository_url_prefix` is the source control server prefix to the repository.\
Here are some example:
- Github: https://github.com/example/example_project/blob/master/
- GitLab: https://gitlab.com/example/example_project/-/blob/master/
Expand All @@ -281,7 +281,7 @@ And the value `repository_type` is one of the supported server type (case does n
- GitLab
- BitBucket

:warning: It's advised to set a link pointing to a specific commit sha1 instead of a branch so the links would always points to a meaningful line.
:warning: It's advised to set a link pointing to a specific commit sha1 instead of a branch so that the report's links would always point to a meaningful line.

For example, setting:
```shell
Expand All @@ -298,3 +298,5 @@ To:
```
==1== at 0x10101042: myFunc() (<a href="https://github.com/example/example_project/blob/master/src/lib1/MyClass.cpp#L14">/var/user/repo/src/lib1/MyClass.cpp:14</a>)
```

Multiple replacements can be defined
3 changes: 2 additions & 1 deletion bin/utils.common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function info()

function get_memcheck_cover_version()
{
echo "1.1"
echo "1.2"
}

function print_copyright_notice()
Expand Down Expand Up @@ -75,6 +75,7 @@ function require_bin_or_die()
exit 1
fi
}

function check_param()
{
local opt_name=$1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>
<div class="report_footer">
<div class="generation_tool_version">
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.1
This report was generated using <a href="https://github.com/Farigh/memcheck-cover">memcheck-cover</a> v1.2
</div>
</div>
</div>
Expand Down
33 changes: 33 additions & 0 deletions tools/awk/update_version.awk
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#! /usr/bin/gawk -f

#####
##
## This script is a helper to increment the release version number
##
#####

BEGIN {
in_version_func = 0
}

# Version function declaration
/^function get_memcheck_cover_version\(\)$/ {
in_version_func = 1
}

# Version function closing brace
/^}$/ {
in_version_func = 0
}

{
current_line = $0

if (in_version_func == 1) {
# Update version
current_line = gensub(/echo "[0-9]+\.[0-9]+"/, "echo \"" new_version "\"", 1, current_line)
}

# Print the current line
print current_line
}
25 changes: 25 additions & 0 deletions tools/awk/update_version_in_changelog.awk
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#! /usr/bin/gawk -f

#####
##
## This script is a helper to increment the release version number
##
#####

{
if ($0 ~ /\[Full Changelog\]\(https:\/\/github\.com\/Farigh\/memcheck-cover\/compare\/release-[0-9]+.[0-9]+\.\.\.HEAD\)/) {
current_date = strftime("%Y-%m-%d")

# Update unreleased changes compare link
print "[Full Changelog](https://github.com/Farigh/memcheck-cover/compare/release-" new_version "...HEAD)"
print ""

# Add new version header
print "## [v" new_version "](https://github.com/Farigh/memcheck-cover/releases/tag/release-" new_version ") (" current_date ")"
print ""
# Add new version changes compare link
print gensub(/HEAD/, "release-" new_version, 1, $0)
} else {
print $0
}
}
16 changes: 16 additions & 0 deletions tools/awk/update_version_in_test_refs.awk
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#! /usr/bin/gawk -f

#####
##
## This script is a helper to increment the release version number
##
#####

{
if ($0 ~ /This report was generated using/) {
print gensub(/v[0-9]+.[0-9]+/, "v" new_version, 1)
} else {
# Print the current line
print $0
}
}
Loading

0 comments on commit 590d720

Please sign in to comment.