| Commit message (Collapse) | Author | Files | Lines |
|
I honestly just switched the definition and then frantically
changed small things based on rusts error messages, but it passes
fmt, clippy and tests so I think it's fine.
This allow a bit finer control over the URI, but is honetly a bit insignificant.
|
|
|
|
|
|
|
|
|
|
|
|
Found via `codespell -L crate`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* README.md will be rendered at currently visiting directory instead
of just in the root.
* Rendering is now done by comrak, which seems heavy but has a lot
more features.
|
|
|
|
|
|
|
|
* Add ability to make directory
Frontend for making directories
Fix potential security vulnerability (CWE-23)
Add tests
Update README.md
Disallow using parent directories altogether
Fix formatting
Fix clippy warnings
Address review comments
Update README.md
Change `making` to `creation`
Co-authored-by: Sven-Hendrik Haase <svenstaro@gmail.com>
Have make directory flag require file upload flag
Address review comments
* Disallow uploading files and making directories through symlinks when disabled
* Add test
* Clippy formatting changes
* Add test doc comment
|
|
|
|
I think if we followed the lint the code would be less readable for no real benefit.
|
|
|
|
|
|
Co-authored-by: Ali MJ Al-Nasrawy <alimjalnasrawy@gmail.com>
|
|
|
|
|
|
- Raw mode only displays file/folders and is more focused on
computer processing
- Display a banner in footer to recursively download the
current folder with wget
|
|
Signe-off-by: Ali MJ Al-Nasrawy <alimjalnasrawy@gmail.com>
|
|
... page rendering
Too many arguments are moved around and many of them are already stored
in MiniserveConfig. Many of these are used to render error pages.
To fix this issue, it was necessary to rework error page rendering:
1. Implement `ResponseError` for `ContextualError` so that it can be
returned from service handlers as is and will then be automatically
logged to the console and converted into an error response.
2. At service handler level, all error responses are now rendered as
plain text.
3. 'error_page_middleware' is now responsible for the rendering of the
final error page from plain text reponses.
Signed-off-by: Ali MJ Al-Nasrawy <alimjalnasrawy@gmail.com>
|
|
Add option `show_symlink_info` to represent show symlink info or not.
(Default to no)
Show symlink destination after symlink symbol in directory listing
Resemble `ls -l` and also the short argument select for this feature
is also `-l`.
Basic testing is included.
Related to #499
|
|
|
|
|
|
|
|
This name more closely resembles its purpose. For instance, we also now
support plain tar archives which are uncompressed but archives nonetheless.
|
|
Use following terminology:
uncompressed tarballs => `uncompressed tar archives`
compressed ones => `gz-compressed tar archives`
|
|
It used to have one flag (-r) to enable both tar archive and tar.
Now it has two flags [ -r: for tar, -g: for tar archive].
Related to #451
|
|
Now that the '%' char itself is accepted in the file name and is encoded
into '%25', this exposed a previously silent bug:
`base` is already percent-encoded but it is encoded again when setting
`file_url`. This produces erroneous URLs such as:
'/%2523/x.y' instead of '/%23/x.y' for the path '/#/x.y'
|
|
Use proper percent-encoding charset for each context.
|
|
For non-symlink files and directories, there is no need to call
`std::fs::metadata()` as the metadata are already obtained via
`entry.metadata()`
|
|
|
|
|
|
This has the benefit of showing the size and modification date of the
pointed-to file. Symlink to directories now respects '--dirs-first'
option and broken symlinks don't show in directory listing.
|
|
|
|
|
|
|
|
|