Commit df974a0f authored by Vitaly Lipatov's avatar Vitaly Lipatov

repack.d/common.sh: add pack_dir command

parent a335a3f3
......@@ -32,6 +32,16 @@ pack_file()
subst "s|%files|%files\n$file|" $SPEC
}
# Usage: pack_dir <path_to_dir>
pack_dir()
{
local file="$1"
[ -n "$file" ] || return
grep -q "^%dir[[:space:]]$file$" $SPEC && return
grep -q "^%dir[[:space:]]\"$file\"$" $SPEC && return
subst "s|%files|%files\n%dir $file|" $SPEC
}
add_bin_link_command()
{
......
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