Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
alpine-conf
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
17
Issues
17
List
Boards
Labels
Service Desk
Milestones
Merge Requests
6
Merge Requests
6
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
alpine
alpine-conf
Commits
22fd8180
Commit
22fd8180
authored
Oct 18, 2007
by
Natanael Copa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
simplify use of password
parent
b2f97315
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
16 deletions
+21
-16
lbu
lbu
+11
-16
libalpine.sh
libalpine.sh
+10
-0
No files found.
lbu
View file @
22fd8180
...
...
@@ -62,7 +62,6 @@ check_openssl() {
$
OPENSSL
list
-
cipher
-
commands
|
grep
"^$ENCRYPTION$"
>
/
dev
/
null
\
||
die
"Cipher $ENCRYPTION is not supported"
vecho
"OPENSSL installed, cipher can be used"
}
gen_current_tdb
()
{
...
...
@@ -194,7 +193,7 @@ cmd_package() {
tmppkg
=
"$tmpdir/$(basename $pkg)"
#
generate
the
packages
.
list
vecho
"Generating
package.list
"
vecho
"Generating
$PACKAGES_LIST
"
cd
"$ROOT"
mkdir
-
p
$(
dirname
$
PACKAGES_LIST
)
echo
"#This file is generated by 'lbu package' (lbu $VERSION)"
\
...
...
@@ -213,7 +212,6 @@ cmd_package() {
$
SFIC
--
add
"$CURRENT_TDB"
$
currentlist
#
create
tar
archive
vecho
"Creating tar archive"
[
-
f
"$EXCLUDE_LIST"
]
&&
excl
=
"-X $EXCLUDE_LIST"
[
-
f
"$INCLUDE_LIST"
]
&&
incl
=
"-T $INCLUDE_LIST"
if
[
-
n
"$VERBOSE"
];
then
...
...
@@ -228,22 +226,18 @@ cmd_package() {
tar
$
excl
$
incl
-
c
$
currentlist
|
gzip
-
c
>
"$tmppkg"
rc
=$?
else
if
[
-
n
"$PASSWORD"
];
then
tar
$
excl
$
incl
-
c
$
currentlist
|
gzip
-
c
\
|
$
OPENSSL
enc
"-$ENCRYPTION"
-
salt
-
pass
pass
:
"$PASSWORD"
>
"$tmppkg"
rc
=$?
else
tar
$
excl
$
incl
-
c
$
currentlist
|
gzip
-
c
\
|
$
OPENSSL
enc
"-$ENCRYPTION"
-
salt
>
"$tmppkg"
rc
=$?
fi
set
--
enc
"-$ENCRYPTION"
-
salt
[
-
n
"$PASSWORD"
]
&&
set
--
"$@"
-
pass
pass
:
"$PASSWORD"
tar
$
excl
$
incl
-
c
$
currentlist
|
gzip
-
c
\
|
$
OPENSSL
"$@"
>
"$tmppkg"
rc
=$?
fi
fi
#
actually
commit
unless
dryrun
mode
if
[
$
rc
-
eq
0
];
then
[
-
z
"$DRYRUN"
]
&&
cp
"$tmppkg"
"$pkg"
vecho
"C
opied apk overlay to destination
$pkg"
vecho
"C
reated
$pkg"
else
rm
-
f
"$CURRENT_TDB"
fi
...
...
@@ -347,8 +341,10 @@ cmd_commit() {
if
[
-
n
"$lines"
]
&&
[
"$lines"
!= "$outfile" ]; then
#
More
then
one
apkovl
,
this
is
a
security
concern
[
-
z
"$was_mounted"
]
&&
umount
"$mnt"
vecho
"$lines"
die
"Found multiple apkovl files. Please use -d to replace them all."
eecho
"The following apkovl file(s) were found:"
eecho
"$lines"
eecho
""
die
"Please use -d to replace."
fi
fi
...
...
@@ -374,7 +370,6 @@ cmd_commit() {
#
move
current
to
commited
.
[
"$DRYRUN"
]
||
mv
"$CURRENT_TDB"
"$COMMITED_TDB"
vecho
"Successfully saved apk overlay files"
}
#---------------------------------------------------------------------------
...
...
libalpine.sh
View file @
22fd8180
...
...
@@ -26,6 +26,16 @@ vecho() {
[
-n
"
$VERBOSE
"
]
&&
echo
"
$@
"
}
# echo unless quiet mode
qecho
()
{
[
-z
"
$QUIET
"
]
&&
echo
"
$@
"
}
# echo to stderr
eecho
()
{
echo
"
$@
"
>
&2
}
init_tmpdir
()
{
local
omask
=
`
umask
`
local
__tmpd
=
"/tmp/
$PROGRAM
-
${
$}
-
`
date
+%s
`
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment