File tree 2 files changed +10
-17
lines changed
2 files changed +10
-17
lines changed Original file line number Diff line number Diff line change @@ -50,8 +50,6 @@ function download_and_verify {
50
50
done
51
51
}
52
52
53
- # Preconditions:
54
- # - $VERSION_METADATA_SECRET must be set to an ed25519 secret
55
53
function publish_metadata {
56
54
local platforms
57
55
platforms=(windows macos linux)
@@ -66,12 +64,16 @@ function publish_metadata {
66
64
cp -r signed/ currently_published/
67
65
echo " "
68
66
67
+ echo " >>> Replacing work/ directory with latest published data"
68
+ cp -rf signed/ work/
69
+ echo " "
70
+
69
71
echo " >>> Adding new release $$ PRODUCT_VERSION (rollout = 1)"
70
72
meta add-release " $PRODUCT_VERSION " " ${platforms[@]} "
71
73
echo " "
72
74
73
75
echo " >>> Signing $PRODUCT_VERSION metadata"
74
- meta sign --secret " $VERSION_METADATA_SECRET " " ${platforms[@]} "
76
+ meta sign " ${platforms[@]} "
75
77
echo " "
76
78
77
79
echo " >>> Verifying signed metadata"
Original file line number Diff line number Diff line change @@ -93,13 +93,10 @@ pub enum Opt {
93
93
} ,
94
94
95
95
/// Sign using an ed25519 key and output the signed metadata to `signed/`
96
+ /// A secret ed25519 key will be read from stdin
96
97
Sign {
97
98
/// Platforms to remove releases for. All if none are specified
98
99
platforms : Vec < Platform > ,
99
- /// Secret ed25519 key used for signing, as hexadecimal string
100
- /// If not specified, this will be read from stdin
101
- #[ arg( long) ]
102
- secret : Option < key:: SecretKey > ,
103
100
/// When the metadata expires, in months from now
104
101
#[ arg( long, default_value_t = DEFAULT_EXPIRY_MONTHS ) ]
105
102
expiry : usize ,
@@ -149,19 +146,13 @@ async fn main() -> anyhow::Result<()> {
149
146
}
150
147
Opt :: Sign {
151
148
platforms,
152
- secret,
153
149
expiry,
154
150
assume_yes,
155
151
} => {
156
- let secret = match secret {
157
- Some ( secret) => secret,
158
- None => {
159
- let key_str = io_util:: wait_for_input ( "Enter ed25519 secret: " )
160
- . await
161
- . context ( "Failed to read secret from stdin" ) ?;
162
- key:: SecretKey :: from_str ( & key_str) . context ( "Invalid secret" ) ?
163
- }
164
- } ;
152
+ let key_str = io_util:: wait_for_input ( "Enter ed25519 secret: " )
153
+ . await
154
+ . context ( "Failed to read secret from stdin" ) ?;
155
+ let secret = key:: SecretKey :: from_str ( & key_str) . context ( "Invalid secret" ) ?;
165
156
166
157
for platform in all_platforms_if_empty ( platforms) {
167
158
platform
You can’t perform that action at this time.
0 commit comments