Skip to content
This repository was archived by the owner on Sep 9, 2020. It is now read-only.

Dep 0.3.1 release packages lack file extensions #1189

Closed
akutz opened this issue Sep 20, 2017 · 4 comments
Closed

Dep 0.3.1 release packages lack file extensions #1189

akutz opened this issue Sep 20, 2017 · 4 comments

Comments

@akutz
Copy link
Contributor

akutz commented Sep 20, 2017

Please update release 0.3.1 with files that have file extensions. Otherwise automated builds that rely on the file names break :(

v0.3.1 Screenshot

image

v0.3.0 Screenshot

image

Makefile Target

Here's the Makefile target broken by the the extensionless filenames:

################################################################################
##                                   DEP                                      ##
################################################################################
DEP := ./dep
DEP_VER ?= 0.3.1
DEP_ZIP := dep-$$GOHOSTOS-$$GOHOSTARCH.zip
DEP_URL := https://github.com/golang/dep/releases/download/v$(DEP_VER)/$$DEP_ZIP

$(DEP):
	GOVERSION=$$(go version | awk '{print $$4}') && \
	GOHOSTOS=$$(echo $$GOVERSION | awk -F/ '{print $$1}') && \
	GOHOSTARCH=$$(echo $$GOVERSION | awk -F/ '{print $$2}') && \
	DEP_ZIP="$(DEP_ZIP)" && \
	DEP_URL="$(DEP_URL)" && \
	mkdir -p .dep && \
	cd .dep && \
	curl -sSLO $$DEP_URL && \
	unzip "$$DEP_ZIP" && \
	mv $(@F) ../ && \
	cd ../ && \
	rm -fr .dep
ifneq (./dep,$(DEP))
dep: $(DEP)
endif

dep-ensure: | $(DEP)
	$(DEP) ensure -v

.PHONY: dep-ensure
@akutz
Copy link
Contributor Author

akutz commented Sep 20, 2017

Ugh. Hey @sdboyer, it looks like the filenames lack extensions because they're no longer zipped at all? I'm all for dropping ZIP for something like TAR.GZ as the latter can be streamed and the binary yanked out without need for a temp file or directory, but dropping the ZIP support altogether breaks certain expectations.

Is this at least going to be the direction moving forward? I just don't really want to see this change again.

@sdboyer
Copy link
Member

sdboyer commented Sep 20, 2017

ah yeah, sorry about that - correct, no longer zipped at all, on the expectation that that's one less tool/step on the receiving end, and I'd imagine that HTTP compression is probably happening anyway?

in any case, yes, this will be the pattern going forward.

@sdboyer
Copy link
Member

sdboyer commented Sep 20, 2017

original issue re: this was #957

@sdboyer sdboyer closed this as completed Sep 20, 2017
@akutz
Copy link
Contributor Author

akutz commented Sep 20, 2017

Hi @sdboyer,

Thank you for the update. I've already updated the Makefile target:

################################################################################
##                                   DEP                                      ##
################################################################################
DEP ?= ./dep
DEP_VER ?= 0.3.1
DEP_BIN := dep-$$GOHOSTOS-$$GOHOSTARCH
DEP_URL := https://github.com/golang/dep/releases/download/v$(DEP_VER)/$$DEP_BIN

$(DEP):
	GOVERSION=$$(go version | awk '{print $$4}') && \
	GOHOSTOS=$$(echo $$GOVERSION | awk -F/ '{print $$1}') && \
	GOHOSTARCH=$$(echo $$GOVERSION | awk -F/ '{print $$2}') && \
	DEP_BIN="$(DEP_BIN)" && \
	DEP_URL="$(DEP_URL)" && \
	curl -sSLO $$DEP_URL && \
	chmod 0755 "$$DEP_BIN" && \
	mv -f "$$DEP_BIN" "$@"
ifneq (./dep,$(DEP))
dep: $(DEP)
endif

vendor: | $(DEP)
	$(DEP) ensure -v

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants