getLastModified.lua 537 B

1234567891011121314151617181920212223
  1. return {
  2. tag = 'filesystem-files',
  3. summary = 'Get the modification time of a file.',
  4. description = 'Returns when a file was last modified, since some arbitrary time in the past.',
  5. arguments = {
  6. path = {
  7. type = 'string',
  8. description = 'The file to check.'
  9. }
  10. },
  11. returns = {
  12. time = {
  13. type = 'number',
  14. description = 'The modification time of the file, in seconds, or `nil` if it\'s unknown.'
  15. }
  16. },
  17. variants = {
  18. {
  19. arguments = { 'path' },
  20. returns = { 'time' }
  21. }
  22. }
  23. }