Skip to content

du: --time shows the creation time instead of last modification time #13267

Description

@Devel08

Title is self-explanatory.

How to reproduce

GNU

$ du --max-depth=1 --time
8	2026-07-02 18:41	./.cargo
280	2026-07-02 18:41	./.github
8	2026-07-02 18:41	./.config
328	2026-07-02 18:41	./util
868	2026-07-02 18:41	./docs
8892	2026-07-02 18:41	./src
44	2026-07-02 18:41	./.vscode
260	2026-07-02 18:41	./fuzz
8136	2026-07-02 18:41	./tests
12	2026-07-02 18:41	./.devcontainer
2043032	2026-07-04 08:17	./target
47172	2026-07-02 18:41	./.git
2109336	2026-07-04 08:17	.

uutils

$ cargo run du --max-depth=1 --time
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.25s
     Running `target/debug/coreutils du --max-depth=1 --time`
8	2026-07-02 18:41	./.cargo
280	2026-07-02 18:41	./.github
8	2026-07-02 18:41	./.config
328	2026-07-02 18:41	./util
868	2026-07-02 18:41	./docs
8892	2026-07-02 18:41	./src
44	2026-07-02 18:41	./.vscode
260	2026-07-02 18:41	./fuzz
8136	2026-07-02 18:41	./tests
12	2026-07-02 18:41	./.devcontainer
2043032	2026-07-02 18:44	./target
47172	2026-07-02 18:41	./.git
2109336	2026-07-02 18:48	.

the last entry is the cwd, in which in GNU's time column is 2026-07-04 08:17 (that is the last modification time) and uutils is 2026-07-02 18:48 (that is the time when the directory was created). Note that this bug occurs on other entries too and not the cwd only (.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions