← All commands
Topic hub Text Processing
Windows Linux Text Processing Search

Windows dir /od (sort by date) equivalent in Linux

Locates files modified within a specific time window.

Windows dir /od (sort by date)
Linux equivalents
Debian/Ubuntu same command
find . -mtime -1
Fedora same command
find . -mtime -1
Arch same command
find . -mtime -1

Overview

What this command does

Locates files modified within a specific time window.

Migration tip: -mtime -1 means modified within the last 24 hours. -mmin -60 means within the last 60 minutes. Positive numbers mean older than that many days.

Practical tasks

Common use cases

Find recently modified files

Locates files modified within a specific time window.

find . -mtime -1

Modified in last 24 hours

find . -mtime -7

Modified in last 7 days

find . -mmin -60

Modified in last 60 minutes

Ready to run

Copyable Linux commands

Review paths, device names, package names and permissions before running any command.

find . -mtime -1 -type f
find /etc -mmin -30
ls -lt

Walkthrough

Examples with explanations

# Windows: dir /od

# Files changed in last 24 hours:
find . -mtime -1 -type f

# Changes in /etc in last 30 minutes:
find /etc -mmin -30

# List with newest first:
ls -lt

Reference

Common options and variations

Command or optionUse
find . -mtime -1Modified in last 24 hours
find . -mtime -7Modified in last 7 days
find . -mmin -60Modified in last 60 minutes
find . -newer file.txtNewer than a reference file
ls -ltList sorted by modification time (newest first)
ls -ltrSorted by modification time (oldest first)

Distro differences

Debian/Ubuntu vs Fedora vs Arch

This command is the same on Debian/Ubuntu, Fedora and Arch Linux when the relevant tool is installed.

DistributionPackage manager / baseEquivalent commandDifference to notice
Debian/Ubuntu same command find . -mtime -1 Same command on this distribution.
Fedora same command find . -mtime -1 Same command on this distribution.
Arch same command find . -mtime -1 Same command on this distribution.

Keep learning

Related Text Processing commands