Skip to content

Commit cecc770

Browse files
committed
chore: update release configuration
1 parent 4c3cca0 commit cecc770

File tree

3 files changed

+71
-32
lines changed

3 files changed

+71
-32
lines changed

.execs/release.flow

Lines changed: 58 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,69 @@ tags: [development, test]
33
executables:
44
- verb: create
55
name: snapshot
6-
description: Create a snapshot release
6+
description: Create a snapshot release locally (skips Docker builds by default)
77
aliases: [release, snap]
88
exec:
99
dir: //
10+
params:
11+
- envKey: SKIP_DOCKER
12+
text: "true"
1013
cmd: |
1114
if ! command -v goreleaser &> /dev/null; then
1215
echo "goreleaser is not installed. Please install it first."
1316
exit 1
1417
fi
15-
16-
echo "creating snapshot release..."
17-
goreleaser release --snapshot --clean
18+
19+
SKIP_FLAG=""
20+
if [ "$SKIP_DOCKER" = "true" ]; then
21+
echo "Creating snapshot release (skipping Docker builds)..."
22+
SKIP_FLAG="--skip=docker"
23+
else
24+
echo "Creating snapshot release (including Docker builds)..."
25+
fi
26+
27+
goreleaser release --snapshot --clean $SKIP_FLAG
28+
29+
echo ""
30+
echo "Snapshot build complete!"
31+
echo ""
32+
echo "Binaries built for:"
33+
ls -1 dist/ | grep -E "^flow_.*_(linux|darwin)_(amd64|arm64)" | sed 's/^/ - /'
34+
35+
if [ "$SKIP_DOCKER" = "false" ]; then
36+
echo ""
37+
echo "Docker images built:"
38+
echo " - ghcr.io/flowexec/flow:{{ .Tag }}"
39+
echo " - ghcr.io/flowexec/flow:latest"
40+
echo ""
41+
echo "Test Docker image locally:"
42+
echo " docker run --rm ghcr.io/flowexec/flow:latest --version"
43+
fi
44+
45+
echo ""
46+
echo "Test your platform's binary:"
47+
CURRENT_OS=$(uname -s | tr '[:upper:]' '[:lower:]')
48+
CURRENT_ARCH=$(uname -m)
49+
if [ "$CURRENT_ARCH" = "x86_64" ]; then CURRENT_ARCH="amd64"; fi
50+
if [ "$CURRENT_ARCH" = "aarch64" ]; then CURRENT_ARCH="arm64"; fi
51+
52+
BINARY_DIR=$(ls -d dist/flow_${CURRENT_OS}_${CURRENT_ARCH}* 2>/dev/null | head -1)
53+
if [ -n "$BINARY_DIR" ]; then
54+
echo " ${BINARY_DIR}/flow --version"
55+
echo ""
56+
${BINARY_DIR}/flow --version
57+
fi
58+
59+
- verb: check
60+
name: release
61+
description: Check goreleaser configuration without building
62+
exec:
63+
dir: //
64+
cmd: |
65+
if ! command -v goreleaser &> /dev/null; then
66+
echo "goreleaser is not installed. Please install it first."
67+
exit 1
68+
fi
69+
70+
echo "Checking goreleaser configuration..."
71+
goreleaser check

.goreleaser.yaml

Lines changed: 12 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,6 @@ archives:
4343
homebrew_casks:
4444
- name: flow
4545
binary: flow
46-
conflicts:
47-
- formula: flow
4846
homepage: https://flowexec.io
4947
license: Apache-2.0
5048
repository:
@@ -63,32 +61,19 @@ homebrew_casks:
6361
if system_command("/usr/bin/xattr", args: ["-h"]).exit_status == 0
6462
system_command "/usr/bin/xattr", args: ["-dr", "com.apple.quarantine", "#{staged_path}/flow"]
6563
end
66-
67-
dockers:
68-
- image_templates:
69-
- "ghcr.io/flowexec/flow:{{ .Tag }}-amd64"
70-
use: buildx
71-
build_flag_templates:
72-
- "--pull"
73-
- "--platform=linux/amd64"
74-
goarch: amd64
75-
- image_templates:
76-
- "ghcr.io/flowexec/flow:{{ .Tag }}-arm64"
77-
use: buildx
78-
build_flag_templates:
79-
- "--pull"
80-
- "--platform=linux/arm64"
81-
goarch: arm64
8264
83-
docker_manifests:
84-
- name_template: "ghcr.io/flowexec/flow:{{ .Tag }}"
85-
image_templates:
86-
- "ghcr.io/flowexec/flow:{{ .Tag }}-amd64"
87-
- "ghcr.io/flowexec/flow:{{ .Tag }}-arm64"
88-
- name_template: "ghcr.io/flowexec/flow:latest"
89-
image_templates:
90-
- "ghcr.io/flowexec/flow:{{ .Tag }}-amd64"
91-
- "ghcr.io/flowexec/flow:{{ .Tag }}-arm64"
65+
dockers_v2:
66+
- id: flow
67+
images:
68+
- "ghcr.io/flowexec/flow"
69+
tags:
70+
- "{{ .Tag }}"
71+
- latest
72+
platforms:
73+
- linux/amd64
74+
- linux/arm64
75+
flags:
76+
- "--pull"
9277

9378
changelog:
9479
sort: asc

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.25.1-bookworm
1+
FROM --platform=$TARGETPLATFORM golang:1.25.1-bookworm
22

33
ENV DISABLE_FLOW_INTERACTIVE="true"
44

0 commit comments

Comments
 (0)