Commit 54fc8954 authored by Yaroslav Halchenko's avatar Yaroslav Halchenko

RF: absorb neurodebian-repository into neurodebian package (and rename debconf variables as well)

parent 0468a115
......@@ -19,13 +19,13 @@ set -ex
apt_file=/etc/apt/sources.list.d/local.list
# clean up from a previous test
dpkg --purge neurodebian-repository neurodebian-keyring || :
echo PURGE | debconf-communicate neurodebian-repository || :
dpkg --purge neurodebian neurodebian-keyring || :
echo PURGE | debconf-communicate neurodebian || :
rm -rf /tmp/apt $apt_file;
mkdir -p /tmp/apt; cd /tmp/apt;
rm -f neurodebian-*deb; apt-get update -y; apt-get install -y wget;
wget http://www.onerussian.com/tmp/neurodebian-repository_0.33~a1_all.deb;
wget http://www.onerussian.com/tmp/neurodebian_0.33~a1_all.deb;
wget http://www.onerussian.com/tmp/neurodebian-keyring_0.33~a1_all.deb;
# generate APT repo
......@@ -33,7 +33,7 @@ apt-get install -y dpkg-dev ; dpkg-scanpackages . /dev/null > Packages
# Add it to the list of available
echo "deb file:///tmp/apt ./" >| $apt_file; apt-get update
# Install the beast
apt-get install -y --allow-unauthenticated neurodebian-repository
apt-get install -y --allow-unauthenticated neurodebian
# Verify that it has correct entries
release=$(grep -v '^[\s#]*$' /etc/apt/sources.list | head -1 | awk '{print $3;}')
......@@ -41,7 +41,7 @@ grep -E "^deb\s+http.* $release main\s*\$" /etc/apt/sources.list.d/neurodebian.s
grep -E '^deb\s+http.* data main\s*$' /etc/apt/sources.list.d/neurodebian.sources.list
# May be even retrospect stored debconf configuration
apt-get install debconf-utils
debconf-get-selections | grep neurodebian-repository/release.*select.*auto
debconf-get-selections | grep neurodebian/release.*select.*auto
# And apt-get must be working
apt-get update
# Make sure it is active
......
......@@ -2,7 +2,7 @@ neurodebian (0.33~a1) unstable; urgency=medium
* New "upstream" release
* New features:
- neurodebian and neurodebian-repository packages to provide 1-click
- neurodebian and neurodebian packages to provide 1-click
NeuroDebian deployment on Debian/Ubuntu boxesw
-- Yaroslav Halchenko <debian@onerussian.com> Mon, 28 Jul 2014 20:03:12 -0400
......
......@@ -12,31 +12,16 @@ XS-DM-Upload-Allowed: yes
Package: neurodebian
Architecture: all
Depends: ${misc:Depends}, neurodebian-repository
Recommends: neurodebian-desktop, neurodebian-popularity-contest
Pre-depends: python-minimal, wget
Depends: neurodebian-keyring, ${misc:Depends}
Recommends: netselect
Suggests: neurodebian-desktop, neurodebian-popularity-contest
Description: turnkey platform for the neuroscience
The NeuroDebian project integrates and maintain a variety of
neuroscience-oriented (such as AFNI, FSL, PsychoPy, etc.) and many
generic computational (such as condor, pandas, etc.) software projects
within Debian.
.
This meta-package depends on packages needed for a typical
NeuroDebian deployment, e.g. enabling the complementary NeuroDebian
repository of package backports and perspective packages not yet
available from stock Debian/Ubuntu.
Package: neurodebian-repository
Architecture: all
Pre-depends: python-minimal, wget
Depends: neurodebian-keyring, ${misc:Depends}
Recommends: netselect
Description: NeuroDebian APT repository installer
Besides making (neuro)scientific software available on stock Debian
systems, neuro.debian.net (and mirrors around the globe) provides
a repository with backport builds of the NeuroDebian-maintained
packages for all supported Debian and Ubuntu releases.
.
This package enables NeuroDebian repository on top of the stock
Debian or Ubuntu system.
......
......@@ -10,7 +10,7 @@ debug()
[ "${DEBCONF_DEBUG:-}" != "developer" ] || echo -e "D: $*" >&2
}
db_settitle neurodebian-repository/title
db_settitle neurodebian/title
if [ "$1" = "configure" ]; then
# Must have been called in preinst state, so no nd-configurerepo
......@@ -33,22 +33,22 @@ while [ "$STATE" != 0 -a "$STATE" != 8 ]; do
1)
export neurodebian_releases="$(ND_IFS=', ' nd-configurerepo --print-releases)"
debug "releases: $neurodebian_releases"
db_subst neurodebian-repository/release releases "$neurodebian_releases"
db_input medium neurodebian-repository/release || true
db_subst neurodebian/release releases "$neurodebian_releases"
db_input medium neurodebian/release || true
;;
2)
export neurodebian_mirrors="$(ND_IFS=', ' nd-configurerepo --print-mirrors)"
debug "mirrors: $neurodebian_mirrors"
db_subst neurodebian-repository/mirror mirrors "$neurodebian_mirrors"
db_input medium neurodebian-repository/mirror || true
db_subst neurodebian/mirror mirrors "$neurodebian_mirrors"
db_input medium neurodebian/mirror || true
mirror_selection_ret="$RET"
debug "mirror select return: <$mirror_selection_ret>"
;;
3) db_input medium neurodebian-repository/flavor || true ;;
4) db_input medium neurodebian-repository/components || true ;;
5) db_input low neurodebian-repository/overwrite || true ;;
6) db_input low neurodebian-repository/suffix || true ;;
7) db_input medium neurodebian-repository/run-update-note || true ;;
3) db_input medium neurodebian/flavor || true ;;
4) db_input medium neurodebian/components || true ;;
5) db_input low neurodebian/overwrite || true ;;
6) db_input low neurodebian/suffix || true ;;
7) db_input medium neurodebian/run-update-note || true ;;
esac
if db_go; then
......@@ -60,7 +60,7 @@ while [ "$STATE" != 0 -a "$STATE" != 8 ]; do
#
# case $STATE in
# 2)
# db_metaget neurodebian-repository/mirror value
# db_metaget neurodebian/mirror value
# selected_mirror="$RET"
# # TODOs:
# # - handle custom
......@@ -71,10 +71,10 @@ while [ "$STATE" != 0 -a "$STATE" != 8 ]; do
# # if the question was not even shown, we would
# # not get a chance to specify mirror, thus
# # better just fail altogether and demand intervention
# db_input high neurodebian-repository/netselect-cannot-be-used
# db_input high neurodebian/netselect-cannot-be-used
# exit 1
# else
# db_input high neurodebian-repository/netselect-not-found
# db_input high neurodebian/netselect-not-found
# continue;
# fi
# fi
......
......@@ -9,13 +9,13 @@ case "$1" in
configure)
# obtain all the options and call nd-configurerepo
opts="--do-not-update"
db_get neurodebian-repository/release; [ "$RET" = "auto" ] || opts+=" -r '$RET'"
db_get neurodebian-repository/mirror; nd_mirror="${RET##* }" # get just a url if it came together with alias
db_get neurodebian-repository/flavor; nd_flavor="$RET"
db_get neurodebian-repository/components; nd_components="${RET// /}"
db_get neurodebian/release; [ "$RET" = "auto" ] || opts+=" -r '$RET'"
db_get neurodebian/mirror; nd_mirror="${RET##* }" # get just a url if it came together with alias
db_get neurodebian/flavor; nd_flavor="$RET"
db_get neurodebian/components; nd_components="${RET// /}"
db_get neurodebian-repository/overwrite; [ "$RET" = "true" ] && opts+=" --overwrite" || :
db_get neurodebian-repository/suffix; [ "$RET" = "" ] || opts+=" --suffix='$RET'" || :
db_get neurodebian/overwrite; [ "$RET" = "true" ] && opts+=" --overwrite" || :
db_get neurodebian/suffix; [ "$RET" = "" ] || opts+=" --suffix='$RET'" || :
eval nd-configurerepo -m "$nd_mirror" -c "$nd_components" $opts
;;
......
Template: neurodebian-repository/title
Template: neurodebian/title
Type: title
Description: NeuroDebian APT repository installer
Template: neurodebian-repository/release
Template: neurodebian/release
Type: select
Choices: auto, ${releases}
Default: auto
......@@ -14,7 +14,7 @@ Description: Release name of the base system
apt-cache policy.
Template: neurodebian-repository/mirror
Template: neurodebian/mirror
Type: select
Choices: origin, best, custom, ${mirrors}
Default: best
......@@ -31,7 +31,7 @@ Description: NeuroDebian mirror to use:
is not available, default mirror (possibly 'origin') will be used.
Template: neurodebian-repository/flavor
Template: neurodebian/flavor
Type: select
Choices: auto, libre, full
Default: auto
......@@ -48,7 +48,7 @@ Description: NeuroDebian flavor to use:
apt-cache policy ('full' -- if non-free (Debian) or multiverse
(Ubuntu) areas are enabled)
Template: neurodebian-repository/components
Template: neurodebian/components
Type: multiselect
Choices: software, data, devel
Default: software, data
......@@ -67,14 +67,14 @@ Description: Select NeuroDebian repository components to enable
required by software packages. Should generally be enabled.
Template: neurodebian-repository/overwrite
Template: neurodebian/overwrite
Type: boolean
Default: true
Description: Should existing NeuroDebian APT file be overridden?
If not allowed, configuration would fail if there is
an existing apt configuration file for the NeuroDebian.
Template: neurodebian-repository/suffix
Template: neurodebian/suffix
Type: string
Default:
Description: Additional suffix to use in the NeuroDebian APT file name
......@@ -82,21 +82,21 @@ Description: Additional suffix to use in the NeuroDebian APT file name
(e.g. NeuroDebian devel) or release, without interfering with the
main/default configuration file.
Template: neurodebian-repository/run-update-note
Template: neurodebian/run-update-note
Type: note
Description: Upon completion of installation invoke update in your APT frontend.
For the installed NeuroDebian APT configuration to take an effect,
list of packages needs to be updated. This needs to be done
"manually" (e.g. apt-get update) upon completion of installation of
the neurodebian-repository package.
the neurodebian package.
Template: neurodebian-repository/netselect-not-found
Template: neurodebian/netselect-not-found
Type: error
Description: netselect tool was not found
Please install netselect tool first (apt-get install netselect) or
choose a specific mirror.
Template: neurodebian-repository/netselect-cannot-be-used
Template: neurodebian/netselect-cannot-be-used
Type: error
Description: netselect tool was not found (no other mirror)
Please install netselect tool first (apt-get install netselect)
......
......@@ -5,13 +5,13 @@ set -ex
apt_file=/etc/apt/sources.list.d/local.list
# clean up from a previous test
dpkg --purge neurodebian-repository neurodebian-keyring || :
echo PURGE | debconf-communicate neurodebian-repository || :
dpkg --purge neurodebian neurodebian-keyring || :
echo PURGE | debconf-communicate neurodebian || :
rm -rf /tmp/apt $apt_file;
mkdir -p /tmp/apt; cd /tmp/apt;
rm -f neurodebian-*deb; apt-get update -y; apt-get install -y wget;
wget http://www.onerussian.com/tmp/neurodebian-repository_0.33~a1_all.deb;
wget http://www.onerussian.com/tmp/neurodebian_0.33~a1_all.deb;
wget http://www.onerussian.com/tmp/neurodebian-keyring_0.33~a1_all.deb;
# generate APT repo
......@@ -19,7 +19,7 @@ apt-get install -y dpkg-dev ; dpkg-scanpackages . /dev/null > Packages
# Add it to the list of available
echo "deb file:///tmp/apt ./" >| $apt_file; apt-get update
# Install the beast
apt-get install -y --allow-unauthenticated neurodebian-repository
apt-get install -y --allow-unauthenticated neurodebian
# Verify that it has correct entries
# Very cruel way to figure out the default release. Would fail if
# options, such as multiarch, are specified after deb
......@@ -28,7 +28,7 @@ grep -E "^deb\s+http.* $release main\s*\$" /etc/apt/sources.list.d/neurodebian.s
grep -E '^deb\s+http.* data main\s*$' /etc/apt/sources.list.d/neurodebian.sources.list
# May be even retrospect stored debconf configuration
apt-get install debconf-utils
debconf-get-selections | grep neurodebian-repository/release.*select.*auto
debconf-get-selections | grep neurodebian/release.*select.*auto
# And apt-get must be working
apt-get update
# Make sure it is active
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment