Skip to content

Commit

Permalink
1.0.7 Version bump, changelog and new update_changes.sh script
Browse files Browse the repository at this point in the history
  • Loading branch information
oesteban committed Feb 14, 2018
1 parent 84b5cf2 commit 3f86345
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 1 deletion.
7 changes: 7 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
1.0.7 (February 13, 2018)
=========================

* [FIX] Write latest BOLD mask out (space-T1w) (#978)
* [PIN] Updating niworkflows to 0.3.1 (#962)
* [FIX] Robuster BOLD mask (#966)

1.0.6 (29th of January 2018)
============================

Expand Down
2 changes: 1 addition & 1 deletion fmriprep/info.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Base module variables
"""

__version__ = '1.0.6'
__version__ = '1.0.7'
__author__ = 'The CRN developers'
__copyright__ = 'Copyright 2018, Center for Reproducible Neuroscience, Stanford University'
__credits__ = ['Craig Moodie', 'Ross Blair', 'Oscar Esteban', 'Chris Gorgolewski',
Expand Down
42 changes: 42 additions & 0 deletions update_changes.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
#!/bin/bash
#
# Collects the pull-requests since the latest release and
# aranges them in the CHANGES.rst.txt file.
#
# This is a script to be run before releasing a new version.
#
# Usage /bin/bash update_changes.sh 1.0.1
#

# Setting # $ help set
set -u # Treat unset variables as an error when substituting.
set -x # Print command traces before executing command.

# Check whether the Upcoming release header is present
head -1 CHANGES.rst | grep -q Upcoming
UPCOMING=$?
if [[ "$UPCOMING" == "0" ]]; then
head -n3 CHANGES.rst >> newchanges
fi

# Elaborate today's release header
HEADER="$1 ($(date '+%B %d, %Y'))"
echo $HEADER >> newchanges
echo $( printf "%${#HEADER}s" | tr " " "=" ) >> newchanges
echo "" >> newchanges

# Search for PRs since previous release
git log --grep="Merge pull request" `git describe --tags --abbrev=0`..HEAD --pretty='format: * %b %s' | sed 's/Merge pull request \#\([^\d]*\)\ from\ .*/(\#\1)/' >> newchanges
echo "" >> newchanges
echo "" >> newchanges

# Add back the Upcoming header if it was present
if [[ "$UPCOMING" == "0" ]]; then
tail -n+4 CHANGES.rst >> newchanges
else
cat CHANGES.rst >> newchanges
fi

# Replace old CHANGES.rst with new file
mv newchanges CHANGES.rst

0 comments on commit 3f86345

Please sign in to comment.