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

feat: add marler8997/zigup #9473

Closed
wants to merge 3 commits into from
Closed

feat: add marler8997/zigup #9473

wants to merge 3 commits into from

Conversation

ryoppippi
Copy link
Contributor

@ryoppippi ryoppippi commented Jan 29, 2023

marler8997/zigup: Download and manage zig compilers

$ aqua g -i marler8997/zigup

How to confirm if this package works well

Reviewers aren't necessarily familiar with this package, so please describe how to confirm if this package works well. Please confirm if this package works well yourself as much as possible.

Command and output

$ zigup master

If files such as configuration file are needed, please share them.

Reference

[marler8997/zigup](https://github.com/marler8997/zigup): Download and manage zig compilers

```console
$ aqua g -i marler8997/zigup
```

## How to confirm if this package works well

Reviewers aren't necessarily familiar with this package, so please describe how to confirm if this package works well.
Please confirm if this package works well yourself as much as possible.

Command and output

```console
$
```

If files such as configuration file are needed, please share them.

```
```

Reference

-
@suzuki-shunsuke suzuki-shunsuke added the enhancement New feature or request label Jan 29, 2023
@suzuki-shunsuke suzuki-shunsuke added this to the v3.126.0 milestone Jan 29, 2023
@suzuki-shunsuke
Copy link
Member

Thank you for your contribution!

@suzuki-shunsuke
Copy link
Member

b1c621c Removed newlines.
a8c726e Supported linux and old versions.

@suzuki-shunsuke
Copy link
Member

Hmm. zigup master doesn't work well. An error occured.

$ zigup master
install directory '/Users/shunsukesuzuki/zig'
mkdir '/Users/shunsukesuzuki/zig'
rm -rf '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing'
mkdir '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing'
downloading 'https://ziglang.org/builds/zig-macos-aarch64-0.11.0-dev.1481+4c1168418.tar.xz' to '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing/zig-macos-aarch64-0.11.0-dev.1481+4c1168418.tar.xz'
[RUN] tar xf /Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing/zig-macos-aarch64-0.11.0-dev.1481+4c1168418.tar.xz -C /Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing
rm -rf '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing/zig-macos-aarch64-0.11.0-dev.1481+4c1168418.tar.xz'
mv '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing/zig-macos-aarch64-0.11.0-dev.1481+4c1168418' '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing/files'
mv '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418.installing' '/Users/shunsukesuzuki/zig/0.11.0-dev.1481+4c1168418'
ln -s '0.11.0-dev.1481+4c1168418' '/Users/shunsukesuzuki/zig/master'
error: path-link '/Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip/zig' is lower priority in PATH than '/Users/shunsukesuzuki/.local/share/aquaproj-aqua/bin/zig'

$ echo $?
1

error: path-link '/Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip/zig' is lower priority in PATH than '/Users/shunsukesuzuki/.local/share/aquaproj-aqua/bin/zig'

@suzuki-shunsuke suzuki-shunsuke removed this from the v3.126.0 milestone Jan 30, 2023
@ryoppippi
Copy link
Contributor Author

Thank you for modifying my PR.
Please delete zig and try zigup master again because they are conflicted

@suzuki-shunsuke
Copy link
Member

suzuki-shunsuke commented Jan 30, 2023

Thank you. I removed zig then another error occured.

$ rm /Users/shunsukesuzuki/.local/share/aquaproj-aqua/bin/zig
$ zigup master                                               
install directory '/Users/shunsukesuzuki/zig'
mkdir '/Users/shunsukesuzuki/zig'
compiler '/Users/shunsukesuzuki/zig/0.11.0-dev.1499+23b7d2889' already installed
symlink '/Users/shunsukesuzuki/zig/master' already points to '0.11.0-dev.1499+23b7d2889'
error: the path link '/Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip/zig' is not in PATH

--

error: the path link '/Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip/zig' is not in PATH
$ tree /Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip
/Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip
└── zigup

@suzuki-shunsuke
Copy link
Member

@suzuki-shunsuke
Copy link
Member

suzuki-shunsuke commented Jan 30, 2023

The error can be reproduced even if zigup is run directly without aqua.

$ /Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip/zigup master
install directory '/Users/shunsukesuzuki/zig'
mkdir '/Users/shunsukesuzuki/zig'
compiler '/Users/shunsukesuzuki/zig/0.11.0-dev.1499+23b7d2889' already installed
symlink '/Users/shunsukesuzuki/zig/master' already points to '0.11.0-dev.1499+23b7d2889'
error: the path link '/Users/shunsukesuzuki/.local/share/aquaproj-aqua/pkgs/github_release/github.com/marler8997/zigup/v2022_08_25/zigup.macos-latest-aarch64.zip/zig' is not in PATH

This error occurs if the executable binary zigup isn't in PATH?

@suzuki-shunsuke
Copy link
Member

Hmm. Probably aqua can't support zigup, because the executable binary zigup must be installed in PATH.

marler8997/zigup#65 (comment)

aqua doesn't install executable binaries in PATH, because aqua has to change tool versions dynamically.
aqua creates symbolic links in PATH ${AQUA_ROOT_DIR:-${XDG_DATA_HOME:-$HOME/.local/share}/aquaproj-aqua}/bin.

ref. https://aquaproj.github.io/docs/reference/lazy-install

@ryoppippi
Copy link
Contributor Author

@suzuki-shunsuke
Thank you for your investigation
I had never encountered such an error and did not know about this behavior.
I understood about aqua not being able to support zigup.
If you need it, I can provide an alternative tool myself.

@ryoppippi ryoppippi closed this Jan 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants