Skip to content

Instantly share code, notes, and snippets.

@rochacbruno
Forked from nixocio/release_smash.rst
Created June 8, 2018 17:47
Show Gist options
  • Save rochacbruno/04ef96b0d1640646d589b48b0095bd85 to your computer and use it in GitHub Desktop.
Save rochacbruno/04ef96b0d1640646d589b48b0095bd85 to your computer and use it in GitHub Desktop.
Release Steps Pulp Smash

Release Goal

The two goals of the release process are to create a tagged commit which bumps the version file and describes changes since the last release, and to generate packages which can be uploaded to PyPI

Objective

This gist describes steps in how to achieve the release goal. There are other ways, but I am familiar with this one described below.

Assumptions

This gist assumes that there are two remotes. Your fork is named origin. And the upstream is named upstream.

Steps

  1. Assure that your master branch is up to date.

    git checkout master
    git fetch --all
    git merge upstream/master
    git status
    
  2. Besides that assure that there is no virtualenv activated.

  3. Clean any previous unnecessary files. Mainly the ones in dist folder.

    git clean -dfx
    
  4. From the root of pulp-smash project run the script related to release.

    ./scripts/release.sh
    
  5. Verify that dis folder contains the proper files.

    ls dist/
    
  6. A new commit was created by the script, and version file should be updated.

    git show HEAD
    

Verify that HEAD is pointing to right commit.

  1. Push to Github.

    git push origin master --tags && git push upstream master --tags
    

Verify that files were pushed properly, and a new tag was created.

  1. Upload to Pypi- Warehouse. From the root of pulp-smash project.

    twine upload dist/*
    
  2. Go to PyPi, and verify that files were uploaded properly.

Problems

  1. Assure that python3-wheels package are installed.

    sudo dnf install -y python3-wheel
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment