Add extension namespace in manifest files, 'extn' lines are preserved
This commit is contained in:
parent
c355faebe8
commit
6c203aaa77
2 changed files with 11 additions and 1 deletions
|
@ -102,6 +102,12 @@ Repository Format
|
||||||
R7awFCUJWYdzXzrlkk7E2Acxq/Y4EfEcd62AwGGe0o0QxL+s5CwWI/NvMhb
|
R7awFCUJWYdzXzrlkk7E2Acxq/Y4EfEcd62AwGGe0o0QxL+s5CwWI/NvMhb
|
||||||
repo :SHA224:5a191cea8c1021a95d813c4007c14f2cc987a40880c2f669430f1916 1
|
repo :SHA224:5a191cea8c1021a95d813c4007c14f2cc987a40880c2f669430f1916 1
|
||||||
|
|
||||||
|
+ Manifest fields:
|
||||||
|
|
||||||
|
+ `<fieldname><space><value>`, extends until newline.
|
||||||
|
+ `{0-9a-f}[40]`, `pack`, `repo`, `keep` (planned), `extn` (extension
|
||||||
|
fields, preserved but unused).
|
||||||
|
|
||||||
|
|
||||||
Pieces yet to be Implemented
|
Pieces yet to be Implemented
|
||||||
----------------------------
|
----------------------------
|
||||||
|
|
|
@ -19,6 +19,7 @@ Hashpfx=":SHA224:"
|
||||||
UrlTag="G."
|
UrlTag="G."
|
||||||
Packpfx="pack $Hashpfx"
|
Packpfx="pack $Hashpfx"
|
||||||
Packkey_bytes=33
|
Packkey_bytes=33
|
||||||
|
Extension_list=
|
||||||
|
|
||||||
# compat/utility functions
|
# compat/utility functions
|
||||||
xecho()
|
xecho()
|
||||||
|
@ -285,6 +286,7 @@ make_new_repo()
|
||||||
fix_config=1
|
fix_config=1
|
||||||
}
|
}
|
||||||
echo_info "Repository URL is" "gcrypt::$URL/$UrlTag$urlid_"
|
echo_info "Repository URL is" "gcrypt::$URL/$UrlTag$urlid_"
|
||||||
|
Extension_list=$(xecho "extn comment")
|
||||||
isnull "$fix_config" || echo_info "(configuration for $NAME updated)"
|
isnull "$fix_config" || echo_info "(configuration for $NAME updated)"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -335,6 +337,7 @@ ensure_connected()
|
||||||
|
|
||||||
Branchlist=$(xecho "$manifest_" | xgrep -E '^[0-9a-f]{40} ')
|
Branchlist=$(xecho "$manifest_" | xgrep -E '^[0-9a-f]{40} ')
|
||||||
Packlist=$(xecho "$manifest_" | xgrep "^$Packpfx")
|
Packlist=$(xecho "$manifest_" | xgrep "^$Packpfx")
|
||||||
|
Extension_list=$(xecho "$manifest_" | xgrep "^extn ")
|
||||||
rcv_repoid=$(xecho "$manifest_" | xgrep "^repo ")
|
rcv_repoid=$(xecho "$manifest_" | xgrep "^repo ")
|
||||||
iseq "$(repoidstr)" "$rcv_repoid" || echo_die "Repository id mismatch!"
|
iseq "$(repoidstr)" "$rcv_repoid" || echo_die "Repository id mismatch!"
|
||||||
}
|
}
|
||||||
|
@ -484,7 +487,8 @@ EOF
|
||||||
TmpManifest_Enc="$Localdir/manifest.$$"
|
TmpManifest_Enc="$Localdir/manifest.$$"
|
||||||
trap 'rm -f "$TmpManifest_Enc"' EXIT
|
trap 'rm -f "$TmpManifest_Enc"' EXIT
|
||||||
|
|
||||||
(xecho "$Branchlist"; xecho "$Packlist"; repoidstr) |
|
(xecho "$Branchlist"; xecho "$Packlist";
|
||||||
|
repoidstr; xecho "$Extension_list") |
|
||||||
PRIVENCRYPT "$Recipients" > "$TmpManifest_Enc"
|
PRIVENCRYPT "$Recipients" > "$TmpManifest_Enc"
|
||||||
|
|
||||||
PUT "$URL" "$Repoid" < "$TmpManifest_Enc"
|
PUT "$URL" "$Repoid" < "$TmpManifest_Enc"
|
||||||
|
|
Loading…
Reference in a new issue