#!/bin/bash
# Usage: ciel-switchmirror <mirror name in apt-gen-list>

export CIEL_INST="ciel--switchmirror--"

ciel add "$CIEL_INST"
echo -e "\e[1m\e[96m[switch-mirror]:\e[0m\e[1m Mirror set to '$1'\e[0m"
ciel shell "apt-gen-list set-mirror $1"
ciel factory-reset
ciel commit
ciel del "$CIEL_INST"
