Skip to content

Commit 29d19f5

Browse files
committed
Fix YAML heredoc indentation in release workflow
1 parent 593d719 commit 29d19f5

1 file changed

Lines changed: 33 additions & 26 deletions

File tree

.github/workflows/release.yml

Lines changed: 33 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -84,32 +84,39 @@ jobs:
8484
git clone https://x-access-token:${HOMEBREW_TAP_TOKEN}@github.com/fenio/homebrew-tap.git
8585
cd homebrew-tap
8686
87-
cat > Casks/anylinuxfs-gui.rb << CASKEOF
88-
cask "anylinuxfs-gui" do
89-
version "${VERSION}"
90-
sha256 "${SHA256}"
91-
92-
url "https://github.com/fenio/anylinuxfs-gui/releases/download/v#{version}/anylinuxfs-gui_#{version}_aarch64.dmg"
93-
name "anylinuxfs GUI"
94-
desc "macOS GUI for anylinuxfs - mount Linux filesystems on macOS"
95-
homepage "https://github.com/fenio/anylinuxfs-gui"
96-
97-
depends_on formula: "nohajc/anylinuxfs/anylinuxfs"
98-
depends_on arch: :arm64
99-
100-
app "anylinuxfs-gui.app"
101-
102-
postflight do
103-
system_command "/usr/bin/xattr",
104-
args: ["-cr", "#{appdir}/anylinuxfs-gui.app"]
105-
end
106-
107-
zap trash: [
108-
"~/Library/Caches/com.anylinuxfs.gui",
109-
"~/Library/Preferences/com.anylinuxfs.gui.plist",
110-
]
111-
end
112-
CASKEOF
87+
cat > Casks/anylinuxfs-gui.rb << 'CASKEOF'
88+
cask "anylinuxfs-gui" do
89+
version "VERSION_PLACEHOLDER"
90+
sha256 "SHA256_PLACEHOLDER"
91+
92+
url "https://github.com/fenio/anylinuxfs-gui/releases/download/v#{version}/anylinuxfs-gui_#{version}_aarch64.dmg"
93+
name "anylinuxfs GUI"
94+
desc "macOS GUI for anylinuxfs - mount Linux filesystems on macOS"
95+
homepage "https://github.com/fenio/anylinuxfs-gui"
96+
97+
depends_on formula: "nohajc/anylinuxfs/anylinuxfs"
98+
depends_on arch: :arm64
99+
100+
app "anylinuxfs-gui.app"
101+
102+
postflight do
103+
system_command "/usr/bin/xattr",
104+
args: ["-cr", "#{appdir}/anylinuxfs-gui.app"]
105+
end
106+
107+
zap trash: [
108+
"~/Library/Caches/com.anylinuxfs.gui",
109+
"~/Library/Preferences/com.anylinuxfs.gui.plist",
110+
]
111+
end
112+
CASKEOF
113+
114+
# Replace placeholders with actual values
115+
sed -i '' "s/VERSION_PLACEHOLDER/${VERSION}/g" Casks/anylinuxfs-gui.rb
116+
sed -i '' "s/SHA256_PLACEHOLDER/${SHA256}/g" Casks/anylinuxfs-gui.rb
117+
118+
# Fix indentation (remove leading spaces from heredoc)
119+
sed -i '' 's/^ //' Casks/anylinuxfs-gui.rb
113120
114121
git config user.name "github-actions[bot]"
115122
git config user.email "github-actions[bot]@users.noreply.github.com"

0 commit comments

Comments
 (0)