Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Headless Installs #104

Open
ProfessorManhattan opened this issue Dec 6, 2022 · 4 comments
Open

Headless Installs #104

ProfessorManhattan opened this issue Dec 6, 2022 · 4 comments

Comments

@ProfessorManhattan
Copy link

Hey, cool tool but zap install --silent etcher fails. It looks like it cannot do headless installs right now. I would love to handle all my appimages with a tool like this. I think this is the best one out so far but the headless installs are the main reason why I'm using something like this anyway.

I tried yes | zap install --silent etcher but that didn't work either

@srevinsaju
Copy link
Owner

This would be a good feature, but I wasn't sure how we could figure out the right version to install. Right now, zap install --silent libresprite would fail with an error message

[FATAL] 2022/12/08 11:45:53 main.main:main.go:163 prompt is disabled because user has requested silence

This is because it found a few bunch of releases and it doesn't know which one of the release you would be interested it. zap tries it best to do a semantic version sort, but at times, the app developers do not use a fixed sem ver in their release names, and that messes up the installation algorithm. This is why I did not automate this, since that would have brought some unexpected surprises. Let me know if you have any ideas. I think I could add a --select-first flag, or something like that which will always select the first item, but know that, the first item on the list may or may not be the latest release.

@ProfessorManhattan
Copy link
Author

Thanks @srevinsaju -- --select-first would be great. I personally think it should be assumed that --silent will make assumptions but I can see why you didn't do that.

@markuspeitl
Copy link

markuspeitl commented Dec 12, 2022

I also did not have any success getting headless interaction to work with zap.
I tried the "yes" command,
using a << pipe to write "Enter + y + y" to the stdinof the process
and writing an "expect" script trying to automatically answer the printed questions.
Having native headless support for zap would be pretty nice for my purposes, i frequently do collect my applications in lists to automatically install them on a new system.

Another option would be to go the npm route and embed the version in the package name separated by an "@" like this:

zap install firefox@firefox-nightly
zap install firefox@firefox-beta`
zap install [email protected]

Once zap can figure out the latest version or the latest stable version, something like

zap install cpu-x@latest
zap install cpu-x@beta
zap install cpu-x@stable

would be an additional option for targeting different types of releases or branches.

@mdeguzis
Copy link

Whatever happened to this? I'd love if Zap could just use the first/latest tag. I install Steam Art Manager from https://github.com/Tormak9970/Steam-Art-Manager, but upgrade always asks for version selection.

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

No branches or pull requests

4 participants