From 11b3f1be5a54b1bd3ac46216ffac631d76c9a229 Mon Sep 17 00:00:00 2001 From: Yorhel Date: Thu, 3 Nov 2011 13:32:32 +0100 Subject: [PATCH] ncdc 1.5 and ncdu 1.8 released + minor changes --- dat/ncdc-changelog | 10 ++++ dat/ncdc-man | 56 +++++++++++++++++----- dat/ncdu-changelog | 5 ++ dat/ncdu-man | 116 ++++++++++++++++++++++----------------------- index.cgi | 19 +++++--- 5 files changed, 128 insertions(+), 78 deletions(-) diff --git a/dat/ncdc-changelog b/dat/ncdc-changelog index 51b9fee..8db45a4 100644 --- a/dat/ncdc-changelog +++ b/dat/ncdc-changelog @@ -1,3 +1,13 @@ +1.5 - 2011-11-03 + - Added filelist_maxage setting + - Added flush_file_cache setting + - Added /ungrant and improved /grant management + - Added key to download queue to clear user state for all files + - Added keys to search results to download file list and match queue + - Select the right user when using the 'q' key in connection tab + - Fixed possible crash when opening file list from search results + - Fixed detection of incompatible session directory version + 1.4 - 2011-10-26 - Added sorting functionality to file list - Added color settings: title, separator, list_default, list_header and list_select diff --git a/dat/ncdc-man b/dat/ncdc-man index 44dc8bd..a0cbf1e 100644 --- a/dat/ncdc-man +++ b/dat/ncdc-man @@ -139,11 +139,17 @@ INTERACTIVE COMMANDS This command may take some time to complete, and will fully block ncdc while it is running. You won't have to perform this command very often. - /grant [] + /grant [-list|] Grant someone a slot. This allows the user to download from you even if you have no free slots. The slot will be granted for as long as ncdc - stays open. If you restart ncdc, the user will have to wait for a regular - slot. Unless, of course, you /grant a slot again. + stays open or the /ungrant command is used. If you restart ncdc, the user + will have to wait for a regular slot. Unless, of course, you /grant a + slot again. + + To get a list of users whom you have granted a slot, use `/grant' without + arguments or with `-list'. Be warned that using `/grant' without argu‐ + ments on a PM tab will grant the slot to the user you are talking with. + Make sure to use `-all' in that case. Note that a granted slot is specific to a single hub. If the same user is also on other hubs, he/she will not be granted a slot on those hubs. @@ -269,6 +275,9 @@ INTERACTIVE COMMANDS name you give it will be public. An initial `/refresh' is done automati‐ cally on the added directory. + /ungrant [|] + Revoke a granted slot. + /unset [] This command can be used to reset a configuration variable back to its default value. @@ -427,6 +436,24 @@ SETTINGS KOI8-R (Cyrillic) UTF-8 (International) + filelist_maxage + The maximum age of a downloaded file list. If a file list was downloaded + longer ago than the configured interval, it will be removed from the + cache (the fl/ directory) and subsequent requests to open the file list + will result in the list being downloaded from the user again. Recognized + suffices are 's' for seconds, 'm' for minutes, 'h' for hours and 'd' for + days. Set to 0 to disable the cache altogether. + + flush_file_cache + Tell the OS to flush the file (disk) cache for file contents read while + hashing and uploading. On one hand, this will avoid trashing your disk + cache with large files and thus improve the overall responsiveness of + your system. On the other hand, ncdc may purge any shared files from the + cache, even if they are still used by other applications. In general, it + is a good idea to enable this if you also use your system for other + things besides ncdc, you share large files (>100MB) and people are not + constantly downloading the same file from you. + hubname The name of the currently opened hub tab. This is a user-assigned name, and is only used within ncdc itself. This is the same name as given to @@ -595,7 +622,8 @@ KEY BINDINGS i/Return Toggle user list. r Remove selected user for this file. R Remove selected user from all files in the download queue. - x Clear error state for the selected user. + x Clear error state for the selected user for this file. + X Clear error state for the selected user for all files. Note: when an item in the queue has `ERR' indicated in the priority col‐ umn, you have two choices: You can remove the item from the queue using @@ -609,6 +637,7 @@ KEY BINDINGS End/Home Select last/first item in the list. f Find user in user list. b/B Browse the selected users' list, B to force a redownload. + d Add selected file to the download queue. h Toggle hub column visibility. u Order by username. s Order by file size. @@ -616,6 +645,8 @@ KEY BINDINGS n Order by file name. m Match selected item with the download queue. M Match all search results with the download queue. + q Match selected users' list with the download queue. + Q Match all matched users' lists with the download queue. a Search for alternative download sources. User list tab @@ -670,7 +701,8 @@ FILES $NCDC_DIR/fl/ Directory where downloaded file lists from other users are stored. The names of the files are hex-encoded user IDs that are used internally by - ncdc. Old file lists are deleted automatically after one week. + ncdc. Old file lists are deleted automatically after a configurable + interval. See the `filelist_maxage' configuration option. $NCDC_DIR/hashdata.dat File information and hash data for shared files. @@ -679,17 +711,17 @@ FILES Command history. $NCDC_DIR/inc/ - Default location for incomplete downloads. Can be changed with the + Default location for incomplete downloads. Can be changed with the `incoming_dir' setting. The file names in this directory are the base32-encoded TTH root of the completed file. $NCDC_DIR/logs/ - Directory where all the log files are stored. File names starting with + Directory where all the log files are stored. File names starting with `#' are hub logs and `~' are user (PM) logs. Special log files are trans‐ fers.log and main.log. ncdc does not have built-in functionality to rotate or compress log files - automatically. When rotating log files manually (e.g. via a cron job), - make sure to send the SIGUSR1 signal afterwards to force ncdc to flush + automatically. When rotating log files manually (e.g. via a cron job), + make sure to send the SIGUSR1 signal afterwards to force ncdc to flush the old logs and create or open the new log files. $NCDC_DIR/stderr.log @@ -697,7 +729,7 @@ FILES $NCDC_DIR/version Version of the data directory. This file locked while an ncdc instance is - running, making sure that no two ncdc instances work with the same ses‐ + running, making sure that no two ncdc instances work with the same ses‐ sion directory at the same time. @@ -708,7 +740,7 @@ LICENSE BUGS - Please report bugs or feature requests to projects@yorhel.nl or connect to the + Please report bugs or feature requests to projects@yorhel.nl or connect to the development hub at adc://dc.blicky.net:2780/. @@ -722,4 +754,4 @@ SEE ALSO -ncdc-1.4 October 2011 ncdc(1) +ncdc-1.5 November 2011 ncdc(1) diff --git a/dat/ncdu-changelog b/dat/ncdu-changelog index 63529fd..405b6bf 100644 --- a/dat/ncdu-changelog +++ b/dat/ncdu-changelog @@ -1,3 +1,8 @@ +1.8 - 2011-11-03 + - Use hash table to speed up hard link detection + - Added read-only option (-r) + - Use KiB instead of kiB (#3399279 + 1.7 - 2010-08-13 - List the detected hard links in file info window - Count the size of a hard linked file once for each directory it appears in diff --git a/dat/ncdu-man b/dat/ncdu-man index b02bb8a..c699cd2 100644 --- a/dat/ncdu-man +++ b/dat/ncdu-man @@ -1,4 +1,4 @@ -ncdu(1) ncdu manual ncdu(1) +ncdu(1) ncdu manual ncdu(1) @@ -11,31 +11,32 @@ SYNOPSIS DESCRIPTION - ncdu (NCurses Disk Usage) is a curses-based version of the well-known - 'du', and provides a fast way to see what directories are using your - disk space. + ncdu (NCurses Disk Usage) is a curses-based version of the well-known 'du', and + provides a fast way to see what directories are using your disk space. OPTIONS -h Print a small help message - -q Quiet mode. While calculating disk space, ncdu will update the - screen 10 times a second by default, this will be decreased to - once every 2 seconds in quiet mode. Use this feature to save - bandwidth over remote connections. + -q Quiet mode. While calculating disk space, ncdu will update the screen 10 + times a second by default, this will be decreased to once every 2 seconds + in quiet mode. Use this feature to save bandwidth over remote connec‐ + tions. + + -r Read-only mode. This will disable the built-in file deletion feature. -v Print version. - -x Only count files and directories on the same filesystem as the - specified dir. + -x Only count files and directories on the same filesystem as the specified + dir. --exclude PATTERN - Exclude files that match PATTERN. This argument can be added - multiple times to add more patterns. + Exclude files that match PATTERN. This argument can be added multiple + times to add more patterns. -X FILE, --exclude-from FILE - Exclude files that match any pattern in FILE. Patterns should be - separated by a newline. + Exclude files that match any pattern in FILE. Patterns should be sepa‐ + rated by a newline. KEYS @@ -56,22 +57,21 @@ KEYS a Toggle between showing disk usage and showing apparent size. - d Delete the selected file or directory. An error message will be - shown when the contents of the directory do not match or do not - exist anymore on the filesystem. + d Delete the selected file or directory. An error message will be shown + when the contents of the directory do not match or do not exist anymore + on the filesystem. t Toggle dirs before files when sorting. - g Toggle between showing percentage, graph, both, or none. Per- - centage is relative to the size of the current directory, graph - is relative to the largest item in the current directory. + g Toggle between showing percentage, graph, both, or none. Percentage is + relative to the size of the current directory, graph is relative to the + largest item in the current directory. - e Show/hide 'hidden' or 'excluded' files and directories. Please - note that even though you can't see the hidden files and direc- - tories, they are still there and they are still included in the - directory sizes. If you suspect that the totals shown at the - bottom of the screen are not correct, make sure you haven't - enabled this option. + e Show/hide 'hidden' or 'excluded' files and directories. Please note that + even though you can't see the hidden files and directories, they are + still there and they are still included in the directory sizes. If you + suspect that the totals shown at the bottom of the screen are not cor‐ + rect, make sure you haven't enabled this option. i Show information about the current selected item. @@ -81,46 +81,44 @@ KEYS HARD LINKS - Every disk usage analysis utility has its own way of (not) counting - hard links. There does not seem to be any universally agreed method of - handling hard links, and it is even inconsistent among different ver- - sions of ncdu. This section explains what each version of ncdu does. + Every disk usage analysis utility has its own way of (not) counting hard links. + There does not seem to be any universally agreed method of handling hard links, + and it is even inconsistent among different versions of ncdu. This section + explains what each version of ncdu does. - ncdu 1.5 and below does not support any hard link detection at all: - each link is considered a separate inode and its size is counted for - every link. This means that the displayed directory sizes are incorrect - when analyzing directories which contain hard links. + ncdu 1.5 and below does not support any hard link detection at all: each link is + considered a separate inode and its size is counted for every link. This means + that the displayed directory sizes are incorrect when analyzing directories + which contain hard links. - ncdu 1.6 has basic hard link detection: When a link to a previously - encountered inode is detected, the link is considered to have a file - size of zero bytes. Its size is not counted again, and the link is - indicated in the browser interface with a 'H' mark. The displayed - directory sizes are only correct when all links to an inode reside - within that directory. When this is not the case, the sizes may or may - not be correct, depending on which links were considered as "duplicate" - and which as "original". The indicated size of the topmost directory - (that is, the one specified on the command line upon starting ncdu) is - always correct. + ncdu 1.6 has basic hard link detection: When a link to a previously encountered + inode is detected, the link is considered to have a file size of zero bytes. + Its size is not counted again, and the link is indicated in the browser inter‐ + face with a 'H' mark. The displayed directory sizes are only correct when all + links to an inode reside within that directory. When this is not the case, the + sizes may or may not be correct, depending on which links were considered as + "duplicate" and which as "original". The indicated size of the topmost directory + (that is, the one specified on the command line upon starting ncdu) is always + correct. - ncdu 1.7 has improved hard link detection. Each file that has more than - two links has the "H" mark visible in the browser interface. Each hard - link is counted exactly once for every directory it appears in. The - indicated size of each directory is therefore, correctly, the sum of - the sizes of all unique inodes that can be found in that directory. - Note, however, that this may not always be same as the space that will - be reclaimed after deleting the directory, as some inodes may still be - accessible from hard links outside it. + ncdu 1.7 has improved hard link detection. Each file that has more than two + links has the "H" mark visible in the browser interface. Each hard link is + counted exactly once for every directory it appears in. The indicated size of + each directory is therefore, correctly, the sum of the sizes of all unique + inodes that can be found in that directory. Note, however, that this may not + always be same as the space that will be reclaimed after deleting the directory, + as some inodes may still be accessible from hard links outside it. BUGS - Directory hard links are not supported. They will not be detected as - being hard links, and will thus be scanned and counted multiple times. + Directory hard links are not supported. They will not be detected as being hard + links, and will thus be scanned and counted multiple times. - Some minor glitches may appear when displaying filenames that contain - multibyte or multicolumn characters. + Some minor glitches may appear when displaying filenames that contain multibyte + or multicolumn characters. - Please report any other bugs you may find at the bug tracker, which can - be found on the web site at http://dev.yorhel.nl/ncdu + Please report any other bugs you may find at the bug tracker, which can be found + on the web site at http://dev.yorhel.nl/ncdu AUTHOR @@ -132,4 +130,4 @@ SEE ALSO -ncdu-1.7 Aug 13, 2010 ncdu(1) +ncdu-1.8 Nov 3, 2011 ncdu(1) diff --git a/index.cgi b/index.cgi index 9cc57fd..1359b83 100755 --- a/index.cgi +++ b/index.cgi @@ -53,6 +53,7 @@ sub home { E; end; h2 'Updates'; + b '2011-11-03'; txt ' ncdc 1.5 and ncdu 1.8 released!'; br; b '2011-10-26'; txt ' ncdc 1.4 released!'; br; b '2011-10-19'; txt ' PGP-signed all releases of ncdu, ncdc and TUWF.'; br; b '2011-10-14'; txt ' ncdc 1.3 released!'; br; @@ -102,8 +103,8 @@ sub ncdu { E; br; br; b 'Latest version: '; - txt '1.7 ('; - $s->htmlDLLink('ncdu-1.7.tar.gz', 'download'); + txt '1.8 ('; + $s->htmlDLLink('ncdu-1.8.tar.gz', 'download'); txt ' - '; a href => '/ncdu/changes', 'changes'; txt ' - '; @@ -141,7 +142,7 @@ sub ncdu { br; br; txt 'Subscribe to '; - a href => 'http://freshmeat.net/projects/ncdu', 'freshmeat'; + a href => 'http://freecode.com/projects/ncdu', 'freecode'; txt ' or to '; a href => 'https://sourceforge.net/api/file/index/project-id/200175/mtime/desc/rss', 'this RSS feed at sf.net'; txt ' to receive notifications for new releases.'; @@ -187,6 +188,8 @@ sub ncduscr { my $s = shift; $s->htmlHeader(title => 'Screenshots', page => 'ncdu', tab => 'scr'); p; + txt 'Note: While these screenshots are from version 1.7, the latest version has only little visible changes.'; + br; br; txt 'Scanning...'; img src => '/img/ncduscan.png', style => 'margin: 5px 0 0 0; border: 1px solid #999', alt => 'Ncdu scanning a large directory.'; br;br; @@ -227,8 +230,8 @@ sub ncdc { h2 'Get ncdc!'; p; - b 'Latest version:'; txt ' 1.4 ('; - $s->htmlDLLink('ncdc-1.4.tar.gz', 'download'); + b 'Latest version:'; txt ' 1.5 ('; + $s->htmlDLLink('ncdc-1.5.tar.gz', 'download'); txt ' - '; a href => '/ncdc/changes', 'changes'; txt ' - '; a href => 'https://sourceforge.net/projects/ncdc/files/ncdc/', 'mirror'; txt ')'; br; @@ -291,8 +294,8 @@ sub ncdc { may have all of these installed already.
Ncdc has been developed on Arch Linux, but I have received reports from people who successfully used it on CentOS, Debian, FreeBSD, Gentoo, Mac OS - X, Solaris and Ubuntu. It should be fairly trivial to port to other - POSIX-like systems.
+ X, OpenSUSE, Solaris and Ubuntu. It should be fairly trivial to port to + other POSIX-like systems.
Ncdc is entirely written in C and available under a liberal MIT license. E; end; @@ -969,6 +972,8 @@ sub htmlFooter { a href => 'http://g.blicky.net', 'git'; txt ' - '; a href => 'http://svn.blicky.net', 'svn'; + txt ' - '; + a href => 'http://pgp.mit.edu:11371/pks/lookup?search=0x8c2739fa', 'pgp'; end; end 'body'; end 'html';