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

Search for packages #43

Open
Totktonada opened this issue Nov 11, 2021 · 0 comments
Open

Search for packages #43

Totktonada opened this issue Nov 11, 2021 · 0 comments
Labels
feature A new functionality

Comments

@Totktonada
Copy link
Member

Idea

The idea is simple. RWS manages metainformation of repositories, so it should be easy to cache it within the service in some convenient form and provide searching functionality.

My scenario

After #10 we can traverse over a repository file tree using a Web browser. I had thought that at this point it would be simple to do search for a package using bash+curl one-liner, because a structure of repositories is known and simple.

I had the need to look, where we have the tarantool-metrics package (and its version). I wrote the following 'one-liner':

$ for u in xenial bionic focal groovy hirsute; do \
    for repo in release/1.10 release/2.{0..9} release/modules live/1.10 live/2.{0..9} pre-release/series-2; do \
        echo -e "\n====\n$repo (ubuntu $u)\n====\n"; \
        curl -Ssf https://rws.tarantool.org/$repo/ubuntu/pool/$u/main/t/tarantool-metrics | \
            grep 'a href' | grep -v 'go to the Home Page'; \
    done; \
done

But see, how many things are not covered:

  1. It is only for Ubuntu (but easy to adopt to Debian as well).
  2. However we need another traverse for CentOS / Fedora / openSUSE packages.
  3. I borrow Ubuntu versions list from actual tarantool sources, but it misses packages for older Ubuntu versions.
  4. Hardcoding of repositories, Ubuntu versions.

If I would handle everything, this one-liner will become a way bigger. So my wish to use just bash+curl to perform various searches is a bit more complicated than I would expect for such quite regular task.

I want a reliable solution, which will be built into RWS itself.

@Totktonada Totktonada added the feature A new functionality label Nov 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature A new functionality
Projects
None yet
Development

No branches or pull requests

3 participants