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

Documentation for headers in TOML #1507

Closed
devin-purple opened this issue Sep 26, 2024 · 6 comments · Fixed by #1540
Closed

Documentation for headers in TOML #1507

devin-purple opened this issue Sep 26, 2024 · 6 comments · Fixed by #1540
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@devin-purple
Copy link
Contributor

The CLI argument works (--header "Host=something.com")

I cannot find anywhere in the documentation that shows how to put this into the lychee.toml

In the example it just shows headers = [] which is not helpful.

@mre
Copy link
Member

mre commented Sep 27, 2024

Have you tried this?

headers = ["Host=something.com"]

@mre mre added the question Further information is requested label Sep 27, 2024
@mre
Copy link
Member

mre commented Oct 1, 2024

You might be running into #1441 (comment)

@devin-purple
Copy link
Contributor Author

I've tried headers = ["Host=asldkfjasldfkj.com"] in .toml, does not seem to work. I should get all 400s with a bad hostname.

Maybe related to #1441, I am reading a list of links from a local file and sending a custom header.

@mre
Copy link
Member

mre commented Oct 1, 2024

I'm beginning to think header parsing from the config is broken. Maybe it never worked.

@mre mre added bug Something isn't working help wanted Extra attention is needed and removed question Further information is requested labels Oct 8, 2024
@cc-stjm
Copy link

cc-stjm commented Oct 11, 2024

I've just come across this - I think you have to specify

header = ["foo=bar"]

in the .toml

the documentation has

headers= ["foo=bar"]

(Note plural)

@mre
Copy link
Member

mre commented Oct 11, 2024

Aha! Thanks for the feedback. Would you like to open a pull request to fix the documentation?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants