Commit d4490a80 authored by Igor Pecovnik's avatar Igor Pecovnik
Browse files

Add support for changing branch when changing nightly / stable

parent 4ed2832e
...@@ -76,6 +76,8 @@ if [[ $1 == "--help" ]]; then ...@@ -76,6 +76,8 @@ if [[ $1 == "--help" ]]; then
echo "Update, upgrade and reboot: ${BASH_SOURCE[0]} main=System selection=Firmware" echo "Update, upgrade and reboot: ${BASH_SOURCE[0]} main=System selection=Firmware"
echo "Change to ZSH: ${BASH_SOURCE[0]} main=System selection=ZSH" echo "Change to ZSH: ${BASH_SOURCE[0]} main=System selection=ZSH"
echo "Change to BASH: ${BASH_SOURCE[0]} main=System selection=BASH" echo "Change to BASH: ${BASH_SOURCE[0]} main=System selection=BASH"
echo "Change to stable repository [branch=dev]: ${BASH_SOURCE[0]} main=System selection=Stable"
echo "Change to nightly repository [branch=dev]: ${BASH_SOURCE[0]} main=System selection=Nightly"
echo "Install headers: ${BASH_SOURCE[0]} main=Software selection=Headers_install" echo "Install headers: ${BASH_SOURCE[0]} main=Software selection=Headers_install"
echo "Remove headers: ${BASH_SOURCE[0]} main=Software selection=Headers_remove" echo "Remove headers: ${BASH_SOURCE[0]} main=Software selection=Headers_remove"
echo "Install kernel source: ${BASH_SOURCE[0]} main=Software selection=Source_install" echo "Install kernel source: ${BASH_SOURCE[0]} main=Software selection=Source_install"
......
...@@ -358,6 +358,9 @@ function generic_select() ...@@ -358,6 +358,9 @@ function generic_select()
# #
function reload_bsp(){ function reload_bsp(){
# switch to defined branch
[[ -n "$1" ]] && BRANCH=$1
clear clear
debconf-apt-progress -- apt-get update debconf-apt-progress -- apt-get update
PACKAGE_LIST="linux-${DISTROID}-root-${BRANCH}-${BOARD} linux-u-boot-${BOARD}-${BRANCH}" PACKAGE_LIST="linux-${DISTROID}-root-${BRANCH}-${BOARD} linux-u-boot-${BOARD}-${BRANCH}"
......
...@@ -1448,7 +1448,7 @@ unset selection ...@@ -1448,7 +1448,7 @@ unset selection
if [[ $? = 0 || -n $scripted ]]; then if [[ $? = 0 || -n $scripted ]]; then
sed -i 's/^deb http:\/\/[^ ]*/deb http:\/\/beta.armbian.com/' /etc/apt/sources.list.d/armbian.list sed -i 's/^deb http:\/\/[^ ]*/deb http:\/\/beta.armbian.com/' /etc/apt/sources.list.d/armbian.list
reload_bsp reload_bsp $branch
fi fi
fi fi
;; ;;
...@@ -1466,7 +1466,7 @@ unset selection ...@@ -1466,7 +1466,7 @@ unset selection
if [[ $? = 0 || -n $scripted ]]; then if [[ $? = 0 || -n $scripted ]]; then
sed -i 's/^deb http:\/\/beta/deb http:\/\/apt/' /etc/apt/sources.list.d/armbian.list sed -i 's/^deb http:\/\/beta/deb http:\/\/apt/' /etc/apt/sources.list.d/armbian.list
reload_bsp reload_bsp $branch
fi fi
fi fi
......
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