Skip to contentSkip to conversation

Create semi-automatic release process

PATCH New Leon Romanovsky 1 participant 3 messages Jan 29, 2017 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover Create semi-automatic release process

Hi Doug and Jason,

This patchset simplifies the github release process for the rdma-core library. Once properly installed, it will allow simply issue "git release" command to create release notes from annotated and signed tags.

Such release notes will be formatted according to the tag context and will have rdma-core-vX.X.X.tar.gz attached to it with properly created top-level directory.

Leon Romanovsky (2):
travis: Simplify travis config
travis: Upload assets to github release

 .travis.yml              |  86 +++++++++++++++-------------------------
 Documentation/release.md | 100 +++++++++++++++++++++++++++++++++++++++++++++++
 buildlib/github-release  |   8 ++++
 buildlib/travis-build    |  29 ++++++++++++++
 4 files changed, 169 insertions(+), 54 deletions(-)
 create mode 100644 Documentation/release.md
 create mode 100755 buildlib/github-release
 create mode 100755 buildlib/travis-build

--
2.11.0

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): 20170129143559.7654-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org

#2 lore raw

PATCH 1/2 travis: Simplify travis config

Move travis build instructions into separate file.

---
 .travis.yml           | 25 +------------------------
 buildlib/travis-build | 29 +++++++++++++++++++++++++++++
 2 files changed, 30 insertions(+), 24 deletions(-)
 create mode 100755 buildlib/travis-build
.travis.yml +1 -24
index 06443530..c4fa1985 100644
@@ -36,27 +36,4 @@ addons:
       - lib32gcc-6-dev
 
 script:
-  - mkdir build build-clang build32 build-no-dma
-  - cd build
-  # The goal is warning free compile on latest gcc.
-  - CC=gcc-6 CFLAGS=-Werror cmake -GNinja ..
-  - ninja
-
-  # .. and latest clang
-  - cd ../build-clang
-  - CC=clang-3.9 CFLAGS=-Werror cmake -GNinja ..
-  - ninja
-
-  # 32 bit build
-  - cd ../build32
-  # travis's trusty is not configured in a way that enables all 32 bit
-  # packages. We could fix this with some sudo stuff.. For now turn off libnl
-  - CC=gcc-6 CFLAGS="-Werror -m32" cmake -GNinja .. -DENABLE_RESOLVE_NEIGH=0
-  - ninja
-
-  # Test with coherent DMA mode disabled (ie as would be on ARM32, etc)
-  - cd ../build-clang
-  - echo "#error Fail" >> ../libibverbs/arch.h
-  - rm CMakeCache.txt
-  - CC=clang-3.9 CFLAGS=-Werror cmake -GNinja ..
-  - ninja
+  - buildlib/travis-build
buildlib/travis-build new file +29 -0
new file mode 100755
index 00000000..bf0143b9
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+set -e
+
+mkdir build build-clang build32 build-no-dma
+cd build
+# The goal is warning free compile on latest gcc.
+CC=gcc-6 CFLAGS=-Werror cmake -GNinja ..
+ninja
+
+# .. and latest clang
+cd ../build-clang
+CC=clang-3.9 CFLAGS=-Werror cmake -GNinja ..
+ninja
+
+# 32 bit build
+cd ../build32
+# travis's trusty is not configured in a way that enables all 32 bit
+# packages. We could fix this with some sudo stuff.. For now turn off libnl
+CC=gcc-6 CFLAGS="-Werror -m32" cmake -GNinja .. -DENABLE_RESOLVE_NEIGH=0
+ninja
+
+# Test with coherent DMA mode disabled (ie as would be on ARM32, etc)
+cd ../build-clang
+echo "#error Fail" >> ../libibverbs/arch.h
+rm CMakeCache.txt
+CC=clang-3.9 CFLAGS=-Werror cmake -GNinja ..
+ninja
+cd ..
Signature · 6 lines
2.11.0

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
#3 lore raw

PATCH 2/2 travis: Upload assets to github release

In reply to a message not in the archive

Create and upload library source code to the corresponding release.

The upload is triggered for pushed tags which are expected to be in semantic version format, e.g. v12.7.0.

---
Sorry for the churn, it was created by "travis setup release" command.

---
 .travis.yml              |  63 ++++++++++++++---------------
 Documentation/release.md | 100 +++++++++++++++++++++++++++++++++++++++++++++++
 buildlib/github-release  |   8 ++++
 3 files changed, 140 insertions(+), 31 deletions(-)
 create mode 100644 Documentation/release.md
 create mode 100755 buildlib/github-release
.travis.yml +32 -31
index c4fa1985..e4d1b983 100644
@@ -1,39 +1,40 @@
 language: c
-# We need at least cmake 2.12, this means we need to use trusty.
-# Precise's glibc, etc predates what we are willing to support.
-# sudo is required to get the trusty image, and at present to enable llvm 3.9
 sudo: required
 dist: trusty
 addons:
-  # We run our builds sequentially in one VM rather than try and use the
-  # matrix feature. This is because Travis is unreasonably inefficient
-  # doing this APT setup pass.
   apt:
     sources:
-      # sourceline because travis won't white list trusty builds, and hasn't
-      # whitelisted 3.9
-      - sourceline: "deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-3.9 main"
-        key_url: "http://apt.llvm.org/llvm-snapshot.gpg.key"
-      - ubuntu-toolchain-r-test
+    - sourceline: deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-3.9 main
+      key_url: http://apt.llvm.org/llvm-snapshot.gpg.key
+    - ubuntu-toolchain-r-test
     packages:
-      - build-essential
-      - clang-3.9
-      - cmake
-      - debhelper
-      - gcc
-      - gcc-6
-      - libnl-3-dev
-      - libnl-route-3-dev
-      - libudev-dev
-      - make
-      - ninja-build
-      - pkg-config
-      - python
-      - valgrind
-
-      # 32 bit support packages
-      - gcc-multilib
-      - lib32gcc-6-dev
-
+    - build-essential
+    - clang-3.9
+    - cmake
+    - debhelper
+    - gcc
+    - gcc-6
+    - libnl-3-dev
+    - libnl-route-3-dev
+    - libudev-dev
+    - make
+    - ninja-build
+    - pkg-config
+    - python
+    - valgrind
+    - gcc-multilib
+    - lib32gcc-6-dev
 script:
-  - buildlib/travis-build
+- buildlib/travis-build
+before_deploy:
+- buildlib/github-release
+deploy:
+  provider: releases
+  api_key:
+    secure: G9sQd578nctgaety6f27P4p5nyrEgXdvMs1g+K2Hj7GPWxBpQ1Jm7kUlahcwfnYXpYqXen9b2dzyGzaLxjLL5rv6rbtOYp9SVrvybQrnJwkB0HCERKVMwEPsLPOB2lMouBDfk4+iUGdxtcw8Y5UU/xqKcAjkHkM5YpF5HauEX1Jj+Ep/XpX5DEcsVmFwkDgPKJOZv/eUgz1eVtXNFIvmSwJ+QuuUz64JpEpKMY4u7bFu0+2qWqACj19P/Rnufxpr+o5yoCuVNVptoRHMIWJiWZsrd2IhmL3knBoPoxNXSOWqQCK6DCW1KYOOVVAfFoD4YWhWrt6MuB3hh7lgLkS0rsdG9+iMlosl4SOkWZF8ZTkmrmtt6yx+s18tFdNI46QKzaA4wS/1hktweIFizYvmEwUCU8sNK5y9PMfDoGJGwiF1FzWrnLItKMiib0sTGO4Umgc0DKTazVRlIJYooOOOnBGubRudNx3elBTy4C/txSmqR39/6GYlvcyUDJMqB/oQJj2erQ5Gu8VykW5zjko6+3miX3C7GFVQ781BLxAdyNl4WRjZ9ibzjMbK3MC7f0ho1hST6cvBBmy2UnIdvB6zMayHZ/gtXKsDqE386k5FwSuTLT2V7942uFRVJiEwhVmgmBzbZND7PTj4s9GPrL2HLlJOgZooRZdx/ZcT/YNPFbA=
+  file: rdma-core-*.tar.gz
+  file_glob: true
+  skip_cleanup: true
+  on:
+    repo: linux-rdma/rdma-core
+    tags: true
Documentation/release.md new file +100 -0

100 lines not on this page · raw message

buildlib/github-release new file +8 -0
new file mode 100755
index 00000000..4c0ffda2
@@ -0,0 +1,8 @@
+#!/bin/bash
+
+set -e
+
+if [[ $TRAVIS_TAG == v* ]] && [ "$TRAVIS_OS_NAME" = "linux" ]; then
+	# Let's create release for vX tags only.
+	git archive --prefix rdma-core/ --output rdma-core-$TRAVIS_TAG.tar.gz HEAD
+fi

--
2.11.0

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html