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 other Platforms when command isn't found #278

Open
k12ish opened this issue Jul 5, 2022 · 2 comments
Open

Search other Platforms when command isn't found #278

k12ish opened this issue Jul 5, 2022 · 2 comments
Labels
feature-request spec This issue involves the tldr client specification.
Milestone

Comments

@k12ish
Copy link

k12ish commented Jul 5, 2022

Taken from the TLDR client specification:

If a page is not available for either the host platform or the common platform, then clients SHOULD search other platforms and display a page from there - along with a warning message.

On Windows, tealdeer outputs this:

$ tldr fuser
Warning: Page `fuser` not found in cache.
Try updating with `tldr --update`, or submit a pull request to:
https://github.com/tldr-pages/tldr

This lead me to believe that fuser didn't have a page, and I mistakenly submitted a PR

I suspect that I'm not the only person to have had this problem, and I would appreciate if we could get this fixed.

@marchersimon
Copy link

The relevant code is from here (line 292) https://github.com/dbrgn/tealdeer/blob/97b4395e258ae809060dd6cdceb5cab9c76dadcc/src/cache.rs#L292

to line 301. It first searches the current platform, then common, and then stops.

@osalbahr
Copy link

I can confirm the problem happens to me too:

~ $ tldr -u
Successfully updated local database
~ $ tldr fuser
This page doesn't exist yet!
Submit new pages here: https://github.com/tldr-pages/tldr
~ $ tldr gcc

gcc

Preprocess and compile C and C++ source files, then assemble and link them together.
More information: <https://gcc.gnu.org>.

- Compile multiple source files into executable:
    gcc path/to/source1.c path/to/source2.c ... -o path/to/output_executable

- Show common warnings, debug symbols in output, and optimize without affecting debugging:
    gcc path/to/source.c -Wall -g -Og -o path/to/output_executable

- Include libraries from a different path:
    gcc path/to/source.c -o path/to/output_executable -Ipath/to/header -Lpath/to/library -llibrary_name

- Compile source code into Assembler instructions:
    gcc -S path/to/source.c

- Compile source code into an object file without linking:
    gcc -c path/to/source.c

~ $ 

@niklasmohrin niklasmohrin added the spec This issue involves the tldr client specification. label Jan 9, 2025
@niklasmohrin niklasmohrin added this to the v1.8.0 milestone Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request spec This issue involves the tldr client specification.
Development

Successfully merging a pull request may close this issue.

5 participants