Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Create Changelog Action #112

Merged
merged 1 commit into from
Aug 18, 2021
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
17 changes: 17 additions & 0 deletions jupyter_releaser/actions/draft_changelog.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,25 @@
# Copyright (c) Jupyter Development Team.
# Distributed under the terms of the Modified BSD License.
import os

from jupyter_releaser.util import CHECKOUT_NAME
from jupyter_releaser.util import get_latest_tag
from jupyter_releaser.util import log
from jupyter_releaser.util import run

run("jupyter-releaser prep-git")

# Capture the "since" argument in case we add tags befor checking changelog
# Do this before bumping the version
if not os.environ.get("RH_SINCE"):
curr_dir = os.getcwd()
os.chdir(CHECKOUT_NAME)
since = get_latest_tag(os.environ["RH_BRANCH"]) or ""
if since:
log(f"Capturing {since} in RH_SINCE variable")
os.environ["RH_SINCE"] = since
os.chdir(curr_dir)

run("jupyter-releaser bump-version")
run("jupyter-releaser build-changelog")
run("jupyter-releaser draft-changelog")
3 changes: 1 addition & 2 deletions jupyter_releaser/actions/draft_release.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,7 @@

run("jupyter-releaser prep-git")

# Capture the "since" argument in case we add tags before the second
# "Check Changelog"
# Capture the "since" argument in case we add tags befor checking changelog
# Do this before bumping the version
if not os.environ.get("RH_SINCE"):
curr_dir = os.getcwd()
Expand Down