Download this file
78 lines (59 with data), 2.2 kB
#!/bin/zsh
########################################################### {{{1 ###########
# Copyright © 2005 … 2023 Martin Krischik
############################################################################
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
########################################################### }}}1 ###########
source ${0:h}/Setup.command
setopt No_XTrace
setopt No_Verbose
setopt SH_Word_Split
setopt Err_Exit
setopt CSH_Null_Glob
setopt Extended_Glob
if test -z "${1}"; then
echo "
Usage:
Release_As_Tar module
Example:
Release_As_Tar wikibook
"
else
in_Module="${1}"
alr index --update-all
git status
echo "
Git must be clean to continue.
"
vared -p "Release ${in_Module} (y/n)?" -c Do_Release
if test ${(U)Do_Release} = "Y"; then
Local_Index="${PROJECT_HOME}/Library/alire-index/index/${I:0:2}/${in_Module}"
pushd "${PROJECT_HOME}/${in_Module}"
alr --force publish --tar
pushd "alire/releases"
setopt No_Err_Exit
mkdir -p "${Local_Index}"
# gcp --verbose --update --target-directory="${Local_Index}" ${in_Module}-*.toml~${in_Module}-*-dev.toml
setopt Err_Exit
popd
alr index --update-all
popd
fi
unset Do_Release
fi
########################################################### {{{1 ###########
# vim: set textwidth=0 nowrap tabstop=8 shiftwidth=4 softtabstop=4 noexpandtab :
# vim: set filetype=zsh fileencoding=utf-8 fileformat=unix foldmethod=marker :
# vim: set nospell spelllang=en_gb :
×
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.