orhun / rustypaste

A minimal file upload/pastebin service.
https://blog.orhun.dev/blazingly-fast-file-sharing
MIT License
771 stars 48 forks source link

feat(server): include file creation date in the list #294

Closed viktaur closed 4 months ago

viktaur commented 4 months ago

Description

This PR includes the date and time in ISO8601 format of the instant the file was created.

Motivation and Context

The information returned in the list function was missing a timestamp representing the date of creation of the file, which can be useful for sorting or retrieving the latest files.

This fixes issue #293.

How Has This Been Tested?

Changelog Entry

Types of Changes

Checklist:

codecov-commenter commented 4 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 83.23%. Comparing base (2bdd62b) to head (339e34e). Report is 2 commits behind head on master.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #294 +/- ## ========================================== + Coverage 83.02% 83.23% +0.21% ========================================== Files 11 11 Lines 1196 1211 +15 ========================================== + Hits 993 1008 +15 Misses 203 203 ``` | [Flag](https://app.codecov.io/gh/orhun/rustypaste/pull/294/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Orhun+Parmaks%C4%B1z) | Coverage Δ | | |---|---|---| | [unit-tests](https://app.codecov.io/gh/orhun/rustypaste/pull/294/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Orhun+Parmaks%C4%B1z) | `83.23% <100.00%> (+0.21%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Orhun+Parmaks%C4%B1z#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

tessus commented 4 months ago

We also need another PR for the rustypaste-cli. ;-)

orhun commented 4 months ago

Can you run cargo fmt and commit the changes pls 😇