Saagar Jha
c9ce16a633
Support excluding firmlinks on macOS
2020-05-13 11:29:55 -07:00
Saagar Jha
684e9e04ad
Typo: exlude → exclude
2020-05-07 16:10:07 -07:00
Yorhel
9a3727759c
Fix calculating of directory apparent sizes with hard links
...
Silly one-character typo that causes directory apparent sizes to be very
off in some scenarios.
Reported & patched by Andrew Neitsch.
2020-05-06 07:04:36 +02:00
Yorhel
4a2def5223
dir_scan.c: Fix integer overflow when list of file names in dir exceeds 2GiB
...
Fixes #150
2020-04-21 14:13:51 +02:00
Yorhel
1563e56223
help.c: Mention new ^ file flag
2020-04-08 18:35:01 +02:00
Christian Göttsche
c209b012b1
Add option --exclude-kernfs to skip scanning Linux pseudo filesystems
...
(cherry picked from commit a076ac714aa6fb24e0e9eb227372df84a4b6000b)
2020-04-08 18:32:11 +02:00
Christian Göttsche
50b48a6435
Mention supported color schemes in help text
2020-04-08 17:17:06 +02:00
Christian Göttsche
e3742f0c80
Remove redundant cast to the same type
...
(cherry picked from commit ef7b4e5c28739c26b3a120296f9dc2ddaf2d4375)
2020-04-08 11:00:41 +02:00
Christian Göttsche
3959210051
Drop never read initialization
...
(cherry picked from commit 9f28920a64c155957b83324cd3a3cf0fda6020c9)
2020-04-08 10:59:25 +02:00
Christian Göttsche
84834ff370
Declare file local variables static
...
(cherry picked from commit ad5b7fce74a3b7b0ed726620c81ea552c643cdad)
2020-04-08 10:58:53 +02:00
Christian Göttsche
53e5080d9a
Avoid using extension of variable length array folded to constant array
...
(cherry picked from commit 2faefc3b2432409f3ccca0b6ab53a228d5b9b00d)
2020-04-08 10:57:23 +02:00
Christian Göttsche
61d268764d
Drop extra ';' outside of a function
...
(cherry picked from commit 32b77d0064d3e5f52e9204ddeffc29bb21a67753)
2020-04-08 10:55:57 +02:00
Christian Göttsche
2bd83b3f22
Avoid using GNU empty initializer extension
...
(cherry picked from commit ce7036d249b6f05633c343ab95d88552aab85402)
2020-04-08 10:55:36 +02:00
Christian Göttsche
70f439d9a9
Enforce const correctness on strings
...
(cherry picked from commit 9801f46ece0ca2525f02d71464efc42296dddcb5)
2020-04-08 10:53:21 +02:00
Christian Göttsche
39709aa665
Use strict prototypes
...
(cherry picked from commit e4e8ebd9e0037812436a1588809deb23e0f3751a)
2020-04-08 10:52:25 +02:00
Christian Göttsche
bd22bf42ee
Update configure.ac
...
* Use AS_HELP_STRING instead of deprecated AC_HELP_STRING
* Use AC_OUTPUT without arguments
* Enclose AC_INIT argument in brackets
* Add automake option std-options
(cherry picked from commit 53a33e1db2c9a58b867f7db26c5f476c3ee4b00b)
2020-04-08 10:48:14 +02:00
Christian Göttsche
227cdb35ae
Ignore generated script compile in git
...
(cherry picked from commit fd75bd0c22a0ab6935ac5332999ebe77c6d8a1c8)
2020-04-08 10:45:24 +02:00
Christian Göttsche
2fd4d8b406
Remove trailing whitespaces
2020-04-07 21:49:14 +02:00
Yorhel
888bd663c6
Also quit on EIO from getch()
...
Fixes #141
2020-04-01 16:54:57 +02:00
Yorhel
8d58297328
Year + version bump for 1.14.2
2020-02-10 16:02:26 +01:00
Yorhel
5c5cd163a1
Fix khash.h -> khashl.h reference in Makefile
2020-02-06 08:58:10 +01:00
Yorhel
2d76190091
deps/khash.h -> khashl.h for slightly reduced memory usage
...
Reduces memory by a tiny bit. Arguably we never needed tombstones
because entries are never removed, so there shouldn't be any performance
hit there. We don't even need a 'used' flag either, considering that can
be represented by a NULL value, but I'm not really up for
implementing/modifying my own hash table.
ref: https://attractivechaos.wordpress.com/2019/12/28/deletion-from-hash-tables-without-tombstones/
2020-02-04 19:15:48 +01:00
Yorhel
ecb71f2550
Fix definitions of global vars confirm_quit
and dir_process
...
They were defined (rather than just declared) in .h files, when they
really should be defined in at most a single .c file.
Fixes #140 .
2020-01-25 09:25:11 +01:00
Yorhel
7875a76bba
static: Add AArch64 binaries
2019-12-15 10:12:13 +01:00
Yorhel
a5e08cf597
Fix cross compiler targets
...
I assumed that ./configure would fail if it can't find a suitable
compiler for the given --host, but it just falls back to the host gcc.
Fixes #138
2019-11-14 19:00:32 +01:00
Yorhel
62bc78d937
Increase space for item count in loading screen
...
Fixes #135
2019-08-17 10:35:51 +02:00
Yorhel
72189c307f
Version bump for 1.14.1 + static bin improvements
2019-08-05 08:22:22 +02:00
Yorhel
dc8b6cfaab
Fix --exclude-caches
...
Broken in 77aca35fce
Fixes #134
2019-08-04 17:31:59 +02:00
Yorhel
bb7b4196f2
Handle malloc failure by pausing any activity
...
This is a best-effort approach to save ncdu state when memory is low.
There's likely allocation in libraries that isn't being checked
(ncurses, printf).
Fixes #132 (it actually doesn't, that needs a 64bit static binary too,
but I'll get to that)
2019-07-23 11:03:41 +02:00
Yorhel
cd38a62aa8
Clear errno before getch()
...
Fixes #128 .
2019-04-19 15:01:58 +02:00
Martin Storsjö
ec0de4afa8
dir_scan: Avoid allocating new copies of buf_dir
...
This allocation is currently leaked, but as long as we don't allocate
new ones for each refresh, that shouldn't be much of an issue.
(cherry picked from commit 9dc2d32a8fb557112f8f96cd14d50b934543ce39)
2019-02-19 10:05:42 +01:00
Martin Storsjö
8e021a46ee
dir_setlasterr: strcpy the right variable
2019-02-18 23:50:17 +02:00
Yorhel
b6ddd491b3
Year + version bump for 1.14
2019-02-04 17:30:22 +01:00
Yorhel
882a32613d
symlinks: Only call stat_to_dir() once, impove manual
...
stat_to_dir() assumes that buf_dir is clean; calling it twice breaks
that asumption.
2019-01-24 08:56:19 +01:00
Simon Doppler
74efdfaf97
Add a '--follow-symlinks' option
...
Symlink loops are handled by the stat(2) syscall. Symlinks pointing to a
directory are ignored (to avoid loops in the recursive scan).
2019-01-24 08:24:09 +01:00
Yorhel
2409cc7a32
Fix minor typo
2019-01-21 07:38:56 +01:00
Alex Wilson
60fdac0680
add a max modified time, or mtime, view and sorting
...
This adds an 'm' command to show the latest modified time of all files
in a directory. The 'M' command allows for ascending and descending
mtime sorting. These are only enabled with the -e flag and overload
the dir_ext mtime field.
2019-01-21 07:33:24 +01:00
Yorhel
2501fb1ad5
Fix crash when attempting to sort an empty directory
...
I had taken care to not sort empty directories during dirlist_open(),
but forgot that manual user actions can still cause dirlist_set_sort()
to be called, which does not handle empty directories.
Reported by Alex Wilson.
2019-01-20 16:43:59 +01:00
Yorhel
93583e645f
Add --help flag as alias for -h
...
https://dev.yorhel.nl/ncdu/bug/125
2018-12-16 10:47:51 +01:00
Yorhel
bf8068b65e
Slightly improve hardlink circular list insertion performance
...
Based on https://dev.yorhel.nl/ncdu/bug/124
2018-12-01 07:53:51 +01:00
Yorhel
d95c65b032
Add -V and --version as alias to -v
2018-09-03 22:19:55 +02:00
Yorhel
9f2350bbc9
Display larger file counts in browser UI
...
Implements https://dev.yorhel.nl/ncdu/bug/43
2018-07-24 18:03:18 +02:00
Yorhel
cbe24d6c8f
Exit ncdu when losing input
...
Ought to fix https://dev.yorhel.nl/ncdu/bug/115
2018-06-13 17:16:02 +02:00
Yorhel
d15fe8d08e
Spelling fixes: "occured" + "an other"
...
https://dev.yorhel.nl/ncdu/bug/112
2018-03-29 17:32:48 +02:00
Yorhel
fa19095e26
Fix '--color off'
...
https://dev.yorhel.nl/ncdu/bug/111
2018-03-29 17:20:43 +02:00
Yorhel
31126c6552
man page/file flags: Minor rewording + use same order as help screen
2018-02-21 18:59:24 +01:00
Thomas McWork
726b1542c6
shift section; adapt to online help wording
2018-02-21 18:55:03 +01:00
Thomas McWork
48a266c348
add a file flags section in the docs
2018-02-21 18:55:03 +01:00
Yorhel
14afd92ba2
Year + version bump for 1.13
2018-01-29 11:58:14 +01:00
Yorhel
7ba0f15f80
delete.c: Fix signedness issue in confirmation selection
...
'char' may be unsigned on some architectures, which will cause the
"overflow check" on decrement to fail.
This would at most result in a confusing UI issue where no confirmation
option appears to be selected.
2018-01-29 11:58:14 +01:00