diff options
author | V3n3RiX <venerix@rogentos.ro> | 2016-11-12 16:45:51 +0000 |
---|---|---|
committer | V3n3RiX <venerix@rogentos.ro> | 2016-11-12 16:45:51 +0000 |
commit | e924068dcd9361ddec1652538dfcf46e4b4be3f5 (patch) | |
tree | ffeac8e8bfd9e3f23a3022c31a2d553546a315aa | |
parent | c6c36876cc9b37f6e6ee137cbbaeb8cb5c21423d (diff) |
add full gentoo mode
-rwxr-xr-x | binmode (renamed from usermodeset) | 2 | ||||
-rwxr-xr-x | mixedmode | 30 | ||||
-rwxr-xr-x | resetmode (renamed from modereset) | 0 | ||||
-rwxr-xr-x | srcmode (renamed from devmodeset) | 2 | ||||
-rwxr-xr-x | vasile | 25 |
5 files changed, 47 insertions, 12 deletions
@@ -21,7 +21,7 @@ fetch_usermode_portage_tree() { set_usermode_portage_tree() { ln -sf "$gitdir" "$confdir" - ln -sf "$confdir"/make.conf.amd64-user "$confdir"/make.conf + ln -sf "$confdir"/make.conf.amd64-binmode "$confdir"/make.conf eselect profile set 1 env-update . /etc/profile diff --git a/mixedmode b/mixedmode new file mode 100755 index 0000000..fab1bc2 --- /dev/null +++ b/mixedmode @@ -0,0 +1,30 @@ +#!/usr/bin/env bash + +export local portagedir="/usr/portage" +export local confdir="/etc/portage" +export local gitdir="/opt/redcore-build/conf/intel/portage" + +fetch_devmode_portage_tree() { + if [[ ! -d "$portagedir"/.git ]] ; then + cd "$portagedir" && git init > /dev/null 2>&1 + git remote add origin https://gitlab.com/redcore/portage.git + git pull --depth=1 origin master + git branch -u origin/master master + rm -rf ""$portagedir"/profiles/updates" + fi +} + +set_devmode_portage_tree() { + ln -sf "$gitdir" "$confdir" + ln -sf "$confdir"/make.conf.amd64-mixedmode "$confdir"/make.conf + eselect profile set 1 + env-update + . /etc/profile +} + +main() { + fetch_devmode_portage_tree + set_devmode_portage_tree +} + +main @@ -16,7 +16,7 @@ fetch_devmode_portage_tree() { set_devmode_portage_tree() { ln -sf "$gitdir" "$confdir" - ln -sf "$confdir"/make.conf.amd64-devel "$confdir"/make.conf + ln -sf "$confdir"/make.conf.amd64-srcmode "$confdir"/make.conf eselect profile set 1 env-update . /etc/profile @@ -24,15 +24,19 @@ case $1 in source /usr/share/vasile/makeiso ;; --resetmode) - source /usr/share/vasile/modereset + source /usr/share/vasile/resetmode ;; - --usermode) - source /usr/share/vasile/modereset - source /usr/share/vasile/usermodeset + --binmode) + source /usr/share/vasile/resetmode + source /usr/share/vasile/binmode ;; - --devmode) - source /usr/share/vasile/modereset - source /usr/share/vasile/devmodeset + --mixedmode) + source /usr/share/vasile/resetmode + source /usr/share/vasile/mixedmode + ;; + --srcmode) + source /usr/share/vasile/resetmode + source /usr/share/vasile/srcmode ;; --help) einfo "Usage: vasile [options]" @@ -40,9 +44,10 @@ case $1 in einfo "Options:" einfo "--makepkg : build package/target in a clean squashed core" einfo "--makeiso : build iso based on clean squashed core + targets" - einfo "--resetmode : reset INSTALLED Redcore Linux system state - You're on your own, you've been warned!" - einfo "--usermode : switch INSTALLED Redcore Linux system state to usermode - use binary packages from repositories" - einfo "--devmode : switch INSTALLED Redcore Linux system state to devmode (aka Gentoo mode) - use source packages from portage tree" + einfo "--resetmode : reset Redcore Linux system state - You're on your own, you've been warned!" + einfo "--binmode : switch Redcore Linux system state to binary only mode" + einfo "--mixedmode : switch Redcore Linux system state to mixed (binary/source) mode" + einfo "--srcmode : switch Redcore Linux system state to source only mode (full Gentoo mode)" einfo "--help : display this help and exit" ;; *) |