Skip to content

Commit a6a09da

Browse files
authored
chore: add nix package automation via GoReleaser (#239)
This adds a nix section to the GoReleaser configuration that will: - Automatically publish container-use packages to dagger/nix - Include shell completions for both container-use and cu commands - Create cu symlink for backward compatibility - Follow the same automation pattern as dagger package
1 parent c70b1de commit a6a09da

1 file changed

Lines changed: 28 additions & 0 deletions

File tree

.goreleaser.yaml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,34 @@ homebrew_casks:
102102
FileUtils.rm_f "#{HOMEBREW_PREFIX}/share/zsh/site-functions/_cu"
103103
FileUtils.rm_f "#{HOMEBREW_PREFIX}/share/fish/vendor_completions.d/cu.fish"
104104
105+
# https://goreleaser.com/customization/nix/
106+
nix:
107+
- name: container-use
108+
repository:
109+
owner: "{{ .Env.GH_ORG_NAME }}"
110+
name: nix
111+
commit_author:
112+
name: container-use-bot
113+
email: noreply@dagger.io
114+
url_template: "https://github.com/{{ .Env.GH_ORG_NAME }}/container-use/releases/download/{{ .Tag }}/{{ .ArtifactName }}"
115+
homepage: "https://github.com/{{ .Env.GH_ORG_NAME }}/container-use"
116+
description: "Containerized environments for coding agents"
117+
license: "asl20"
118+
post_install: |
119+
installShellCompletion --cmd container-use \
120+
--bash <($out/bin/container-use completion bash) \
121+
--fish <($out/bin/container-use completion fish) \
122+
--zsh <($out/bin/container-use completion zsh)
123+
124+
# Create cu symlink for backward compatibility
125+
ln -sf $out/bin/container-use $out/bin/cu
126+
127+
# Install cu completions for backward compatibility
128+
installShellCompletion --cmd cu \
129+
--bash <($out/bin/cu completion bash) \
130+
--fish <($out/bin/cu completion fish) \
131+
--zsh <($out/bin/cu completion zsh)
132+
105133
checksum:
106134
name_template: "checksums.txt"
107135

0 commit comments

Comments
 (0)