aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorJake Petroules <jake.petroules@qt.io>2017-06-06 17:05:54 -0700
committerJake Petroules <jake.petroules@qt.io>2017-06-07 16:10:01 +0000
commit2fd4c0a8e8a4a4dda54e29fb59a9b82a86d58643 (patch)
tree0ac4110afd191ebfdd028ee0b16e011cbf4ab1aa /scripts
parent29a8d044b5dfc7997b007720b207f208ea25da9a (diff)
Move release script into scripts directory
Change-Id: I3e9cff70daeb330a544c2b3ebbb3139e03e01975 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/make-release-archive.sh49
1 files changed, 49 insertions, 0 deletions
diff --git a/scripts/make-release-archive.sh b/scripts/make-release-archive.sh
new file mode 100644
index 000000000..b554e78fe
--- /dev/null
+++ b/scripts/make-release-archive.sh
@@ -0,0 +1,49 @@
+#!/bin/sh
+
+#############################################################################
+##
+## Copyright (C) 2016 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of Qbs.
+##
+## $QT_BEGIN_LICENSE:LGPL$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU Lesser General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU Lesser
+## General Public License version 3 as published by the Free Software
+## Foundation and appearing in the file LICENSE.LGPL3 included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU Lesser General Public License version 3 requirements
+## will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 2.0 or (at your option) the GNU General
+## Public license version 3 or any later version approved by the KDE Free
+## Qt Foundation. The licenses are as published by the Free Software
+## Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-2.0.html and
+## https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+test $# -eq 2 || { echo "Usage: $(basename $0) <archive format> <tag>" >&2; exit 1; }
+
+format=${1}
+tag=${2}
+version=${tag#v}
+dir_name=qbs-src-${version}
+
+git archive --format=${format} --prefix=${dir_name}/ -o ${dir_name}.${format} ${tag}