File: init-dev.sh

package info (click to toggle)
debci 3.13
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,656 kB
  • sloc: ruby: 6,516; sh: 2,437; javascript: 100; makefile: 92; perl: 11
file content (35 lines) | stat: -rwxr-xr-x 844 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/sh

set -eu

configdir=`./bin/debci config --values-only config_dir`

SEED_LIST='autodep8
pinpoint
python-whitenoise
ruby-defaults
rubygems-integration
vim-addon-manager'

if [ -e $configdir/whitelist ]; then
  mv "${configdir}/whitelist" "${configdir}/seed_list"
fi

if [ ! -f $configdir/seed_list ]; then
  echo "$SEED_LIST" > "${configdir}/seed_list"
  tail -n 1000 config/seed_list config/conf.d/*.conf || :
  echo
fi

if [ ! -f $configdir/conf.d/dev.conf ]; then
  echo "debci_arch_list='amd64 arm64'" > $configdir/conf.d/dev.conf
  echo "debci_suite_list='unstable testing'" >> $configdir/conf.d/dev.conf
  echo "debci_backend=fake" >> $configdir/conf.d/dev.conf
fi

if [ ! -f $configdir/conf.d/secret.conf ]; then
  echo "debci_session_secret=$(openssl rand -hex 32)" \
    > $configdir/conf.d/secret.conf
fi

./bin/debci migrate