Files
tools/stx/toCOPY/builder/userenv
Scott Little 8b8ea31dc3 Remove pkgbuilder help text from repomgr commands
Repomgr commands are often forwarded into the
package builder for execution.  They are run under the
user's id, and a help text is displayed as if the
'stx control enter' command had been used.  That help
text is confusing in this context.

The mechanism to run these commands failed to distinguish
'user' from 'interactive'.   This update adds that distinction.

Only an interactive session should display the help text.

Repomgr will use the non-interactive method, avoiding the
unwanted help text.

This update also adds some missing repomgr sub-commands supported
by the repo_manage.py back end, e.g. search_pkg.  It also fixes
arguement passing so that --help functions as expected on sub-commands.

NOTE: While testing, I noticed that two recently added repomgr commands,
'merge' and 'search_pkg', available within the build container, were
reflected in the external wrapper.  I've added them

Testing
stx control enter ... displays help text
stx repomgr list ... shows repo list without help text
stx repomgr search_pkg --help ...
              command is valid and help functions as expected
stx repomgr merge --help
              command is valid and help functions as expected

Story: 2008862
Task: 44683

Signed-off-by: Scott Little <scott.little@windriver.com>
Change-Id: Iad96b3f93ce15c52837ddebed16b9f67899ea27c
2022-03-09 16:14:27 -05:00

53 lines
1.2 KiB
Plaintext

# Common configuration for StarlingX builder
# Find the other rc files
BUILDRC_DIR=$(cd $(dirname "${BASH_SOURCE:-$0}") && pwd)
# Allow local overrides of env variables
if [[ -f $BUILDRC_DIR/localrc ]]; then
source $BUILDRC_DIR/localrc
fi
# Allow local overrides of env variables
if [[ -f $BUILDRC_DIR/buildrc ]]; then
source $BUILDRC_DIR/buildrc
fi
if [ ! -d $MY_REPO_ROOT_DIR ]; then
mkdir -p $MY_REPO_ROOT_DIR > /dev/null 2>&1
fi
if [ ! -d $MY_WORKSPACE ]; then
mkdir -p $MY_WORKSPACE > /dev/null 2>&1
fi
if echo $- | grep -q i ; then
cat <<EOF
To ease checkout do:
!!!! Mandatory:
sudo apt-get update
git config --global user.name <username>
git config --global user.email <email>
If proxy used:
ssh -D 8080 -qTfnN <proxy host>
echo "alias wget='proxychains wget'" >>~/.bashrc
echo "alias repo='proxychains repo'" >>~/.bashrc
source ~/.bashrc
To start a fresh source tree:
cd \$MY_REPO_ROOT_DIR
repo init -u https://opendev.org/starlingx/manifest.git -m default.xml
repo sync
To download the sources & 3rd-party to local mirror:
downloader -b -s
To build all packages:
build-pkgs -a | build-pkgs -p <packageA,packageB...>
To make image:
build-image [ -t std|rt ]
EOF
fi
cd ${MY_WORKSPACE}