Merge branch 'pkg-comments' into dev
This commit is contained in:
commit
b8f19029cd
|
@ -71,5 +71,8 @@ maintenance and allows for more easy customization.
|
|||
enhancements, etc. This is a base desktop system, with some development
|
||||
tools installed.
|
||||
|
||||
- Stage 4, complete Raspbian system. More development tools, large packages
|
||||
like LibreOffice, email, sonic-pi, wolfram-engine, etc. All the things.
|
||||
- Stage 4, complete Raspbian system. More development tools, an email
|
||||
client, learning tools like Scratch, specialized packages like sonic-pi and
|
||||
wolfram-engine, system documentation, office productivity, etc. This is
|
||||
the stage that installs all of the things that make Raspbian friendly to
|
||||
new users.
|
||||
|
|
6
build.sh
6
build.sh
|
@ -16,7 +16,8 @@ EOF
|
|||
fi
|
||||
if [ -f ${i}-packages-nr ]; then
|
||||
log "Begin ${SUB_STAGE_DIR}/${i}-packages-nr"
|
||||
PACKAGES=`cat $i-packages-nr | tr '\n' ' '`
|
||||
PACKAGES="$(sed -f "${SCRIPT_DIR}/remove-comments.sed" < ${i}-packages-nr)"
|
||||
PACKAGES="$(sed -e "$sed_expr_packages" < ${i}-packages-nr)"
|
||||
if [ -n "$PACKAGES" ]; then
|
||||
on_chroot sh -e - << EOF
|
||||
apt-get install --no-install-recommends -y $PACKAGES
|
||||
|
@ -26,7 +27,7 @@ EOF
|
|||
fi
|
||||
if [ -f ${i}-packages ]; then
|
||||
log "Begin ${SUB_STAGE_DIR}/${i}-packages"
|
||||
PACKAGES=`cat $i-packages | tr '\n' ' '`
|
||||
PACKAGES="$(sed -f "${SCRIPT_DIR}/remove-comments.sed" < ${i}-packages)"
|
||||
if [ -n "$PACKAGES" ]; then
|
||||
on_chroot sh -e - << EOF
|
||||
apt-get install -y $PACKAGES
|
||||
|
@ -77,6 +78,7 @@ EOF
|
|||
log "End ${SUB_STAGE_DIR}"
|
||||
}
|
||||
|
||||
|
||||
run_stage(){
|
||||
log "Begin ${STAGE_DIR}"
|
||||
STAGE=$(basename ${STAGE_DIR})
|
||||
|
|
11
scripts/remove-comments.sed
Normal file
11
scripts/remove-comments.sed
Normal file
|
@ -0,0 +1,11 @@
|
|||
# Deletes comments and collapses whitespace in ##-packages files
|
||||
|
||||
# Append (N)ext line to buffer
|
||||
# if (!)not ($)buffer is EOF, (b)ranch to (:)label loop
|
||||
:loop
|
||||
N
|
||||
$ !b loop
|
||||
|
||||
# Buffer is "line1\nline2\n...lineN", del comments and collapse whitespace
|
||||
s/#[^\n]*//g
|
||||
s/[[:space:]]\{1,\}/ /g
|
Loading…
Reference in New Issue
Block a user