fix: fix releaser (#23)
## Description
<!-- **Please link some issue here describing what you are trying to achieve.**
In case there is no issue present for your PR, please consider creating one.
At least please give us some description what you are trying to achieve and why your change is needed. -->
relates to #1234
## Checklist
- [ ] Issue was linked above
- [ ] Code format was applied: `make fmt`
- [ ] Examples were added / adjusted (see `examples/` directory)
- [x] Docs are up-to-date: `make generate-docs` (will be checked by CI)
- [ ] Unit tests got implemented or updated
- [ ] Acceptance tests got implemented or updated (see e.g. [here](f5f99d1709/stackit/internal/services/dns/dns_acc_test.go))
- [x] Unit tests are passing: `make test` (will be checked by CI)
- [x] No linter issues: `make lint` (will be checked by CI)
Reviewed-on: #23
This commit is contained in:
parent
024534da5f
commit
760bcfd658
2 changed files with 21 additions and 16 deletions
|
|
@ -22,6 +22,10 @@ type Architecture struct {
|
|||
}
|
||||
|
||||
type SigningKey struct {
|
||||
GpgPublicKeys []GpgPublicKey `json:"gpg_public_keys"`
|
||||
}
|
||||
|
||||
type GpgPublicKey struct {
|
||||
KeyId string `json:"key_id"`
|
||||
AsciiArmor string `json:"ascii_armor"`
|
||||
TrustSignature string `json:"trust_signature"`
|
||||
|
|
@ -85,17 +89,23 @@ func (p *Provider) CreateArchitectureFiles() error {
|
|||
ShaSumsUrl: shasumsUrl,
|
||||
ShaSumsSignatureUrl: shasumsSigUrl,
|
||||
ShaSum: sum.Sum,
|
||||
SigningKeys: []SigningKey{
|
||||
{
|
||||
KeyId: p.GpgFingerprint,
|
||||
AsciiArmor: gpgAsciiPub,
|
||||
TrustSignature: "",
|
||||
Source: "",
|
||||
SourceUrl: "",
|
||||
},
|
||||
},
|
||||
SigningKeys: []SigningKey{},
|
||||
}
|
||||
|
||||
a.SigningKeys = append(
|
||||
a.SigningKeys,
|
||||
SigningKey{
|
||||
GpgPublicKeys: []GpgPublicKey{
|
||||
{
|
||||
KeyId: p.GpgFingerprint,
|
||||
AsciiArmor: gpgAsciiPub,
|
||||
TrustSignature: "",
|
||||
Source: "",
|
||||
SourceUrl: "",
|
||||
},
|
||||
},
|
||||
},
|
||||
)
|
||||
// var architectureTemplate = []byte(fmt.Sprintf(`
|
||||
//{
|
||||
// "protocols": [
|
||||
|
|
|
|||
|
|
@ -26,12 +26,6 @@ type Data struct {
|
|||
}
|
||||
|
||||
func (d *Data) WriteToFile(filePath string) error {
|
||||
//file, err := os.OpenFile(filePath, os.O_CREATE, os.ModePerm)
|
||||
//if err != nil {
|
||||
// return fmt.Errorf("error creating file: %w", err)
|
||||
//}
|
||||
//defer file.Close()
|
||||
//
|
||||
jsonString, err := json.Marshal(d)
|
||||
if err != nil {
|
||||
return fmt.Errorf("error encoding data: %w", err)
|
||||
|
|
@ -51,7 +45,8 @@ func (d *Data) AddVersion(v Version) error {
|
|||
newVersions = append(newVersions, ver)
|
||||
}
|
||||
}
|
||||
d.Versions = append(d.Versions, v)
|
||||
newVersions = append(newVersions, v)
|
||||
d.Versions = newVersions
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue