Skip to content

Commit

Permalink
due to cgo goreleaser cannot build mutliplatform
Browse files Browse the repository at this point in the history
  • Loading branch information
eltorio committed Mar 24, 2024
1 parent fcaaf84 commit 4b66f01
Show file tree
Hide file tree
Showing 7 changed files with 158 additions and 12 deletions.
9 changes: 0 additions & 9 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,10 @@ builds:
- -v
goos:
- linux
- windows
- darwin
goarch:
- amd64
- arm64
- '386'
ignore:
- goos: darwin
goarch: '386'
- goos: darwin
goarch: 'arm64'
- goos: windows
goarch: 'arm64'
checksum:
name_template: 'checksums.txt'
archives:
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ require (
go.uber.org/atomic v1.9.0 // indirect
go.uber.org/multierr v1.9.0 // indirect
golang.org/x/crypto v0.21.0 // indirect
golang.org/x/exp v0.0.0-20230905200255-921286631fa9 // indirect
golang.org/x/exp v0.0.0-20231108232855-2478ac86f678 // indirect
golang.org/x/net v0.22.0 // indirect
golang.org/x/sys v0.18.0 // indirect
golang.org/x/text v0.14.0 // indirect
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,8 @@ go.uber.org/multierr v1.9.0 h1:7fIwc/ZtS0q++VgcfqFDxSBZVv/Xo49/SYnDFupUwlI=
go.uber.org/multierr v1.9.0/go.mod h1:X2jQV1h+kxSjClGpnseKVIxpmcjrj7MNnI0bnlfKTVQ=
golang.org/x/crypto v0.21.0 h1:X31++rzVUdKhX5sWmSOFZxx8UW/ldWx55cbf08iNAMA=
golang.org/x/crypto v0.21.0/go.mod h1:0BP7YvVV9gBbVKyeTG0Gyn+gZm94bibOW5BjDEYAOMs=
golang.org/x/exp v0.0.0-20230905200255-921286631fa9 h1:GoHiUyI/Tp2nVkLI2mCxVkOjsbSXD66ic0XW0js0R9g=
golang.org/x/exp v0.0.0-20230905200255-921286631fa9/go.mod h1:S2oDrQGGwySpoQPVqRShND87VCbxmc6bL1Yd2oYrm6k=
golang.org/x/exp v0.0.0-20231108232855-2478ac86f678 h1:mchzmB1XO2pMaKFRqk/+MV3mgGG96aqaPXaMifQU47w=
golang.org/x/exp v0.0.0-20231108232855-2478ac86f678/go.mod h1:zk2irFbV9DP96SEBUUAy67IdHUaZuSnrz1n472HUCLE=
golang.org/x/net v0.22.0 h1:9sGLhx7iRIHEiX0oAJ3MRZMUCElJgy7Br1nO+AMN3Tc=
golang.org/x/net v0.22.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg=
golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4=
Expand Down
78 changes: 78 additions & 0 deletions static/client.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<!DOCTYPE html>
<!--
Copyright (c) 2024, Ronan Le Meillat
All rights reserved.
-->
<html lang="en">

<head>
<meta charset="utf-8">
<title>Client download</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
body {
background-color: black;
display: flex;
align-items: center;
justify-content: center;
height: 100vh;
margin: 0;
padding: 0;
}

.logo-container {
display: flex;
flex-direction: column;
align-items: center;
}

.logo-main {
width: 90%;
max-width: 140px;
}

.logo-sub {
width: 60%;
max-width: 84px;
/* 60% de 140px */
padding: 10px;
}

@media (min-width: 600px) {
.logo-main {
width: 140px;
}

.logo-sub {
width: 84px;
}
}
</style>
</head>

<body>
<div class="logo-container">
<img class="logo-main" src="images/logo.svg" alt="Logo principal">
<div>
<a id="windows64"><img class="logo-sub" src="images/windows.svg" alt="Logo Windows"></a>
<a id="osx"><img class="logo-sub" src="images/apple.svg" alt="Logo Apple"></a>
</div>
</div>
</body>
<script>
window.onload = function () {
fetch('/api/software/client-download-link/w64')
.then(response => response.json())
.then(data => {
document.getElementById('windows64').href = data.url;
});

fetch('/api/software/client-download-link/osx')
.then(response => response.json())
.then(data => {
document.getElementById('osx').href = data.url;
});
};
</script>

</html>
7 changes: 7 additions & 0 deletions static/images/apple.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
63 changes: 63 additions & 0 deletions static/images/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions static/images/windows.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 4b66f01

Please sign in to comment.